Mailing List Archive

Early questions.
Hi all

We're planning on migrating to trac from a (frankly awful) twiki-based
bug tracking system. Early tests have gone well; the installation was a
breeze and the subversion hookup was seemless. I've even written some
sed to convert Twiki markup to TracWiki.

What I'd like to do before we can start using it is add some custom
fields to the ticket table, altering the templates and reports to match.

Given that sqlite doesn't support ALTER TABLE, the best way I've found
is by performing a dump and editing the SQL by hand. (and amending any
existing data, should it be there.) So far, it doesn't look like I need
to touch a single line of python and any form fields I add to the
templates will be pushed into the db with the original stuff. Is this
correct?

Secondly; how to I edit or create reports? TracReports is very clear on
how to construct the query, but it neglects to mention where to put it.
I can, tantalisingly, _look_ at any existing report SQL, but I can't
find the "Edit me" button. Do I have to edit the dump again or am I just
being dense? :)

Cheers,

Terry.

PS. Kudos to whoever designed the CSS. Ticket #575 aside, it looks lovely.
Early questions. [ In reply to ]
Hi

For the second question :

You need REPORT_CREATE and REPORT_MODIFY access right, consult
http://projects.edgewall.com/trac/wiki/TracPermissions for more information

Francois Harvey
SecuriWeb inc. (http://www.securiweb.net)

Terry Dooher wrote:

>
> Secondly; how to I edit or create reports? TracReports is very clear on
> how to construct the query, but it neglects to mention where to put it.
> I can, tantalisingly, _look_ at any existing report SQL, but I can't
> find the "Edit me" button. Do I have to edit the dump again or am I just
> being dense? :)
>
Early questions. [ In reply to ]
Thanks for that. I hadn't even begun to consider the permissions yet. I
thought anonymous could do everything by default.

I added the permission, inserted a missing comma in my new report and
suddenly I can see my new database field on the right and I didn't even
have to touch the templates. I like this.

Terry.

Fran?ois Harvey wrote:

> Hi
>
> For the second question :
>
> You need REPORT_CREATE and REPORT_MODIFY access right, consult
> http://projects.edgewall.com/trac/wiki/TracPermissions for more information
>
> Francois Harvey
> SecuriWeb inc. (http://www.securiweb.net)
>
> Terry Dooher wrote:
>
>>
>> Secondly; how to I edit or create reports? TracReports is very clear
>> on how to construct the query, but it neglects to mention where to put
>> it. I can, tantalisingly, _look_ at any existing report SQL, but I
>> can't find the "Edit me" button. Do I have to edit the dump again or
>> am I just being dense? :)
>>
> _______________________________________________
> Trac mailing list
> Trac@lists.edgewall.com
> http://lists.edgewall.com/mailman/listinfo/trac
>
>
Early questions. [ In reply to ]
It seems I was a little premature. In order to modify this new field
from within Trac, I have to add the naem of it to the fields list at the
top of Ticket.py

It's a minor change, but I don't want to make changes to anything in
/usr/lib/python2.3/site-packages/trac. Not least because these will
break any other project using these files. Is there somewhere I can put
project specific .py files to override the defaults?

The other option, I suppose, is to un-hardcode it by populating fields
from the database schema.

Terry Dooher wrote:

> Thanks for that. I hadn't even begun to consider the permissions yet. I
> thought anonymous could do everything by default.
>
> I added the permission, inserted a missing comma in my new report and
> suddenly I can see my new database field on the right and I didn't even
> have to touch the templates. I like this.
>
> Terry.
>
> Fran?ois Harvey wrote:
>
>> Hi
>>
>> For the second question :
>>
>> You need REPORT_CREATE and REPORT_MODIFY access right, consult
>> http://projects.edgewall.com/trac/wiki/TracPermissions for more
>> information
>>
>> Francois Harvey
>> SecuriWeb inc. (http://www.securiweb.net)
>>
>> Terry Dooher wrote:
>>
>>>
>>> Secondly; how to I edit or create reports? TracReports is very clear
>>> on how to construct the query, but it neglects to mention where to
>>> put it. I can, tantalisingly, _look_ at any existing report SQL, but
>>> I can't find the "Edit me" button. Do I have to edit the dump again
>>> or am I just being dense? :)
>>>
>> _______________________________________________
>> Trac mailing list
>> Trac@lists.edgewall.com
>> http://lists.edgewall.com/mailman/listinfo/trac
>>
>>
>
> _______________________________________________
> Trac mailing list
> Trac@lists.edgewall.com
> http://lists.edgewall.com/mailman/listinfo/trac
>
>
Early questions. [ In reply to ]
Terry,

If you wait for trac 0.8 (seems to be in pre-release at the moment) you can add custom fields by simply editting the conf/trac.ini file. Just add a section like that shown in:

http://projects.edgewall.com/trac/wiki/TracTicketsCustom

To the end of the afforementioned file, and extra fields appear in the ticket view.

The only potential downsides are:
- that your reports will (I think) need to join (possibly multiple times) with the ticket_custom table.
- that the custom fields appear separately from the 'core' fields when adding/amending tickets - not a problem for us, but...

Ian.

-----Original Message-----
From: trac-bounces@lists.edgewall.com [mailto:trac-bounces@lists.edgewall.com] On Behalf Of Terry Dooher
Sent: 15 July 2004 11:18
To: trac@lists.edgewall.com
Subject: Re: [Trac] Early questions.


It seems I was a little premature. In order to modify this new field
from within Trac, I have to add the naem of it to the fields list at the
top of Ticket.py

It's a minor change, but I don't want to make changes to anything in
/usr/lib/python2.3/site-packages/trac. Not least because these will
break any other project using these files. Is there somewhere I can put
project specific .py files to override the defaults?

The other option, I suppose, is to un-hardcode it by populating fields
from the database schema.

Terry Dooher wrote:

> Thanks for that. I hadn't even begun to consider the permissions yet.
> I
> thought anonymous could do everything by default.
>
> I added the permission, inserted a missing comma in my new report and
> suddenly I can see my new database field on the right and I didn't even
> have to touch the templates. I like this.
>
> Terry.
>
> Fran?ois Harvey wrote:
>
>> Hi
>>
>> For the second question :
>>
>> You need REPORT_CREATE and REPORT_MODIFY access right, consult
>> http://projects.edgewall.com/trac/wiki/TracPermissions for more
>> information
>>
>> Francois Harvey
>> SecuriWeb inc. (http://www.securiweb.net)
>>
>> Terry Dooher wrote:
>>
>>>
>>> Secondly; how to I edit or create reports? TracReports is very clear
>>> on how to construct the query, but it neglects to mention where to
>>> put it. I can, tantalisingly, _look_ at any existing report SQL, but
>>> I can't find the "Edit me" button. Do I have to edit the dump again
>>> or am I just being dense? :)
>>>
>> _______________________________________________
>> Trac mailing list
>> Trac@lists.edgewall.com
>> http://lists.edgewall.com/mailman/listinfo/trac
>>
>>
>
> _______________________________________________
> Trac mailing list
> Trac@lists.edgewall.com
> http://lists.edgewall.com/mailman/listinfo/trac
>
>

_______________________________________________
Trac mailing list
Trac@lists.edgewall.com http://lists.edgewall.com/mailman/listinfo/trac

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.716 / Virus Database: 475 - Release Date: 12/07/2004