Changeset a43543 in indico


Ignore:
Timestamp:
04/20/11 15:25:03 (2 years ago)
Author:
Jose Benito <jose.benito.gonzalez@…>
Branches:
master, hello-world-walkthrough, ipv6, v0.98-series, v0.98.2, v0.98.3, v0.98b2, v0.99, b8c30da8ebdbdcbd675a873997cc3e95f567de49, 4287315ec967a3da168d83963c14001db8487d53
Children:
77d8e3
Parents:
40200c
git-author:
Leszek Syroka <leszek.marek.syroka@…> (11/12/10 17:18:55)
git-committer:
Jose Benito <jose.benito.gonzalez@…> (04/20/11 15:25:03)
Message:

[FIX] Next week/month overview

  • link to the week/month overview was added in the category display page
  • fix#579
Location:
indico/MaKaC/webinterface
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • indico/MaKaC/webinterface/tpls/CategoryDisplay.tpl

    r988cfe ra43543  
    88<div class="categoryHeader"> 
    99<ul> 
    10         % if not isRootCategory:  
     10        % if not isRootCategory: 
    1111            <li><a href="${ urlHandlers.UHCategoryDisplay.getURL(categ.owner) }">${ _("Go to parent category") }</a>|</li> 
    1212        % endif 
    13             % if categ.getConferenceList() != []:  
     13            % if categ.getConferenceList() != []: 
    1414                <li><a href="${ urlHandlers.UHCategoryToiCal.getURL(categ) }">${ _("iCal export")}</a>|</li> 
    1515            % endif 
    1616        <li><a id="moreLink" class="dropDownMenu" href="#">${ _("View") }</a></li> 
    17         % if allowCreateEvent:  
     17        % if allowCreateEvent: 
    1818            <li>|<a id="createEventLink" class="dropDownMenu" href="#">${ _("Create") }</a></li> 
    1919        % endif 
    20         % if allowUserModif:  
     20        % if allowUserModif: 
    2121            <li style="font-weight: bold" >|<a id="manageLink" class="dropDownMenu highlight" href="#">${ _("Manage")}</a></li> 
    2222        % endif 
    2323</ul> 
    2424<h1 class="categoryTitle"> 
    25 % if isRootCategory and containsCategories:  
     25% if isRootCategory and containsCategories: 
    2626    ${ _("Main categories") } 
    27 % elif isRootCategory:  
     27% elif isRootCategory: 
    2828    ${ _("All events") } 
    29 % else:  
     29% else: 
    3030    ${ name } 
    3131% endif 
    3232</h1> 
    3333 
    34 % if isRootCategory and containsCategories:  
     34% if isRootCategory and containsCategories: 
    3535<div class="categoryInfo"> 
    3636    ${ _("Click on a category to start browsing through the hierarchy") } 
    3737</div> 
    3838% endif 
    39 % if description:  
     39% if description: 
    4040<div class="categoryInfo"> 
    4141    ${ description } 
     
    4444 
    4545 
    46 % if managers:  
     46% if managers: 
    4747    <div class="categoryManagers"><strong>${ _("Managers") }:</strong> ${ managers }</div> 
    4848% endif 
    4949 
    5050<!-- 
    51 % if taskList:  
     51% if taskList: 
    5252<h2 class="subtitle"> 
    5353    ${ taskList } 
     
    8787    var menuItems = {}; 
    8888    menuItems["${ _("Today's events") }"] = "${ urlHandlers.UHCategoryOverview.getURL(categ) }"; 
     89    menuItems["${ _("Week's events") }"] = "${ urlHandlers.UHCategoryOverview.getWeekOverviewUrl(categ) }"; 
     90    //menuItems["${ _("Month's events") }"] = "${ urlHandlers.UHCategoryOverview.getMonthOverviewUrl(categ) }"; 
    8991    menuItems['${ _("Calendar") }'] = "${ urlHandlers.UHCalendar.getURL([categ]) }"; 
    9092    menuItems['${ _("Category map") }'] = "${ urlHandlers.UHCategoryMap.getURL(categ) }"; 
     
    99101 
    100102 
    101 % if allowCreateEvent:  
     103% if allowCreateEvent: 
    102104<script type="text/javascript"> 
    103105var createEventLink2 = $E('createEventLink'); 
     
    124126% endif 
    125127 
    126 % if allowUserModif:  
     128% if allowUserModif: 
    127129<script type="text/javascript"> 
    128130var manageLink = $E('manageLink'); 
  • indico/MaKaC/webinterface/urlHandlers.py

    rbb77c9 ra43543  
    2424from new import classobj 
    2525from MaKaC.common.utils import utf8rep 
     26from MaKaC.common.timezoneUtils import nowutc 
    2627 
    2728""" 
     
    24172418    getURLFromOverview = classmethod( getURLFromOverview ) 
    24182419 
     2420    @classmethod 
     2421    def getWeekOverviewUrl(cls, categ): 
     2422        url = cls.getURL(categ) 
     2423        p = {"day" : nowutc().day, 
     2424             "month" : nowutc().month, 
     2425             "year" : nowutc().year, 
     2426             "period" : "week", 
     2427             "detail" : "conference"} 
     2428        url.addParams(p) 
     2429        return url 
     2430 
     2431    @classmethod 
     2432    def getMonthOverviewUrl(cls, categ): 
     2433        url = cls.getURL(categ) 
     2434        p = {"day" : nowutc().day, 
     2435             "month" : nowutc().month, 
     2436             "year" : nowutc().year, 
     2437             "period" : "month", 
     2438             "detail" : "conference"} 
     2439        url.addParams(p) 
     2440        return url 
    24192441 
    24202442class UHTaskList( URLHandler ): 
Note: See TracChangeset for help on using the changeset viewer.