소스 검색

巡检范围增删改查

seimin 2 년 전
부모
커밋
f250eac1fc
3개의 변경된 파일865개의 추가작업 그리고 1900개의 파일을 삭제
  1. 16 16
      assets/js/controllers/inspect/inspectPlanCtrl.js
  2. 849 1858
      assets/js/controllers/inspect/inspectionScopeCtrl.js
  3. 0 26
      assets/views/system/tpl/incpectionchange.html

+ 16 - 16
assets/js/controllers/inspect/inspectPlanCtrl.js

@@ -81,9 +81,9 @@ app.controller('inspectPlanCtrl', ["$rootScope", "$scope", "$state", "$timeout",
81
     };
81
     };
82
 
82
 
83
     $scope.transfer = function (status) {
83
     $scope.transfer = function (status) {
84
-        if (status === "正常") {
84
+        if (status === "执行中") {
85
             return "执行中"
85
             return "执行中"
86
-        } else if (status === "停止") {
86
+        } else if (status === "暂停中") {
87
             return "暂停中"
87
             return "暂停中"
88
         }
88
         }
89
     }
89
     }
@@ -176,10 +176,10 @@ app.controller('inspectPlanCtrl', ["$rootScope", "$scope", "$state", "$timeout",
176
             cellTemplate: '<div class="cl-effect-1 ui-grid-cell-contents pull-left">' +
176
             cellTemplate: '<div class="cl-effect-1 ui-grid-cell-contents pull-left">' +
177
                 // '<a ng-click="grid.appScope.selectRowFunction(row.entity)" tooltip="编辑" tooltip-placement="right"><i class="icon  iconfont icon-bianji bianjifont"></i></a>' +
177
                 // '<a ng-click="grid.appScope.selectRowFunction(row.entity)" tooltip="编辑" tooltip-placement="right"><i class="icon  iconfont icon-bianji bianjifont"></i></a>' +
178
                 '<a ng-click="grid.appScope.seeFunction(row.entity)" class="bianjifont">查看</a>' +
178
                 '<a ng-click="grid.appScope.seeFunction(row.entity)" class="bianjifont">查看</a>' +
179
-                '<a ng-click="grid.appScope.selectRowFunction(row.entity)"  ng-show="{{(row.entity.status.name==\'配置中\'||row.entity.status.name==\'正常\'||row.entity.status.name==\'停止\')&&grid.appScope.bianji}}"  class="bianjifont">编辑</a>' +
179
+                '<a ng-click="grid.appScope.selectRowFunction(row.entity)"  ng-show="{{(row.entity.status.name==\'配置中\'||row.entity.status.name==\'执行中\'||row.entity.status.name==\'暂停中\')&&grid.appScope.bianji}}"  class="bianjifont">编辑</a>' +
180
                 // '<a ng-click="grid.appScope.runFunction(row.entity)" tooltip={{row.entity.runStatus}} tooltip-placement="left"><i class={{row.entity.style}}/></a>' +
180
                 // '<a ng-click="grid.appScope.runFunction(row.entity)" tooltip={{row.entity.runStatus}} tooltip-placement="left"><i class={{row.entity.style}}/></a>' +
181
-                '<a ng-click="grid.appScope.runFunction(row.entity)"  ng-show="{{row.entity.status.name==\'正常\'&&grid.appScope.zantingzhixing}}"   class="bianjifont">执行中</a>' +
182
-                '<a ng-click="grid.appScope.runFunction(row.entity)" ng-show="{{row.entity.status.name==\'停止\'&&grid.appScope.zantingzhixing}}"   class="bianjifont">暂停中</a>' +
181
+                '<a ng-click="grid.appScope.runFunction(row.entity)"  ng-show="{{row.entity.status.name==\'执行中\'&&grid.appScope.zantingzhixing}}"   class="bianjifont">暂停计划</a>' +
182
+                '<a ng-click="grid.appScope.runFunction(row.entity)" ng-show="{{row.entity.status.name==\'暂停中\'&&grid.appScope.zantingzhixing}}"   class="bianjifont">继续执行</a>' +
183
                 '</div>'
183
                 '</div>'
184
         },
184
         },
