Changeset 1845
- Timestamp:
- 04/20/08 02:51:18
- Files:
-
- releases/bedework-3.4.1.1/deployment/websubmit/webapp/resources/demoskins/default/default/default.xsl (modified) (5 diffs)
- releases/bedework-3.4.1.1/deployment/websubmit/webapp/resources/demoskins/resources/bedeworkEventForm.js (modified) (2 diffs)
- releases/bedework-3.4.1.1/deployment/websubmit/webapp/resources/demoskins/resources/bedeworkXProperties.js (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
releases/bedework-3.4.1.1/deployment/websubmit/webapp/resources/demoskins/default/default/default.xsl
r1842 r1845 107 107 <xsl:if test="/bedework/page = 'editEvent' and 108 108 normalize-space(/bedework/formElements/form/xproperties/xproperty[@name='X-BEDEWORK-SUBMIT-COMMENT']/value) != ''"> 109 <xsl:attribute name="onload">initRXDates();initXProperties(); getComments('standardForm','<xsl:value-of select="/bedework/formElements/form/xproperties/xproperty[@name='X-BEDEWORK-SUBMIT-COMMENT']/value"/>');</xsl:attribute>109 <xsl:attribute name="onload">initRXDates();initXProperties();</xsl:attribute> 110 110 </xsl:if> 111 111 <div id="bedework"><!-- main wrapper div --> … … 906 906 <p> 907 907 <label for="commentLocationAddress">Address: </label> 908 <input type="text" name="commentLocationAddress" id="bwCommentLocationAddress"/> 908 <input type="text" name="commentLocationAddress" id="bwCommentLocationAddress"> 909 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-LOCATION-ADDRESS']"/></xsl:attribute> 910 </input> 909 911 </p> 910 912 <p> 911 <label for="commentLocationSubaddress"><em>Sub-address:</em> </label><input type="text" name="commentLocationSubaddress"/> 913 <label for="commentLocationSubaddress"><em>Sub-address:</em> </label> 914 <input type="text" name="commentLocationSubaddress" id="commentLocationSubaddress"> 915 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-LOCATION-SUBADDRESS']"/></xsl:attribute> 916 </input> 912 917 <span class="note"> optional</span> 913 918 </p> 914 919 <p> 915 <label for="commentLocationURL"><em>URL:</em> </label><input type="text" name="commentLocationURL"/> 920 <label for="commentLocationURL"><em>URL:</em> </label> 921 <input type="text" name="commentLocationURL" id="commentLocationURL"> 922 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-LOCATION-URL']"/></xsl:attribute> 923 </input> 916 924 <span class="note"> optional</span> 917 925 </p> … … 937 945 <p> 938 946 <label for="commentContactName">Organization Name: </label> 939 <input type="text" name="commentContactName" id="bwCommentContactName" size="40"/> 947 <input type="text" name="commentContactName" id="bwCommentContactName" size="40"> 948 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-CONTACT-NAME']"/></xsl:attribute> 949 </input> 940 950 <span class="note"> Please limit contacts to organizations, not individuals.</span> 941 951 </p> 942 952 <p> 943 <label for="commentContactPhone"><em>Phone:</em> </label><input type="text" name="commentContactPhone"/> 953 <label for="commentContactPhone"><em>Phone:</em> </label> 954 <input type="text" name="commentContactPhone"> 955 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-CONTACT-PHONE']"/></xsl:attribute> 956 </input> 944 957 <span class="note"> optional</span> 945 958 </p> 946 959 <p> 947 <label for="commentContactURL"><em>URL:</em> </label><input type="text" name="commentContactURL"/> 960 <label for="commentContactURL"><em>URL:</em> </label> 961 <input type="text" name="commentContactURL"> 962 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-CONTACT-URL']"/></xsl:attribute> 963 </input> 948 964 <span class="note"> optional</span> 949 965 </p> 950 966 <p> 951 <label for="commentContactEmail"><em>Email:</em> </label><input type="text" name="commentContactEmail"/> 967 <label for="commentContactEmail"><em>Email:</em> </label> 968 <input type="text" name="commentContactEmail"> 969 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-CONTACT-EMAIL']"/></xsl:attribute> 970 </input> 952 971 <span class="note"> optional</span> 953 972 </p> … … 994 1013 <p> 995 1014 <label for="commentCategories">Category suggestion: </label> 996 <input type="text" name="commentCategories" size="30"/> 1015 <input type="text" name="commentCategories" size="30"> 1016 <xsl:attribute name="value"><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/parameters/node()[name()='X-BEDEWORK-PARAM-CATEGORIES']"/></xsl:attribute> 1017 </input> 997 1018 </p> 998 1019 </div> … … 1010 1031 <div id="bwCommentNotes"> 1011 1032 Please supply any final notes or instructions regarding your event:<br/> 1012 <textarea name="commentNotes" cols="60" rows="4"> </textarea> 1033 <!-- note: don't remove the #160 from the textarea or browsers will see it as a closed tag when empty --> 1034 <textarea name="commentNotes" cols="60" rows="4"><!-- 1035 --><xsl:value-of select="form/xproperties/node()[name()='X-BEDEWORK-SUBMIT-COMMENT']/values/text"/> <!-- 1036 --></textarea> 1013 1037 </div> 1014 1038 <div class="eventSubmitButtons"> releases/bedework-3.4.1.1/deployment/websubmit/webapp/resources/demoskins/resources/bedeworkEventForm.js
r1842 r1845 245 245 } 246 246 setComments(formObj); 247 setRecurrence(formObj);247 //setRecurrence(formObj); 248 248 setBedeworkXProperties(formObj,submitter); 249 setAccessHow(formObj,1);249 //setAccessHow(formObj,1); 250 250 //setAccessAcl(formObj); 251 251 } … … 265 265 function setComments(formObj) { 266 266 // set the submission comments (location, contact, and category suggestions) 267 // in a parsable format that can be filtered on output. 268 269 var comment = ""; 270 comment += formObj["commentLocationAddress"].value + "\t"; 271 comment += formObj["commentLocationSubaddress"].value + "\t"; 272 comment += formObj["commentLocationURL"].value + "\t"; 273 comment += formObj["commentContactName"].value + "\t"; 274 comment += formObj["commentContactPhone"].value + "\t"; 275 comment += formObj["commentContactURL"].value + "\t"; 276 comment += formObj["commentContactEmail"].value + "\t"; 277 comment += formObj["commentCategories"].value + "\t"; 278 comment += formObj["commentNotes"].value; 279 280 formObj["xbwsubmitcomment"].value = comment; 267 // as an xproperty. Relies on bedeworkXProperties.js 268 269 bwXProps.update(bwXPropertySubmitComment, 270 [[bwXParamLocationAddress,formObj["commentLocationAddress"].value], 271 [bwXParamLocationSubAddress,formObj["commentLocationSubaddress"].value], 272 [bwXParamLocationURL,formObj["commentLocationURL"].value], 273 [bwXParamContactName,formObj["commentContactName"].value], 274 [bwXParamContactPhone,formObj["commentContactPhone"].value], 275 [bwXParamContactURL,formObj["commentContactURL"].value], 276 [bwXParamContactEmail,formObj["commentContactEmail"].value], 277 [bwXParamCategories,formObj["commentCategories"].value]], 278 formObj["commentNotes"].value,true); 281 279 } 282 280 function getComments(formId,comment) { releases/bedework-3.4.1.1/deployment/websubmit/webapp/resources/demoskins/resources/bedeworkXProperties.js
r1844 r1845 38 38 var bwXPropertySubmittedBy = "X-BEDEWORK-SUBMITTEDBY"; 39 39 var bwXPropertySubmitComment = "X-BEDEWORK-SUBMIT-COMMENT"; 40 40 var bwXParamLocationAddress = "X-BEDEWORK-PARAM-LOCATION-ADDRESS"; 41 var bwXParamLocationSubAddress = "X-BEDEWORK-PARAM-LOCATION-SUBADDRESS"; 42 var bwXParamLocationURL = "X-BEDEWORK-PARAM-LOCATION-URL"; 43 var bwXParamContactName = "X-BEDEWORK-PARAM-CONTACT-NAME"; 44 var bwXParamContactPhone = "X-BEDEWORK-PARAM-CONTACT-PHONE"; 45 var bwXParamContactURL = "X-BEDEWORK-PARAM-CONTACT-URL"; 46 var bwXParamContactEmail = "X-BEDEWORK-PARAM-CONTACT-EMAIL"; 47 var bwXParamCategories = "X-BEDEWORK-PARAM-CATEGORIES"; 41 48 42 49 // ======================================================================== … … 61 68 if (this.params.length) { 62 69 for (var i = 0; i < this.params.length; i++) { 63 curXparams += ";" + this.params[i][0] + "= " + this.params[i][1];70 curXparams += ";" + this.params[i][0] + "=\"" + this.params[i][1] + "\""; 64 71 } 65 72 } … … 77 84 78 85 this.update = function(name, params, value, isUnique) { 86 // strip out any double quotes in the parameter values: 87 if (params.length) { 88 for (var i = 0; i < params.length; i++) { 89 var strippedParamValue = ""; 90 for (var j = 0; j < params[i][1].length; j++) { 91 var c = params[i][1][j]; 92 if (c != '"') { 93 strippedParamValue += c; 94 } 95 } 96 params[i][1] = strippedParamValue; 97 } 98 } 99 // add or update the xproperty: 79 100 var xprop = new BwXProperty(name, params, value); 80 101 if (isUnique && this.contains(name)) {
