-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 26.06.2013 22:34, Lukasz Szybalski wrote:
> Hello,
>
> We recently upgrade to 0.12.3 (Debian 7).
>
> 1. Is there a way to default that "modify" tab is ALWAYS OPEN? This
> really slows down the processing time for people who watch incoming new
> tickets and assign them out to proper milestones? Can I overwrite that
> somewhere in code if there is not setting for it?
Just been discussed and pointed out by Ryan here:
http://trac.edgewall.org/ticket/9807#comment:18
> Also less critical :
>
> A). Is there a way to remove the preview. We either get PDF or TIFF
> files in one of the trac instances we setup. PDF has no preview so you
> need download in original format anyway, and TIFF files have multiple
> pages which the preview does not show. When people click on the
> attachment I want them to go straight into download in original format?
> What part of the trac would this be in so I can customize the link?
> ( I know there is a download arrow next to attachment name but that does
> not work in firefox 20+, and a lot of people don't see it).
See PdfRedirectorPlugin [1], should be possible to do/customize for
other extensions too.
> B) Is there a plugin that would allow displaying "show under each
> result: attachments". Similar how "Show under each result: Description"
> gives you description..I want to show attachments so that you can click
> on them while you are in the query.
I see your point, but have not recognized something like that in
existing hacks, at least not at
trac-hacks.org yet. But extending each
ticket match in query by querying for attachments of that ticket and
display matches as a list with links pointing at that attachments sounds
like a doable task.
Got some development foo and time? I see this way to get what you want:
Using the IRequestFilter [2] extension interface to catch calls to
'/query', maybe check for results (matching tickets), before kicking in
at all,
iterate over results and query each ticket for associated attachments,
extend the data object, that will be passed on by a list of matching files,
implant a Genshi fragment containing generator code with
ITemplateStreamFilter [3] to render that list(s) as a linked list per
ticket row in trac/ticket/templates/query_results.html.
Once done, name it TicketQueryAttachmentListPlugin or similar. :-)
Steffen Hoffmann
[1]
http://trac-hacks.org/wiki/PdfRedirectorPlugin
[2]
http://trac.edgewall.org/wiki/TracDev/PluginDevelopment/ExtensionPoints/trac.web.api.IRequestFilter
[3]
http://trac.edgewall.org/wiki/TracDev/PluginDevelopment/ExtensionPoints/trac.web.api.ITemplateStreamFilter
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla -
http://enigmail.mozdev.org/
iEYEARECAAYFAlHLaCgACgkQ31DJeiZFuHebNQCgwIP5NJAjMbVvsH/4fFbMCS9m
MycAn3bUHUhGtmdwG3DsURTS+TU84REY
=ezrK
-----END PGP SIGNATURE-----