ソースを参照

18.回访上面要加上,回访处理结果,就是结果类型

seimin 11 ヶ月 前
コミット
9a39013b06
共有2 個のファイルを変更した33 個の追加0 個の削除を含む
  1. 17 0
      assets/js/controllers/incident/incidentCtrl.js
  2. 16 0
      assets/views/incident/tpl/callback.tpl.html

+ 17 - 0
assets/js/controllers/incident/incidentCtrl.js

@@ -1235,8 +1235,16 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
1235 1235
                     })
1236 1236
                 }
1237 1237
 
1238
+                // 获取结果类型
1239
+                $scope.getHandleResult = function(){
1240
+                    api_wechatfile.getDictionary({"key":"incident_handleresult","type":"list"}).then(function (data) {
1241
+                        $scope.handleResultList = data || [];
1242
+                    })
1243
+                }
1244
+
1238 1245
                 // 初始化
1239 1246
                 $scope.getDegree();
1247
+                $scope.getHandleResult();
1240 1248
                 $scope.ok = function () {
1241 1249
                     if (!$scope.postData.degree){
1242 1250
                         Alert.swal({
@@ -1246,8 +1254,17 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
1246 1254
                         });
1247 1255
                         return;
1248 1256
                     }
1257
+                    if (!$scope.postData.handleResult){
1258
+                        Alert.swal({
1259
+                            title: "操作失败",
1260
+                            text: "请选择结果类型!",
1261
+                            type: "error"
1262
+                        });
1263
+                        return;
1264
+                    }
1249 1265
                     let postData = {incident: {...model, ...{
1250 1266
                         degree: $scope.postData.degree,
1267
+                        handleResult: $scope.postData.handleResult,
1251 1268
                         visitRemarks: $scope.postData.visitRemarks,
1252 1269
                     }}};
1253 1270
 

+ 16 - 0
assets/views/incident/tpl/callback.tpl.html

@@ -24,6 +24,22 @@
24 24
     <div class="form-group incidentsearch" style="margin:0 auto;width: 300px;">
25 25
         <div class=" input-group" style="margin:8px 0 0;">
26 26
             <div class="control-label pull-left margin-top-5 margin-right-5">
27
+                <label class="demoincident"><span class="red">*</span>结果类型</label>:</div>
28
+            <div class="pull-right">
29
+                <ui-select class="pull-left" style="width:210px" ng-model="postData.handleResult" theme="bootstrap">
30
+                    <ui-select-match placeholder="">
31
+                        {{$select.selected.name}}
32
+                    </ui-select-match>
33
+                    <ui-select-choices repeat="item in handleResultList | filter:{$:$select.search}">
34
+                        <div ng-bind-html="item.name | highlight: $select.search"></div>
35
+                    </ui-select-choices>
36
+                </ui-select>
37
+            </div>
38
+        </div>
39
+    </div>
40
+    <div class="form-group incidentsearch" style="margin:0 auto;width: 300px;">
41
+        <div class=" input-group" style="margin:8px 0 0;">
42
+            <div class="control-label pull-left margin-top-5 margin-right-5">
27 43
                 <label class="demoincident">回访备注</label>:</div>
28 44
             <div class="pull-right">
29 45
                 <textarea rows="3" style="resize: none;width:210px" placeholder="" ng-model="postData.visitRemarks"></textarea>