XMLWAN 4 年前
父节点
当前提交
7f24d26dda
共有 2 个文件被更改,包括 492 次插入3 次删除
  1. 234 0
      src/api/device.js
  2. 258 3
      src/xt_pages/management/components/QualityForm.vue

+ 234 - 0
src/api/device.js 查看文件

@@ -0,0 +1,234 @@
1
+import request from '@/utils/request'
2
+
3
+export function saveOxygenates(id, data) {
4
+  return request({
5
+    url: '/api/manage/saveoxygenates?id=' + id,
6
+    method: 'Post',
7
+    data: data
8
+  })
9
+}
10
+
11
+export function saveHardWater(id,data){
12
+  return request({
13
+    url:"/api/manage/savehardwater?id="+id,
14
+    method:"Post",
15
+    data:data
16
+  })
17
+}
18
+
19
+export function saveWater(id,data){
20
+  return request({
21
+    url:"/api/manage/savewater?id="+id,
22
+    method:"Post",
23
+    data:data
24
+  })
25
+}
26
+
27
+export function saveDevicePH(id,data){
28
+  return request({
29
+    url:"/api/manage/savedeviceph?id="+id,
30
+    method:"Post",
31
+    data:data,
32
+  })
33
+}
34
+
35
+export function editOxygenates(id,params){
36
+  
37
+  return request({
38
+    url:"/api/manage/editoxygenates?id="+id,
39
+    method:"get",
40
+    params:params
41
+  })
42
+}
43
+
44
+export function UpdateOxygenates(data) {
45
+    return request({
46
+      url: '/api/manage/updateoxygenates',
47
+      method: 'post',
48
+      data: data
49
+    })
50
+}
51
+
52
+export function editHardWater(id,params){
53
+   return request({
54
+      url:"/api/manage/edithardwater?id="+id,
55
+      method:"Get",
56
+      params:params
57
+   })
58
+}
59
+
60
+export function editWater(id,params){
61
+   return request({
62
+     url:"/api/manage/editwater?id="+id,
63
+     method:"get",
64
+     params:params
65
+   })
66
+}
67
+
68
+export function editDevicePh(id,params){
69
+  return request({
70
+    url:"/api/manage/editdeviceph?id="+id,
71
+    method:"get",
72
+    params:params
73
+  })
74
+}
75
+
76
+export function getAllDoctorList(params){
77
+   return request({
78
+     url:"/api/manage/getalldoctlist",
79
+     method:"get",
80
+     params:params
81
+   })
82
+}
83
+
84
+export function saveAirDisinfect(params){
85
+    return request({
86
+      url:"/api/manage/saveairdisinfect",
87
+      method:"get",
88
+      params:params
89
+    })
90
+}
91
+
92
+export function getAirList(params){
93
+    
94
+    return request({
95
+      url:"/api/manage/getairlist",
96
+      method:"get",
97
+      params:params
98
+    })
99
+}
100
+
101
+export function getAirDisinfectDetail(id,params){
102
+   
103
+  return request({
104
+    url:"/api/manage/getairdisinfctdetal?id="+id,
105
+    method:"Get",
106
+    params:params
107
+  })
108
+}
109
+
110
+export function updateAirDisinfect(params){
111
+  
112
+  return request({
113
+    url:"/api/manage/updateairdisinfect",
114
+    method:"Get",
115
+    params:params
116
+  })
117
+}
118
+
119
+export function deleteAirDisinfect(id,params){
120
+  
121
+  return request({
122
+    url:"/api/manage/deleteairdisinfect?id="+id,
123
+    method:"get",
124
+    params:params,
125
+  })
126
+}
127
+
128
+export function saveBodyDisinfect(params){
129
+   
130
+  return request({
131
+    url:"/api/manage/savebodydisinfect",
132
+    method:"Get",
133
+    params:params
134
+  })
135
+}
136
+
137
+export function getBodyList(params){
138
+  
139
+  return request({
140
+    url:"/api/manage/getbodylist",
141
+    method:"get",
142
+    params:params
143
+  })
144
+}
145
+
146
+export function getBodyDisinfectDetail(id,params){
147
+  
148
+  return request({
149
+    url:"/api/manage/getbodydisinfectdetal?id="+id,
150
+    method:"Get",
151
+    params:params
152
+  })
153
+}
154
+
155
+export function updateBodyDisinfect(params){
156
+  
157
+  return request({
158
+    url:"/api/manage/updatebodydisinfect",
159
+    method:"get",
160
+    params:params
161
+  })
162
+}
163
+
164
+export function deleteBodyDisinfect(id,params){
165
+  
166
+  return request({
167
+    url:"/api/manage/deletebodydisinfect?id="+id,
168
+    method:"get",
169
+    params:params
170
+  })
171
+}
172
+
173
+export function UpdateHadWater(data){
174
+  
175
+  return request({
176
+    url:"/api/manage/updatehadwater",
177
+    method:"post",
178
+    data:data,
179
+  })
180
+}
181
+
182
+export function updateWater(data){
183
+
184
+  return request({
185
+    url:"/api/manage/updatewater",
186
+    method:"post",
187
+    data:data
188
+  })
189
+}
190
+
191
+export function updateDevicePh(data){
192
+  
193
+  return request({
194
+    url:"/api/manage/updatedeviceph",
195
+    method:"post",
196
+    data:data
197
+  })
198
+}
199
+
200
+export function DeleteOxygenates(id,params){
201
+   
202
+  return request({
203
+    url:"/api/manage/deleteoxygenates?id="+id,
204
+    method:"get",
205
+    params:params
206
+  })
207
+} 
208
+
209
+export function DeleteHadWater(id,params){
210
+  
211
+  return request({
212
+    url:"/api/manage/deletehadwater?id="+id,
213
+    method:"get",
214
+    params:params
215
+  })
216
+}
217
+
218
+export function DeleteWater(id,params){
219
+  
220
+  return request({
221
+    url:"/api/manage/deletewater?id="+id,
222
+    method:"get",
223
+    params:params
224
+  })
225
+}
226
+
227
+export function DeleteDevicePh(id,params){
228
+  
229
+  return request({
230
+    url:"/api/manage/deletedeviceph?id="+id,
231
+    method:"Get",
232
+    params:params
233
+  })
234
+}

