XMLWAN 5 år sedan
förälder
incheckning
d7c8c5a5b1

+ 15 - 1
src/xt_pages/qcd/dialysisTotal.vue Visa fil

22
         <el-date-picker
22
         <el-date-picker
23
           v-model="listQuery.end_time"
23
           v-model="listQuery.end_time"
24
           prefix-icon="el-icon-date"
24
           prefix-icon="el-icon-date"
25
-          @change="changeTime"
25
+          @change="changeEndTime"
26
           :editable="false"
26
           :editable="false"
27
           style="width: 196px;"
27
           style="width: 196px;"
28
           type="date"
28
           type="date"
301
     changeTime() {
301
     changeTime() {
302
       this.getList();
302
       this.getList();
303
     },
303
     },
304
+    changeEndTime(val) {
305
+      var time =
306
+        this.getTimestamp(val) - this.getTimestamp(this.listQuery.start_time);
307
+      if (time < 0) {
308
+        this.$message.error("结束时间不能小于开始时间");
309
+        this.listQuery.end_time = "";
310
+      } else {
311
+        this.getList();
312
+      }
313
+    },
314
+    getTimestamp(time) {
315
+      // 把时间日期转成时间戳
316
+      return new Date(time).getTime() / 1000;
317
+    },
304
     selectStatisticalMethod(type) {
318
     selectStatisticalMethod(type) {
305
       this.statisticalMethod = type;
319
       this.statisticalMethod = type;
306
       this.listQuery.statistical_method = type;
320
       this.listQuery.statistical_method = type;

+ 15 - 1
src/xt_pages/qcd/outcomeIndicators/control.vue Visa fil

31
         <el-date-picker
31
         <el-date-picker
32
           v-model="listQuery.end_time"
32
           v-model="listQuery.end_time"
33
           prefix-icon="el-icon-date"
33
           prefix-icon="el-icon-date"
34
-          @change="changeTime"
34
+          @change="changeEndTime"
35
           :editable="false"
35
           :editable="false"
36
           style="width: 196px;"
36
           style="width: 196px;"
37
           type="date"
37
           type="date"
376
     changeTime() {
376
     changeTime() {
377
       this.getList();
377
       this.getList();
378
     },
378
     },
379
+    changeEndTime(val) {
380
+      var time =
381
+        this.getTimestamp(val) - this.getTimestamp(this.listQuery.start_time);
382
+      if (time < 0) {
383
+        this.$message.error("结束时间不能小于开始时间");
384
+        this.listQuery.end_time = "";
385
+      } else {
386
+        this.getList();
387
+      }
388
+    },
389
+    getTimestamp(time) {
390
+      // 把时间日期转成时间戳
391
+      return new Date(time).getTime() / 1000;
392
+    },
379
     selectLapseTo(lapseto) {
393
     selectLapseTo(lapseto) {
380
       this.lapsetoType = lapseto;
394
       this.lapsetoType = lapseto;
381
       this.listQuery.lapseto = lapseto;
395
       this.listQuery.lapseto = lapseto;

+ 15 - 1
src/xt_pages/qcd/patientAnalysis/total.vue Visa fil

38
         <el-date-picker
38
         <el-date-picker
39
           v-model="listQuery.end_time"
39
           v-model="listQuery.end_time"
40
           prefix-icon="el-icon-date"
40
           prefix-icon="el-icon-date"
41
-          @change="changeTime"
41
+          @change="changeEndTime"
42
           :editable="false"
42
           :editable="false"
43
           style="width: 196px;"
43
           style="width: 196px;"
44
           type="date"
44
           type="date"
283
     changeTime() {
283
     changeTime() {
284
       this.getList();
284
       this.getList();
285
     },
285
     },
286
+    changeEndTime(val) {
287
+      var time =
288
+        this.getTimestamp(val) - this.getTimestamp(this.listQuery.start_time);
289
+      if (time < 0) {
290
+        this.$message.error("结束时间不能小于开始时间");
291
+        this.listQuery.end_time = "";
292
+      } else {
293
+        this.getList();
294
+      }
295
+    },
296
+    getTimestamp(time) {
297
+      // 把时间日期转成时间戳
298
+      return new Date(time).getTime() / 1000;
299
+    },
286
     onSearch() {
300
     onSearch() {
287
       this.getList();
301
       this.getList();
288
     },
302
     },

+ 15 - 1
src/xt_pages/qcd/processIndicators.vue Visa fil

22
         <el-date-picker
22
         <el-date-picker
23
           v-model="listQuery.end_time"
23
           v-model="listQuery.end_time"
24
           prefix-icon="el-icon-date"
24
           prefix-icon="el-icon-date"
25
-          @change="changeTime"
25
+          @change="changeEndTime"
26
           :editable="false"
26
           :editable="false"
27
           style="width: 196px;"
27
           style="width: 196px;"
28
           type="date"
28
           type="date"
321
     changeTime() {
321
     changeTime() {
322
       this.getList();
322
       this.getList();
323
     },
323
     },
324
+    changeEndTime(val) {
325
+      var time =
326
+        this.getTimestamp(val) - this.getTimestamp(this.listQuery.start_time);
327
+      if (time < 0) {
328
+        this.$message.error("结束时间不能小于开始时间");
329
+        this.listQuery.end_time = "";
330
+      } else {
331
+        this.getList();
332
+      }
333
+    },
334
+    getTimestamp(time) {
335
+      // 把时间日期转成时间戳
336
+      return new Date(time).getTime() / 1000;
337
+    },
324
     selectLapseTo(lapseto) {
338
     selectLapseTo(lapseto) {
325
       this.lapsetoType = lapseto;
339
       this.lapsetoType = lapseto;
326
       this.listQuery.lapseto = lapseto;
340
       this.listQuery.lapseto = lapseto;

+ 11 - 1
src/xt_pages/stock/cancelStockOrder.vue Visa fil

339
       this.GetCancelStock();
339
       this.GetCancelStock();
340
     },
340
     },
341
     endTimeChange(val) {
341
     endTimeChange(val) {
342
-      this.GetCancelStock();
342
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
343
+      if (time < 0) {
344
+        this.$message.error("结束时间不能小于开始时间");
345
+        this.end_time = "";
346
+      } else {
347
+        this.GetCancelStock();
348
+      }
349
+    },
350
+    getTimestamp(time) {
351
+      // 把时间日期转成时间戳
352
+      return new Date(time).getTime() / 1000;
343
     },
353
     },
344
     calculate: function(val) {
354
     calculate: function(val) {
345
       return Math.round(parseFloat(val) * 100) / 100;
355
       return Math.round(parseFloat(val) * 100) / 100;

+ 11 - 1
src/xt_pages/stock/detail/cancelStockDetail.vue Visa fil

381
       this.GetCancelStock();
381
       this.GetCancelStock();
382
     },
382
     },
383
     endTimeChange(val) {
383
     endTimeChange(val) {
384
-      this.GetCancelStock();
384
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
385
+      if (time < 0) {
386
+        this.$message.error("结束时间不能小于开始时间");
387
+        this.end_time = "";
388
+      } else {
389
+        this.GetCancelStock();
390
+      }
391
+    },
392
+    getTimestamp(time) {
393
+      // 把时间日期转成时间戳
394
+      return new Date(time).getTime() / 1000;
385
     },
395
     },
386
     calculate: function(val) {
396
     calculate: function(val) {
387
       return Math.round(parseFloat(val) * 100) / 100;
397
       return Math.round(parseFloat(val) * 100) / 100;

+ 11 - 1
src/xt_pages/stock/detail/salesReturnDetail.vue Visa fil

380
       this.GetCancelStock();
380
       this.GetCancelStock();
381
     },
381
     },
382
     endTimeChange(val) {
382
     endTimeChange(val) {
383
-      this.GetCancelStock();
383
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
384
+      if (time < 0) {
385
+        this.$message.error("结束时间不能小于开始时间");
386
+        this.end_time = "";
387
+      } else {
388
+        this.GetCancelStock();
389
+      }
390
+    },
391
+    getTimestamp(time) {
392
+      // 把时间日期转成时间戳
393
+      return new Date(time).getTime() / 1000;
384
     },
394
     },
385
     calculate: function(val) {
395
     calculate: function(val) {
386
       return Math.round(parseFloat(val) * 100) / 100;
396
       return Math.round(parseFloat(val) * 100) / 100;

+ 11 - 1
src/xt_pages/stock/detail/stockInDetail.vue Visa fil

422
       this.GetCancelStock();
422
       this.GetCancelStock();
423
     },
423
     },
424
     endTimeChange(val) {
424
     endTimeChange(val) {
425
-      this.GetCancelStock();
425
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
426
+      if (time < 0) {
427
+        this.$message.error("结束时间不能小于开始时间");
428
+        this.end_time = "";
429
+      } else {
430
+        this.GetCancelStock();
431
+      }
432
+    },
433
+    getTimestamp(time) {
434
+      // 把时间日期转成时间戳
435
+      return new Date(time).getTime() / 1000;
426
     },
436
     },
427
     calculate: function(val) {
437
     calculate: function(val) {
428
       return Math.round(parseFloat(val) * 100) / 100;
438
       return Math.round(parseFloat(val) * 100) / 100;

+ 11 - 1
src/xt_pages/stock/detail/stockOutDetail.vue Visa fil

404
       this.GetCancelStock();
404
       this.GetCancelStock();
405
     },
405
     },
406
     endTimeChange(val) {
406
     endTimeChange(val) {
407
-      this.GetCancelStock();
407
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
408
+      if (time < 0) {
409
+        this.$message.error("结束时间不能小于开始时间");
410
+        this.end_time = "";
411
+      } else {
412
+        this.GetCancelStock();
413
+      }
414
+    },
415
+    getTimestamp(time) {
416
+      // 把时间日期转成时间戳
417
+      return new Date(time).getTime() / 1000;
408
     },
418
     },
409
     calculate: function(val) {
419
     calculate: function(val) {
410
       return Math.round(parseFloat(val) * 100) / 100;
420
       return Math.round(parseFloat(val) * 100) / 100;

+ 11 - 1
src/xt_pages/stock/otherCancelStockOrder.vue Visa fil

337
       this.GetCancelStock();
337
       this.GetCancelStock();
338
     },
338
     },
339
     endTimeChange(val) {
339
     endTimeChange(val) {
340
-      this.GetCancelStock();
340
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
341
+      if (time < 0) {
342
+        this.$message.error("结束时间不能小于开始时间");
343
+        this.end_time = "";
344
+      } else {
345
+        this.GetCancelStock();
346
+      }
347
+    },
348
+    getTimestamp(time) {
349
+      // 把时间日期转成时间戳
350
+      return new Date(time).getTime() / 1000;
341
     },
351
     },
342
     calculate: function(val) {
352
     calculate: function(val) {
343
       return Math.round(parseFloat(val) * 100) / 100;
353
       return Math.round(parseFloat(val) * 100) / 100;

+ 125 - 127
src/xt_pages/stock/otherSalesReturnOrder.vue Visa fil

174
 </template>
174
 </template>
175
 
175
 
176
 <script>
176
 <script>
177
-import { uParseTime } from '@/utils/tools'
178
-import { fetchAllAdminUsers, fetchAllDoctorAndNurse } from '@/api/doctor'
177
+import { uParseTime } from "@/utils/tools";
178
+import { fetchAllAdminUsers, fetchAllDoctorAndNurse } from "@/api/doctor";
179
 import {
179
 import {
180
   deleteSalesReturn,
180
   deleteSalesReturn,
181
   GetAllConfig,
181
   GetAllConfig,
182
   getSalesReturnList,
182
   getSalesReturnList,
183
   getWarehouseInfoList,
183
   getWarehouseInfoList,
184
   getWarehouseList
184
   getWarehouseList
185
-} from '@/api/stock'
186
-import BreadCrumb from '../components/bread-crumb'
185
+} from "@/api/stock";
186
+import BreadCrumb from "../components/bread-crumb";
187
 
187
 
188
 export default {
188
 export default {
189
-  name: 'salesReturnOrder',
189
+  name: "salesReturnOrder",
190
   components: { BreadCrumb },
190
   components: { BreadCrumb },
191
   created() {
191
   created() {
192
-    var nowDate = new Date()
193
-    var nowYear = nowDate.getFullYear()
194
-    var nowMonth = nowDate.getMonth() + 1
195
-    var nowDay = nowDate.getDate()
192
+    var nowDate = new Date();
193
+    var nowYear = nowDate.getFullYear();
194
+    var nowMonth = nowDate.getMonth() + 1;
195
+    var nowDay = nowDate.getDate();
196
     this.end_time =
196
     this.end_time =
197
       nowYear +
197
       nowYear +
198
-      '-' +
199
-      (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
200
-      '-' +
201
-      (nowDay < 10 ? '0' + nowDay : nowDay)
202
-    nowDate.setMonth(nowDate.getMonth() - 1)
203
-    nowYear = nowDate.getFullYear()
204
-    nowMonth = nowDate.getMonth() + 1
205
-    nowDay = nowDate.getDate()
198
+      "-" +
199
+      (nowMonth < 10 ? "0" + nowMonth : nowMonth) +
200
+      "-" +
201
+      (nowDay < 10 ? "0" + nowDay : nowDay);
202
+    nowDate.setMonth(nowDate.getMonth() - 1);
203
+    nowYear = nowDate.getFullYear();
204
+    nowMonth = nowDate.getMonth() + 1;
205
+    nowDay = nowDate.getDate();
206
     this.start_time =
206
     this.start_time =
207
       nowYear +
207
       nowYear +
208
-      '-' +
209
-      (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
210
-      '-' +
211
-      (nowDay < 10 ? '0' + nowDay : nowDay)
212
-    this.GetSalesReturn()
213
-    this.GetConfigInfo()
214
-    this.fetchAllAdminUsers()
208
+      "-" +
209
+      (nowMonth < 10 ? "0" + nowMonth : nowMonth) +
210
+      "-" +
211
+      (nowDay < 10 ? "0" + nowDay : nowDay);
212
+    this.GetSalesReturn();
213
+    this.GetConfigInfo();
214
+    this.fetchAllAdminUsers();
215
   },
215
   },
216
   data() {
216
   data() {
217
     return {
217
     return {
218
-      searchKey: '',
218
+      searchKey: "",
219
       crumbs: [
219
       crumbs: [
220
-        { path: false, name: '库存管理' },
221
-        { path: false, name: '其他退货单' }
220
+        { path: false, name: "库存管理" },
221
+        { path: false, name: "其他退货单" }
222
       ],
222
       ],
223
       type: 2,
223
       type: 2,
224
       page: 1,
224
       page: 1,
229
       pageSelect: 0,
229
       pageSelect: 0,
230
       adminUserOptions: [],
230
       adminUserOptions: [],
231
       multipleSelection: [],
231
       multipleSelection: [],
232
-      signAndWeighBoxPatients: 'sign-and-weigh-box-patients',
233
-      start_time: '',
232
+      signAndWeighBoxPatients: "sign-and-weigh-box-patients",
233
+      start_time: "",
234
       saleReturnDate: [],
234
       saleReturnDate: [],
235
-      end_time: '',
235
+      end_time: "",
236
       goodType: [],
236
       goodType: [],
237
       goodInfo: [],
237
       goodInfo: [],
238
       manufacturer: [],
238
       manufacturer: [],
239
       selectedTableData: [],
239
       selectedTableData: [],
240
       dealer: [],
240
       dealer: [],
241
-      startTime: ''
242
-    }
241
+      startTime: ""
242
+    };
243
   },
243
   },
244
   methods: {
244
   methods: {
245
     search: function() {
245
     search: function() {
250
         end_time: this.end_time,
250
         end_time: this.end_time,
251
         type: this.type,
251
         type: this.type,
252
         keywords: this.searchKey
252
         keywords: this.searchKey
253
-      }
254
-      this.saleReturnDate = []
253
+      };
254
+      this.saleReturnDate = [];
255
       getSalesReturnList(Params).then(response => {
255
       getSalesReturnList(Params).then(response => {
256
         if (response.data.state == 0) {
256
         if (response.data.state == 0) {
257
-          this.$message.error(response.data.msg)
258
-          return false
257
+          this.$message.error(response.data.msg);
258
+          return false;
259
         } else {
259
         } else {
260
-          this.total = response.data.data.total
260
+          this.total = response.data.data.total;
261
           for (let i = 0; i < response.data.data.list.length; i++) {
261
           for (let i = 0; i < response.data.data.list.length; i++) {
262
-            this.saleReturnDate.push(response.data.data.list[i])
262
+            this.saleReturnDate.push(response.data.data.list[i]);
263
           }
263
           }
264
         }
264
         }
265
-      })
265
+      });
266
     },
266
     },
267
     AddNewOrder: function() {
267
     AddNewOrder: function() {
268
       this.$router.push({
268
       this.$router.push({
269
-        name: 'salesReturnOrderAdd',
269
+        name: "salesReturnOrderAdd",
270
         query: { type: this.type }
270
         query: { type: this.type }
271
-      })
271
+      });
272
     },
272
     },
273
     GetSalesReturn: function() {
273
     GetSalesReturn: function() {
274
       const Params = {
274
       const Params = {
277
         start_time: this.start_time,
277
         start_time: this.start_time,
278
         end_time: this.end_time,
278
         end_time: this.end_time,
279
         type: this.type
279
         type: this.type
280
-      }
281
-      this.saleReturnDate = []
280
+      };
281
+      this.saleReturnDate = [];
282
       getSalesReturnList(Params).then(response => {
282
       getSalesReturnList(Params).then(response => {
283
         if (response.data.state == 0) {
283
         if (response.data.state == 0) {
284
-          this.$message.error(response.data.msg)
285
-          return false
284
+          this.$message.error(response.data.msg);
285
+          return false;
286
         } else {
286
         } else {
287
-          this.total = response.data.data.total
287
+          this.total = response.data.data.total;
288
           for (let i = 0; i < response.data.data.list.length; i++) {
288
           for (let i = 0; i < response.data.data.list.length; i++) {
289
-            this.saleReturnDate.push(response.data.data.list[i])
289
+            this.saleReturnDate.push(response.data.data.list[i]);
290
           }
290
           }
291
         }
291
         }
292
-      })
292
+      });
293
     },
293
     },
294
     getXuserName(id) {
294
     getXuserName(id) {
295
       if (id <= 0) {
295
       if (id <= 0) {
296
-        return ''
296
+        return "";
297
       }
297
       }
298
-      var name = ''
298
+      var name = "";
299
       if (
299
       if (
300
         this.adminUserOptions == null ||
300
         this.adminUserOptions == null ||
301
-        typeof this.adminUserOptions.length === 'undefined'
301
+        typeof this.adminUserOptions.length === "undefined"
302
       ) {
302
       ) {
303
-        return name
303
+        return name;
304
       }
304
       }
305
-      var leng = this.adminUserOptions.length
305
+      var leng = this.adminUserOptions.length;
306
       if (leng == 0) {
306
       if (leng == 0) {
307
-        return name
307
+        return name;
308
       }
308
       }
309
       for (let index = 0; index < leng; index++) {
309
       for (let index = 0; index < leng; index++) {
310
         if (this.adminUserOptions[index].id == id) {
310
         if (this.adminUserOptions[index].id == id) {
311
-          name = this.adminUserOptions[index].name
312
-          break
311
+          name = this.adminUserOptions[index].name;
312
+          break;
313
         }
313
         }
314
       }
314
       }
315
-      return name
315
+      return name;
316
     },
316
     },
317
     fetchAllAdminUsers() {
317
     fetchAllAdminUsers() {
318
       fetchAllAdminUsers().then(response => {
318
       fetchAllAdminUsers().then(response => {
319
-        console.log(response)
319
+        console.log(response);
320
         if (response.data.state == 1) {
320
         if (response.data.state == 1) {
321
-          this.adminUserOptions = response.data.data.users
322
-          var alen = this.adminUserOptions.length
321
+          this.adminUserOptions = response.data.data.users;
322
+          var alen = this.adminUserOptions.length;
323
           for (let index = 0; index < alen; index++) {
323
           for (let index = 0; index < alen; index++) {
324
             if (this.adminUserOptions[index].user_type == 2) {
324
             if (this.adminUserOptions[index].user_type == 2) {
325
               // this.doctorOptions.push(this.adminUserOptions[index]);
325
               // this.doctorOptions.push(this.adminUserOptions[index]);
326
             }
326
             }
327
           }
327
           }
328
         }
328
         }
329
-      })
329
+      });
330
     },
330
     },
331
     handleSelectionChange: function(val) {
331
     handleSelectionChange: function(val) {
332
-      this.multipleSelection = val
332
+      this.multipleSelection = val;
333
     },
333
     },
334
     handleSizeChange(val) {
334
     handleSizeChange(val) {
335
-      this.limit = val
336
-      this.GetSalesReturn()
335
+      this.limit = val;
336
+      this.GetSalesReturn();
337
     },
337
     },
338
     handleCurrentChange(val) {
338
     handleCurrentChange(val) {
339
-      this.page = val
340
-      this.GetSalesReturn()
339
+      this.page = val;
340
+      this.GetSalesReturn();
341
     },
341
     },
342
     startTimeChange(val) {
342
     startTimeChange(val) {
343
-      this.startTime = this.getTimestamp(val)
344
-      this.GetSalesReturn()
343
+      this.startTime = this.getTimestamp(val);
344
+      this.GetSalesReturn();
345
     },
345
     },
346
     endTimeChange(val) {
346
     endTimeChange(val) {
347
-      var time = this.getTimestamp(val) - this.startTime
348
-      console.log('开始时间', this.startTime)
349
-      console.log('结束', this.getTimestamp(val))
350
-      console.log('时间差', time)
347
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
351
       if (time < 0) {
348
       if (time < 0) {
352
-        this.$message.error('结束时间不能小于开始时间')
353
-        this.end_time = ''
349
+        this.$message.error("结束时间不能小于开始时间");
350
+        this.end_time = "";
354
       } else {
351
       } else {
355
-        this.GetSalesReturn()
352
+        this.GetSalesReturn();
356
       }
353
       }
357
     },
354
     },
358
-    getTimestamp(time) { // 把时间日期转成时间戳
359
-      return (new Date(time)).getTime() / 1000
355
+    getTimestamp(time) {
356
+      // 把时间日期转成时间戳
357
+      return new Date(time).getTime() / 1000;
360
     },
358
     },
361
     calculate: function(val) {
359
     calculate: function(val) {
362
-      return Math.round(parseFloat(val) * 100) / 100
360
+      return Math.round(parseFloat(val) * 100) / 100;
363
     },
361
     },
364
     GetConfigInfo: function() {
362
     GetConfigInfo: function() {
365
       GetAllConfig().then(response => {
363
       GetAllConfig().then(response => {
366
         if (response.data.state == 0) {
364
         if (response.data.state == 0) {
367
-          this.$message.error(response.data.msg)
368
-          return false
365
+          this.$message.error(response.data.msg);
366
+          return false;
369
         } else {
367
         } else {
370
-          this.manufacturer = response.data.data.manufacturer
371
-          this.dealer = response.data.data.dealer
368
+          this.manufacturer = response.data.data.manufacturer;
369
+          this.dealer = response.data.data.dealer;
372
         }
370
         }
373
-      })
371
+      });
374
     },
372
     },
375
     getManufactuerName: function(manufacturer_id) {
373
     getManufactuerName: function(manufacturer_id) {
376
       for (let i = 0; i < this.manufacturer.length; i++) {
374
       for (let i = 0; i < this.manufacturer.length; i++) {
377
         if (this.manufacturer[i].id == manufacturer_id) {
375
         if (this.manufacturer[i].id == manufacturer_id) {
378
-          return this.manufacturer[i].manufacturer_name
376
+          return this.manufacturer[i].manufacturer_name;
379
         }
377
         }
380
       }
378
       }
381
     },
379
     },
382
     getDealerName: function(dealer_id) {
380
     getDealerName: function(dealer_id) {
383
       for (let i = 0; i < this.dealer.length; i++) {
381
       for (let i = 0; i < this.dealer.length; i++) {
384
         if (this.dealer[i].id == dealer_id) {
382
         if (this.dealer[i].id == dealer_id) {
385
-          return this.dealer[i].dealer_name
383
+          return this.dealer[i].dealer_name;
386
         }
384
         }
387
       }
385
       }
388
     },
386
     },
389
     handleEdit: function(index, row) {
387
     handleEdit: function(index, row) {
390
       this.$router.push({
388
       this.$router.push({
391
-        name: 'salesReturnDetail',
389
+        name: "salesReturnDetail",
392
         query: { id: row.id, type: this.type }
390
         query: { id: row.id, type: this.type }
393
-      })
391
+      });
394
     },
392
     },
395
     handleDelete: function(index, row) {
393
     handleDelete: function(index, row) {
396
-      const ids = []
397
-      ids.push(row.id)
398
-      const idStr = ids.join(',')
394
+      const ids = [];
395
+      ids.push(row.id);
396
+      const idStr = ids.join(",");
399
 
397
 
400
       const params = {
398
       const params = {
401
         ids: idStr
399
         ids: idStr
402
-      }
400
+      };
403
 
401
 
404
-      this.$confirm('确认删除退货单记录?', '删除退货单记录', {
405
-        confirmButtonText: '确定',
406
-        cancelButtonText: '取消',
407
-        type: 'warning'
402
+      this.$confirm("确认删除退货单记录?", "删除退货单记录", {
403
+        confirmButtonText: "确定",
404
+        cancelButtonText: "取消",
405
+        type: "warning"
408
       })
406
       })
409
         .then(() => {
407
         .then(() => {
410
           deleteSalesReturn(params).then(response => {
408
           deleteSalesReturn(params).then(response => {
411
             if (response.data.state == 0) {
409
             if (response.data.state == 0) {
412
-              this.$message.error(response.data.msg)
413
-              return false
410
+              this.$message.error(response.data.msg);
411
+              return false;
414
             } else {
412
             } else {
415
               this.$notify({
413
               this.$notify({
416
-                title: '成功',
417
-                message: '删除成功',
418
-                type: 'success',
414
+                title: "成功",
415
+                message: "删除成功",
416
+                type: "success",
419
                 duration: 2000
417
                 duration: 2000
420
-              })
418
+              });
421
               for (let i = 0; i < ids.length; i++) {
419
               for (let i = 0; i < ids.length; i++) {
422
                 for (let y = 0; y < this.saleReturnDate.length; y++) {
420
                 for (let y = 0; y < this.saleReturnDate.length; y++) {
423
                   if (ids[i] == this.saleReturnDate[y].id) {
421
                   if (ids[i] == this.saleReturnDate[y].id) {
424
-                    this.saleReturnDate.splice(y, 1)
422
+                    this.saleReturnDate.splice(y, 1);
425
                   }
423
                   }
426
                 }
424
                 }
427
               }
425
               }
428
             }
426
             }
429
-          })
427
+          });
430
         })
428
         })
431
-        .catch(() => {})
429
+        .catch(() => {});
432
     },
430
     },
433
     changeAllSelected: function(val) {
431
     changeAllSelected: function(val) {
434
       if (val) {
432
       if (val) {
435
-        this.$refs.multipleTable.toggleAllSelection()
433
+        this.$refs.multipleTable.toggleAllSelection();
436
       } else {
434
       } else {
437
-        this.$refs.multipleTable.clearSelection()
435
+        this.$refs.multipleTable.clearSelection();
438
       }
436
       }
439
     },
437
     },
440
     select(selection) {
438
     select(selection) {
441
-      this.selectedTableData = selection
439
+      this.selectedTableData = selection;
442
     },
440
     },
443
     batchDelete() {
441
     batchDelete() {
444
       if (this.selectedTableData.length <= 0) {
442
       if (this.selectedTableData.length <= 0) {
445
-        this.$message.error('请选择要删除的记录')
446
-        return
443
+        this.$message.error("请选择要删除的记录");
444
+        return;
447
       }
445
       }
448
-      const ids = []
446
+      const ids = [];
449
       for (let i = 0; i < this.selectedTableData.length; i++) {
447
       for (let i = 0; i < this.selectedTableData.length; i++) {
450
-        ids.push(this.selectedTableData[i].id)
448
+        ids.push(this.selectedTableData[i].id);
451
       }
449
       }
452
-      const idStr = ids.join(',')
450
+      const idStr = ids.join(",");
453
       const params = {
451
       const params = {
454
         ids: idStr
452
         ids: idStr
455
-      }
456
-      this.$confirm('确认删除退货单记录?', '删除退货单记录', {
457
-        confirmButtonText: '确定',
458
-        cancelButtonText: '取消',
459
-        type: 'warning'
453
+      };
454
+      this.$confirm("确认删除退货单记录?", "删除退货单记录", {
455
+        confirmButtonText: "确定",
456
+        cancelButtonText: "取消",
457
+        type: "warning"
460
       })
458
       })
461
         .then(() => {
459
         .then(() => {
462
           deleteSalesReturn(params).then(response => {
460
           deleteSalesReturn(params).then(response => {
463
             if (response.data.state == 0) {
461
             if (response.data.state == 0) {
464
-              this.$message.error(response.data.msg)
465
-              return false
462
+              this.$message.error(response.data.msg);
463
+              return false;
466
             } else {
464
             } else {
467
               this.$notify({
465
               this.$notify({
468
-                title: '成功',
469
-                message: '删除成功',
470
-                type: 'success',
466
+                title: "成功",
467
+                message: "删除成功",
468
+                type: "success",
471
                 duration: 2000
469
                 duration: 2000
472
-              })
470
+              });
473
 
471
 
474
               for (let i = 0; i < ids.length; i++) {
472
               for (let i = 0; i < ids.length; i++) {
475
                 for (let y = 0; y < this.saleReturnDate.length; y++) {
473
                 for (let y = 0; y < this.saleReturnDate.length; y++) {
476
                   if (ids[i] == this.saleReturnDate[y].id) {
474
                   if (ids[i] == this.saleReturnDate[y].id) {
477
-                    this.saleReturnDate.splice(y, 1)
475
+                    this.saleReturnDate.splice(y, 1);
478
                   }
476
                   }
479
                 }
477
                 }
480
               }
478
               }
481
             }
479
             }
482
-          })
480
+          });
483
         })
481
         })
484
-        .catch(() => {})
482
+        .catch(() => {});
485
     }
483
     }
486
   }
484
   }
487
-}
485
+};
488
 </script>
486
 </script>
489
 
487
 
490
 <style rel="stylesheet/css" lang="scss" scoped>
488
 <style rel="stylesheet/css" lang="scss" scoped>

+ 11 - 1
src/xt_pages/stock/otherStockInOrder.vue Visa fil

453
       this.GetWarehouse();
453
       this.GetWarehouse();
454
     },
454
     },
455
     endTimeChange(val) {
455
     endTimeChange(val) {
456
-      this.GetWarehouse();
456
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
457
+      if (time < 0) {
458
+        this.$message.error("结束时间不能小于开始时间");
459
+        this.end_time = "";
460
+      } else {
461
+        this.GetWarehouse();
462
+      }
463
+    },
464
+    getTimestamp(time) {
465
+      // 把时间日期转成时间戳
466
+      return new Date(time).getTime() / 1000;
457
     },
467
     },
458
     calculate: function(val) {
468
     calculate: function(val) {
459
       return Math.round(parseFloat(val) * 100) / 100;
469
       return Math.round(parseFloat(val) * 100) / 100;

+ 11 - 1
src/xt_pages/stock/otherStockOutOrder.vue Visa fil

336
       this.GetWarehouseOut();
336
       this.GetWarehouseOut();
337
     },
337
     },
338
     endTimeChange(val) {
338
     endTimeChange(val) {
339
-      this.GetWarehouseOut();
339
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
340
+      if (time < 0) {
341
+        this.$message.error("结束时间不能小于开始时间");
342
+        this.end_time = "";
343
+      } else {
344
+        this.GetWarehouseOut();
345
+      }
346
+    },
347
+    getTimestamp(time) {
348
+      // 把时间日期转成时间戳
349
+      return new Date(time).getTime() / 1000;
340
     },
350
     },
341
     calculate: function(val) {
351
     calculate: function(val) {
342
       return Math.round(parseFloat(val) * 100) / 100;
352
       return Math.round(parseFloat(val) * 100) / 100;

+ 11 - 0
src/xt_pages/stock/salesReturnOrder.vue Visa fil

338
       this.GetSalesReturn();
338
       this.GetSalesReturn();
339
     },
339
     },
340
     endTimeChange(val) {
340
     endTimeChange(val) {
341
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
342
+      if (time < 0) {
343
+        this.$message.error("结束时间不能小于开始时间");
344
+        this.end_time = "";
345
+      } else {
346
+        this.GetWarehouse();
347
+      }
341
       this.GetSalesReturn();
348
       this.GetSalesReturn();
342
     },
349
     },
350
+    getTimestamp(time) {
351
+      // 把时间日期转成时间戳
352
+      return new Date(time).getTime() / 1000;
353
+    },
343
     calculate: function(val) {
354
     calculate: function(val) {
344
       return Math.round(parseFloat(val) * 100) / 100;
355
       return Math.round(parseFloat(val) * 100) / 100;
345
     },
356
     },

+ 0 - 2
src/xt_pages/stock/stockInOrder.vue Visa fil

483
       this.startTime = this.getTimestamp(val);
483
       this.startTime = this.getTimestamp(val);
484
     },
484
     },
485
     endTimeChange(val) {
485
     endTimeChange(val) {
486
-      console.log("开始时间", this.start_time);
487
       var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
486
       var time = this.getTimestamp(val) - this.getTimestamp(this.start_time);
488
-      console.log("time", time);
489
       if (time < 0) {
487
       if (time < 0) {
490
         this.$message.error("结束时间不能小于开始时间");
488
         this.$message.error("结束时间不能小于开始时间");
491
         this.end_time = "";
489
         this.end_time = "";

+ 127 - 117
src/xt_pages/stock/stockOutOrder.vue Visa fil

168
 </template>
168
 </template>
169
 
169
 
170
 <script>
170
 <script>
171
-import { uParseTime } from "@/utils/tools";
172
-import { fetchAllAdminUsers, fetchAllDoctorAndNurse } from "@/api/doctor";
171
+import { uParseTime } from '@/utils/tools'
172
+import { fetchAllAdminUsers, fetchAllDoctorAndNurse } from '@/api/doctor'
173
 
173
 
174
 import {
174
 import {
175
   deleteWarehouseOut,
175
   deleteWarehouseOut,
176
   GetAllConfig,
176
   GetAllConfig,
177
   getWarehouseOutList
177
   getWarehouseOutList
178
-} from "@/api/stock";
179
-import BreadCrumb from "../components/bread-crumb";
178
+} from '@/api/stock'
179
+import BreadCrumb from '../components/bread-crumb'
180
 
180
 
181
 export default {
181
 export default {
182
-  name: "salesReturnOrder",
182
+  name: 'salesReturnOrder',
183
   components: { BreadCrumb },
183
   components: { BreadCrumb },
184
   created() {
184
   created() {
185
-    var nowDate = new Date();
186
-    var nowYear = nowDate.getFullYear();
187
-    var nowMonth = nowDate.getMonth() + 1;
188
-    var nowDay = nowDate.getDate();
185
+    var nowDate = new Date()
186
+    var nowYear = nowDate.getFullYear()
187
+    var nowMonth = nowDate.getMonth() + 1
188
+    var nowDay = nowDate.getDate()
189
     this.end_time =
189
     this.end_time =
190
       nowYear +
190
       nowYear +
191
-      "-" +
192
-      (nowMonth < 10 ? "0" + nowMonth : nowMonth) +
193
-      "-" +
194
-      (nowDay < 10 ? "0" + nowDay : nowDay);
195
-    nowDate.setMonth(nowDate.getMonth() - 1);
196
-    nowYear = nowDate.getFullYear();
197
-    nowMonth = nowDate.getMonth() + 1;
198
-    nowDay = nowDate.getDate();
191
+      '-' +
192
+      (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
193
+      '-' +
194
+      (nowDay < 10 ? '0' + nowDay : nowDay)
195
+    nowDate.setMonth(nowDate.getMonth() - 1)
196
+    nowYear = nowDate.getFullYear()
197
+    nowMonth = nowDate.getMonth() + 1
198
+    nowDay = nowDate.getDate()
199
     this.start_time =
199
     this.start_time =
200
       nowYear +
200
       nowYear +
201
-      "-" +
202
-      (nowMonth < 10 ? "0" + nowMonth : nowMonth) +
203
-      "-" +
204
-      (nowDay < 10 ? "0" + nowDay : nowDay);
205
-    this.GetWarehouseOut();
206
-    this.GetConfigInfo();
207
-    this.fetchAllAdminUsers();
201
+      '-' +
202
+      (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
203
+      '-' +
204
+      (nowDay < 10 ? '0' + nowDay : nowDay)
205
+    this.GetWarehouseOut()
206
+    this.GetConfigInfo()
207
+    this.fetchAllAdminUsers()
208
   },
208
   },
209
   data() {
209
   data() {
210
     return {
210
     return {
211
-      searchKey: "",
211
+      searchKey: '',
212
       crumbs: [
212
       crumbs: [
213
-        { path: false, name: "库存管理" },
214
-        { path: false, name: "出库单" }
213
+        { path: false, name: '库存管理' },
214
+        { path: false, name: '出库单' }
215
       ],
215
       ],
216
       page: 1,
216
       page: 1,
217
       limit: 10,
217
       limit: 10,
221
       pageSelect: 0,
221
       pageSelect: 0,
222
       adminUserOptions: [],
222
       adminUserOptions: [],
223
       multipleSelection: [],
223
       multipleSelection: [],
224
-      signAndWeighBoxPatients: "sign-and-weigh-box-patients",
225
-      start_time: "",
224
+      signAndWeighBoxPatients: 'sign-and-weigh-box-patients',
225
+      start_time: '',
226
       warehouseOutDate: [],
226
       warehouseOutDate: [],
227
-      end_time: "",
227
+      end_time: '',
228
       goodType: [],
228
       goodType: [],
229
       goodInfo: [],
229
       goodInfo: [],
230
       manufacturer: [],
230
       manufacturer: [],
231
       selectedTableData: [],
231
       selectedTableData: [],
232
       dealer: [],
232
       dealer: [],
233
       type: 1
233
       type: 1
234
-    };
234
+    }
235
   },
235
   },
236
   methods: {
236
   methods: {
237
     search: function() {
237
     search: function() {
242
         end_time: this.end_time,
242
         end_time: this.end_time,
243
         type: this.type,
243
         type: this.type,
244
         keywords: this.searchKey
244
         keywords: this.searchKey
245
-      };
246
-      this.warehouseOutDate = [];
245
+      }
246
+      this.warehouseOutDate = []
247
       getWarehouseOutList(Params).then(response => {
247
       getWarehouseOutList(Params).then(response => {
248
         if (response.data.state == 0) {
248
         if (response.data.state == 0) {
249
-          this.$message.error(response.data.msg);
250
-          return false;
249
+          this.$message.error(response.data.msg)
250
+          return false
251
         } else {
251
         } else {
252
-          this.total = response.data.data.total;
252
+          this.total = response.data.data.total
253
           for (let i = 0; i < response.data.data.list.length; i++) {
253
           for (let i = 0; i < response.data.data.list.length; i++) {
254
-            this.warehouseOutDate.push(response.data.data.list[i]);
254
+            this.warehouseOutDate.push(response.data.data.list[i])
255
           }
255
           }
256
         }
256
         }
257
-      });
257
+      })
258
     },
258
     },
259
     AddNewOrder: function() {
259
     AddNewOrder: function() {
260
       this.$router.push({
260
       this.$router.push({
261
-        name: "stockOutOrderAdd",
261
+        name: 'stockOutOrderAdd',
262
         query: { type: this.type }
262
         query: { type: this.type }
263
-      });
263
+      })
264
     },
264
     },
265
     GetWarehouseOut: function() {
265
     GetWarehouseOut: function() {
266
       const Params = {
266
       const Params = {
269
         start_time: this.start_time,
269
         start_time: this.start_time,
270
         end_time: this.end_time,
270
         end_time: this.end_time,
271
         type: this.type
271
         type: this.type
272
-      };
273
-      this.warehouseOutDate = [];
272
+      }
273
+      this.warehouseOutDate = []
274
       getWarehouseOutList(Params).then(response => {
274
       getWarehouseOutList(Params).then(response => {
275
         if (response.data.state == 0) {
275
         if (response.data.state == 0) {
276
-          this.$message.error(response.data.msg);
277
-          return false;
276
+          this.$message.error(response.data.msg)
277
+          return false
278
         } else {
278
         } else {
279
-          this.total = response.data.data.total;
279
+          this.total = response.data.data.total
280
           for (let i = 0; i < response.data.data.list.length; i++) {
280
           for (let i = 0; i < response.data.data.list.length; i++) {
281
-            this.warehouseOutDate.push(response.data.data.list[i]);
281
+            this.warehouseOutDate.push(response.data.data.list[i])
282
           }
282
           }
283
         }
283
         }
284
-      });
284
+      })
285
     },
285
     },
286
     getXuserName(id) {
286
     getXuserName(id) {
287
       if (id <= 0) {
287
       if (id <= 0) {
288
-        return "";
288
+        return ''
289
       }
289
       }
290
-      var name = "";
290
+      var name = ''
291
       if (
291
       if (
292
         this.adminUserOptions == null ||
292
         this.adminUserOptions == null ||
293
-        typeof this.adminUserOptions.length === "undefined"
293
+        typeof this.adminUserOptions.length === 'undefined'
294
       ) {
294
       ) {
295
-        return name;
295
+        return name
296
       }
296
       }
297
-      var leng = this.adminUserOptions.length;
297
+      var leng = this.adminUserOptions.length
298
       if (leng == 0) {
298
       if (leng == 0) {
299
-        return name;
299
+        return name
300
       }
300
       }
301
       for (let index = 0; index < leng; index++) {
301
       for (let index = 0; index < leng; index++) {
302
         if (this.adminUserOptions[index].id == id) {
302
         if (this.adminUserOptions[index].id == id) {
303
-          name = this.adminUserOptions[index].name;
304
-          break;
303
+          name = this.adminUserOptions[index].name
304
+          break
305
         }
305
         }
306
       }
306
       }
307
-      return name;
307
+      return name
308
     },
308
     },
309
     fetchAllAdminUsers() {
309
     fetchAllAdminUsers() {
310
       fetchAllAdminUsers().then(response => {
310
       fetchAllAdminUsers().then(response => {
311
-        console.log(response);
311
+        console.log(response)
312
         if (response.data.state == 1) {
312
         if (response.data.state == 1) {
313
-          this.adminUserOptions = response.data.data.users;
314
-          var alen = this.adminUserOptions.length;
313
+          this.adminUserOptions = response.data.data.users
314
+          var alen = this.adminUserOptions.length
315
           for (let index = 0; index < alen; index++) {
315
           for (let index = 0; index < alen; index++) {
316
             if (this.adminUserOptions[index].user_type == 2) {
316
             if (this.adminUserOptions[index].user_type == 2) {
317
               // this.doctorOptions.push(this.adminUserOptions[index]);
317
               // this.doctorOptions.push(this.adminUserOptions[index]);
318
             }
318
             }
319
           }
319
           }
320
         }
320
         }
321
-      });
321
+      })
322
     },
322
     },
323
     handleSelectionChange: function(val) {
323
     handleSelectionChange: function(val) {
324
-      this.multipleSelection = val;
324
+      this.multipleSelection = val
325
     },
325
     },
326
     handleSizeChange(val) {
326
     handleSizeChange(val) {
327
-      this.limit = val;
328
-      this.GetWarehouseOut();
327
+      this.limit = val
328
+      this.GetWarehouseOut()
329
     },
329
     },
330
     handleCurrentChange(val) {
330
     handleCurrentChange(val) {
331
-      this.page = val;
332
-      this.GetWarehouseOut();
331
+      this.page = val
332
+      this.GetWarehouseOut()
333
     },
333
     },
334
     startTimeChange(val) {
334
     startTimeChange(val) {
335
-      this.GetWarehouseOut();
335
+      this.GetWarehouseOut()
336
     },
336
     },
337
     endTimeChange(val) {
337
     endTimeChange(val) {
338
-      this.GetWarehouseOut();
338
+      var time = this.getTimestamp(val) - this.getTimestamp(this.start_time)
339
+      if (time < 0) {
340
+        this.$message.error('结束时间不能小于开始时间')
341
+        this.end_time = ''
342
+      } else {
343
+        this.GetWarehouseOut()
344
+      }
345
+    },
346
+    getTimestamp(time) {
347
+      // 把时间日期转成时间戳
348
+      return new Date(time).getTime() / 1000
339
     },
349
     },
340
     calculate: function(val) {
350
     calculate: function(val) {
341
-      return Math.round(parseFloat(val) * 100) / 100;
351
+      return Math.round(parseFloat(val) * 100) / 100
342
     },
352
     },
343
     GetConfigInfo: function() {
353
     GetConfigInfo: function() {
344
       GetAllConfig().then(response => {
354
       GetAllConfig().then(response => {
345
         if (response.data.state == 0) {
355
         if (response.data.state == 0) {
346
-          this.$message.error(response.data.msg);
347
-          return false;
356
+          this.$message.error(response.data.msg)
357
+          return false
348
         } else {
358
         } else {
349
-          this.manufacturer = response.data.data.manufacturer;
350
-          this.dealer = response.data.data.dealer;
359
+          this.manufacturer = response.data.data.manufacturer
360
+          this.dealer = response.data.data.dealer
351
         }
361
         }
352
-      });
362
+      })
353
     },
363
     },
354
     getManufactuerName: function(manufacturer_id) {
364
     getManufactuerName: function(manufacturer_id) {
355
       for (let i = 0; i < this.manufacturer.length; i++) {
365
       for (let i = 0; i < this.manufacturer.length; i++) {
356
         if (this.manufacturer[i].id == manufacturer_id) {
366
         if (this.manufacturer[i].id == manufacturer_id) {
357
-          return this.manufacturer[i].manufacturer_name;
367
+          return this.manufacturer[i].manufacturer_name
358
         }
368
         }
359
       }
369
       }
360
     },
370
     },
361
     getDealerName: function(dealer_id) {
371
     getDealerName: function(dealer_id) {
362
       for (let i = 0; i < this.dealer.length; i++) {
372
       for (let i = 0; i < this.dealer.length; i++) {
363
         if (this.dealer[i].id == dealer_id) {
373
         if (this.dealer[i].id == dealer_id) {
364
-          return this.dealer[i].dealer_name;
374
+          return this.dealer[i].dealer_name
365
         }
375
         }
366
       }
376
       }
367
     },
377
     },
368
     handleEdit: function(index, row) {
378
     handleEdit: function(index, row) {
369
       this.$router.push({
379
       this.$router.push({
370
-        name: "stockOutDetail",
380
+        name: 'stockOutDetail',
371
         query: { id: row.id, type: this.type }
381
         query: { id: row.id, type: this.type }
372
-      });
382
+      })
373
     },
383
     },
374
     handleDelete: function(index, row) {
384
     handleDelete: function(index, row) {
375
-      const ids = [];
376
-      ids.push(row.id);
377
-      const idStr = ids.join(",");
385
+      const ids = []
386
+      ids.push(row.id)
387
+      const idStr = ids.join(',')
378
 
388
 
379
       const params = {
389
       const params = {
380
         ids: idStr
390
         ids: idStr
381
-      };
391
+      }
382
 
392
 
383
-      this.$confirm("确认删除出库单记录?", "删除出库单记录", {
384
-        confirmButtonText: "确定",
385
-        cancelButtonText: "取消",
386
-        type: "warning"
393
+      this.$confirm('确认删除出库单记录?', '删除出库单记录', {
394
+        confirmButtonText: '确定',
395
+        cancelButtonText: '取消',
396
+        type: 'warning'
387
       })
397
       })
388
         .then(() => {
398
         .then(() => {
389
           deleteWarehouseOut(params).then(response => {
399
           deleteWarehouseOut(params).then(response => {
390
             if (response.data.state == 0) {
400
             if (response.data.state == 0) {
391
-              this.$message.error(response.data.msg);
392
-              return false;
401
+              this.$message.error(response.data.msg)
402
+              return false
393
             } else {
403
             } else {
394
               this.$notify({
404
               this.$notify({
395
-                title: "成功",
396
-                message: "删除成功",
397
-                type: "success",
405
+                title: '成功',
406
+                message: '删除成功',
407
+                type: 'success',
398
                 duration: 2000
408
                 duration: 2000
399
-              });
409
+              })
400
               for (let i = 0; i < ids.length; i++) {
410
               for (let i = 0; i < ids.length; i++) {
401
                 for (let y = 0; y < this.warehouseOutDate.length; y++) {
411
                 for (let y = 0; y < this.warehouseOutDate.length; y++) {
402
                   if (ids[i] == this.warehouseOutDate[y].id) {
412
                   if (ids[i] == this.warehouseOutDate[y].id) {
403
-                    this.warehouseOutDate.splice(y, 1);
413
+                    this.warehouseOutDate.splice(y, 1)
404
                   }
414
                   }
405
                 }
415
                 }
406
               }
416
               }
407
             }
417
             }
408
-          });
418
+          })
409
         })
419
         })
410
-        .catch(() => {});
420
+        .catch(() => {})
411
     },
421
     },
412
     changeAllSelected: function(val) {
422
     changeAllSelected: function(val) {
413
       if (val) {
423
       if (val) {
414
-        this.$refs.multipleTable.toggleAllSelection();
424
+        this.$refs.multipleTable.toggleAllSelection()
415
       } else {
425
       } else {
416
-        this.$refs.multipleTable.clearSelection();
426
+        this.$refs.multipleTable.clearSelection()
417
       }
427
       }
418
     },
428
     },
419
     select(selection) {
429
     select(selection) {
420
-      this.selectedTableData = selection;
430
+      this.selectedTableData = selection
421
     },
431
     },
422
     batchDelete() {
432
     batchDelete() {
423
       if (this.selectedTableData.length <= 0) {
433
       if (this.selectedTableData.length <= 0) {
424
-        this.$message.error("请选择要删除的记录");
425
-        return;
434
+        this.$message.error('请选择要删除的记录')
435
+        return
426
       }
436
       }
427
-      const ids = [];
437
+      const ids = []
428
       for (let i = 0; i < this.selectedTableData.length; i++) {
438
       for (let i = 0; i < this.selectedTableData.length; i++) {
429
-        ids.push(this.selectedTableData[i].id);
439
+        ids.push(this.selectedTableData[i].id)
430
       }
440
       }
431
-      const idStr = ids.join(",");
441
+      const idStr = ids.join(',')
432
       const params = {
442
       const params = {
433
         ids: idStr
443
         ids: idStr
434
-      };
435
-      this.$confirm("确认删除退货单记录?", "删除退货单记录", {
436
-        confirmButtonText: "确定",
437
-        cancelButtonText: "取消",
438
-        type: "warning"
444
+      }
445
+      this.$confirm('确认删除退货单记录?', '删除退货单记录', {
446
+        confirmButtonText: '确定',
447
+        cancelButtonText: '取消',
448
+        type: 'warning'
439
       })
449
       })
440
         .then(() => {
450
         .then(() => {
441
           deleteWarehouseOut(params).then(response => {
451
           deleteWarehouseOut(params).then(response => {
442
             if (response.data.state == 0) {
452
             if (response.data.state == 0) {
443
-              this.$message.error(response.data.msg);
444
-              return false;
453
+              this.$message.error(response.data.msg)
454
+              return false
445
             } else {
455
             } else {
446
               this.$notify({
456
               this.$notify({
447
-                title: "成功",
448
-                message: "删除成功",
449
-                type: "success",
457
+                title: '成功',
458
+                message: '删除成功',
459
+                type: 'success',
450
                 duration: 2000
460
                 duration: 2000
451
-              });
461
+              })
452
 
462
 
453
               for (let i = 0; i < ids.length; i++) {
463
               for (let i = 0; i < ids.length; i++) {
454
                 for (let y = 0; y < this.warehouseOutDate.length; y++) {
464
                 for (let y = 0; y < this.warehouseOutDate.length; y++) {
455
                   if (ids[i] == this.warehouseOutDate[y].id) {
465
                   if (ids[i] == this.warehouseOutDate[y].id) {
456
-                    this.warehouseOutDate.splice(y, 1);
466
+                    this.warehouseOutDate.splice(y, 1)
457
                   }
467
                   }
458
                 }
468
                 }
459
               }
469
               }
460
             }
470
             }
461
-          });
471
+          })
462
         })
472
         })
463
-        .catch(() => {});
473
+        .catch(() => {})
464
     }
474
     }
465
   }
475
   }
466
-};
476
+}
467
 </script>
477
 </script>
468
 
478
 
469
 <style rel="stylesheet/scss" lang="scss">
479
 <style rel="stylesheet/scss" lang="scss">