[Checklist] Adding support for auto adding checklist templates to new checklists

Review Request #8013 — Created Feb. 28, 2016 and discarded

Information

rb-extension-pack
master

Reviewers

Added support for automatically adding checklist templates to all new review
checklists for a user.

Added an evolution which adds a field, 'auto_add' to ChecklistTemplate that
determines whether they should be added to all new checklists made by the user.
In the UI this is represented with a checkbox as shown in the attachment below.

The templates are added when the checklist is created which happens the first
time a user loads the diff page for a review they haven't seen before.

Additional templates and items can still be added to a checklist that was
initially populated with default template items.

These changes depend on the changes in review request #7960.

Manually ensured that the evolution migration worked without errors on
reviewboard-2.5.x with the previous checklist schema.

Ensured that the auto add fields toggle correctly and get loaded
correctly on the templates page in My Accounts.

Ensured that new only those templates marked with the auto add flag are
added to every new review checklist created by the user.

Regression testing to confirm that making templates, adding checklist
items, checking them off, deleting them, and so on still work.


Description From Last Updated

Col: 21 E711 comparison to None should be 'if cond is not None:'

reviewbotreviewbot

Col: 29 E271 multiple spaces after keyword

reviewbotreviewbot
reviewbot
  1. Tool: Pyflakes
    Processed Files:
        checklist/checklist/evolutions/__init__.py
        checklist/checklist/models.py
        checklist/checklist/resources/checklist_template.py
        checklist/checklist/evolutions/add_auto_add.py
        checklist/checklist/resources/checklist_resource.py
    
    Ignored Files:
        checklist/checklist/static/css/accountpage.less
        checklist/checklist/static/js/models/checklistTemplate.js
        checklist/checklist/static/js/views/checklistAccountPageView.js
    
    
    
    Tool: PEP8 Style Checker
    Processed Files:
        checklist/checklist/evolutions/__init__.py
        checklist/checklist/models.py
        checklist/checklist/resources/checklist_template.py
        checklist/checklist/evolutions/add_auto_add.py
        checklist/checklist/resources/checklist_resource.py
    
    Ignored Files:
        checklist/checklist/static/css/accountpage.less
        checklist/checklist/static/js/models/checklistTemplate.js
        checklist/checklist/static/js/views/checklistAccountPageView.js
    
    
  2. Show all issues
    Col: 21
     E711 comparison to None should be 'if cond is not None:'
    
  3. 
      
imadueme
  1. 
      
  2. WIP test code, missing load of auto-added templates

  3. 
      
imadueme
imadueme
reviewbot
  1. Tool: PEP8 Style Checker
    Processed Files:
        checklist/checklist/evolutions/__init__.py
        checklist/checklist/models.py
        checklist/checklist/resources/checklist_template.py
        checklist/checklist/evolutions/add_auto_add.py
        checklist/checklist/resources/checklist_resource.py
    
    Ignored Files:
        checklist/checklist/static/css/accountpage.less
        checklist/checklist/static/js/models/checklistTemplate.js
        checklist/checklist/static/js/views/checklistAccountPageView.js
    
    
    
    Tool: Pyflakes
    Processed Files:
        checklist/checklist/evolutions/__init__.py
        checklist/checklist/models.py
        checklist/checklist/resources/checklist_template.py
        checklist/checklist/evolutions/add_auto_add.py
        checklist/checklist/resources/checklist_resource.py
    
    Ignored Files:
        checklist/checklist/static/css/accountpage.less
        checklist/checklist/static/js/models/checklistTemplate.js
        checklist/checklist/static/js/views/checklistAccountPageView.js
    
    
  2. Show all issues
    Col: 29
     E271 multiple spaces after keyword
    
  3. 
      
imadueme
reviewbot
  1. Tool: PEP8 Style Checker
    Processed Files:
        checklist/checklist/evolutions/__init__.py
        checklist/checklist/models.py
        checklist/checklist/resources/checklist_template.py
        checklist/checklist/evolutions/add_auto_add.py
        checklist/checklist/resources/checklist_resource.py
    
    Ignored Files:
        checklist/checklist/static/css/accountpage.less
        checklist/checklist/static/js/models/checklistTemplate.js
        checklist/checklist/static/js/views/checklistAccountPageView.js
    
    
    
    Tool: Pyflakes
    Processed Files:
        checklist/checklist/evolutions/__init__.py
        checklist/checklist/models.py
        checklist/checklist/resources/checklist_template.py
        checklist/checklist/evolutions/add_auto_add.py
        checklist/checklist/resources/checklist_resource.py
    
    Ignored Files:
        checklist/checklist/static/css/accountpage.less
        checklist/checklist/static/js/models/checklistTemplate.js
        checklist/checklist/static/js/views/checklistAccountPageView.js
    
    
  2. 
      
imadueme
david
Review request changed
Status:
Discarded