Kaynağa Gözat

feat: 补单

seimin 11 ay önce
ebeveyn
işleme
9748905e99

+ 450 - 0
assets/js/controllers/mainCtrl.js

@@ -4874,6 +4874,456 @@ function ($rootScope, $scope, $state, $translate, $localStorage, $cookieStore, $
4874 4874
               },
4875 4875
             });
4876 4876
           }
4877
+          // 补单
4878
+          $scope.supplement = function(){
4879
+            if(!$scope.categorySelectId){
4880
+              SweetAlert.swal({
4881
+                  title: "提示",
4882
+                  text: "请选择故障现象!",
4883
+                  type: "error",
4884
+                  confirmButtonColor: "#DD6B55"
4885
+              });
4886
+              return;
4887
+            }
4888
+            if(!$scope.selectedDuty){
4889
+              SweetAlert.swal({
4890
+                  title: "提示",
4891
+                  text: "故障现象【"+ $scope.categorySelect.category +"】没有设置责任科室!",
4892
+                  type: "error",
4893
+                  confirmButtonColor: "#DD6B55"
4894
+              });
4895
+              return;
4896
+            }
4897
+            if(!$scope.incidentModel.department){
4898
+              SweetAlert.swal({
4899
+                  title: "提示",
4900
+                  text: "请选择报修科室!",
4901
+                  type: "error",
4902
+                  confirmButtonColor: "#DD6B55"
4903
+              });
4904
+              return;
4905
+            }
4906
+            if(!$scope.incidentModel.contactsInformation){
4907
+              SweetAlert.swal({
4908
+                  title: "提示",
4909
+                  text: "请填写联系电话!",
4910
+                  type: "error",
4911
+                  confirmButtonColor: "#DD6B55"
4912
+              });
4913
+              return;
4914
+            }
4915
+            if(!$scope.incidentModel.priority){
4916
+              SweetAlert.swal({
4917
+                  title: "提示",
4918
+                  text: "请选择优先级!",
4919
+                  type: "error",
4920
+                  confirmButtonColor: "#DD6B55"
4921
+              });
4922
+              return;
4923
+            }
4924
+            if(!$scope.incidentModel.description){
4925
+              SweetAlert.swal({
4926
+                  title: "提示",
4927
+                  text: "请选择故障描述!",
4928
+                  type: "error",
4929
+                  confirmButtonColor: "#DD6B55"
4930
+              });
4931
+              return;
4932
+            }
4933
+            $modal.open({
4934
+              templateUrl: "assets/views/newOrderSupplement.html",
4935
+              controller: function ($scope,scope,$state, $modalInstance, SweetAlert,api_bpm) {
4936
+                $scope.categorySelect = scope.categorySelect;
4937
+                console.log($scope.categorySelect)
4938
+                $scope.incidentModel = {
4939
+                  handlerMsg:'',//处理方案
4940
+                  closecode:'',//处理结果
4941
+                  acceptDate:'',//登记时间
4942
+                  responseHandleTime:'',//接单时间
4943
+                  handleTime:'',//解决时间
4944
+                  handlingPersonnelUser:'',//处理人
4945
+                };
4946
+                // 处理人模糊搜索
4947
+                $scope.jry_userSearch = function (key = "") {
4948
+                  var userData = {
4949
+                    idx: 0,
4950
+                    sum: 1000,
4951
+                    user: {
4952
+                      duty: scope.selectedDuty || undefined,
4953
+                      roledata: {rolecode: "first-line support"},
4954
+                      selectDetails:'1',
4955
+                      simple:true,
4956
+                      name: key,
4957
+                      selectType: "pinyin_qs",
4958
+                      engineer: 1,
4959
+                    },
4960
+                  };
4961
+                  api_user_data.fetchDataList("user", userData).then(function (data) {
4962
+                    $scope.jry_userData = data.list;
4963
+                  });
4964
+                };
4965
+                $scope.jry_userSearch();
4966
+                // 处理结果
4967
+                $scope.closecodeArray = [];
4968
+                $scope.jry_closecodeSearch = function () {
4969
+                  api_wechatfile
4970
+                    .getDictionary({ type: "list", key: "incident_closecode" })
4971
+                    .then(function (data) {
4972
+                      $scope.closecodeArray = data;
4973
+                    });
4974
+                };
4975
+                $scope.jry_closecodeSearch();
4976
+                // 确定
4977
+                $scope.ok = function () {
4978
+                  if($scope.categorySelect.hasSimple != 1 && !$scope.incidentModel.handlerMsg){
4979
+                    SweetAlert.swal({
4980
+                        title: "提示",
4981
+                        text: "请填写处理方案!",
4982
+                        type: "error",
4983
+                        confirmButtonColor: "#DD6B55"
4984
+                    });
4985
+                    return;
4986
+                  }
4987
+                  if(!$scope.incidentModel.closecode.id){
4988
+                    SweetAlert.swal({
4989
+                        title: "提示",
4990
+                        text: "请选择处理结果!",
4991
+                        type: "error",
4992
+                        confirmButtonColor: "#DD6B55"
4993
+                    });
4994
+                    return;
4995
+                  }
4996
+                  if(!$scope.incidentModel.acceptDate){
4997
+                    SweetAlert.swal({
4998
+                        title: "提示",
4999
+                        text: "请选择登记时间!",
5000
+                        type: "error",
5001
+                        confirmButtonColor: "#DD6B55"
5002
+                    });
5003
+                    return;
5004
+                  }
5005
+                  if(!$scope.incidentModel.responseHandleTime){
5006
+                    SweetAlert.swal({
5007
+                        title: "提示",
5008
+                        text: "请选择接单时间!",
5009
+                        type: "error",
5010
+                        confirmButtonColor: "#DD6B55"
5011
+                    });
5012
+                    return;
5013
+                  }
5014
+                  if(!$scope.incidentModel.handleTime){
5015
+                    SweetAlert.swal({
5016
+                        title: "提示",
5017
+                        text: "请选择解决时间!",
5018
+                        type: "error",
5019
+                        confirmButtonColor: "#DD6B55"
5020
+                    });
5021
+                    return;
5022
+                  }
5023
+                  if(!$scope.incidentModel.handlingPersonnelUser){
5024
+                    SweetAlert.swal({
5025
+                        title: "提示",
5026
+                        text: "请选择处理人!",
5027
+                        type: "error",
5028
+                        confirmButtonColor: "#DD6B55"
5029
+                    });
5030
+                    return;
5031
+                  }
5032
+
5033
+                  // -------新建事件,积分机制,补单-------
5034
+                  var integralMechanism = sessionStorage.getItem('integralMechanism');
5035
+                  if(integralMechanism == 1 || (integralMechanism == 2 && $rootScope.user.userType.value == 2)){
5036
+                    $modal.open({
5037
+                      templateUrl: 'assets/views/incident/tpl/toIntegralMechanism.tpl.html',
5038
+                      controller: function ($scope, $modalInstance, incidentData,categorySelect, currentUserId, Alert, api_wechatfile,scope,api_bpm_data) {
5039
+                          console.log(incidentData,currentUserId,categorySelect);
5040
+                          $scope.complexityConfirm = {complexity:null,updateReason:''};
5041
+                          $scope.complexityFn = function(category){
5042
+                            if(category.complexity){
5043
+                              return category.complexity.value;
5044
+                            }else if(category.parent){
5045
+                              return $scope.complexityFn(category.parent);
5046
+                            }else{
5047
+                              return $scope.list[0]?$scope.list[0].value:1;
5048
+                            }
5049
+                          }
5050
+                          $scope.list = [];
5051
+                          api_wechatfile.getDictionary({"key":"incident_complexity","type":"list"}).then(function(res){
5052
+                            $scope.list = res;
5053
+                            if(categorySelect && categorySelect.id){
5054
+                              api_bpm_data.fetchData("incidentCategory",categorySelect.id).then(function(result){
5055
+                                if(result.status == 200){
5056
+                                  $scope.complexity = $scope.complexityFn(result.data);
5057
+                                  $scope.complexityConfirm.complexity = $scope.list.find(v=>v.value == $scope.complexity);
5058
+                                }
5059
+                              })
5060
+                            }
5061
+                          })
5062
+                          $scope.onChangeComplexity = function(item){
5063
+
5064
+                          }
5065
+                          $scope.ok = function () {
5066
+                              if (!$scope.complexityConfirm.complexity){
5067
+                                  Alert.swal({
5068
+                                      title: "操作失败",
5069
+                                      text: "请选择工时!",
5070
+                                      type: "error"
5071
+                                  });
5072
+                                  return;
5073
+                              }
5074
+                              if ($scope.complexityConfirm.complexity.value != $scope.complexity&&!$scope.complexityConfirm.updateReason.trim()){
5075
+                                  Alert.swal({
5076
+                                      title: "操作失败",
5077
+                                      text: "请填写升级原因!",
5078
+                                      type: "error"
5079
+                                  });
5080
+                                  return;
5081
+                              }
5082
+                              $modalInstance.close('success');
5083
+                              handlerStart();
5084
+                              scope.complexity = $scope.complexity;
5085
+                              scope.complexityConfirm = $scope.complexityConfirm;
5086
+                              // 暂存--后面直接处理后调用积分接口
5087
+                          }
5088
+                          $scope.cancel = function () {
5089
+                              if (localStorage.getItem('fenjiNumber')) {
5090
+                                $rootScope.jry_shixian();
5091
+                              }
5092
+                              $modalInstance.dismiss('cancel');
5093
+                          }
5094
+                      },
5095
+                      size: 'sm',
5096
+                      resolve: {
5097
+                          scope: function () {
5098
+                              return $scope;
5099
+                          },
5100
+                          api_bpm: function () {
5101
+                              return api_bpm;
5102
+                          },
5103
+                          incidentData: function () {
5104
+                              return scope.incidentModel;
5105
+                          },
5106
+                          categorySelect: function () {
5107
+                              return scope.categorySelect;
5108
+                          },
5109
+                          currentUserId: function () {
5110
+                              return $rootScope.user.id;
5111
+                          },
5112
+                          Alert: function () {
5113
+                              return SweetAlert;
5114
+                          },
5115
+                          api_user_data: function () {
5116
+                              return api_user_data;
5117
+                          },
5118
+                          api_wechatfile: function () {
5119
+                              return api_wechatfile;
5120
+                          }
5121
+                      }
5122
+                    });
5123
+                  }else{
5124
+                    handlerStart();
5125
+                  }
5126
+                  // -------新建事件,积分机制,补单-------
5127
+                };
5128
+                // 补单,新建事件
5129
+                async function handlerStart(){
5130
+                  $rootScope.isMask = true;
5131
+                  console.log(scope.incidentModel,$scope.incidentModel);
5132
+                  var repair_main = JSON.parse(sessionStorage.getItem('repair_main'));
5133
+                  var postData = {
5134
+                    "incident": {
5135
+                      "id": scope.incidentModel.id || undefined,
5136
+                      "deleteFlag": 0,
5137
+                      "duty":scope.selectedDuty?scope.selectedDuty:undefined,
5138
+                      "requester":scope.incidentModel.requester||undefined,
5139
+                      "alarmType": false,
5140
+                      "department": scope.incidentModel.department||undefined,
5141
+                      "contactsInformation": scope.incidentModel.contactsInformation,
5142
+                      "contacts": scope.incidentModel.contacts,
5143
+                      "branch": scope.incidentModel.branch?scope.incidentModel.branch.id:undefined,
5144
+                      "area": scope.incidentModel.area||undefined,
5145
+                      "place": scope.incidentModel.place||undefined,
5146
+                      "houseNumber": scope.incidentModel.address,
5147
+                      "category": scope.categorySelect||undefined,
5148
+                      "priority": scope.incidentModel.priority||undefined,
5149
+                      "source": scope.incidentModel.source||undefined,
5150
+                      "title": scope.categorySelect.category,
5151
+                      "description": scope.incidentModel.description,
5152
+                      "directProcess": 1,
5153
+                      "handleDescription": $scope.incidentModel.handlerMsg,
5154
+                      "handlingPersonnelUser":{id:$scope.incidentModel.handlingPersonnelUser.id},
5155
+                      "yyTime": scope.incidentModel.yyTime ? moment(scope.incidentModel.yyTime).format('YYYY-MM-DD HH:mm:ss') : undefined,
5156
+                      "acceptDate": $scope.incidentModel.acceptDate ? moment($scope.incidentModel.acceptDate).format('YYYY-MM-DD HH:mm:ss') : undefined,
5157
+                      "responseHandleTime": $scope.incidentModel.responseHandleTime ? moment($scope.incidentModel.responseHandleTime).format('YYYY-MM-DD HH:mm:ss') : undefined,
5158
+                      "handleTime": $scope.incidentModel.handleTime ? moment($scope.incidentModel.handleTime).format('YYYY-MM-DD HH:mm:ss') : undefined,
5159
+                      "closecode": $scope.incidentModel.closecode||undefined,
5160
+                      "repairType": repair_main?repair_main.valueconfig:undefined,
5161
+                      "acceptUser": $scope.incidentModel.handlingPersonnelUser||undefined,
5162
+                      "callID": scope.incidentModel.callID||undefined,
5163
+                      "incomingPhone": scope.incidentModel.incomingPhone||undefined,
5164
+                    },
5165
+                  };
5166
+                  scope.modelData && (postData.incident = Object.assign({}, scope.modelData.incident, postData.incident));
5167
+                  // if(scope.modelData){
5168
+                  //   // 微信报修转事件
5169
+                  //   postData.flow = scope.modelData.flow;
5170
+                  // }
5171
+                  if(!postData.incident.incidentsign){
5172
+                    let res1 = await api_bpm_domain.workernumber('sj');
5173
+                    postData.incident.incidentsign = res1.data;
5174
+                  }
5175
+
5176
+                  // api_bpm_domain.workernumber('sj').then(res1=>{
5177
+                  //   postData.incident.incidentsign = res1.data;
5178
+                    api_flow.accept("patchOrder", postData).then(function (resData) {
5179
+                      if (scope.uploader != null) {
5180
+                        // 有图片
5181
+                          scope.uploader.onBeforeUploadItem = function(item) {
5182
+                              angular.extend(item.headers, $rootScope.getSession());
5183
+                              item.url = api_bpm_domain.uploadAttachmentJryModel("wechatRequesterIncident", resData.data.id).getRequestedUrl();
5184
+                              item.formData.push({ 'fileName': item.file.name });
5185
+                          };
5186
+                          scope.uploader.uploadAll();
5187
+                      }
5188
+                      var integralMechanism = sessionStorage.getItem('integralMechanism');
5189
+                      if(integralMechanism == 1 || (integralMechanism == 2 && $rootScope.user.userType.value == 2)){
5190
+                        api_wechatfile.getDictionary({"key":"incident_integral_state","type":"list"}).then(function(res){
5191
+                          var auditState = res.find(v=>v.value == 0);
5192
+                          var postData = {
5193
+                            incidentIntegral: {
5194
+                              incidentId:resData.bussId,
5195
+                              auditState:auditState,
5196
+                              handlerUser:$rootScope.user.id,
5197
+                              handlerUserName:$rootScope.user.name,
5198
+                              sourceScore:$scope.complexity,
5199
+                              currentScore:$scope.complexityConfirm.complexity.value,
5200
+                              updateReason:$scope.complexityConfirm.updateReason.trim() || undefined,
5201
+                            }
5202
+                          }
5203
+                          console.log(postData)
5204
+                          api_bpm_data.addData('incidentIntegral', postData).then(function (response) {
5205
+                              console.log(response)
5206
+                              $rootScope.isMask = false;
5207
+                              if (response.status == 200) {
5208
+                                SweetAlert.swal(
5209
+                                  {
5210
+                                    title: "保存成功!",
5211
+                                    type: "success",
5212
+                                    confirmButtonColor: "#007AFF",
5213
+                                  },
5214
+                                  function (isConfirm) {
5215
+                                    if(isConfirm){
5216
+                                      $modalInstance.dismiss("cancel");
5217
+                                      // 是否连续建单
5218
+                                      if(scope.btns.isBuildOrderAgagin){
5219
+                                        scope.categorySelect = "";
5220
+                                        scope.categorySelectId = 0;
5221
+                                        scope.incidentModel.assign = 1;
5222
+                                        scope.incidentModel.user = "";
5223
+                                        scope.incidentModel.group = "";
5224
+                                      }else{
5225
+                                        if (localStorage.getItem('fenjiNumber')) {
5226
+                                          $rootScope.jry_shixian();
5227
+                                        }
5228
+                                        scope.cancel();
5229
+                                      }
5230
+                                      $rootScope.newOrderShowOpen = false;
5231
+                                      if($state.current.name === 'app.incident.list'){
5232
+                                        $state.reload();
5233
+                                      }else{
5234
+                                        $state.go("app.incident.list");
5235
+                                      }
5236
+                                    }
5237
+                                  }
5238
+                                );
5239
+                              } else {
5240
+                                  Alert.swal({
5241
+                                      title: "操作失败",
5242
+                                      text: "操作失败, 请稍后再试!",
5243
+                                      type: "error"
5244
+                                  });
5245
+                              }
5246
+                          });
5247
+                        })
5248
+                      }else{
5249
+                        SweetAlert.swal(
5250
+                          {
5251
+                            title: "提交成功!",
5252
+                            type: "success",
5253
+                            confirmButtonColor: "#007AFF",
5254
+                          },
5255
+                          function (isConfirm) {
5256
+                            if(isConfirm){
5257
+                              if (localStorage.getItem('fenjiNumber')) {
5258
+                                $rootScope.jry_shixian();
5259
+                              }
5260
+                              scope.cancel();
5261
+                              $modalInstance.dismiss("cancel");
5262
+                              $rootScope.newOrderShowOpen = false;
5263
+                              if($state.current.name === 'app.incident.list'){
5264
+                                $state.reload();
5265
+                              }else{
5266
+                                $state.go("app.incident.list");
5267
+                              }
5268
+                            }
5269
+                          }
5270
+                        );
5271
+                      }
5272
+                      // -------------------------------------------
5273
+                      $rootScope.isMask = false;
5274
+                      SweetAlert.swal(
5275
+                        {
5276
+                          title: "保存成功!",
5277
+                          type: "success",
5278
+                          confirmButtonColor: "#007AFF",
5279
+                        },
5280
+                        function (isConfirm) {
5281
+                          if(isConfirm){
5282
+                            $modalInstance.dismiss("cancel");
5283
+                            // 是否连续建单
5284
+                            if(scope.btns.isBuildOrderAgagin){
5285
+                              scope.categorySelect = "";
5286
+                              scope.categorySelectId = 0;
5287
+                              scope.incidentModel.assign = 1;
5288
+                              scope.incidentModel.user = "";
5289
+                              scope.incidentModel.group = "";
5290
+                            }else{
5291
+                              if (localStorage.getItem('fenjiNumber')) {
5292
+                                $rootScope.jry_shixian();
5293
+                              }
5294
+                              scope.cancel();
5295
+                            }
5296
+                            $rootScope.newOrderShowOpen = false;
5297
+                            if($state.current.name === 'app.incident.list'){
5298
+                              $state.reload();
5299
+                            }else{
5300
+                              $state.go("app.incident.list");
5301
+                            }
5302
+                          }
5303
+                        }
5304
+                      );
5305
+                    });
5306
+                  // })
5307
+                }
5308
+                // 取消
5309
+                $scope.cancel = function () {
5310
+                  if (localStorage.getItem('fenjiNumber')) {
5311
+                    $rootScope.jry_shixian();
5312
+                  }
5313
+                  $modalInstance.dismiss("cancel");
5314
+                };
5315
+              },
5316
+              size:'lg',
5317
+              resolve: {
5318
+                SweetAlert: function () {
5319
+                  return SweetAlert;
5320
+                },
5321
+                scope: function(){
5322
+                  return $scope;
5323
+                }
5324
+              },
5325
+            });
5326
+          }
4877 5327
           // 处理顶部责任科室数据
