Преглед изворни кода

fix: 添加新的字段、修改bug

XuPengHui пре 2 година
родитељ
комит
9ade143e1b

+ 3 - 3
src/main/resources/static/app/intelligent/grainDetection/controller/insectPestDetectionCtrl.js

@@ -1,6 +1,6 @@
1 1
 "use strict";
2 2
 angular.module('app.intelligent').controller("insectPestDetectionCtrl", function ($scope, $stateParams, $state, $rootScope, insectPestDetectionService, $interval,archiveService,$filter) {
3
-
3
+    // console.log($rootScope);
4 4
     // 默认分页
5 5
     $scope.pageInfo = {pageNum: 1, pageSize: 10};
6 6
     // 筛选条件
@@ -319,7 +319,7 @@ angular.module('app.intelligent').controller("insectPestDetectionCtrl", function
319 319
 
320 320
     // 保存.
321 321
     $scope.saveData = function () {
322
-        console.log($scope.pestList);
322
+        // console.log($scope.pestList);
323 323
         if (!$scope.saveFlag) {
324 324
             if (validator.form()) {
325 325
                 // 设置saveFlag为true,防止重复提交.
@@ -346,7 +346,7 @@ angular.module('app.intelligent').controller("insectPestDetectionCtrl", function
346 346
                 });
347 347
                 hczlStr = hczlStr.slice(0, hczlStr.length - 1);
348 348
                 ckmdzjhStr = ckmdzjhStr.slice(0, ckmdzjhStr.length - 1);
349
-                console.log(hczlStr, ckmdzjhStr);
349
+                // console.log(hczlStr, ckmdzjhStr);
350 350
                 $scope.insectPests.hczl = hczlStr;
351 351
                 $scope.insectPests.ckmdzjh = ckmdzjhStr;
352 352
                 //保存熏蒸数据

+ 17 - 0
src/main/resources/static/app/intelligent/grainDetection/views/insectPestDetection-edit.html

@@ -124,6 +124,23 @@
124 124
 												</label>
125 125
 											</th>
126 126
 										</tr>
127
+										<tr>
128
+											<th>
129
+												<label label class="label" style="margin-top: 9px;text-align: center;">发生部位</label>
130
+											</th>
131
+											<th>
132
+												<section>
133
+													<label class="input">
134
+														<input class="form-control" type="text" ng-model="insectPests.fsbw"
135
+															   name="hckyxfx">
136
+													</label>
137
+												</section>
138
+											</th>
139
+											<th></th>
140
+											<th></th>
141
+											<th></th>
142
+											<th></th>
143
+										</tr>
127 144
 									</table>
128 145
 								</fieldset>
129 146
 

+ 17 - 7
src/main/resources/static/app/intelligent/grainDetection/views/insectPestDetection-list.html

@@ -58,7 +58,7 @@
58 58
                                         <th data-class="expand" style="text-align:center;">货位名称</th>
59 59
                                         <th data-class="expand" style="text-align:center;">扦样人</th>
60 60
                                         <th data-class="expand" style="text-align:center;">扦样时间</th>
61
-                                        <th data-class="expand" style="text-align:center;">通道号</th>
61
+                                        <!-- <th data-class="expand" style="text-align:center;">通道号</th> -->
62 62
                                         <th data-class="expand" style="text-align:center;">害虫种类</th>
63 63
                                         <th data-class="expand" style="text-align:center;">虫情(个)</th>
64 64
                                         <th data-class="expand" style="text-align:center;">检测人</th>
@@ -68,19 +68,29 @@
68 68
                                     </thead>
69 69
 
70 70
                                     <tbody>
71
-                                    <tr ng-repeat="insectPest in pageInfo.list">
71
+                                    <tr ng-repeat="insectPest in pageInfo.list track by $index" ng-init="parentIndex=$index">
72 72
                                         <td style="text-align:center;">{{ $index + 1 }}</td>
73 73
                                         <td style="text-align:center;">{{ storeHouseCodeObj[insectPest.vcfcode].storehouseName }}</td>
74 74
                                         <td style="text-align:center;">{{ wares[insectPest.vhwid].warehouseName }}</td>
75 75
                                         <td style="text-align:center;">{{ insectPest.standor }}</td>
76
-                                        <td style="text-align:center;">{{ insectPest.standtime | date:'yyyy-MM-dd HH:mm:ss' }}</td>
77
-                                        <td style="text-align:center;">{{ insectPest.itdh }}</td>
78
-                                        <td style="text-align:center;">{{ dicData[insectPest.hczl] }}</td>
79
-                                        <td style="text-align:center;">{{ insectPest.ivalue }}</td>
76
+                                        <td style="text-align:center;">{{ insectPest.standtime.slice(0, insectPest.standtime.length - 2) | date:'yyyy-MM-dd HH:mm:ss' }}</td>
77
+                                        <!-- <td style="text-align:center;">{{ insectPest.itdh }}</td> -->
78
+                                        <td style="text-align:center;">
79
+                                            <span ng-repeat="cIns in insectPest.hczl.split('#') track by $index">
80
+                                                <span ng-if="$index < insectPest.ckmdzjh.split('|').length - 1">{{ dicData[cIns] }}&nbsp;|</span>
81
+                                                <span ng-if="$index >= insectPest.ckmdzjh.split('|').length - 1">{{ dicData[cIns] }}</span>
82
+                                            </span>
83
+                                        </td>
84
+                                        <td style="text-align:center;">
85
+                                            <span ng-repeat="cIns in insectPest.ckmdzjh.split('|') track by $index">
86
+                                                <span ng-if="$index < insectPest.ckmdzjh.split('|').length - 1">{{ cIns }}&nbsp;|</span>
87
+                                                <span ng-if="$index >= insectPest.ckmdzjh.split('|').length - 1">{{ cIns }}</span>
88
+                                            </span>&nbsp;
89
+                                        </td>
80 90
                                         <td style="text-align:center;">{{ insectPest.vupdatepeople }}</td>
81 91
                                         <td style="text-align:center;">{{ insectPest.vupdatetime | date:'yyyy-MM-dd HH:mm:ss' }}</td>
82 92
                                         <td style="text-align:center;">
83
-                                            <a ng-hide="isArchive" ng-hide="insectPest.iTdh == null" href-void ng-click="onlyInsectPestDetection(insectPest.vCfCode)"><i class=""></i>{{storeHouseCodeObj[insectPest.vCfCode].storehouseName}}检测</a>
93
+                                            <a ng-hide="isArchive" ng-hide="insectPest.iTdh == null" href-void ng-click="onlyInsectPestDetection(insectPest.vcfcode)"><i class=""></i>{{storeHouseCodeObj[insectPest.vcfcode].storehouseName}}检测</a>
84 94
                                         </td>
85 95
                                     </tr>
86 96
                                     </tbody>