Attachment 'MonthCalendar-3.patch'

Download

   1 --- MoinMoin/macro/MonthCalendar.py	2010-08-22 00:42:37.812770363 +0200
   2 +++ wiki/data/plugin/macro/MonthCalendar.py	2010-08-29 00:25:10.475930622 +0200
   3 @@ -7,6 +7,7 @@
   4      BasePageName/year-month-day
   5  
   6      @copyright: 2002-2009 MoinMoin:ThomasWaldmann
   7 +    @copyright: 2010 Modified by MarcelHaefner (http://moinmo.in/MoinMoinBugs/1.9%20MonthCalenderAndSidebarFunctionNotWorking)
   8      @license: GNU GPL, see COPYING for details.
   9  
  10      Revisions:
  11 @@ -268,11 +269,11 @@
  12      p = Page(request, thispage)
  13      qpagenames = '*'.join([wikiutil.quoteWikinameURL(pn) for pn in parmpagename])
  14      qtemplate = wikiutil.quoteWikinameURL(parmtemplate)
  15 -    querystr = "calparms=%%s,%d,%d,%d,%%d,,,%%s" % (parmyear, parmmonth, parmoffset)
  16 -    prevlink = p.url(request, querystr % (qpagenames, parmoffset2 - 1, qtemplate))
  17 -    nextlink = p.url(request, querystr % (qpagenames, parmoffset2 + 1, qtemplate))
  18 -    prevylink = p.url(request, querystr % (qpagenames, parmoffset2 - 12, qtemplate))
  19 -    nextylink = p.url(request, querystr % (qpagenames, parmoffset2 + 12, qtemplate))
  20 +    querystr = "?calparms=%%s,%d,%d,%d,%%d,,,%%s" % (parmyear, parmmonth, parmoffset)
  21 +    prevlink =  querystr % (qpagenames, parmoffset2 - 1, qtemplate)
  22 +    nextlink = querystr % (qpagenames, parmoffset2 + 1, qtemplate)
  23 +    prevylink = querystr % (qpagenames, parmoffset2 - 12, qtemplate)
  24 +    nextylink = querystr % (qpagenames, parmoffset2 + 12, qtemplate)
  25  
  26      prevmonth = formatter.url(1, prevlink, 'cal-link', **attrs) + '<' + formatter.url(0)
  27      nextmonth = formatter.url(1, nextlink, 'cal-link', **attrs) + '>' + formatter.url(0)
  28 @@ -389,6 +390,8 @@
  29                              r, g, b = (r, g+colorstep, b)
  30                  r, g, b = cliprgb(r, g, b)
  31                  style = 'background-color:#%02x%02x%02x' % (r, g, b)
  32 +                if has_calparms:
  33 +                    query["calparms"] = macro.request.args['calparms']
  34                  fmtlink = formatter.url(1, daypage.url(request, query), csslink, **attrs) + str(day) + formatter.url(0)
  35                  if day == currentday and month == currentmonth and year == currentyear:
  36                      cssday = "cal-today"

Attached Files

To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
  • [get | view] (2010-08-28 21:58:11, 2.4 KB) [[attachment:MonthCalendar-2.patch]]
  • [get | view] (2010-08-28 22:25:56, 2.1 KB) [[attachment:MonthCalendar-3.patch]]
  • [get | view] (2010-08-23 11:10:12, 1.3 KB) [[attachment:MonthCalendar.patch]]
  • [get | view] (2010-08-23 10:59:31, 73.1 KB) [[attachment:screenshot.png]]
 All files | Selected Files: delete move to page copy to page

You are not allowed to attach a file to this page.