#2894 Fix custom field admin controller and UI

v1.0.0
closed
sf-4 (350)
General
nobody
2015-08-20
2011-09-29
No

Couple of problems here:

  1. forgetracker.tracker_main.TrackerAdminController.set_custom_fields: right now this method just does a blind replace of the tracker's custom fields. It needs to be refactored to update tickets properly when a milestone field or it's milestone are deleted or updated. It also needs to sanitize milestone names.

  2. SortableRepeatedField jQuery plugin: this plugin doesn't work properly when nested (when a SRF contains another SRF), as is the case in the custom fields admin UI. This results in invalid data being posted to the controller.

These problems were discovered during work on [#2699].

Related

Tickets: #2699
Tickets: #3066

Discussion

    • Description has changed:

    Diff:

    --- old 
    +++ new 
    @@ -1,6 +1,6 @@
     Couple of problems here:
    
    -1. forgetracker.tracker_main.TrackerAdminController.set_custom_fields: right now this method just does a blind replace of the tracker's custom fields. It needs to be refactored to update tickets properly when a milestone field or it's milestone are deleted or updated. It also need to sanitize milestone names.
    +1. forgetracker.tracker_main.TrackerAdminController.set_custom_fields: right now this method just does a blind replace of the tracker's custom fields. It needs to be refactored to update tickets properly when a milestone field or it's milestone are deleted or updated. It also needs to sanitize milestone names.
    
     2. SortableRepeatedField jQuery plugin: this plugin doesn't work properly when nested (when a SRF contains another SRF), as is the case in the custom fields admin UI. This results in invalid data being posted to the controller.
    
     
  • Dave Brondsema

    Dave Brondsema - 2011-09-29
    • size: --> 4
     
    • status: in-progress --> code-review
    • assigned_to: Tim Van Steenburgh --> Dave Brondsema
     
  • forge:tv/2699 (not a typo)

    Go to Admin -> Tools -> Tracker -> Field Management

    Try adding, removing, and updating custom fields (especially of type 'milestone') and milestones. Try creating a new milestone, creating a ticket in that milestone, and then deleting or renaming the milestone. Check to make sure the ticket gets updated properly. Try to break stuff.

    Renaming an actual field (not a milestone) does not update tickets. I found that at the end of my testing so I created a new ticket for it ([#3171]).

     

    Related

    Tickets: #3171

  • Dave Brondsema

    Dave Brondsema - 2011-11-07
    • status: code-review --> closed
    • assigned_to: Dave Brondsema --> Tim Van Steenburgh
     

Log in to post a comment.