Upgrade selector controls from 2016 to 2016 R2
In WorkZone Process 2016 R2 changes have been implemented for methods to select options in forms. Follow the guidelines below to upgrade forms:
- In forms that are created with a JavaScript controller, go to the line
angular.module('wzp', ['….
and remove'ui.select2'
,'ui.selector'
,'ui.forward'
,'ui.rollbackselector'
. Then, if it does not exist already, add the appropriate wzp controls. - In all HTML forms, replace old controls with new ones as follows:
Old element New element Comments ui:selector wzp:selector Use this for single selectors such as multiple:false, or use it if you don’t need the possibility to edit items. ui:selector wzp-multi-selector Use this for editable multiple selectors. ui:filter-selector wzp:filter-selector ui:sequence-mask-selector wzp:sequence-mask-selector ui:forward wzp:forward usertask-rollbackselector-panel-helper wzp-usertask-rollbackselector-panel-helper Use this for HTML attributes ui:rollbackselector-panel wzp:rollbackselector-panel ui:rollbackselector wzp:rollbackselector-panel ui-checkboxselector wzp-checkboxselector Use this for HTML attributes in the ui:selector element - In all HTML forms replace the old ng-controller with new ones:
Old controller New controller SelectODATACtrl wzpSelectODATACtrl SelectODATAWithFilterCtrl wzpSelectODATAWithFilterCtrl InitFormFilterForSelectorCtrl wzpInitFormFilterForSelectorCtrl InitFormSequenceMaskForSelectorCtrl wzpInitFormSequenceMaskForSelectorCtrl SelectUserTaskDocumentsCtrl wzpSelectUserTaskDocumentsCtrl SelectUserTaskActorsCtrl wzpSelectUserTaskActorsCtrl CustomEditDocumentController wzpCustomEditDocumentController SmartTaskFilterForSelectorCtrl zpSmartTaskFilterForSelectorCtrl - Remove the attribute
wzp-ad-selector-change-label
and its value. - Remove change-title-variable attribute and its value.
- For the new
wzp:filter-selector
control, change the attributeng-controller-name
tong-controller
. - For instances of
wzp-multi-selector
orwzp:rollbackselector
that contain instances ofwzp:filter-selector
orwzp:sequence-mask-selector
, change the class attribute toclass="newline wzp-task-documentlist wzp-select-with-filter"
. - Separate each
wzp-multi-selector
by<div class="wzp-task-editdocument">
. - Set
always-editable
="true"
for the instance ofwzp-multi-selector
orwzp:rollbackselector
that you want only in editable mode. An example would be the use of these selectors in Init forms.