| 3298 | | <!-- event form submenu --> |
|---|
| | 3302 | <xsl:if test="/bedework/attendees/attendee"> |
|---|
| | 3303 | <table id="attendees" class="widget" cellspacing="0"> |
|---|
| | 3304 | <tr> |
|---|
| | 3305 | <th colspan="4">Attendees</th> |
|---|
| | 3306 | </tr> |
|---|
| | 3307 | <!--<tr> |
|---|
| | 3308 | <td>attendee</td> |
|---|
| | 3309 | <td>role</td> |
|---|
| | 3310 | <td>status</td> |
|---|
| | 3311 | </tr>--> |
|---|
| | 3312 | <xsl:for-each select="/bedework/attendees/attendee"> |
|---|
| | 3313 | <xsl:sort select="cn" order="ascending" case-order="upper-first"/> |
|---|
| | 3314 | <xsl:sort select="attendeeUri" order="ascending" case-order="upper-first"/> |
|---|
| | 3315 | <xsl:variable name="attendeeUri" select="attendeeUri"/> |
|---|
| | 3316 | <tr> |
|---|
| | 3317 | <td class="trash"> |
|---|
| | 3318 | <a href="{$event-attendeesForEvent}&uri={$attendeeUri}&attendee=true&delete=true" title="remove"> |
|---|
| | 3319 | <img src="{$resourcesRoot}/resources/trashIcon.gif" width="13" height="13" border="0" alt="remove"/> |
|---|
| | 3320 | </a> |
|---|
| | 3321 | </td> |
|---|
| | 3322 | <td> |
|---|
| | 3323 | <a href="{$attendeeUri}"> |
|---|
| | 3324 | <xsl:choose> |
|---|
| | 3325 | <xsl:when test="cn != ''"> |
|---|
| | 3326 | <xsl:value-of select="cn"/> |
|---|
| | 3327 | </xsl:when> |
|---|
| | 3328 | <xsl:otherwise> |
|---|
| | 3329 | <xsl:value-of select="attendeeUri"/> |
|---|
| | 3330 | </xsl:otherwise> |
|---|
| | 3331 | </xsl:choose> |
|---|
| | 3332 | </a> |
|---|
| | 3333 | </td> |
|---|
| | 3334 | <td class="role"> |
|---|
| | 3335 | <xsl:value-of select="role"/> |
|---|
| | 3336 | </td> |
|---|
| | 3337 | <td class="status"> |
|---|
| | 3338 | <xsl:value-of select="partstat"/> |
|---|
| | 3339 | </td> |
|---|
| | 3340 | </tr> |
|---|
| | 3341 | </xsl:for-each> |
|---|
| | 3342 | </table> |
|---|
| | 3343 | </xsl:if> |
|---|
| | 3344 | |
|---|
| | 3345 | <xsl:if test="/bedework/recipients/recipient"> |
|---|
| | 3346 | <table id="recipients" class="widget" cellspacing="0"> |
|---|
| | 3347 | <tr> |
|---|
| | 3348 | <th colspan="2">Recipients</th> |
|---|
| | 3349 | </tr> |
|---|
| | 3350 | <xsl:for-each select="/bedework/recipients/recipient"> |
|---|
| | 3351 | <xsl:variable name="recipientUri" select="."/> |
|---|
| | 3352 | <tr> |
|---|
| | 3353 | <td class="trash"> |
|---|
| | 3354 | <a href="{$event-attendeesForEvent}&uri={$recipientUri}&recipient=true&delete=true" title="remove"> |
|---|
| | 3355 | <img src="{$resourcesRoot}/resources/trashIcon.gif" width="13" height="13" border="0" alt="remove"/> |
|---|
| | 3356 | </a> |
|---|
| | 3357 | </td> |
|---|
| | 3358 | <td> |
|---|
| | 3359 | <a href="{$recipientUri}"> |
|---|
| | 3360 | <xsl:value-of select="."/> |
|---|
| | 3361 | </a> |
|---|
| | 3362 | </td> |
|---|
| | 3363 | </tr> |
|---|
| | 3364 | </xsl:for-each> |
|---|
| | 3365 | </table> |
|---|
| | 3366 | </xsl:if> |
|---|
| | 3367 | |
|---|
| 3304 | | <table cellspacing="0"> |
|---|
| 3305 | | <tr> |
|---|
| 3306 | | <td> |
|---|
| 3307 | | <input name="uri" width="40"/> |
|---|
| 3308 | | <input type="submit" value="add" /> |
|---|
| 3309 | | <br/> |
|---|
| 3310 | | <input type="checkbox" name="recipient" value="true" checked="checked"/> recipient |
|---|
| 3311 | | <input type="checkbox" name="attendee" value="true" checked="checked"/> attendee |
|---|
| 3312 | | </td> |
|---|
| 3313 | | <td> |
|---|
| 3314 | | Role: |
|---|
| 3315 | | <select name="role"> |
|---|
| 3316 | | <option value="REQ-PARTICIPANT">required participant</option> |
|---|
| 3317 | | <option value="OPT-PARTICIPANT">optional participant</option> |
|---|
| 3318 | | <option value="CHAIR">chair</option> |
|---|
| 3319 | | <option value="NON-PARTICIPANT">non-participant</option> |
|---|
| 3320 | | </select><br/> |
|---|
| 3321 | | Status: |
|---|
| 3322 | | <select name="partstat"> |
|---|
| 3323 | | <option value="NEEDS-ACTION">needs action</option> |
|---|
| 3324 | | <option value="ACCEPTED">accepted</option> |
|---|
| 3325 | | <option value="DECLINED">declined</option> |
|---|
| 3326 | | <option value="TENTATIVE">tentative</option> |
|---|
| 3327 | | <option value="DELEGATED">delegated</option> |
|---|
| 3328 | | </select> |
|---|
| 3329 | | </td> |
|---|
| 3330 | | </tr> |
|---|
| 3331 | | </table> |
|---|
| 3332 | | |
|---|
| 3333 | | <xsl:if test="/bedework/attendees/attendee"> |
|---|
| 3334 | | <table id="attendees" class="widget" cellspacing="0"> |
|---|
| | 3372 | <input name="uri" width="40"/> |
|---|
| | 3373 | <input type="submit" value="add" /> |
|---|
| | 3374 | <br/> |
|---|
| | 3375 | <input type="checkbox" name="recipient" value="true" checked="checked"/> recipient |
|---|
| | 3376 | <input type="checkbox" name="attendee" value="true" checked="checked"/> attendee |
|---|
| | 3377 | <br/> |
|---|
| | 3378 | Role: |
|---|
| | 3379 | <select name="role"> |
|---|
| | 3380 | <option value="REQ-PARTICIPANT">required participant</option> |
|---|
| | 3381 | <option value="OPT-PARTICIPANT">optional participant</option> |
|---|
| | 3382 | <option value="CHAIR">chair</option> |
|---|
| | 3383 | <option value="NON-PARTICIPANT">non-participant</option> |
|---|
| | 3384 | </select> |
|---|
| | 3385 | <br/> |
|---|
| | 3386 | Status: |
|---|
| | 3387 | <select name="partstat"> |
|---|
| | 3388 | <option value="NEEDS-ACTION">needs action</option> |
|---|
| | 3389 | <option value="ACCEPTED">accepted</option> |
|---|
| | 3390 | <option value="DECLINED">declined</option> |
|---|
| | 3391 | <option value="TENTATIVE">tentative</option> |
|---|
| | 3392 | <option value="DELEGATED">delegated</option> |
|---|
| | 3393 | </select> |
|---|
| | 3394 | |
|---|
| | 3395 | <xsl:for-each select="/bedework/freebusy"> |
|---|
| | 3396 | <!-- there's only one collection of freebusy; this for-each is |
|---|
| | 3397 | being used to pick out just the freebusy node and |
|---|
| | 3398 | shorten the select statements below. --> |
|---|
| | 3399 | <xsl:variable name="currentTimezone">America/Los_Angeles</xsl:variable> |
|---|
| | 3400 | <xsl:variable name="formattedStartDate"> |
|---|
| | 3401 | <xsl:value-of select="substring(start,1,4)"/>-<xsl:value-of select="number(substring(start,5,2))"/>-<xsl:value-of select="number(substring(start,7,2))"/> |
|---|
| | 3402 | </xsl:variable> |
|---|
| | 3403 | <xsl:variable name="formattedEndDate"> |
|---|
| | 3404 | <xsl:value-of select="substring(end,1,4)"/>-<xsl:value-of select="number(substring(end,5,2))"/>-<xsl:value-of select="number(substring(end,7,2))"/> |
|---|
| | 3405 | </xsl:variable> |
|---|
| | 3406 | |
|---|
| | 3407 | <table id="freeBusyAgg"> |
|---|
| 3336 | | <th colspan="4">Attendees</th> |
|---|
| | 3409 | <td></td> |
|---|
| | 3410 | <th colspan="24" class="left"> |
|---|
| | 3411 | Freebusy for |
|---|
| | 3412 | <span class="who"> |
|---|
| | 3413 | <xsl:choose> |
|---|
| | 3414 | <xsl:when test="who != ''"> |
|---|
| | 3415 | <xsl:value-of select="who"/> |
|---|
| | 3416 | </xsl:when> |
|---|
| | 3417 | <xsl:otherwise> |
|---|
| | 3418 | all attendees |
|---|
| | 3419 | </xsl:otherwise> |
|---|
| | 3420 | </xsl:choose> |
|---|
| | 3421 | </span> |
|---|
| | 3422 | </th> |
|---|
| | 3423 | <!--<th colspan="32" class="right"> |
|---|
| | 3424 | <xsl:value-of select="$formattedStartDate"/> to <xsl:value-of select="$formattedEndDate"/> |
|---|
| | 3425 | <select name="timezone" id="timezonesDropDown" onchange="submit()"> |
|---|
| | 3426 | <xsl:for-each select="/bedework-fbaggregator/timezones/tzid"> |
|---|
| | 3427 | <option> |
|---|
| | 3428 | <xsl:attribute name="value"><xsl:value-of select="."/></xsl:attribute> |
|---|
| | 3429 | <xsl:if test="node() = $currentTimezone"><xsl:attribute name="selected">selected</xsl:attribute></xsl:if> |
|---|
| | 3430 | <xsl:value-of select="."/> |
|---|
| | 3431 | </option> |
|---|
| | 3432 | </xsl:for-each> |
|---|
| | 3433 | </select> |
|---|
| | 3434 | </th>--> |
|---|
| 3338 | | <!--<tr> |
|---|
| 3339 | | <td>attendee</td> |
|---|
| 3340 | | <td>role</td> |
|---|
| 3341 | | <td>status</td> |
|---|
| 3342 | | </tr>--> |
|---|
| 3343 | | <xsl:for-each select="/bedework/attendees/attendee"> |
|---|
| 3344 | | <xsl:sort select="cn" order="ascending" case-order="upper-first"/> |
|---|
| 3345 | | <xsl:sort select="attendeeUri" order="ascending" case-order="upper-first"/> |
|---|
| 3346 | | <xsl:variable name="attendeeUri" select="attendeeUri"/> |
|---|
| | 3436 | <tr> |
|---|
| | 3437 | <td> </td> |
|---|
| | 3438 | <td colspan="12" class="morning">AM</td> |
|---|
| | 3439 | <td colspan="12" class="evening">PM</td> |
|---|
| | 3440 | </tr> |
|---|
| | 3441 | <tr> |
|---|
| | 3442 | <td> </td> |
|---|
| | 3443 | <xsl:for-each select="day[position()=1]/period"> |
|---|
| | 3444 | <td class="timeLabels"> |
|---|
| | 3445 | <xsl:choose> |
|---|
| | 3446 | <xsl:when test="number(start) mod 200 = 0"> |
|---|
| | 3447 | <xsl:call-template name="timeFormatter"> |
|---|
| | 3448 | <xsl:with-param name="timeString" select="start"/> |
|---|
| | 3449 | <xsl:with-param name="showMinutes">no</xsl:with-param> |
|---|
| | 3450 | <xsl:with-param name="showAmPm">no</xsl:with-param> |
|---|
| | 3451 | </xsl:call-template> |
|---|
| | 3452 | </xsl:when> |
|---|
| | 3453 | <xsl:otherwise> |
|---|
| | 3454 |   |
|---|
| | 3455 | </xsl:otherwise> |
|---|
| | 3456 | </xsl:choose> |
|---|
| | 3457 | </td> |
|---|
| | 3458 | </xsl:for-each> |
|---|
| | 3459 | </tr> |
|---|
| | 3460 | <xsl:for-each select="day"> |
|---|
| 3348 | | <td class="trash"> |
|---|
| 3349 | | <a href="{$event-attendeesForEvent}&uri={$attendeeUri}&attendee=true&delete=true" title="remove"> |
|---|
| 3350 | | <img src="{$resourcesRoot}/resources/trashIcon.gif" width="13" height="13" border="0" alt="remove"/> |
|---|
| 3351 | | </a> |
|---|
| 3352 | | </td> |
|---|
| 3353 | | <td> |
|---|
| 3354 | | <a href="{$attendeeUri}"> |
|---|
| 3355 | | <xsl:choose> |
|---|
| 3356 | | <xsl:when test="cn != ''"> |
|---|
| 3357 | | <xsl:value-of select="cn"/> |
|---|
| 3358 | | </xsl:when> |
|---|
| 3359 | | <xsl:otherwise> |
|---|
| 3360 | | <xsl:value-of select="attendeeUri"/> |
|---|
| 3361 | | </xsl:otherwise> |
|---|
| 3362 | | </xsl:choose> |
|---|
| 3363 | | </a> |
|---|
| 3364 | | </td> |
|---|
| 3365 | | <td class="role"> |
|---|
| 3366 | | <xsl:value-of select="role"/> |
|---|
| 3367 | | </td> |
|---|
| 3368 | | <td class="status"> |
|---|
| 3369 | | <xsl:value-of select="partstat"/> |
|---|
| 3370 | | </td> |
|---|
| | 3462 | <td class="dayDate"><xsl:value-of select="number(substring(dateString,5,2))"/>-<xsl:value-of select="number(substring(dateString,7,2))"/></td> |
|---|
| | 3463 | <xsl:for-each select="period"> |
|---|
| | 3464 | <xsl:variable name="startTime" select="start"/> |
|---|
| | 3465 | <!-- the start date for the add event link is a concat of the day's date plus the period's time (+ seconds)--> |
|---|
| | 3466 | <xsl:variable name="startDate"><xsl:value-of select="../dateString"/>T<xsl:value-of select="start"/>00</xsl:variable> |
|---|
| | 3467 | <xsl:variable name="meetingDuration" select="length"/> |
|---|
| | 3468 | <td> |
|---|
| | 3469 | <xsl:attribute name="class"> |
|---|
| | 3470 | <xsl:choose> |
|---|
| | 3471 | <xsl:when test="fbtype = '0'">busy</xsl:when> |
|---|
| | 3472 | <xsl:when test="fbtype = '3'">tentative</xsl:when> |
|---|
| | 3473 | <xsl:otherwise>free</xsl:otherwise> |
|---|
| | 3474 | </xsl:choose> |
|---|
| | 3475 | </xsl:attribute> |
|---|
| | 3476 | <a href="{$initEvent}&meetingStartdt={$startDate}&meetingDuration={$meetingDuration}"> |
|---|
| | 3477 | <xsl:choose> |
|---|
| | 3478 | <xsl:when test="((numBusy > 0) and (numBusy < 9)) or ((numTentative > 0) and (numTentative < 9)) and (number(numBusy) + number(numTentative) < 9)"> |
|---|
| | 3479 | <xsl:value-of select="number(numBusy) + number(numTentative)"/> |
|---|
| | 3480 | </xsl:when> |
|---|
| | 3481 | <xsl:otherwise>*</xsl:otherwise> |
|---|
| | 3482 | </xsl:choose> |
|---|
| | 3483 | <span class="eventTip"> |
|---|
| | 3484 | <xsl:value-of select="$formattedStartDate"/><br/> |
|---|
| | 3485 | <strong> |
|---|
| | 3486 | <xsl:call-template name="timeFormatter"> |
|---|
| | 3487 | <xsl:with-param name="timeString" select="$startTime"/> |
|---|
| | 3488 | </xsl:call-template> |
|---|
| | 3489 | </strong> |
|---|
| | 3490 | <xsl:if test="numBusy > 0"> |
|---|
| | 3491 | <br/><xsl:value-of select="numBusy"/> busy |
|---|
| | 3492 | </xsl:if> |
|---|
| | 3493 | <xsl:if test="numTentative > 0"> |
|---|
| | 3494 | <br/><xsl:value-of select="numTentative"/> tentative |
|---|
| | 3495 | </xsl:if> |
|---|
| | 3496 | <xsl:if test="numBusy = 0 and numTentative = 0"> |
|---|
| | 3497 | <br/><em>all free</em> |
|---|
| | 3498 | </xsl:if> |
|---|
| | 3499 | </span> |
|---|
| | 3500 | </a> |
|---|
| | 3501 | </td> |
|---|
| | 3502 | </xsl:for-each> |
|---|
| | 7297 | <!-- time formatter (should be extended as needed) --> |
|---|
| | 7298 | <xsl:template name="timeFormatter"> |
|---|
| | 7299 | <xsl:param name="timeString"/><!-- required --> |
|---|
| | 7300 | <xsl:param name="showMinutes">yes</xsl:param> |
|---|
| | 7301 | <xsl:param name="showAmPm">yes</xsl:param> |
|---|
| | 7302 | <xsl:param name="hour24">no</xsl:param> |
|---|
| | 7303 | <xsl:variable name="hour" select="number(substring($timeString,1,2))"/> |
|---|
| | 7304 | <xsl:variable name="minutes" select="substring($timeString,3,2)"/> |
|---|
| | 7305 | <xsl:variable name="AmPm"> |
|---|
| | 7306 | <xsl:choose> |
|---|
| | 7307 | <xsl:when test="$hour < 12">AM</xsl:when> |
|---|
| | 7308 | <xsl:otherwise>PM</xsl:otherwise> |
|---|
| | 7309 | </xsl:choose> |
|---|
| | 7310 | </xsl:variable> |
|---|
| | 7311 | <xsl:choose> |
|---|
| | 7312 | <xsl:when test="hour24 = 'yes'"> |
|---|
| | 7313 | <xsl:value-of select="$hour"/><!-- |
|---|
| | 7314 | --><xsl:if test="$showMinutes = 'yes'">:<xsl:value-of select="$minutes"/></xsl:if> |
|---|
| | 7315 | </xsl:when> |
|---|
| | 7316 | <xsl:otherwise> |
|---|
| | 7317 | <xsl:choose> |
|---|
| | 7318 | <xsl:when test="$hour = 0">12</xsl:when> |
|---|
| | 7319 | <xsl:when test="$hour < 13"><xsl:value-of select="$hour"/></xsl:when> |
|---|
| | 7320 | <xsl:otherwise><xsl:value-of select="$hour - 12"/></xsl:otherwise> |
|---|
| | 7321 | </xsl:choose><!-- |
|---|
| | 7322 | --><xsl:if test="$showMinutes = 'yes'">:<xsl:value-of select="$minutes"/></xsl:if> |
|---|
| | 7323 | <xsl:if test="$showAmPm = 'yes'"> |
|---|
| | 7324 | <xsl:text> </xsl:text> |
|---|
| | 7325 | <xsl:value-of select="$AmPm"/> |
|---|
| | 7326 | </xsl:if> |
|---|
| | 7327 | </xsl:otherwise> |
|---|
| | 7328 | </xsl:choose> |
|---|
| | 7329 | </xsl:template> |
|---|
| | 7330 | |
|---|