+ 258 - 3
src/xt_pages/management/components/QualityForm.vue 查看文件

@@ -173,6 +173,38 @@
173 173
             {{ getTime(scope.row.reporting_date) }}
174 174
           </template>
175 175
         </el-table-column>
176
+        <el-table-column
177
+          prop="address"
178
+          label="顺序号"
179
+          width="110"
180
+          align="center"
181
+        >
182
+          <template slot-scope="scope">
183
+            {{scope.row.sort}}
184
+          </template>
185
+        </el-table-column>
186
+        <el-table-column
187
+          prop="address"
188
+          label="检查合格"
189
+          width="110"
190
+          align="center"
191
+        >
192
+          <template slot-scope="scope">
193
+            <span v-if="scope.row.pass_examination == 1">是</span> 
194
+            <span v-if="scope.row.pass_examination == 2">否</span> 
195
+          </template>
196
+        </el-table-column>
197
+        <el-table-column
198
+          prop="address"
199
+          label="修改标志"
200
+          width="110"
201
+          align="center"
202
+        >
203
+          <template slot-scope="scope">
204
+            <span v-if="scope.row.modifications == 1">正常</span> 
205
+            <span v-if="scope.row.modifications == 2">撤消</span> 
206
+          </template>
207
+        </el-table-column>
176 208
         <el-table-column
177 209
           prop="address"
178 210
           label="检测结果(cfu/ml)"
@@ -311,6 +343,38 @@
311 343
           <template slot-scope="scope">
312 344
             {{ getTime(scope.row.reporting_dateb) }}
313 345
           </template>
346
+        </el-table-column>
347
+           <el-table-column
348
+          prop="address"
349
+          label="顺序号"
350
+          width="110"
351
+          align="center"
352
+        >
353
+          <template slot-scope="scope">
354
+            {{scope.row.sort}}
355
+          </template>
356
+        </el-table-column>
357
+        <el-table-column
358
+          prop="address"
359
+          label="检查合格"
360
+          width="110"
361
+          align="center"
362
+        >
363
+          <template slot-scope="scope">
364
+            <span v-if="scope.row.pass_examination == 1">是</span> 
365
+            <span v-if="scope.row.pass_examination == 2">否</span> 
366
+          </template>
367
+        </el-table-column>
368
+        <el-table-column
369
+          prop="address"
370
+          label="修改标志"
371
+          width="110"
372
+          align="center"
373
+        >
374
+          <template slot-scope="scope">
375
+            <span v-if="scope.row.modifications == 1">正常</span> 
376
+            <span v-if="scope.row.modifications == 2">撤消</span> 
377
+          </template>
314 378
         </el-table-column>
315 379
         <el-table-column
316 380
           prop="address"
@@ -430,6 +494,38 @@
430 494
           <template slot-scope="scope">
431 495
             {{ getTime(scope.row.date_reportc) }}
432 496
           </template>
