Changeset 1422

Show
Ignore:
Timestamp:
06/14/07 17:24:08
Author:
johnsa
Message:

user client: add rudimentary pull-down menus to the calendar grid; this requires slight reworking of the grid xsl. Some work still to be done to finish this off.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/deployment/webuser/webapp/resources/demoskins/default/default/default.css

    r1418 r1422  
    284284  margin: 0; 
    285285  padding: 0; 
    286   padding: 0.2em 0 0.2em 1em; 
    287   white-space: nowrap; 
    288 
    289 #bedework #utilBarTable .leftCell a { 
    290   color: #666; 
    291   background-color: transparent; 
    292   font-size: 0.75em; 
    293   text-decoration: none; 
    294   margin-right: 6px; 
     286  padding: 0.2em 0 0.2em 0.2em; 
     287  white-space: nowrap; 
    295288} 
    296289#bedework #utilBarTable .leftCell img { 
     
    315308  float: right; 
    316309} 
    317 #bedework #utilBarTable form input { 
     310#bedework #utilBarTable input { 
    318311  font-size: 0.7em; 
    319312} 
     
    322315  margin: 0; 
    323316  padding: 0; 
     317} 
     318#bedework .bwActionIcons,  
     319#bedework .bwActionIconsInGrid { 
     320  position: absolute; 
     321  white-space: nowrap; 
     322  border: 1px solid #333; 
     323  background-color: #eee; 
     324  color: black; 
     325  padding: 0.5em; 
     326  margin: 0; 
     327} 
     328#bedework .bwActionIconsInGrid { 
     329  margin-top: 10px; 
     330  margin-left: -100px; 
     331} 
     332#bedework .bwActionIcons a:link, 
     333#bedework .bwActionIcons a:active,  
     334#bedework .bwActionIcons a:visited, 
     335#bedework .bwActionIconsInGrid a:link, 
     336#bedework .bwActionIconsInGrid a:active,  
     337#bedework .bwActionIconsInGrid a:visited { 
     338  display: block; 
     339  margin: 0 0 2px 0; 
     340  color: #666; 
     341  background-color: transparent; 
     342  font-size: 0.75em; 
     343  text-decoration: none; 
     344} 
     345#bedework .bwActionIcons a:hover, 
     346#bedework .bwActionIconsInGrid a:hover { 
     347  color: black; 
     348  background-color: transparent; 
    324349} 
    325350#bedework #searchTable { 
     
    11651190  text-align: center; 
    11661191} 
    1167 #bedework a.gridAdd { 
     1192#bedework div.gridAdd { 
     1193  position: relative; /* required so that the bwActionIcons position correctly */ 
    11681194  display: block; 
    11691195  float: right; 
  • trunk/deployment/webuser/webapp/resources/demoskins/default/default/default.xsl

    r1419 r1422  
    717717       <tr> 
    718718         <td class="leftCell"> 
    719            <xsl:choose> 
    720              <xsl:when test="/bedework/periodname = 'day'"> 
    721                <xsl:variable name="date" select="/bedework/firstday/date"/> 
    722                <a href="{$initEvent}&amp;startdate={$date}" title="add event"> 
    723                   <img src="{$resourcesRoot}/resources/add2mycal-icon-small.gif" width="12" height="16" border="0" alt="add event"/> 
    724                   add event 
    725                </a> 
    726              </xsl:when> 
    727              <xsl:otherwise> 
    728                <a href="{$initEvent}" title="add event"> 
    729                   <img src="{$resourcesRoot}/resources/add2mycal-icon-small.gif" width="12" height="16" border="0" alt="add event"/> 
    730                   add event 
    731                </a> 
    732              </xsl:otherwise> 
    733            </xsl:choose> 
    734            <a href="{$event-initMeeting}&amp;schedule=request" title="schedule a meeting"> 
    735               <img src="{$resourcesRoot}/resources/std-icalMeeting-icon-small.gif" width="12" height="16" border="0" alt="add meeting"/> 
    736               add meeting 
    737            </a> 
    738            <a href="{$initUpload}" title="upload event"> 
    739               <img src="{$resourcesRoot}/resources/std-icalUpload-icon-small.gif" width="12" height="16" border="0" alt="upload event"/> 
    740               upload 
    741            </a> 
     719           <input type="button" value="add..." onmouseover="changeClass('bwActionIcons-0','bwActionIcons')" onclick="toggleVisibility('bwActionIcons-0','bwActionIcons')"/> 
     720           <xsl:call-template name="actionIcons"> 
     721             <xsl:with-param name="actionIconsId">bwActionIcons-0</xsl:with-param>  
     722             <xsl:with-param name="startDate"> 
     723               <xsl:choose> 
     724                 <xsl:when test="/bedework/periodname = 'day'"><xsl:value-of select="/bedework/firstday/date"/></xsl:when> 
     725                 <xsl:otherwise><xsl:value-of select="/bedework/now/date"/></xsl:otherwise> 
     726               </xsl:choose> 
     727             </xsl:with-param>              
     728           </xsl:call-template> 
    742729         </td> 
    743730         <td class="rightCell"> 
     
    848835       </tr> 
    849836    </table> 
     837  </xsl:template> 
     838   
     839  <xsl:template name="actionIcons"> 
     840    <xsl:param name="startDate"/> 
     841    <xsl:param name="actionIconsId"/> 
     842    <div id="{$actionIconsId}" class="invisible"> 
     843       <a href="{$initEvent}&amp;entityType=event&amp;startdate={$startDate}" title="add event" onclick="javascript:changeClass('{$actionIconsId}','invisible')"> 
     844          <img src="{$resourcesRoot}/resources/add2mycal-icon-small.gif" width="12" height="16" border="0" alt="add event"/> 
     845          add event 
     846       </a> 
     847       <a href="{$event-initMeeting}&amp;entityType=event&amp;schedule=request&amp;startdate={$startDate}" title="schedule a meeting" onclick="javascript:changeClass('{$actionIconsId}','invisible')"> 
     848          <img src="{$resourcesRoot}/resources/std-icalMeeting-icon-small.gif" width="12" height="16" border="0" alt="schedule meeting"/> 
     849          schedule meeting 
     850       </a> 
     851       <a href="{$initEvent}&amp;entityType=task&amp;startdate={$startDate}" title="add task" onclick="javascript:changeClass('{$actionIconsId}','invisible')"> 
     852          <img src="{$resourcesRoot}/resources/std-icalTask-icon-small.gif" width="12" height="16" border="0" alt="add task"/> 
     853          add task 
     854       </a> 
     855       <a href="{$event-initMeeting}&amp;entityType=task&amp;schedule=request&amp;startdate={$startDate}" title="schedule a task" onclick="javascript:changeClass('{$actionIconsId}','invisible')"> 
     856          <img src="{$resourcesRoot}/resources/std-icalSchTask-icon-small.gif" width="12" height="16" border="0" alt="schedule task"/> 
     857          schedule task 
     858       </a> 
     859       <a href="{$initUpload}" title="upload event" onclick="javascript:changeClass('{$actionIconsId}','invisible')"> 
     860          <img src="{$resourcesRoot}/resources/std-icalUpload-icon-small.gif" width="12" height="16" border="0" alt="upload event"/> 
     861          upload 
     862       </a> 
     863     </div> 
    850864  </xsl:template> 
    851865 
     
    11021116              </xsl:if> 
    11031117              <xsl:variable name="dayDate" select="date"/> 
    1104               <a href="{$initEvent}&amp;startdate={$dayDate}" class="gridAdd" title="add event"> 
    1105                 <img src="{$resourcesRoot}/resources/addEvent-forGrid-icon.gif" width="9" height="10" border="0" alt="add event"/> 
    1106               </a> 
     1118              <xsl:variable name="actionIconsId">bwActionIcons-<xsl:value-of select="value"/></xsl:variable> 
     1119              <div class="gridAdd"> 
     1120                <a href="javascript:toggleVisibility('{$actionIconsId}','bwActionIconsInGrid')" title="add..."> 
     1121                  <img src="{$resourcesRoot}/resources/addEvent-forGrid-icon.gif" width="10" height="10" border="0" alt="add..."/> 
     1122                </a> 
     1123                <xsl:call-template name="actionIcons"> 
     1124                  <xsl:with-param name="actionIconsId"><xsl:value-of select="$actionIconsId"/></xsl:with-param>  
     1125                  <xsl:with-param name="startDate"><xsl:value-of select="$dayDate"/></xsl:with-param> 
     1126                </xsl:call-template> 
     1127              </div> 
    11071128              <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$dayDate}" class="dayLink" title="go to day"> 
    11081129                <xsl:value-of select="value"/> 
     
    11441165                  </xsl:if> 
    11451166                  <xsl:variable name="dayDate" select="date"/> 
    1146                   <a href="{$initEvent}&amp;startdate={$dayDate}" class="gridAdd" title="add event"> 
    1147                     <img src="{$resourcesRoot}/resources/addEvent-forGrid-icon.gif" width="10" height="10" border="0" alt="add event"/> 
    1148                   </a> 
     1167                  <xsl:variable name="actionIconsId">bwActionIcons-<xsl:value-of select="value"/></xsl:variable> 
     1168                  <div class="gridAdd"> 
     1169                    <a href="javascript:toggleVisibility('{$actionIconsId}','bwActionIconsInGrid')" title="add..."> 
     1170                      <img src="{$resourcesRoot}/resources/addEvent-forGrid-icon.gif" width="10" height="10" border="0" alt="add..."/> 
     1171                    </a> 
     1172                   <xsl:call-template name="actionIcons"> 
     1173                     <xsl:with-param name="actionIconsId"><xsl:value-of select="$actionIconsId"/></xsl:with-param>   
     1174                     <xsl:with-param name="startDate"><xsl:value-of select="$dayDate"/></xsl:with-param> 
     1175                   </xsl:call-template> 
     1176                  </div> 
    11491177                  <a href="{$setViewPeriod}&amp;viewType=dayView&amp;date={$dayDate}" class="dayLink" title="go to day"> 
    11501178                    <xsl:value-of select="value"/> 
  • trunk/deployment/webuser/webapp/resources/demoskins/resources/bedework.js

    r1396 r1422  
    3131      changeClass(arguments[i],'visible'); 
    3232    } 
     33  } 
     34} 
     35// show and hide an item based on its current  
     36// visibility; if visible, hide it; if invisible 
     37// show it. 
     38function toggleVisibility(id,cl) { 
     39  if(document.getElementById(id).className == 'invisible') { 
     40    changeClass(id,cl); 
     41  } else { 
     42    changeClass(id,'invisible'); 
    3343  } 
    3444} 
     
    94104// launch the calSelect pop-up window for selecting a calendar when creating, 
    95105// editing, and importing events 
     106// DEPRECATED - can't use pop-ups in current portal environments in a  
     107// portal-agnostic way 
    96108function launchCalSelectWindow(URL) { 
    97109  calSelect = window.open(URL, "calSelect", "width=500,height=600,scrollbars=yes,resizable=yes,alwaysRaised=yes,menubar=no,toolbar=no");