Commit | Line | Data |
---|---|---|
4c58e251 TO |
1 | <!-- |
2 | Controller: CaseTypeCtrl | |
3 | Required vars: caseType | |
4 | --> | |
f75a3cf2 | 5 | <h1 crm-page-title>{{caseType.title || ts('New Case Type')}}</h1> |
51d499e1 | 6 | <form name="editCaseTypeForm" unsaved-warning-form> |
76e4acb8 | 7 | <div class="crm-block crm-form-block crmCaseType"> |
1dda695b | 8 | <div class="help"> |
6b02fdc3 | 9 | {{ts('Use this screen to define or update the Case Roles, Activity Types, and Timelines for a case type.')}} <a href="https://docs.civicrm.org/user/en/stable/case-management/set-up/" target="_blank">{{ts('Learn more...')}}</a> |
1b9edd3a | 10 | </div> |
599e58a9 | 11 | <div class="crm-submit-buttons"> |
77ec5a8d | 12 | <button crm-icon="fa-check" ng-click="editCaseTypeForm.$setPristine(); save()" ng-disabled="editCaseTypeForm.$invalid"> |
7abbf317 CW |
13 | {{ts('Save')}} |
14 | </button> | |
77ec5a8d | 15 | <button crm-icon="fa-times" ng-click="editCaseTypeForm.$setPristine(); goto('caseType')"> |
7abbf317 CW |
16 | {{ts('Cancel')}} |
17 | </button> | |
599e58a9 DG |
18 | </div> |
19 | ||
ef5d18a1 | 20 | <div ng-include="'~/crmCaseType/caseTypeDetails.html'"></div> |
4c58e251 | 21 | |
7abbf317 | 22 | <h2 ng-show="isForkable()">{{ts('Roles')}}</h2> |
bbb29627 | 23 | |
ef5d18a1 | 24 | <div ng-show="isForkable()" ng-include="'~/crmCaseType/rolesTable.html'"></div> |
4c58e251 | 25 | |
7abbf317 | 26 | <h2 ng-show="isForkable()">{{ts('Activities')}}</h2> |
4c58e251 | 27 | |
b40b4114 | 28 | <div ng-show="isForkable()" class="crmCaseType-acttab" ui-jq="tabs" ui-options="{show: true, hide: true}"> |
bbb29627 | 29 | <ul> |
7abbf317 | 30 | <li><a href="#acttab-actType">{{ts('Activity Types')}}</a></li> |
7c2b40d1 | 31 | <li><a href="#acttab-statuses">{{ts('Statuses')}}</a></li> |
bbb29627 TO |
32 | <li ng-repeat="activitySet in caseType.definition.activitySets"> |
33 | <a href="#acttab-{{$index}}">{{ activitySet.label }}</a> | |
77ec5a8d | 34 | <span class="crm-i fa-trash" title="{{ts('Remove')}}" |
154a0253 | 35 | ng-hide="activitySet.name == 'standard_timeline'" |
7abbf317 | 36 | ng-click="removeItem(caseType.definition.activitySets, activitySet)">{{ts('Remove')}}</span> |
059cd0c2 TO |
37 | <!-- Weird spacing: |
38 | <a class="crm-hover-button" ng-click="removeItem(caseType.definition.activitySets, activitySet)"> | |
77ec5a8d | 39 | <span class="crm-i fa-trash" title="Remove">Remove</span> |
059cd0c2 TO |
40 | </a> |
41 | --> | |
bbb29627 | 42 | </li> |
7abbf317 CW |
43 | <select class="crm-form-select" ng-model="newActivitySetWorkflow" ng-change="addActivitySet(newActivitySetWorkflow); newActivitySetWorkflow='';"> |
44 | <option value="">{{ts('Add...')}}</option> | |
45 | <option value="timeline" ng-show="isNewActivitySetAllowed('timeline')">{{ts('Timeline')}}</option> | |
46 | <option value="sequence" ng-show="isNewActivitySetAllowed('sequence')">{{ts('Sequence')}}</option> | |
76e4acb8 | 47 | </select> |
bbb29627 | 48 | </ul> |
4c58e251 | 49 | |
7c2b40d1 CW |
50 | <div id="acttab-actType" ng-include="'~/crmCaseType/activityTypesTable.html'"></div> |
51 | ||
52 | <div id="acttab-statuses" ng-include="'~/crmCaseType/statusTable.html'"></div> | |
4c58e251 | 53 | |
bbb29627 | 54 | <div ng-repeat="activitySet in caseType.definition.activitySets" id="acttab-{{$index}}"> |
4c58e251 TO |
55 | <div ng-include="activityTableTemplate(activitySet)"></div> |
56 | ||
599e58a9 | 57 | <div class="crm-accordion-wrapper collapsed"> |
7abbf317 | 58 | <div class="crm-accordion-header">{{ts('Advanced')}}</div> |
ef5d18a1 | 59 | <div class="crm-accordion-body" ng-include="'~/crmCaseType/activitySetDetails.html'"></div> |
bbb29627 TO |
60 | </div> |
61 | </div> | |
4c58e251 TO |
62 | </div> |
63 | ||
599e58a9 | 64 | <div class="crm-submit-buttons"> |
77ec5a8d | 65 | <button crm-icon="fa-check" ng-click="editCaseTypeForm.$setPristine(); save()" ng-disabled="editCaseTypeForm.$invalid"> |
7abbf317 CW |
66 | {{ts('Save')}} |
67 | </button> | |
77ec5a8d | 68 | <button crm-icon="fa-times" ng-click="editCaseTypeForm.$setPristine(); goto('caseType')"> |
7abbf317 CW |
69 | {{ts('Cancel')}} |
70 | </button> | |
c1c8b490 | 71 | </div> |
4c58e251 | 72 | </div> |
ef5d18a1 | 73 | </form> |