497
+        </el-table-column>
498
+           <el-table-column
499
+          prop="address"
500
+          label="顺序号"
501
+          width="110"
502
+          align="center"
503
+        >
504
+          <template slot-scope="scope">
505
+            {{scope.row.sort}}
506
+          </template>
507
+        </el-table-column>
508
+        <el-table-column
509
+          prop="address"
510
+          label="检查合格"
511
+          width="110"
512
+          align="center"
513
+        >
514
+          <template slot-scope="scope">
515
+            <span v-if="scope.row.pass_examination == 1">是</span> 
516
+            <span v-if="scope.row.pass_examination == 2">否</span> 
517
+          </template>
518
+        </el-table-column>
519
+        <el-table-column
520
+          prop="address"
521
+          label="修改标志"
522
+          width="110"
523
+          align="center"
524
+        >
525
+          <template slot-scope="scope">
526
+            <span v-if="scope.row.modifications == 1">正常</span> 
527
+            <span v-if="scope.row.modifications == 2">撤消</span> 
528
+          </template>
433 529
         </el-table-column>
434 530
         <el-table-column
435 531
           prop="address"
@@ -632,6 +728,38 @@
632 728
           <template slot-scope="scope">
633 729
             {{ getTime(scope.row.reporting_dateb) }}
634 730
           </template>
731
+        </el-table-column>
732
+           <el-table-column
733
+          prop="address"
734
+          label="顺序号"
735
+          width="110"
736
+          align="center"
737
+        >
738
+          <template slot-scope="scope">
739
+            {{scope.row.sort}}
740
+          </template>
741
+        </el-table-column>
742
+        <el-table-column
743
+          prop="address"
744
+          label="检查合格"
745
+          width="110"
746
+          align="center"
747
+        >
748
+          <template slot-scope="scope">
749
+            <span v-if="scope.row.pass_examination == 1">是</span> 
750
+            <span v-if="scope.row.pass_examination == 2">否</span> 
751
+          </template>
752
+        </el-table-column>
753
+        <el-table-column
754
+          prop="address"
755
+          label="修改标志"
756
+          width="110"
757
+          align="center"
758
+        >
759
+          <template slot-scope="scope">
760
+            <span v-if="scope.row.modifications == 1">正常</span> 
761
+            <span v-if="scope.row.modifications == 2">撤消</span> 
762
+          </template>
635 763
         </el-table-column>
636 764
         <el-table-column
637 765
           prop="address"
@@ -770,6 +898,38 @@
770 898
           <template slot-scope="scope">
771 899
             {{ getTime(scope.row.reporting_dateb) }}
772 900
           </template>
901
+        </el-table-column>
902
+           <el-table-column
903
+          prop="address"
904
+          label="顺序号"
905
+          width="110"
906
+          align="center"
907
+        >
908
+          <template slot-scope="scope">
909
+            {{scope.row.sort}}
910
+          </template>
911
+        </el-table-column>
912
+        <el-table-column
913
+          prop="address"
914
+          label="检查合格"
915
+          width="110"
916
+          align="center"
917
+        >
918
+          <template slot-scope="scope">
919
+            <span v-if="scope.row.pass_examination == 1">是</span> 
920
+            <span v-if="scope.row.pass_examination == 2">否</span> 
921
+          </template>
922
+        </el-table-column>
923
+        <el-table-column
924
+          prop="address"
925
+          label="修改标志"
926
+          width="110"
927
+          align="center"
928
+        >
929
+          <template slot-scope="scope">
930
+            <span v-if="scope.row.modifications == 1">正常</span> 
931
+            <span v-if="scope.row.modifications == 2">撤消</span> 
932
+          </template>
773 933
         </el-table-column>
774 934
         <el-table-column
775 935
           prop="address"
@@ -908,6 +1068,38 @@
908 1068
           <template slot-scope="scope">
909 1069
             {{ getTime(scope.row.reporting_dateb) }}
910 1070
           </template>
1071
+        </el-table-column>
1072
+           <el-table-column
1073
+          prop="address"
1074
+          label="顺序号"
1075
+          width="110"
1076
+          align="center"
1077
+        >
1078
+          <template slot-scope="scope">
1079
+            {{scope.row.sort}}
1080
+          </template>
1081
+        </el-table-column>
1082
+        <el-table-column
1083
+          prop="address"
1084
+          label="检查合格"
1085
+          width="110"
1086
+          align="center"
1087
+        >
1088
+          <template slot-scope="scope">
1089
+            <span v-if="scope.row.pass_examination == 1">是</span> 
1090
+            <span v-if="scope.row.pass_examination == 2">否</span> 
1091
+          </template>
1092
+        </el-table-column>
1093
+        <el-table-column
1094
+          prop="address"
1095
+          label="修改标志"
1096
+          width="110"
1097
+          align="center"
1098
+        >
1099
+          <template slot-scope="scope">
1100
+            <span v-if="scope.row.modifications == 1">正常</span> 
1101
+            <span v-if="scope.row.modifications == 2">撤消</span> 
1102
+          </template>
911 1103
         </el-table-column>
912 1104
         <el-table-column
913 1105
           prop="address"
@@ -1047,6 +1239,38 @@
1047 1239
           <template slot-scope="scope">
