Changeset 131

Show
Ignore:
Timestamp:
02/09/06 15:53:29
Author:
douglm
Message:

Add current subscriptions and calendars to header

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/calendar3/webclient/war/docs/header.jsp

    r122 r131  
    197197      Value: string - Current search string for display 
    198198      Note: this will change when proper searching is implemented --%> 
    199     <subscription></subscription><%-- 
     199    <subscriptions> 
     200      <logic:iterate id="sub" name="calForm" property="currentSubscriptions"> 
     201        <subscription> 
     202          <name><bean:write name="sub" property="name" /></name> 
     203          <logic:present name="sub" property="calendar" > 
     204            <calendar> 
     205              <name><bean:write name="sub" property="calendar.name" /></name> 
     206            </calendar> 
     207          </logic:present> 
     208          <logic:notPresent name="sub" property="calendar" > 
     209            <calendar><name></name></calendar> 
     210          </logic:notPresent> 
     211        </subscription> 
     212      </logic:iterate> 
     213    </subscriptions><%-- 
    200214      Value: string - currently selected subscription ("calendar" too) --%> 
    201215    <filter></filter> <%-- unimplemented --%> 
  • trunk/calendar3/webcommon/src/org/bedework/webcommon/BwActionFormBase.java

    r128 r131  
    287287 
    288288  /* .................................................................... 
    289    *                       Selection type 
     289   *                       Selection type and selection 
    290290   * .................................................................... */ 
    291291 
    292292  // ENUM 
    293293  private String selectionType = selectionTypeView; 
     294 
     295  private Collection currentSubscriptions; 
    294296 
    295297  /* .................................................................... 
     
    12221224  } 
    12231225 
     1226  /** Set the current collections of subscriptions defining the display 
     1227   * 
     1228   * @param val Collection of subscriptions 
     1229   */ 
     1230  public void assignCurrentSubscriptions(Collection val) { 
     1231    currentSubscriptions = val; 
     1232  } 
     1233 
     1234  /** Return the current collections of subscriptions defining the display 
     1235   * 
     1236   * @return Collection of subscriptions 
     1237   */ 
     1238  public Collection getCurrentSubscriptions() { 
     1239    if (currentSubscriptions == null) { 
     1240      currentSubscriptions = new Vector(); 
     1241    } 
     1242    return currentSubscriptions; 
     1243  } 
     1244 
    12241245  /* ==================================================================== 
    12251246   *                   Views 
  • trunk/calendar3/webcommon/src/org/bedework/webcommon/misc/SetSelectionAction.java

    r120 r131  
    121121 
    122122    Collection c = new Vector(); 
    123     c.add(sub); 
     123    c.add(sub.clone()); 
    124124    svci.setCurrentSubscriptions(c); 
     125    form.assignCurrentSubscriptions(c); 
    125126    form.setSelectionType(BedeworkDefs.selectionTypeSubscription); 
    126127 
     
    152153    c.add(sub); 
    153154    svci.setCurrentSubscriptions(c); 
     155    form.assignCurrentSubscriptions(c); 
    154156    form.setSelectionType(BedeworkDefs.selectionTypeCalendar); 
    155157