change query paramter name for year/month navigation
This commit is contained in:
parent
5e7ada6f19
commit
22b4145c79
|
@ -77,8 +77,8 @@ class View(grok.View, utils.MonthlyView):
|
|||
return self.updated
|
||||
|
||||
def getYearAndMonthToDisplay(self):
|
||||
year = self.request.form.get('year') or self.now[0]
|
||||
month = self.request.form.get('month') or self.now[1]
|
||||
year = self.request.form.get('navyear') or self.now[0]
|
||||
month = self.request.form.get('navmonth') or self.now[1]
|
||||
year, month = int(year), int(month)
|
||||
return year, month
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
<div id="content-core" tal:condition="view/as_month">
|
||||
|
||||
<div tal:condition="view/has_view_switcher" id="agenda-view-switcher">
|
||||
<span>Calendrier</span> | <a tal:attributes="href string:list?year=${view/year}&month=${view/month}">Liste</a>
|
||||
<span>Calendrier</span> | <a tal:attributes="href string:list?navyear=${view/year}&navmonth=${view/month}">Liste</a>
|
||||
</div>
|
||||
|
||||
<table class="ploneCalendar"
|
||||
|
@ -42,7 +42,7 @@
|
|||
id="agenda-calendar-previous"
|
||||
tal:define="prevMonthMonth view/prevMonthMonth;
|
||||
prevMonthYear view/prevMonthYear"
|
||||
tal:attributes="href string:${viewname}?year=${prevMonthYear}&month=${prevMonthMonth}"
|
||||
tal:attributes="href string:${viewname}?navyear=${prevMonthYear}&navmonth=${prevMonthMonth}"
|
||||
i18n:attributes="title title_previous_month;">«</a>
|
||||
|
||||
<span i18n:translate="" tal:omit-tag="">
|
||||
|
@ -55,7 +55,7 @@
|
|||
<a href="#" rel="nofollow" title="Next month" id="agenda-calendar-next"
|
||||
tal:define="nextMonthMonth view/nextMonthMonth;
|
||||
nextMonthYear view/nextMonthYear"
|
||||
tal:attributes="href string:${viewname}?year=${nextMonthYear}&month=${nextMonthMonth}"
|
||||
tal:attributes="href string:${viewname}?navyear=${nextMonthYear}&navmonth=${nextMonthMonth}"
|
||||
i18n:attributes="title title_next_month;">»</a>
|
||||
|
||||
</tr>
|
||||
|
@ -153,7 +153,7 @@ jq('#tabellio-agenda tbody a').click(
|
|||
<div id="content-core" tal:condition="python: view.as_list() or view.as_seances()">
|
||||
|
||||
<div tal:condition="view/has_view_switcher" id="agenda-view-switcher">
|
||||
<a tal:attributes="href string:?year=${view/year}&month=${view/month}">Calendrier</a> | <span>Liste</span>
|
||||
<a tal:attributes="href string:?navyear=${view/year}&navmonth=${view/month}">Calendrier</a> | <span>Liste</span>
|
||||
</div>
|
||||
|
||||
|
||||
|
@ -165,7 +165,7 @@ jq('#tabellio-agenda tbody a').click(
|
|||
class="agenda-calendar-previous"
|
||||
tal:define="prevMonthMonth view/prevMonthMonth;
|
||||
prevMonthYear view/prevMonthYear"
|
||||
tal:attributes="href string:${viewname}?year=${prevMonthYear}&month=${prevMonthMonth}"
|
||||
tal:attributes="href string:${viewname}?navyear=${prevMonthYear}&navmonth=${prevMonthMonth}"
|
||||
i18n:attributes="title title_previous_month;">«</a>
|
||||
|
||||
<span i18n:translate="" tal:omit-tag="">
|
||||
|
@ -180,7 +180,7 @@ jq('#tabellio-agenda tbody a').click(
|
|||
class="agenda-calendar-next"
|
||||
tal:define="nextMonthMonth view/nextMonthMonth;
|
||||
nextMonthYear view/nextMonthYear"
|
||||
tal:attributes="href string:${viewname}?year=${nextMonthYear}&month=${nextMonthMonth}"
|
||||
tal:attributes="href string:${viewname}?navyear=${nextMonthYear}&navmonth=${nextMonthMonth}"
|
||||
i18n:attributes="title title_next_month;">»</a>
|
||||
</div>
|
||||
|
||||
|
|
Reference in New Issue