1048 1240
             {{ getTime(scope.row.reporting_dateb) }}
1049 1241
           </template>
1242
+        </el-table-column>
1243
+           <el-table-column
1244
+          prop="address"
1245
+          label="顺序号"
1246
+          width="110"
1247
+          align="center"
1248
+        >
1249
+          <template slot-scope="scope">
1250
+            {{scope.row.sort}}
1251
+          </template>
1252
+        </el-table-column>
1253
+        <el-table-column
1254
+          prop="address"
1255
+          label="检查合格"
1256
+          width="110"
1257
+          align="center"
1258
+        >
1259
+          <template slot-scope="scope">
1260
+            <span v-if="scope.row.pass_examination == 1">是</span> 
1261
+            <span v-if="scope.row.pass_examination == 2">否</span> 
1262
+          </template>
1263
+        </el-table-column>
1264
+        <el-table-column
1265
+          prop="address"
1266
+          label="修改标志"
1267
+          width="110"
1268
+          align="center"
1269
+        >
1270
+          <template slot-scope="scope">
1271
+            <span v-if="scope.row.modifications == 1">正常</span> 
1272
+            <span v-if="scope.row.modifications == 2">撤消</span> 
1273
+          </template>
1050 1274
         </el-table-column>
1051 1275
         <el-table-column
1052 1276
           prop="address"
@@ -1197,6 +1421,26 @@
1197 1421
               ></el-date-picker>
1198 1422
             </el-form-item>
1199 1423
           </el-col>
1424
+          <el-col :span="8">
1425
+              <el-form-item label="顺序号:" required prop="sort">
1426
+                 <el-input style="width:150px" v-model="form.sort" ></el-input>
1427
+              </el-form-item>
1428
+         </el-col>
1429
+        </el-row>
1430
+         <el-row>
1431
+            <el-col :span="12">
1432
+               <el-form-item label="检测合格:" required prop="pass_examination">
1433
+                  <el-radio v-model="form.pass_examination" label="1">是</el-radio>
1434
+                  <el-radio v-model="form.pass_examination" label="2">否</el-radio>
1435
+               </el-form-item>
1436
+            </el-col>
1437
+            <el-col :span="12">
1438
+               <el-form-item label="修改标志:" required prop="modifications">
1439
+                 <el-select style="width:150px"  v-model="form.modifications">
1440
+                   <el-option v-for="item in modifications" :key="item.id" :label="item.name" :value="item.id"></el-option>
1441
+                 </el-select>
1442
+              </el-form-item>
1443
+            </el-col>
1200 1444
         </el-row>
1201 1445
         <el-row>
1202 1446
           <el-col :span="24" class="result">
@@ -2129,7 +2373,10 @@ export default {
2129 2373
         detection_unit: "",
2130 2374
         sampler: "",
2131 2375
         reporting_date: "",
2132
-        detection_result: ""
2376
+        detection_result: "",
2377
+        sort:"",
2378
+        pass_examination:"",
2379
+        modifications:""
2133 2380
       },
2134 2381
       diaForm: {
2135 2382
         id: "",
@@ -2188,7 +2435,11 @@ export default {
2188 2435
         actual_hco: "",
2189 2436
         actual_mg: "",
2190 2437
         actual_ph: ""
2191
-      }
2438
+      },
2439
+     modifications:[
2440
+       {id:1,name:"正常"},
2441
+       {id:2,name:"撤销"}
2442
+     ]
2192 2443
     };
2193 2444
   },
2194 2445
   methods: {
@@ -2233,7 +2484,7 @@ export default {
2233 2484
       getAllQulityInfo().then(response => {
2234 2485
         if (response.data.state === 1) {
2235 2486
           var cultures = response.data.data.cultures;
2236
-          // console.log('cultures', cultures)
2487
+           console.log('cultures', cultures)
2237 2488
 
2238 2489
           for (let index = 0; index < cultures.length; index++) {
2239 2490
             if (cultures[index].specimen === 0) {
@@ -2701,11 +2952,15 @@ export default {
2701 2952
           this.form.sampler = culture.sampler;
2702 2953
           this.form.reporting_date = this.getTime(culture.reporting_date);
2703 2954
           this.form.detection_result = culture.detection_result;
2955
+          this.form.sort  = culture.sort
2956
+          this.form.pass_examination = culture.pass_examination.toString()
2957
+          this.form.modifications = culture.modifications
2704 2958
         }
2705 2959
       });
2706 2960
     },
2707 2961
 
2708 2962
     UpdateCulture(formName) {
2963
+      this.form.pass_examination = parseInt(this.form.pass_examination)
2709 2964
       this.$refs[formName].validate(valid => {
2710 2965
         if (valid) {
2711 2966
           UpdateCulture(this.form).then(response => {