Re: How to set a default priority
"R. Diez via Roundup-users" <[email protected]>
| Newsgroups | gmane.comp.bug-tracking.roundup.user |
|---|---|
| Message-ID | <[email protected]> |
> You can remove the 'priority' from the list of required attributes in > the @required list in html/issue.item.html (search for the string > "@required"). And you probably want to update the style so that the > fieldname is not printed in bold by removing the 'class="required"' from > the Priority header (search for the string "Priority") Thanks for the hint. > Now for setting a default: You can add an auditor to a new file in the > "detectors" directory. Something along the lines of (untested): > > def add_prio_if_empty (db, cl, nodeid, newvalues): > if 'priority' not in newvalues: > newvalues ['priority'] = '1' # or whatever default you want > > I think as long as the user doesn't select anything from the menu the > field will be left empty which is then caught by the proposed auditor. I am not sure whether that is what I wanted. From looking at your code example and your comment above, it looks like the code would be intercepting the new issue and setting a default priority if not already there. But I want the priority automatically set to "normal" instead of "- no selection -" when the user clicks on "Create New". Well, first I would have to figure out how change the priority names. At the moment, it looks like a mixture of types (bug, feature, wish) and priorities (critical, urgent). But a bug can be urgent, normal, or low priority, so it is inconsistent. And, in any case, I was thinking about other things, and not software development bugs. But I guess when I carefully read the docs I'll find out how to do that myself. > I do have another auditor that limits the size of files (there is a > [...] That is not really what I am after. Like I said, this is like e-mails. Of course users are going to fill it up with attachments, sooner or later. And yes, the server will run out of space. And no, you cannot really limit the size or number of attachments in any meaningful way. The only effective measure is to limit each person's mailbox size, which is what everybody does. But that is hard to do in a issue tracker system, because the data is shared across users. So every now and then, you have to clean up, like you have to clean up your mailbox every now and then. For example, in Thunderbird, you can: 1) Delete old e-mails. That would be the equivalent of deleting old, closed issues in Roundup. But this is not ideal. 2) Sort e-mails by size, mark the biggest ones, and delete their attachments. I even have a script that can do that automatically for many selected e-mails with Microsoft Outlook. E-mails retain an indication that there was a file named xxxx in the e-mail, but it has been deleted. That is very useful, because you can later try to find the file on the file server by name. Where does Roundup store attachments? In the database, or in a separate "upload" directory? If files are in directory, one could just delete files based on creation date. And write in the user guide for the company users: "Please use the file server for long-lived attachments. Attachments in the issue tracker are automatically deleted after 1 year". If files are in the internal database, is there some reasonably easy-to-use tool to browse them by size and delete them? Regards, rdiez