瀏覽代碼

留言列表bugfix

seimin 2 年之前
父節點
當前提交
f2d1aca615
共有 2 個文件被更改,包括 21 次插入6 次删除
  1. 19 4
      assets/js/controllers/desk/recordCtrl.js
  2. 2 2
      assets/js/controllers/incident/incidentCtrl.js

+ 19 - 4
assets/js/controllers/desk/recordCtrl.js

@@ -193,7 +193,7 @@ app.controller("recordCtrl", [
193 193
       gridApi.pagination.on.paginationChanged(
194 194
         $scope,
195 195
         function (newPage, pageSize) {
196
-          var filtersData = $scope.memoryfilterData;
196
+          var filtersData = $scope.filData;
197 197
           filtersData.idx = newPage - 1;
198 198
           filtersData.sum = pageSize;
199 199
           $scope.refreshData("expand-right", filtersData);
@@ -715,7 +715,7 @@ app.controller("recordCtrl", [
715 715
           id: data.id,
716 716
           field1: "1",
717 717
           isValid: data.isValid,
718
-          isExcute: data.isExcute,
718
+          isExcute: (data.isExcute === 0 || data.isExcute) ? data.isExcute : undefined
719 719
         })
720 720
         .then(function (data) {
721 721
           if (data.status) {
@@ -825,9 +825,14 @@ app.controller("recordCtrl", [
825 825
       } else if (data == "bushouli") {
826 826
         toData = 2;
827 827
       }
828
-      $scope.filData.hjzxRecord.isExcute = toData;
828
+      $scope.filData.idx = 0;
829
+      $scope.filData.hjzxRecord.isExcute = (toData === 0 || toData) ? toData : undefined;
830
+      if($scope.searchstate == data){
831
+        $scope.refreshData("expand-right", $scope.filData);
832
+      }else{
833
+        $scope.gridOptions.paginationCurrentPage = 0;
834
+      }
829 835
       $scope.searchstate = data;
830
-      $scope.refreshData("expand-right", $scope.filData);
831 836
     };
832 837
     // 搜索
833 838
     $scope.search = function () {
@@ -857,6 +862,15 @@ app.controller("recordCtrl", [
857 862
       }
858 863
       $scope.myData = [];
859 864
       $scope.gridOptions["sum"] = filterData.sum;
865
+      var toData = '';
866
+      if ($scope.searchstate == "weishouli") {
867
+        toData = 0;
868
+      } else if ($scope.searchstate == "yishouli") {
869
+        toData = 1;
870
+      } else if ($scope.searchstate == "bushouli") {
871
+        toData = 2;
872
+      }
873
+      filterData.hjzxRecord.isExcute = (toData === 0 || toData) ? toData : undefined;
860 874
       api_bpm_data.fetchDataList("hjzxRecord", filterData).then(
861 875
         function (data) {
862 876
           var myData = Restangular.stripRestangular(data);
@@ -883,6 +897,7 @@ app.controller("recordCtrl", [
883 897
       }
884 898
       // $scope.myData = [];
885 899
       $scope.gridOptions["sum"] = filterData.sum;
900
+      $scope.gridOptions.paginationCurrentPage = filterData.idx + 1;
886 901
       api_bpm_data.fetchDataList("hjzxRecord", filterData).then(
887 902
         function (data) {
888 903
           var myData = Restangular.stripRestangular(data);

+ 2 - 2
assets/js/controllers/incident/incidentCtrl.js

@@ -1133,7 +1133,7 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
1133 1133
             backdrop: "static",
1134 1134
             templateUrl: 'assets/views/incident/tpl/audio.html',
1135 1135
             controller: function ($rootScope, $scope, $modalInstance, $sce, $http, api_playservice) {
1136
-                // $rootScope.setbusy();
1136
+                $rootScope.setbusy();
1137 1137
                 $scope.audioUrl = "";
1138 1138
                 $http({
1139 1139
                     url: "http://192.168.77.57:8088/recording/recording?callID=" + data.callID,
@@ -1181,7 +1181,7 @@ app.controller('incidentListCtrl', ["$scope", "$http", "i18nService", "$rootScop
1181 1181
         modalInstance.result.then(function (result) {
1182 1182
             // $rootScope.setidle();
1183 1183
         }, function (reason) {
1184
-            // $rootScope.setidle();
1184
+            $rootScope.setidle();
1185 1185
         });
1186 1186
     };
1187 1187
     $scope.jry_paging = "";