GNOME Bugzilla – Bug 324504
Add priority to ical output
Last modified: 2005-12-20 01:21:51 UTC
First off, freakin' awesome work with the new bugzilla installation! One version of the original ical patch added priorities to the output. However, we had to remove this since priorities are essentially defined by each bugzilla site and not by upstream. https://bugzilla.mozilla.org/show_bug.cgi?id=235459 It would be nice for us (bugzilla.gnome.org) to add priorities that are relevant for GNOME. This would make the order that appears in the clock applet make more sense.
Ah, you wrote the patch. Good :) Exactly what parts need to be added? I looked at this patch: https://bugzilla.mozilla.org/attachment.cgi?id=142158&action=view Is it just this for the list.ics.tmpl: > +[% FOREACH priority = priorities %] > +[% NEXT IF !priority %] > +[% IF bug.priority == priority %] > +PRIORITY:[% loop.count() FILTER html %] > +[% END %] > +[% END %] (the buglist.cgi I understand)
My memory is a little rusty let me try to reconstruct what I was thinking. :) The spec for iCalendar is: http://www.ietf.org/rfc/rfc2445.txt See Section 4.8.1.9 for the definition of the PRIORITY field. Based on that, how about the following mapping from our priorities as shown in the web interface to PRIORITY values: "Immediate" => 1 "Urgent" => 2 "High" => 3 "Normal" => 5 "Low" => 6 The patch that you quote does a very crude mapping, I think we can do better. Should patches be against http://cvs.gnome.org/viewcvs/bugzilla-new/ ?
No bugzilla-newer :) I'm thinking of putting a hash in template/en/default/global/field-descs.none.tmpl or just the list.ics.tmpl and using that. The PRIORITY: should only be added if the bugs priority is in the hash (to be sure, although I do not believe we will ever change our priorities).
Sounds good to me. You're way more familiar with the code then I am anymore. :)
$ cicl Checking in ChangeLog; /cvs/gnome/bugzilla-newer/ChangeLog,v <-- ChangeLog new revision: 1.293; previous revision: 1.292 done Checking in template/en/default/list/list.ics.tmpl; /cvs/gnome/bugzilla-newer/template/en/default/list/list.ics.tmpl,v <-- list.ics.tmpl new revision: 1.2; previous revision: 1.1 done
It works. Thanks Olav!