4878 5328
           $scope.handlerDuty = function(){
4879 5329
             if(!$scope.categorySelect){

+ 1 - 0
assets/views/newOrderSeimin.html

@@ -516,6 +516,7 @@
516 516
       <button class="btn btn-primary" ng-click="build()">直接解决</button>
517 517
       <button class="btn btn-primary" ng-click="buildAndAssign()">建单并派单</button>
518 518
       <button class="btn btn-primary" ng-click="temporaryStorage()">暂存</button>
519
+      <button class="btn btn-primary" ng-click="supplement()">补单</button>
519 520
     </ng-container>
520 521
     <ng-container ng-if="newOrderType === 'edit'">
521 522
       <button class="btn btn-primary" ng-click="editSave()">保存</button>

+ 434 - 0
assets/views/newOrderSupplement.html

@@ -0,0 +1,434 @@
1
+<div>
2
+    <div class="modal-header" draggable class="modal-dialog">
3
+      <div class="modal-title fontcolor-two fontsizes-14">
4
+        补单<button
5
+          type="button"
6
+          class="close pull-right"
7
+          ng-click="cancel()"
8
+        >
9
+          ×
10
+        </button>
11
+      </div>
12
+    </div>
13
+    <div class="newOrder_content" style="width: 100%">
14
+      <div class="centerList" style="height: 250px;">
15
+        <div class="body clearfix">
16
+          <div class="c_item c_item_value_textarea clearfix">
17
+            <label><span class="colorRed">*</span>处理方案:</label>
18
+            <textarea
19
+              class="c_item_value"
20
+              ng-model="incidentModel.handlerMsg"
21
+              placeholder="请填写处理方案"
22
+            ></textarea>
23
+          </div>
24
+          <div class="c_item clearfix">
25
+            <label><span class="colorRed">*</span>处理结果:</label>
26
+            <ui-select
27
+              class="c_item_value"
28
+              ng-model="incidentModel.closecode"
29
+              theme="bootstrap"
30
+            >
31
+              <ui-select-match placeholder="请选择处理结果">
32
+                <span ng-bind="$select.selected.name"> </span>
33
+              </ui-select-match>
34
+              <ui-select-choices
35
+                repeat="item in (closecodeArray | filter:$select.search) track by item.id"
36
+              >
37
+                <span ng-bind="item.name"></span>
38
+              </ui-select-choices>
39
+            </ui-select>
40
+          </div>
41
+          <div class="c_item clearfix">
42
+            <label><span class="colorRed">*</span>登记时间:</label>
43
+            <span class="input-icon" style="float: left">
44
+              <input
45
+                type="text"
46
+                class="c_item_value underline"
47
+                style="width: 175px"
48
+                ng-click="endOpen = !endOpen"
49
+                datepicker-popup="yyyy-MM-dd HH:mm:ss"
50
+                ng-model="incidentModel.acceptDate"
51
+                is-open="endOpen"
52
+                close-on-date-selection="false"
53
+                ng-init="endOpen = false"
54
+                close-text="关闭"
55
+                current-text="今天"
56
+                clear-text="清空"
57
+                save-text="确定"
58
+                show-weeks="false"
59
+              />
60
+              <i class="ti-calendar"></i>
61
+            </span>
62
+          </div>
63
+          <div class="c_item clearfix">
64
+            <label><span class="colorRed">*</span>接单时间:</label>
65
+            <span class="input-icon" style="float: left">
66
+              <input
67
+                type="text"
68
+                class="c_item_value underline"
69
+                style="width: 175px"
70
+                ng-click="endOpen1 = !endOpen1"
71
+                datepicker-popup="yyyy-MM-dd HH:mm:ss"
72
+                ng-model="incidentModel.responseHandleTime"
73
+                is-open="endOpen1"
74
+                close-on-date-selection="false"
75
+                ng-init="endOpen1 = false"
76
+                close-text="关闭"
77
+                current-text="今天"
78
+                clear-text="清空"
79
+                save-text="确定"
80
+                show-weeks="false"
81
+              />
82
+              <i class="ti-calendar"></i>
83
+            </span>
84
+          </div>
85
+          <div class="c_item clearfix">
86
+            <label><span class="colorRed">*</span>解决时间:</label>
87
+            <span class="input-icon" style="float: left">
88
+              <input
89
+                type="text"
90
+                class="c_item_value underline"
91
+                style="width: 175px"
92
+                ng-click="endOpen2 = !endOpen2"
93
+                datepicker-popup="yyyy-MM-dd HH:mm:ss"
94
+                ng-model="incidentModel.handleTime"
95
+                is-open="endOpen2"
96
+                close-on-date-selection="false"
97
+                ng-init="endOpen2 = false"
98
+                close-text="关闭"
99
+                current-text="今天"
100
+                clear-text="清空"
101
+                save-text="确定"
102
+                show-weeks="false"
103
+              />
104
+              <i class="ti-calendar"></i>
105
+            </span>
106
+          </div>
107
+          <div class="c_item clearfix">
108
+            <label><span class="colorRed">*</span>处理人:</label>
109
+            <ui-select
110
+              class="c_item_value"
111
+              style="min-width: 300px"
112
+              ng-model="incidentModel.handlingPersonnelUser"
113
+              theme="bootstrap"
114
+              ng-required="true"
115
+              reset-search-input="false"
116
+            >
117
+              <ui-select-match placeholder="请选择处理人">
118
+                <span ng-bind="$select.selected.name"></span>
119
+              </ui-select-match>
120
+              <ui-select-choices
121
+                repeat="item in jry_userData| filter:{$:$select.search}"
122
+                refresh="jry_userSearch($select.search)"
123
+              >
124
+                <div
125
+                  ng-bind-html="item.name | highlight: $select.search"
126
+                ></div>
127
+              </ui-select-choices>
128
+            </ui-select>
129
+          </div>
130
+        </div>
131
+      </div>
132
+    </div>
133
+    <div class="modal-footer">
134
+      <button class="btn btn-primary" ng-click="ok()">确定</button>
135
+      <button class="btn btn-primary btn-o" ng-click="cancel()">取消</button>
136
+    </div>
137
+  </div>
138
+  <style>
139
+    @media (min-width: 768px) {
140
+      .modal-dialog {
141
+        width: 1300px;
142
+        margin: 30px auto;
143
+        height: 100%;
144
+      }
145
+    }
146
+    .newOrder_content input::-webkit-input-placeholder {
147
+      /* Chrome/Opera/Safari */
148
+      color: #c2c2c5;
149
+    }
150
+    .newOrder_content input:-ms-input-placeholder {
151
+      /* IE 10+ */
152
+      color: #c2c2c5;
153
+    }
154
+    .newOrder_content input:-moz-placeholder {
155
+      /* Firefox 18- */
156
+      color: #c2c2c5;
157
+      opacity: 1;
158
+    }
159
+    .newOrder_content input::-moz-placeholder {
160
+      /* Firefox 19+ */
161
+      color: #c2c2c5;
162
+      opacity: 1;
163
+    }
164
+
165
+    .newOrder_content textarea::-webkit-input-placeholder {
166
+      /* Chrome/Opera/Safari */
167
+      color: #c2c2c5;
168
+    }
169
+    .newOrder_content textarea:-ms-input-placeholder {
170
+      /* IE 10+ */
171
+      color: #c2c2c5;
172
+    }
173
+    .newOrder_content textarea:-moz-placeholder {
174
+      /* Firefox 18- */
175
+      color: #c2c2c5;
176
+      opacity: 1;
177
+    }
178
+    .newOrder_content textarea::-moz-placeholder {
179
+      /* Firefox 19+ */
180
+      color: #c2c2c5;
181
+      opacity: 1;
182
+    }
183
+
184
+    .newOrder_content .colorRed {
185
+      color: red;
186
+    }
187
+    .newOrder_content .imgsBox {
188
+      display: flex;
189
+      justify-content: space-between;
190
+      padding: 10px 10px;
191
+      background: #f9f9f9;
192
+    }
193
+    .newOrder_content .fileupload {
194
+      width: 64px;
195
+      height: 64px;
196
+      border: 1px dotted #ccc;
197
+      display: inline-block;
198
+      background: #fff;
199
+      border-radius: 5px;
200
+      color: #d8d8d8;
201
+    }
202
+
203
+    .newOrder_content .fileupload-icon {
204
+      font-size: 32px;
205
+      position: absolute;
206
+      top: 50%;
207
+      left: 50%;
208
+      transform: translate(-50%, -50%);
209
+    }
210
+    .newOrder_content .close {
211
+      position: absolute;
212
+      top: -5px;
213
+      right: -6px;
214
+      font-size: 16px;
215
+      display: inline-block;
216
+      width: 14px;
217
+      height: 14px;
218
+      color: #fff;
219
+      background: #bd2535;
220
+      line-height: 8px;
221
+      text-align: center;
222
+      border-radius: 9px;
223
+      border: 1px solid #bd2535;
224
+      opacity: 1;
225
+      overflow: hidden;
226
+    }
227
+
228
+    .newOrder_content .close:hover {
229
+      opacity: 0.8;
230
+    }
231
+    .newOrder_content .category {
232
+      margin-right: 8px;
233
+    }
234
+    .newOrder_content .newOrder_body {
235
+      height: 652px;
236
+      overflow-y: auto;
237
+    }
238
+    .newOrder_content .newOrder_category li {
239
+      font-size: 14px;
240
+      color: #606367;
241
+      padding: 8px;
242
+      border-bottom: 1px dashed #d3d3d3;
243
+    }
244
+    .newOrder_content .newOrder_l li {
245
+      cursor: pointer;
246
+    }
247
+    .newOrder_content .newOrder_l li.active {
248
+      background-color: #d3d3d3;
249
+    }
250
+    .newOrder_content .newOrder_l li:hover {
251
+      background-color: #d3d3d3;
252
+    }
253
+    .newOrder_content .newOrder_r_item {
254
+      display: flex;
255
+      align-items: center;
256
+      justify-content: space-between;
257
+      padding: 4px 0;
258
+    }
259
+    .newOrder_content .newOrder_r_item .ll {
260
+      flex: 1;
261
+      text-align: left;
262
+    }
263
+    .newOrder_content .newOrder_r_item .rr {
264
+      flex: 1;
265
+      text-align: right;
266
+    }
267
+
268
+    .jry_positionFather .describe {
269
+      width: 430px;
270
+    }
271
+
272
+    .jry_positionChild {
273
+      position: absolute;
274
+      height: 20px;
275
+      margin-top: -10px;
276
+      right: 14px;
277
+      top: 50%;
278
+    }
279
+
280
+    .jry_positionFather {
281
+      position: relative;
282
+      width: 100%;
283
+    }
284
+
285
+    .jry_item {
286
+      display: inline-block;
287
+      margin-left: 5px;
288
+    }
289
+
290
+    .jry_icon {
291
+      position: absolute;
292
+      right: 0;
293
+      top: 0;
294
+      display: inline-block;
295
+      width: 20px;
296
+      height: 30px;
297
+      text-align: center;
298
+      line-height: 30px;
299
+      border: 1px rgb(211, 211, 211) solid;
300
+      background-color: white;
301
+      border-radius: 0 4px 4px 0;
302
+    }
303
+
304
+    .DingW {
305
+      position: relative;
306
+      display: flex;
307
+      justify-content: center;
308
+      height: 36px;
309
+      line-height: 36px;
310
+      border-bottom: 1px solid #d3d3d3;
311
+    }
312
+    .DingW .ui-select-match {
313
+      line-height: normal;
314
+    }
315
+    .DingW .tab_name {
316
+      flex: 1;
317
+      text-align: center;
318
+      cursor: pointer;
319
+      border-right: 1px solid #d3d3d3;
320
+    }
321
+    .DingW .tab_name:last-of-type {
322
+      border-right: none;
323
+    }
324
+    .DingW .tab_name.active {
325
+      color: #fff;
326
+      background-color: #006bc0;
327
+    }
328
+
329
+    .SJFL_ipt {
330
+      width: 100%;
331
+      height: 30px;
332
+      border-radius: 4px 0 0 4px !important;
333
+    }
334
+
335
+    .radio_left {
336
+      width: 40px;
337
+      display: flex;
338
+      align-items: center;
339
+      justify-content: center;
340
+    }
341
+
342
+    .list {
343
+      padding: 10px 0;
344
+      border-bottom: 1px rgb(211, 211, 211) solid;
345
+      border-top: 1px rgb(211, 211, 211) solid;
346
+      display: flex;
347
+    }
348
+
349
+    .noData {
350
+      display: flex;
351
+      width: 100%;
352
+      height: 100%;
353
+      justify-content: center;
354
+      align-items: center;
355
+      border-bottom: none !important;
356
+      padding-top: 30px !important;
357
+    }
358
+
359
+    .noData img {
360
+      width: 120px;
361
+    }
362
+
363
+    .newOrder_content {
364
+      display: flex;
365
+    }
366
+
367
+    .leftList {
368
+      width: 280px;
369
+      background-color: rgb(245, 245, 245);
370
+      height: 700px;
371
+      margin: 4px;
372
+      border: 1px rgb(211, 211, 211) solid;
373
+      border-radius: 4px;
374
+      padding: 5px;
375
+    }
376
+
377
+    .centerList {
378
+      /* width: 778px; */
379
+      flex: 1;
380
+      background-color: rgb(245, 245, 245);
381
+      height: 700px;
382
+      margin: 4px;
383
+      border: 1px rgb(211, 211, 211) solid;
384
+      border-radius: 4px;
385
+      padding: 5px;
386
+    }
387
+    .centerList .c_item {
388
+      height: 30px;
389
+      margin-top: 16px;
390
+      margin-right: 8px;
391
+      float: left;
392
+    }
393
+    .centerList .c_item .c_item_value {
394
+      min-width: 165px;
395
+      height: 30px;
396
+      float: left;
397
+    }
398
+    .centerList .c_item input[type="text"].c_item_value {
399
+      width: 165px;
400
+    }
401
+    .centerList .c_item_value_textarea {
402
+      width: 100%;
403
+      height: 100px;
404
+      display: flex;
405
+    }
406
+    .centerList .c_item_value_textarea .c_item_value {
407
+      flex: 1;
408
+      height: 100px;
409
+      resize: none;
410
+    }
411
+    .centerList .c_item label {
412
+      float: left;
413
+      line-height: 30px;
414
+      margin: 0;
415
+    }
416
+
417
+    .rightList {
418
+      width: 280px;
419
+      background-color: rgb(245, 245, 245);
420
+      height: 700px;
421
+      margin: 4px;
422
+      border: 1px rgb(211, 211, 211) solid;
423
+      border-radius: 4px;
424
+      padding: 5px;
425
+    }
426
+
427
+    .head {
428
+      color: #005395;
429
+      font-size: 12px;
430
+      height: 30px;
431
+      line-height: 30px;
432
+      border-bottom: 1px rgb(211, 211, 211) solid;
433
+    }
434
+  </style>

+ 28 - 7
bower_components/angular-bootstrap/ui-bootstrap-tpls.js

@@ -2020,9 +2020,18 @@ angular.module('ui.bootstrap.datepicker', ['ui.bootstrap.dateparser', 'ui.bootst
2020 2020
                 if(scope.$parent.model){
2021 2021
                     scope.hours = (new Date(Date.parse(scope.$parent.model[scope.$parent.options.key]))).getHours();
2022 2022
                     scope.minutes = (new Date(Date.parse(scope.$parent.model[scope.$parent.options.key]))).getMinutes();
2023
-                }else if(scope.$parent.incidentModel){
2023
+                }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.yyTime){
2024 2024
                     scope.hours = scope.$parent.incidentModel.yyTime.getHours();
2025 2025
                     scope.minutes = scope.$parent.incidentModel.yyTime.getMinutes();
2026
+                }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.acceptDate && scope.$parent.endOpen){
2027
+                    scope.hours = scope.$parent.incidentModel.acceptDate.getHours();
2028
+                    scope.minutes = scope.$parent.incidentModel.acceptDate.getMinutes();
2029
+                }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.responseHandleTime && scope.$parent.endOpen1){
2030
+                    scope.hours = scope.$parent.incidentModel.responseHandleTime.getHours();
2031
+                    scope.minutes = scope.$parent.incidentModel.responseHandleTime.getMinutes();
2032
+                }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.handleTime && scope.$parent.endOpen2){
2033
+                    scope.hours = scope.$parent.incidentModel.handleTime.getHours();
2034
+                    scope.minutes = scope.$parent.incidentModel.handleTime.getMinutes();
2026 2035
                 }
