Opened 18 years ago
Closed 4 years ago
#3754 closed enhancement (fixed)
retarget open tickets to other milestone of choice - Webadmin
Reported by: | jl | Owned by: | Ryan J Ollos |
---|---|---|---|
Priority: | normal | Milestone: | 1.5.1 |
Component: | admin/web | Version: | none |
Severity: | normal | Keywords: | milestone patch review |
Cc: | t.riedel@… | Branch: | |
Release Notes: |
Open tickets can be retargeted from the Ticket Admin > Milestones page. |
||
API Changes: | |||
Internal Changes: |
Description
This would be the same functionality as #2743 for the main trac (r3372 & r3732). I prefer to work with the webadmin and I would like to see this feature also in the webadmin.
Closing a milestone manually should retarget open tickets to other milestone of choice. This should be very similar to deleting a milestone.
Attachments (4)
Change History (28)
comment:1 by , 18 years ago
Keywords: | needinfo added |
---|
comment:2 by , 18 years ago
Keywords: | needinfo removed |
---|---|
Milestone: | 0.10.3 → 0.11 |
Status: | new → assigned |
Actually, the current WebAdmin plugin (and the integrated admin in trunk) does support milestone management. And indeed, the issue raised here is the only feature missing.
The reason it's not been implemented yet is that WebAdmin generally allows deleting multiple items at once, and I'm not sure how to integrate that with retargetting tickets at deletion time. But once this does get added, the traditional milestone management via the roadmap will probably be removed completely (because it'd be redundant.
follow-up: 4 comment:3 by , 18 years ago
i am not sure if traditional milestone management is not more intuitive. you also do not manage wiki pages via web-admin, or attachment deletions.
comment:4 by , 16 years ago
Milestone: | 0.11-retriage → 0.13 |
---|---|
Owner: | removed |
Status: | assigned → new |
Replying to ThurnerRupert:
i am not sure if traditional milestone management is not more intuitive. you also do not manage wiki pages via web-admin, or attachment deletions.
I tend to agree, I don't think it makes sense to remove milestone management in the traditional milestone editor. Actually, it would be more interesting to simply be able to reuse that editor in the admin panel context, when editing one milestone.
However, when doing a deletion of several milestones at once, it should be possible to select a milestone to be the new milestone to associate to tickets that belonged to the milestones that are going to be deleted.
by , 11 years ago
Attachment: | MilestoneDeleteConfirm.png added |
---|
follow-up: 7 comment:5 by , 11 years ago
Milestone: | next-major-releases → next-dev-1.1.x |
---|---|
Owner: | set to |
Status: | new → assigned |
This was recently discussed on the mailing list, and I'll plan to implement following #5658 and #4582 with the following goals for the milestone admin page:
- Provide a select for retargeting on milestone deletion. One possibility is to have a confirm page, like you see when deleting a milestone from the Roadmap.
- Investigate reuse of
milestone_edit.html
in milestone admin. The Milestone edit page/milestone/milestone1?action=edit
and Admin milestone edit page differ very slightly, with the latter only lacking the functionality to retarget tickets.
Milestone edit page
Admin Milestone edit page
comment:6 by , 11 years ago
Keywords: | milestone added |
---|
by , 11 years ago
Attachment: | MilestoneEditPage.png added |
---|
by , 11 years ago
Attachment: | AdminMilestoneEditPage.png added |
---|
follow-up: 10 comment:7 by , 11 years ago
Replying to rjollos:
- Investigate reuse of
milestone_edit.html
in milestone admin. The Milestone edit page/milestone/milestone1?action=edit
and Admin milestone edit page differ very slightly, with the latter only lacking the functionality to retarget tickets.
This is also slightly related to #1233. In #1233, it is proposed to add Milestone-like pages for viewing and managing Components and Versions. If we can successfully include the same form within milestone_edit.html
and admin_milestone_edit.html
, then it should translate to the possibility of extracting the form from admin_component.html
for reuse in component_edit.html
, and likewise for the Versions edit pages.
comment:8 by , 11 years ago
Milestone: | next-dev-1.1.x → 1.1.2 |
---|
comment:9 by , 11 years ago
Milestone: | 1.1.2 → 1.1.3 |
---|
comment:10 by , 11 years ago
Replying to rjollos:
If we can successfully include the same form within
milestone_edit.html
andadmin_milestone_edit.html
, then it should translate to the possibility of extracting the form fromadmin_component.html
for reuse incomponent_edit.html
, and likewise for the Versions edit pages.
These changes are pretty extensive, so I've made a new ticket #11499.
comment:11 by , 10 years ago
Milestone: | 1.1.3 → next-dev-1.1.x |
---|---|
Owner: | removed |
Status: | assigned → new |
comment:12 by , 9 years ago
Milestone: | next-dev-1.1.x → next-dev-1.3.x |
---|
comment:13 by , 8 years ago
Cc: | added |
---|
comment:14 by , 7 years ago
comment:73:ticket:5658 notes the need for a batch notification when deleting a milestone.
comment:15 by , 7 years ago
When closing a milestone retarget tickets in same way as on roadmap:
-
trac/ticket/admin.py
diff -r a3e91091080a trac/ticket/admin.py
a b 18 18 from trac.resource import ResourceNotFound 19 19 from trac.ticket import model 20 20 from trac.ticket.api import TicketSystem 21 from trac.ticket.roadmap import MilestoneModule 21 from trac.ticket.roadmap import MilestoneModule, \ 22 get_num_tickets_for_milestone, \ 23 group_milestones 22 24 from trac.util import as_int, getuser 23 25 from trac.util.datefmt import format_date, format_datetime, \ 24 26 get_datetime_format_hint, parse_date, user_time … … 249 251 elif 'cancel' in req.args: 250 252 req.redirect(req.href.admin(cat, page)) 251 253 254 milestones = [m for m in model.Milestone.select(self.env) 255 if m.name != milestone.name 256 and 'MILESTONE_VIEW' in req.perm(m.resource)] 257 milestone_groups = group_milestones(milestones, 258 'TICKET_ADMIN' in req.perm) 259 num_open_tickets = \ 260 get_num_tickets_for_milestone(self.env, milestone, 261 exclude_closed=True) 262 252 263 chrome = Chrome(self.env) 253 264 chrome.add_wiki_toolbars(req) 254 265 chrome.add_auto_preview(req) 255 266 data = {'view': 'detail', 256 267 'milestone': milestone, 257 'default_due': milestone_module.get_default_due(req)} 268 'default_due': milestone_module.get_default_due(req), 269 'milestone_groups': milestone_groups, 270 'num_open_tickets': num_open_tickets, 271 'retarget_to': milestone_module.default_retarget_to} 258 272 259 273 # List view 260 274 else:
follow-up: 17 comment:16 by , 6 years ago
Keywords: | patch review added |
---|
Please can you let me know what is missing in the patch above for Trac? It would be very helpful. Thanks! 🎅
comment:17 by , 6 years ago
Replying to anonymous:
Please can you let me know what is missing in the patch above for Trac? It would be very helpful. Thanks! 🎅
I'll review soon. Thanks for the patch. It will need unit tests, per TracDev/SubmittingPatches.
by , 6 years ago
Attachment: | T3754_milestone_retarget.patch added |
---|
follow-up: 20 comment:18 by , 6 years ago
Thanks!
I found the existing unit tests for milestone admin in trac.ticket.tests.admin.MilestoneAdminPanelTestCase, and functional tests in trac.ticket.tests.functional.admin.TestAdminMilestoneCompleted*. They still succeed but don't test the retargeting feature yet.
Unit tests for the roadmap are in trac.ticket.tests.roadmap.MilestoneModuleTestCase, but I could not find anything related to the retargeting feature there. Functional tests for the roadmap *do* test the retargeting feature in trac.ticket.tests.functional.main.TestMilestoneClose.
Is it sufficient to copy that functional test to a new trac.ticket.tests.functional.admin.TestAdminMilestoneCompletedRetargeting
, and adjusting it to use the admin panel instead of the roadmap? → I did that in T3754_milestone_retarget.patch.
comment:20 by , 5 years ago
Milestone: | next-dev-1.5.x → 1.5.1 |
---|---|
Owner: | set to |
Status: | new → assigned |
Replying to anonymous:
Is it sufficient to copy that functional test to a new
trac.ticket.tests.functional.admin.TestAdminMilestoneCompletedRetargeting
, and adjusting it to use the admin panel instead of the roadmap? → I did that in T3754_milestone_retarget.patch.
Sorry for the delay. Looks good to me. I'll add some unit test coverage and commit the changes.
comment:22 by , 4 years ago
Release Notes: | modified (diff) |
---|
Added some test coverage: [f99f91400/rjollos.git]
Nice that this was pretty simple to do after #11499 (comment:7). I hope to work on #1233 soon.
comment:24 by , 4 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
This ticket is confusing. #2743 does exactly what this ticket wants except it does it in the Roadmap when you are closing a milestone.
Currently, there are no features to manipulate the roadmap or milestones using WebAdmin. Is that the feature requested in this ticket? Could this be accomplished using batch ticket modification instead (see #525)?