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