New Ticket

TICKET_CREATE privileges are required to perform this operation. You don't have the required permissions



Login Close


Ticket delete buttons don't appear when tracopt.ticket.deleter is enabled

Ticket #427 Assigned to rjollos, last modified 4 years ago

Details

Reporter rjollos
Keywords
Type defect
Status new
Priority major
Product BHD
Milestone next 0.x
Component ui design
Version
Cc

Description

The element with id = comment:description was changed from an h3 in Trac to an h5 in Bloodhound, and the Genshi stream filter is matching an h3, so the delete button does not appear in Bloodhound. The ticket comment delete button also does not display.

Attachments (1)

Buttons.png (11.4 KB) - added by rjollos 5 years ago.
Download all attachments as: .zip
Note: See TracTickets for help on using tickets.

rjollos

Replying to rjollos:

The element with id = comment:description was changed from an h3 in Trac to an h5 in Bloodhound, and the Genshi stream filter is matching an h3, so the delete button does not appear in Bloodhound.

Much more is required to get this working, but trac:#11100 is potentially a start on the changes that need to be made to the Trac core.

rjollos

In addition to trac:#11100, another problem is that filter_stream is matching for ticket.html, but bh_ticket.html is being filtered. Finally, we need to get the button styling correct, which involves another change to tracopt.ticket.deleter:

<input class="trac-delete" type="submit" value="– Delete" title="Delete ticket">

->

<input class="trac-delete pull-right btn btn-mini" type="submit" value="Delete" title="Delete ticket">

This would lead to a nice styling of the buttons:


The latter change could be done with JavaScript, however that doesn't resolve the problem of the filter_stream not being called until after the template is replaced in post_process_request.

Perhaps the best solution here is to just implement adding of the button through JavaScript?. That is what was proposed in trac:comment:1:ticket:11100.

rjollos

We should also keep an eye on trac:#10948, which proposes to move the position of the Clone and Delete buttons, and therefore change the XPath in ITemplateStreamFilter. The TicketCloneButton class in tracopt likely has the same issue as the TicketDeleter class.

rjollos

Moving tickets forward that probably won't be completed for 0.9 release. Tickets can be rescheduled for release 0.9 once work has started.

  • Milestone changed from Release 9 to next 0.x - by rjollos, 4 years ago