Ilias Lazaridis wrote: > Matt Good wrote: > > The parameter could be called "cols" which I think would be more clear. > > The model talks about "fields", thus possibly this term should be > prefered for consistency reasons (the user does not see the term "cols" > within the code).
Well, the model's part of the code too, so they wouldn't see "fields" either. I went ahead and wrote a patch tthat should fix the issues I mentioned before which uses "columns". I figured this would be meaningful to end-users since it corresponds to the columns in the displayed table of results. However, I'd be fine with "fields" if there's consensus from the other developers for that. > one thing is a given: the parameter describes a collection of "sets". > > Thus, if "col" should be use, the parameter would be "colsets". Well, I don't think it should just be limited just to the column lists defined in trac.ini. This patch provides a "columns" parameter which can contain a list of column names, or aliases defined in trac.ini: http://en.pastebin.ca/246140 This also allows aliases to be defined in terms of each other such as: basic = id,description expanded = basic,reporter,owner > > Maybe the trac.ini section > > could be renamed to "query-field-aliases" or "query-col-aliases", but > > I'm open to suggestions there. > > Query is not specific enouth (other queries will become possible, e.g. > MilestoneQuery). I was thinking there was already a [query] section, so I was going to be consistent with that, but I checked again and realized that's not yet defined. The patch I provided uses [ticket-query-column-aliases]. That is a bit long though, so suggestions for shorter names would be fine. > I apoligize, the provided diff contains a change against a previous > version of mine and is missleading. the default behaviour is not > overridden: Well, I noticed that it wasn't diffed against a vanilla Trac, but that's not what I was referring to. See: http://dev.lazaridis.com/base/browser/infra/trac-dev/trac/ticket/query.py?rev=88#L111 In line 111 and 112 Trac defines the initial list of "cols", which you override in lines 118 and 121. Compare the columns when querying your site with a "Keywords" filter: http://dev.lazaridis.com/base/query?status=new&status=assigned&status=reopened&keywords=%7Ea&order=priority To the same query on the Trac site: http://trac.edgewall.org/query?status=new&status=assigned&status=reopened&keywords=%7Ea&order=priority The Trac site lists the "Keywords" column in the results while yours doesn't. The patch I provided above also fixes this. -- Matt Good --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Trac Development" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/trac-dev?hl=en -~----------~----~----~----~------~----~------~--~---
