Changeset 1509
- Timestamp:
- 08/11/07 00:29:17
- Files:
-
- trunk/deployment/solr/conf/schema.xml (modified) (2 diffs)
- trunk/deployment/webuser/webapp/resources/demoskins/default/default/default.xsl (modified) (3 diffs)
- trunk/deployment/webuser/webapp/resources/demoskins/resources/bedework.js (modified) (5 diffs)
- trunk/deployment/webuser/webapp/resources/demoskins/resources/bedeworkEventForm.js (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/deployment/solr/conf/schema.xml
r1504 r1509 250 250 required="false" /> 251 251 252 <field name="summary" type="text" indexed="true" stored="true"/> 253 <field name="description" type="text" indexed="true" stored="true"/> 252 254 <field name="location" type="text" indexed="true" stored="true"/> 253 255 254 256 <!-- These are really date fields and should be formatted as above --> 255 <field name="creat or" type="text" indexed="true" stored="true"/>257 <field name="created" type="text" indexed="true" stored="true"/> 256 258 <field name="lastmod" type="text" indexed="true" stored="true"/> 257 259 <field name="startDate" type="text" indexed="true" stored="true"/> 258 260 <field name="endDate" type="text" indexed="true" stored="true"/> 259 261 <field name="dueDate" type="text" indexed="true" stored="true"/> 262 263 <field name="creator" type="text" indexed="true" stored="true"/> 260 264 261 265 <field name="category" type="text" indexed="true" stored="true" multiValued="true"/> … … 304 308 305 309 <copyField source="created" dest="text"/> 310 <copyField source="summary" dest="text"/> 306 311 <copyField source="description" dest="text"/> 307 <copyField source="lastmod" dest="nameSort"/> 308 <copyField source="summary" dest="alphaNameSort"/> 312 <copyField source="lastmod" dest="text"/> 309 313 <copyField source="startDate" dest="text"/> 310 314 <copyField source="endDate" dest="text"/> 311 315 <copyField source="dueDate" dest="text"/> 312 <copyField source="category" dest=" category"/>316 <copyField source="category" dest="text"/> 313 317 314 318 <!-- <copyField source="manu" dest="manu_exact"/> --> trunk/deployment/webuser/webapp/resources/demoskins/default/default/default.xsl
r1508 r1509 3148 3148 </select> 3149 3149 <xsl:text> </xsl:text> 3150 3150 3151 3151 <select name="tzid" id="rdateTzid" class="timezones"> 3152 3152 <xsl:if test="form/floating/input/@checked='checked'"><xsl:attribute name="disabled">disabled</xsl:attribute></xsl:if> … … 3177 3177 store as UTC 3178 3178 </div> 3179 3180 <!-- if there are no recur ence dates, the following table will show -->3181 <table cellspacing="0" id="bwCurrentRdates">3179 3180 <!-- if there are no recurrence dates, the following table will show --> 3181 <table cellspacing="0" class="invisible" id="bwCurrentRdatesNone"> 3182 3182 <tr><th>Recurrence Dates</th></tr> 3183 3183 <tr><td>No recurrence dates</td></tr> 3184 3184 </table> 3185 3185 3186 3186 <!-- if there are no recurence dates, the following table will show --> 3187 <table cellspacing="0" id="bwCurrentRdates">3187 <table cellspacing="0" class="invisible" id="bwCurrentRdates"> 3188 3188 <tr> 3189 3189 <th colspan="4">Recurrence Dates</th> … … 3196 3196 </tr> 3197 3197 </table> 3198 3198 3199 3199 <!-- if there are no recurence dates, the following table will show --> 3200 <table cellspacing="0" id="bwCurrentExdatesNone">3200 <table cellspacing="0" class="invisible" id="bwCurrentExdatesNone"> 3201 3201 <tr><th>Exception Dates</th></tr> 3202 3202 <tr><td>No exception dates</td></tr> 3203 3203 </table> 3204 3204 3205 3205 <!-- if there are no recurence dates, the following table will show --> 3206 <table cellspacing="0" id="bwCurrentExdates">3206 <table cellspacing="0" class="invisible" id="bwCurrentExdates"> 3207 3207 <tr> 3208 3208 <th colspan="4">Exception Dates</th> trunk/deployment/webuser/webapp/resources/demoskins/resources/bedework.js
r1439 r1509 29 29 30 30 function changeClass(id, newClass) { 31 identity = document.getElementById(id); 31 var identity = document.getElementById(id); 32 if (identity == null) { 33 alert("No element with id: " + id + " to set to class: " + newClass); 34 } 32 35 identity.className=newClass; 33 36 } 37 34 38 // show hide items using a checkbox 35 39 function swapVisible(obj,id) { … … 58 62 } 59 63 } 60 // show and hide an item based on its current 64 // show and hide an item based on its current 61 65 // visibility; if visible, hide it; if invisible 62 66 // show it. … … 70 74 // Toggle action icons box visibility at the selected position and 71 75 // set any open action icon boxes to invisible. 72 // Action icon boxes are used in the calendar grid - their ids are 76 // Action icon boxes are used in the calendar grid - their ids are 73 77 // built from a prefix plus the day number; the box identified by zero is the topmost box 74 78 // associated with the "add..." button. Id's will therefore be prefix-0 through … … 148 152 // launch the calSelect pop-up window for selecting a calendar when creating, 149 153 // editing, and importing events 150 // DEPRECATED - can't use pop-ups in current portal environments in a 154 // DEPRECATED - can't use pop-ups in current portal environments in a 151 155 // portal-agnostic way 152 156 function launchCalSelectWindow(URL) { … … 160 164 } 161 165 // used to update the calendar in various forms from 162 // the calSelect pop-up widget. We must do three things: update the hidden 166 // the calSelect pop-up widget. We must do three things: update the hidden 163 167 // calendar input field, update the displayed text, and close widget 164 168 function updateEventFormCalendar(newCalPath,calDisplay) { trunk/deployment/webuser/webapp/resources/demoskins/resources/bedeworkEventForm.js
r1508 r1509 59 59 } 60 60 61 /* row: current table row 61 /* varName: NOT GOOD - name of object 62 * reqPar: request par for hidden field 63 * row: current table row 62 64 * rdi: index of rdate fro delete 63 65 */ 64 this.toFormRow = function( reqPar, row, rdi) {66 this.toFormRow = function(varName, reqPar, row, rdi) { 65 67 row.insertCell(0).appendChild(document.createTextNode(this.date)); 66 68 row.insertCell(1).appendChild(document.createTextNode(this.time)); 67 69 row.insertCell(2).appendChild(document.createTextNode(this.tzid)); 68 row.insertCell(3).innerHTML = "<a href=\"javascript: bwRdates.deleteRdate('" +70 row.insertCell(3).innerHTML = "<a href=\"javascript:" + varName + ".deleteDate('" + 69 71 rdi + "')\">" + rdateDeleteStr + "</a>" + 70 "<input type='hidden' name='" + reqPar + 72 "<input type='hidden' name='" + reqPar + 71 73 "' value='" + this.format() + "'/>"; 72 74 } 73 75 74 76 this.format= function() { 75 77 var res = this.date + "\t" + this.time + "\t"; 76 78 77 79 if (this.tzid != null) { 78 80 res += "\t" + this.tzid; 79 81 } 80 82 81 83 return res; 82 84 } 83 85 84 86 this.equals = function(that) { 85 return (that.val = this.val) && (that.tzid = this.tzid); 86 } 87 } 88 89 var bwRdates = new BwREXdates("rdate", "bwCurrentRdates", "bwCurrentRdatesNone", "visible", "invisible", 2); 90 var bwExdates = new BwREXdates("exdate", "bwCurrentExdates", "bwCurrentExdatesNone", "visible", "invisible", 2); 91 92 function BwREXdates(reqPar, tableId, noDatesId, visibleClass, invisibleClass, numHeaderRows) { 93 var rdates = new Array(); 94 87 return this.compareTo(that) == 0; 88 } 89 90 this.compareTo = function(that) { 91 var res = compareTo(that.date, this.date); 92 if (res != 0) { 93 return res; 94 } 95 96 res = compareTo(that.time, this.time); 97 if (res != 0) { 98 return res; 99 } 100 101 return compareTo(that.tzid, this.tzid); 102 } 103 } 104 105 function compareTo(thys, that) { 106 if (that < thys) { 107 return -1; 108 } 109 110 if (that > thys) { 111 return 1; 112 } 113 114 return 0; 115 } 116 117 function sortCompare(thys, that) { 118 return thys.compareTo(that); 119 } 120 121 var bwRdates = new BwREXdates("bwRdates", "rdate", "bwCurrentRdates", "bwCurrentRdatesNone", 122 "visible", "invisible", 2); 123 var bwExdates = new BwREXdates("bwExdates", "exdate", "bwCurrentExdates", "bwCurrentExdatesNone", 124 "visible", "invisible", 2); 125 126 /** Manipulate table of exception or recurrence dates. 127 * 128 * @param varName: NOT GOOD - name of object 129 * @param reqPar: request parameter we gernate (multi-valued) 130 * @param tableId: id of table we are manipulating 131 * @param noDatesId: some info to display when we have nothing 132 * @param visibleClass: class to set to make something visible 133 * @param invisibleClass: class to set to make something invisible 134 * @param numHeaderRows: Number of header rows in the table. 135 */ 136 function BwREXdates(varName, reqPar, tableId, noDatesId, 137 visibleClass, invisibleClass, numHeaderRows) { 138 var dates = new Array(); 139 140 this.varName = varName; 95 141 this.reqPar = reqPar; 96 142 this.tableId = tableId; 143 this.noDatesId = noDatesId; 144 this.visibleClass = visibleClass; 145 this.invisibleClass = invisibleClass; 146 this.numHeaderRows = numHeaderRows; 97 147 98 148 /* val: String: internal date … … 104 154 105 155 if (!this.contains(newRdate)) { 106 rdates.push(newRdate);156 dates.push(newRdate); 107 157 } 108 158 } 109 159 110 160 this.contains = function(rdate) { 111 for (var j = 0; j < rdates.length; j++) {112 var curRdate = rdates[j];161 for (var j = 0; j < dates.length; j++) { 162 var curRdate = dates[j]; 113 163 if (curRdate.equals(rdate)) { 114 164 return true; … … 119 169 } 120 170 121 // Update the list - expects the browser form object171 // Update the list - 122 172 this.update = function(date, time, allDay, floating, utc, tzid) { 123 173 this.addRdate(date, time, allDay, floating, utc, tzid); … … 127 177 } 128 178 129 this.delete Rdate = function(index) {130 rdates.splice(index, 1);179 this.deleteDate = function(index) { 180 dates.splice(index, 1); 131 181 132 182 // redraw the display … … 138 188 try { 139 189 // get the table body 140 var rdTableBody = document.getElementById(t his.tableId).tBodies[0];190 var rdTableBody = document.getElementById(tableId).tBodies[0]; 141 191 142 192 // remove existing rows 143 for (i = rdTableBody.rows.length - 1; i >= 0; i--) {193 for (i = rdTableBody.rows.length - 1; i >= numHeaderRows; i--) { 144 194 rdTableBody.deleteRow(i); 145 195 } 146 196 197 dates.sort(sortCompare); 198 147 199 // recreate the table rows 148 for (var j = 0; j < rdates.length; j++) { 149 var curRdate = rdates[j]; 150 var tr = rdTableBody.insertRow(j); 151 152 curRdate.toFormRow(this.reqPar, tr, j); 200 for (var j = 0; j < dates.length; j++) { 201 var curRdate = dates[j]; 202 var tr = rdTableBody.insertRow(j + numHeaderRows); 203 204 curRdate.toFormRow(varName, reqPar, tr, j); 205 } 206 207 if (dates.length == 0) { 208 changeClass(tableId, invisibleClass); 209 changeClass(noDatesId, visibleClass); 210 } else { 211 changeClass(tableId, visibleClass); 212 changeClass(noDatesId, invisibleClass); 153 213 } 154 214 } catch (e) {
