Merge pull request #11205 from agileware/CRM-20166
[civicrm-core.git] / ang / crmCaseType / timelineTable.html
CommitLineData
4c58e251
TO
1<!--
2Controller: CaseTypeCtrl
3Required vars: activitySet
4-->
5<table>
6 <thead>
7 <tr>
4324b8d7 8 <th></th>
7abbf317
CW
9 <th>{{ts('Activity')}}</th>
10 <th>{{ts('Status')}}</th>
11 <th>{{ts('Reference')}}</th>
12 <th>{{ts('Offset')}}</th>
13 <th>{{ts('Select')}}</th>
4c58e251
TO
14 <th></th>
15 </tr>
16 </thead>
17
c45daff0 18 <tbody ui-sortable ng-model="activitySet.activityTypes">
4c58e251
TO
19 <tr ng-repeat="activity in activitySet.activityTypes">
20 <td>
77ec5a8d 21 <i class="crm-i fa-arrows grip-n-drag"></i>
4324b8d7
CW
22 </td>
23 <td>
24 <i class="crm-i {{ activityTypes[activity.name].icon }}"></i>
be5aae33 25 {{ activity.label }}
4c58e251
TO
26 </td>
27 <td>
29d7a6e7 28 <select
a2e9f07c
TO
29 ui-jq="select2"
30 ui-options="{dropdownAutoWidth : true}"
29d7a6e7 31 ng-model="activity.status"
be5aae33 32 ng-options="actStatus.name as actStatus.label for actStatus in activityStatuses|orderBy:'label'"
29d7a6e7 33 >
24f6e9ac 34 <option value=""></option>
dc7a657e 35 </select>
4c58e251
TO
36 </td>
37 <td>
29d7a6e7 38 <select
a2e9f07c
TO
39 ui-jq="select2"
40 ui-options="{dropdownAutoWidth : true}"
29d7a6e7 41 ng-model="activity.reference_activity"
be5aae33 42 ng-options="activityType.name as activityType.label for activityType in activitySet.activityTypes"
12b84ade 43 ng-required="activity.name != ''"
29d7a6e7 44 >
12b84ade 45 <option value="">-- Case Start --</option>
dc7a657e 46 </select>
4c58e251
TO
47 </td>
48 <td>
29d7a6e7 49 <input
4324b8d7 50 class="number crm-form-text"
29d7a6e7 51 type="text"
ba0fd8dd 52 ng-pattern="/^-?[0-9]*$/"
29d7a6e7 53 ng-model="activity.reference_offset"
12b84ade 54 ng-required="activity.name != ''"
d56abcbf 55 >
4c58e251
TO
56 </td>
57 <td>
29d7a6e7 58 <select
a2e9f07c
TO
59 ui-jq="select2"
60 ui-options="{dropdownAutoWidth : true}"
29d7a6e7 61 ng-model="activity.reference_select"
69ca66d2 62 ng-options="key as value for (key,value) in {newest: ts('Newest'), oldest: ts('Oldest')}"
12b84ade 63 ng-required="activity.name != ''"
29d7a6e7 64 >
dc7a657e 65 </select>
4c58e251
TO
66 </td>
67 <td>
259a7652 68 <a class="crm-hover-button"
77ec5a8d 69 crm-icon="fa-trash"
259a7652 70 ng-show="isActivityRemovable(activitySet, activity)"
3e5e512f 71 ng-click="removeItem(activitySet.activityTypes, activity)"
7abbf317 72 title="{{ts('Remove')}}">
059cd0c2 73 </a>
4c58e251
TO
74 </td>
75 </tr>
c45daff0
TO
76 </tbody>
77
78 <tfoot>
95fd24c0
TO
79 <tr class="addRow">
80 <td colspan="6">
d56abcbf 81 <span crm-add-name=""
4324b8d7 82 crm-options="activityTypeOptions"
95fd24c0
TO
83 crm-var="newActivity"
84 crm-on-add="addActivity(activitySet, newActivity)"
00eee619 85 placeholder="{{ts('Add activity')}}"
d56abcbf 86 ></span>
95fd24c0
TO
87 </td>
88 </tr>
c45daff0 89 </tfoot>
4c58e251 90</table>