2027 2036
                 scope.incrementHours = function() {
2028 2037
                     addMinutes(1 * 60);
@@ -2030,17 +2039,29 @@ angular.module('ui.bootstrap.datepicker', ['ui.bootstrap.dateparser', 'ui.bootst
2030 2039
                 scope.save = function(hours, minutes) {
2031 2040
                     if(scope.$parent.model){
2032 2041
                         scope.$parent.model[scope.$parent.options.key] = moment((new Date(Date.parse(scope.$parent.model[scope.$parent.options.key]))).setHours(hours, minutes)).format('YYYY-MM-DD HH:mm:ss');
2033
-                    }else if(scope.$parent.incidentModel){
2034
-                        scope.$parent.incidentModel.yyTime = moment((new Date(Date.parse(scope.$parent.model[scope.$parent.options.key]))).setHours(hours, minutes)).format('YYYY-MM-DD HH:mm:ss');
2042
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.yyTime){
2043
+                        scope.$parent.incidentModel.yyTime = moment((new Date(Date.parse(scope.$parent.incidentModel.yyTime))).setHours(hours, minutes)).format('YYYY-MM-DD HH:mm:ss');
2044
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.acceptDate && scope.$parent.endOpen){
2045
+                        scope.$parent.incidentModel.acceptDate = moment((new Date(Date.parse(scope.$parent.incidentModel.acceptDate))).setHours(hours, minutes)).format('YYYY-MM-DD HH:mm:ss');
2046
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.responseHandleTime && scope.$parent.endOpen1){
2047
+                        scope.$parent.incidentModel.responseHandleTime = moment((new Date(Date.parse(scope.$parent.incidentModel.responseHandleTime))).setHours(hours, minutes)).format('YYYY-MM-DD HH:mm:ss');
2048
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.handleTime && scope.$parent.endOpen2){
2049
+                        scope.$parent.incidentModel.handleTime = moment((new Date(Date.parse(scope.$parent.incidentModel.handleTime))).setHours(hours, minutes)).format('YYYY-MM-DD HH:mm:ss');
2035 2050
                     }
2036 2051
                     scope.isOpen = false;
2037 2052
                 };
2038 2053
                 scope.updateHours = function(dates) { //手动填写时
2039 2054
                     //  scope.hours =(new Date(new Date(new Date(Date.parse(scope.$parent.model[scope.$parent.options.key]))).setHours( minutes))).getHours();
2040 2055
                     if(scope.$parent.model){
2041
-                        scope.$parent.model[scope.$parent.options.key] = moment(new Date(dates)).format('YYYY-MM-DD HH:mm:ss');
2042
-                    }else if(scope.$parent.incidentModel){
2043
-                        scope.$parent.incidentModel.yyTime = moment(new Date(dates)).format('YYYY-MM-DD HH:mm:ss');
2056
+                        scope.$parent.model[scope.$parent.options.key] = moment(new Date(dates)).startOf('minute').format('YYYY-MM-DD HH:mm:ss');
2057
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.yyTime){
2058
+                        scope.$parent.incidentModel.yyTime = moment(new Date(dates)).startOf('minute').format('YYYY-MM-DD HH:mm:ss');
2059
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.acceptDate && scope.$parent.endOpen){
2060
+                        scope.$parent.incidentModel.acceptDate = moment(new Date(dates)).startOf('minute').format('YYYY-MM-DD HH:mm:ss');
2061
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.responseHandleTime && scope.$parent.endOpen1){
2062
+                        scope.$parent.incidentModel.responseHandleTime = moment(new Date(dates)).startOf('minute').format('YYYY-MM-DD HH:mm:ss');
2063
+                    }else if(scope.$parent.incidentModel && scope.$parent.incidentModel.handleTime && scope.$parent.endOpen2){
2064
+                        scope.$parent.incidentModel.handleTime = moment(new Date(dates)).startOf('minute').format('YYYY-MM-DD HH:mm:ss');
2044 2065
                     }
2045 2066
                 }
2046 2067
             }
@@ -4104,7 +4125,7 @@ angular.module('ui.bootstrap.typeahead', ['ui.bootstrap.position', 'ui.bootstrap
4104 4125
                 //we need to propagate user's query so we can higlight matches
4105 4126
                 scope.query = undefined;
4106 4127
 
4107
-                //Declare the timeout promise var outside the function scope so that stacked calls can be cancelled later 
4128
+                //Declare the timeout promise var outside the function scope so that stacked calls can be cancelled later
4108 4129
                 var timeoutPromise;
4109 4130
 
4110 4131
                 var scheduleSearchWithTimeout = function(inputValue) {