185
         // { name: 'planTime2', displayName: '截止时间', width: 160, enableFiltering: false },
185
         // { name: 'planTime2', displayName: '截止时间', width: 160, enableFiltering: false },
@@ -269,11 +269,11 @@ app.controller('inspectPlanCtrl', ["$rootScope", "$scope", "$state", "$timeout",
269
             controller: function ($scope, $modalInstance) {
269
             controller: function ($scope, $modalInstance) {
270
                 $scope.isRunFunction = true;
270
                 $scope.isRunFunction = true;
271
                 var status = "";
271
                 var status = "";
272
-                if (data.status.name == "正常") {
272
+                if (data.status.name == "执行中") {
273
                     $scope.title = '暂停巡检计划';
273
                     $scope.title = '暂停巡检计划';
274
                     $scope.connect = '确定要暂停该巡检计划?';
274
                     $scope.connect = '确定要暂停该巡检计划?';
275
                     // $scope.textLog = "是否暂停该巡检计划";
275
                     // $scope.textLog = "是否暂停该巡检计划";
276
-                } else if (data.status.name == "停止") {
276
+                } else if (data.status.name == "暂停中") {
277
                     $scope.title = '开始巡检计划';
277
                     $scope.title = '开始巡检计划';
278
                     $scope.connect = '确定要开始该巡检计划?';
278
                     $scope.connect = '确定要开始该巡检计划?';
279
                     // $scope.textLog = "是否开始该巡检计划";
279
                     // $scope.textLog = "是否开始该巡检计划";
@@ -282,11 +282,11 @@ app.controller('inspectPlanCtrl', ["$rootScope", "$scope", "$state", "$timeout",
282
                 $scope.ok = function () {
282
                 $scope.ok = function () {
283
                     // var groupdata = "123";
283
                     // var groupdata = "123";
284
                     // $modalInstance.dismiss('cancel');
284
                     // $modalInstance.dismiss('cancel');
285
-                    if (data.status.name == "正常") {
286
-                        upData.status = "停止";
285
+                    if (data.status.name == "执行中") {
286
+                        upData.status = "暂停中";
287
                         // data.style = "fa fa-pause";
287
                         // data.style = "fa fa-pause";
288
-                    } else if (data.status.name == "停止") {
289
-                        upData.status = "正常";
288
+                    } else if (data.status.name == "暂停中") {
289
+                        upData.status = "执行中";
290
                         // data.style = "fa fa-play";
290
                         // data.style = "fa fa-play";
291
                     }
291
                     }
292
 
292
 
@@ -304,7 +304,7 @@ app.controller('inspectPlanCtrl', ["$rootScope", "$scope", "$state", "$timeout",
304
 
304
 
305
         modalInstance.result.then(function (result) {
305
         modalInstance.result.then(function (result) {
306
             if (result) {
306
             if (result) {
307
-                // if(result.status=="停止"){
307
+                // if(result.status=="暂停中"){
308
                 //     result.status={"id":$scope.statusData[1].id}
308
                 //     result.status={"id":$scope.statusData[1].id}
309
                 // }else{
309
                 // }else{
310
                 //     result.status={"id":$scope.statusData[2].id}
310
                 //     result.status={"id":$scope.statusData[2].id}
@@ -617,9 +617,9 @@ app.controller('inspectPlanCtrl', ["$rootScope", "$scope", "$state", "$timeout",
617
                 }
617
                 }
618
                 console.log($scope.myData)
618
                 console.log($scope.myData)
619
                 for (var i = 0; i < $scope.myData.length; i++) {
619
                 for (var i = 0; i < $scope.myData.length; i++) {
620
-                    if ($scope.myData[i].status == "正常") {
620
+                    if ($scope.myData[i].status == "执行中") {
621
                         $scope.myData[i].style = "fa fa-play";
621
                         $scope.myData[i].style = "fa fa-play";
622
-                    } else if ($scope.myData[i].status == "停止") {
622
+                    } else if ($scope.myData[i].status == "暂停中") {
623
                         $scope.myData[i].style = "fa fa-pause";
623
                         $scope.myData[i].style = "fa fa-pause";
624
                     };
624
                     };
625
                     $scope.myData[i].runStatus = $scope.transfer($scope.myData[i].status);
625
                     $scope.myData[i].runStatus = $scope.transfer($scope.myData[i].status);
@@ -662,9 +662,9 @@ app.controller('inspectPlanCtrl', ["$rootScope", "$scope", "$state", "$timeout",
662
                 }
662
                 }
663
                 console.log($scope.myData)
663
                 console.log($scope.myData)
664
                 for (var i = 0; i < $scope.myData.length; i++) {
664
                 for (var i = 0; i < $scope.myData.length; i++) {
665
-                    if ($scope.myData[i].status == "正常") {
665
+                    if ($scope.myData[i].status == "执行中") {
666
                         $scope.myData[i].style = "fa fa-play";
666
                         $scope.myData[i].style = "fa fa-play";
667
-                    } else if ($scope.myData[i].status == "停止") {
667
+                    } else if ($scope.myData[i].status == "暂停中") {
668
                         $scope.myData[i].style = "fa fa-pause";
668
                         $scope.myData[i].style = "fa fa-pause";
669
                     };
669
                     };
670
                     $scope.myData[i].runStatus = $scope.transfer($scope.myData[i].status);
670
                     $scope.myData[i].runStatus = $scope.transfer($scope.myData[i].status);

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 849 - 1858
assets/js/controllers/inspect/inspectionScopeCtrl.js


+ 0 - 26
assets/views/system/tpl/incpectionchange.html

@@ -22,32 +22,6 @@
22
                     <multi-select-tree ng-model="add1data.parent" data-input-model="tree_1data" data-output-model="add1data.parent" theme="bootstrap" multi-select="false" data-default-label="{{thisParent.type}}" data-select-only-leafs="false" data-trans-label="label" data-switch-view="false" style="text-align: left;"></multi-select-tree>
22
                     <multi-select-tree ng-model="add1data.parent" data-input-model="tree_1data" data-output-model="add1data.parent" theme="bootstrap" multi-select="false" data-default-label="{{thisParent.type}}" data-select-only-leafs="false" data-trans-label="label" data-switch-view="false" style="text-align: left;"></multi-select-tree>
23
                 </div>
23
                 </div>
24
             </div>
24
             </div>
25
-            <!-- <div class="margin-bottom-15 anline">
26
-                <div class="pull-left openaddlable control-label fontcolor-two fontsizes-14">线下巡检默认组:</div>
27
-                <div class="pull-right openaddinput">
28
-                    <ui-select class="tab-mainDiv-body-content" ng-model="group_user_Add.offlineGroup" theme="bootstrap">
29
-                        <ui-select-match placeholder="">
30
-                            {{$select.selected.groupName}}
31
-                        </ui-select-match>
32
-                        <ui-select-choices repeat="item in groupList | filter: $select.search">
33
-                            <div ng-bind-html="item.groupName | highlight: $select.search"></div>
34
-                        </ui-select-choices>
35
-                    </ui-select>
36
-                </div>
37
-            </div>
38
-            <div class="margin-bottom-15 anline">
39
-                <div class="pull-left openaddlable control-label fontcolor-two fontsizes-14">线上巡检默认人:</div>
40
-                <div class="pull-right openaddinput">
41
-                    <ui-select class="tab-mainDiv-body-content" ng-model="group_user_Add.onlineUser" theme="bootstrap">
42
-                        <ui-select-match placeholder="">
43
-                            {{$select.selected.name}}
44
-                        </ui-select-match>
45
-                        <ui-select-choices repeat="item in userList | filter: $select.search">
46
-                            <div ng-bind-html="item.name | highlight: $select.search"></div>
47
-                        </ui-select-choices>
48
-                    </ui-select>
49
-                </div>
50
-            </div> -->
51
         </div>
25
         </div>
52
     </form>
26
     </form>
53
 </div>
27
 </div>