CRM-14798 - crmCaseType "Reference" fields - Disable for "Open Case". Require for...
authortotten@civicrm.org <Tim Otten>
Thu, 26 Jun 2014 06:22:19 +0000 (23:22 -0700)
committertotten@civicrm.org <Tim Otten>
Thu, 26 Jun 2014 06:30:27 +0000 (23:30 -0700)
partials/crmCaseType/timelineTable.html

index 72922917b9af290c60340e185a7a358936248e07..700ad65923126927e4718fdf0e71913113722903 100644 (file)
@@ -21,22 +21,36 @@ Required vars: activitySet
       {{ activity.name }}
     </td>
     <td>
-      <!-- <select ng-model="activity.status" ng-options="value for (key,value) in activityStatuses|orderBy:'value'"> -->
-      <select ng-model="activity.status" ng-options="actStatus.name as actStatus.name for actStatus in activityStatuses|orderBy:'name'">
-        <option value=""></option>
+      <select
+        ng-model="activity.status"
+        ng-options="actStatus.name as actStatus.name for actStatus in activityStatuses|orderBy:'name'"
+        >
       </select>
     </td>
     <td>
-      <select ng-model="activity.reference_activity" ng-options="actType.name as actType.name for actType in activityTypes|orderBy:'name'">
-        <option value=""></option>
+      <select
+        ng-model="activity.reference_activity"
+        ng-options="actType.name as actType.name for actType in activityTypes|orderBy:'name'"
+        ng-hide="activity.name == 'Open Case'"
+        >
       </select>
     </td>
     <td>
-      <input class="number" type="text" ng-pattern="/^[0-9]*$/" ng-model="activity.reference_offset" />
+      <input
+        class="number"
+        type="text"
+        ng-pattern="/^[0-9]*$/"
+        ng-model="activity.reference_offset"
+        ng-hide="activity.name == 'Open Case'"
+        required
+        />
     </td>
     <td>
-      <select ng-model="activity.reference_select" ng-options="key as value for (key,value) in {newest: 'Newest', oldest: 'Oldest'}">
-        <option value=""></option>
+      <select
+        ng-model="activity.reference_select"
+        ng-options="key as value for (key,value) in {newest: 'Newest', oldest: 'Oldest'}"
+        ng-hide="activity.name == 'Open Case'"
+        >
       </select>
     </td>
     <td>