schangxiang@126.com
2025-09-17 c0e20b1b0f1298cdc0af0037d60e74d51e364501
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
<template>
  <view class="overflow" style="padding-bottom: 150px">
    <cu-custom bgColor="bg-white" :isBack="true">
      <block slot="backText"> </block>
      <block slot="content">
        <span v-if="orderType == 1">整体拣货</span>
        <span v-if="orderType == 2">逐件拣货</span>
      </block>
    </cu-custom>
    <!-- <view class="flex justify-end align-center padding_right30rpx padding10">
            <text class="fontSize12rpx"> 操作人:{{ operator }} </text>
        </view> -->
    <modal-code ref="resmodal" :rescode="rescode" :resmessage="resmessage" />
    <u-select
      v-model="containerVisible"
      :list="containerList"
      @confirm="containerConfirm"
    ></u-select>
    <u-select
      v-model="containerVisibleDo"
      :list="containerListDo"
      @confirm="containerConfirmDo"
    ></u-select>
    <view class="" v-if="renameFocus">
      <u-form
        labelPosition="left"
        label-width="180rpx"
        :model="warehouse"
        ref="warehouseRef"
      >
        <u-row
          class="border_bottom margin_top10rpx padding_left25rpx"
          style="background-color: #fff"
        >
          <u-col span="12">
            <u-form-item
              label="容器编号:"
              prop="containerCode"
              required
              class="uFormItem"
            >
              <u-input
                :focus="curFoucus"
                v-model.trim="warehouse.containerCode"
                @confirm="getOutWarehouse(1)"
                :clearable="false"
                @focus="warehouse.containerCode = ''"
                placeholder="请扫码录入"
              >
              </u-input>
            </u-form-item>
          </u-col>
        </u-row>
        <!-- 逐件拣货2 -->
        <u-row
          class="border_bottom margin_top10rpx padding_left25rpx"
          style="background-color: #fff"
          v-if="this.orderType == 2"
        >
          <u-col span="10">
            <u-form-item label="下架单号:" prop="DoOrderNo" class="uFormItem">
              <u-input
                v-model.trim="warehouse.DoOrderNo"
                placeholder="请录入或扫码"
                @focus="warehouse.DoOrderNo = ''"
                class="width"
                :clearable="false"
                @confirm="orderBlurDo"
              >
              </u-input>
            </u-form-item>
          </u-col>
          <u-col span="2" @tap="containerFocusDo">
            <span class="fontSize15rpx">选择</span>
            <u-icon name="arrow-right" size="14" class="fontSize15rpx"></u-icon>
          </u-col>
        </u-row>
 
        <!-- 逐件拣货2 -->
        <u-row
          class="border_bottom margin_top10rpx padding_left25rpx"
          style="background-color: #fff"
          v-if="this.orderType == 2"
        >
          <u-col span="12">
            <u-form-item label="物料跟踪码:" class="uFormItem">
              <u-input
                v-model="warehouse.SNCode"
                @focus="warehouse.SNCode = ''"
                placeholder="请录入或扫码"
                @confirm="getOutWarehouse"
                :clearable="false"
              >
              </u-input>
            </u-form-item>
          </u-col>
        </u-row>
 
        <!-- 整体拣货1 -->
        <u-row
          class="border_bottom margin_top10rpx padding_left25rpx"
          style="background-color: #fff"
          v-if="this.orderType == 1"
        >
          <u-col span="12">
            <u-form-item label="物料编号:" class="uFormItem">
              <u-input
                v-model="warehouse.materialCode"
                @focus="warehouse.materialCode = ''"
                placeholder="请录入或扫码"
                @blur="getMaterialDetails"
              >
              </u-input>
            </u-form-item>
          </u-col>
        </u-row>
      </u-form>
      <view>
        <view
          v-for="(item, eindex) in singlist"
          :key="eindex"
          style="width: 100vw; display: flex; margin: 5px auto"
        >
          <u-swipe-action
            :show="item.show"
            :index="eindex"
            @click="longpress"
            @open="open"
            :options="options"
            style="width: 100vw"
          >
            <view
              class="fontSize32rpx background_fff padding10"
              :class="item.showItem ? 'bg_item' : ''"
              style="width: 100vw"
            >
              <u-row>
                <u-col span="1">
                  <view
                    class="flex justify-center align-center"
                    style="
                      background-color: #f18202;
                      color: #fff;
                      border-radius: 50%;
                      width: 40rpx;
                      height: 40rpx;
                    "
                  >
                    {{ eindex + 1 }}
                  </view>
                </u-col>
                <u-col span="11">
                  <view class="color_f18202">
                    {{ item.materialCode }}-{{ item.materialName }}
                  </view>
                </u-col>
              </u-row>
              <u-row v-if="orderType == 2">
                <u-col span="12">
                  <view class="color_80 padding_left25rpx">
                    下架单号:{{ item.relationNo }}
                  </view>
                </u-col>
              </u-row>
              <u-row v-if="orderType == 2">
                <u-col span="12">
                  <view class="color_80 padding_left25rpx">
                    物料跟踪码:{{ item.snCode }}
                  </view>
                </u-col>
              </u-row>
              <u-row>
                <u-col span="6">
                  <view class="color_80 padding_left25rpx">
                    分拣需求数:{{ item.quantity }}
                  </view>
                </u-col>
                <u-col span="6">
                  <view class="color_80">
                    库位编号:{{ item.containerCode }}
                  </view>
                </u-col>
              </u-row>
              <u-row>
                <u-col span="6">
                  <view class="color_80 padding_left25rpx">
                    已分拣数:{{ item.pickQuantity }}
                  </view>
                </u-col>
                <u-col span="6" class="flex" v-if="orderType == 1">
                  <view class="color_80"> 实际分拣数: </view>
                  <input
                    class="border_bottom_f18202 text-left color_f18202 fontSize32rpx"
                    style="
                      background-color: #f2f2f2;
                      height: 70rpx;
                      width: 100rpx;
                    "
                    v-model="item.uncollectedQuantity"
                    type="number"
                    @blur="changeNum(item)"
                    placeholder=""
                  />
                </u-col>
 
                <u-col span="5" class="flex" v-if="orderType == 2">
                  <view class="color_f18202">
                    实际分拣数:{{ item.uncollectedQuantity }}
                  </view>
                </u-col>
              </u-row>
            </view>
          </u-swipe-action>
        </view>
      </view>
      <u-popup
        v-model="detailshow"
        border-radius="14"
        @close="detailshow = false"
        mode="bottom"
      >
        <view class="pop">
          <h2 class="text_align_center padding_bottom18 padding15">物料信息</h2>
          <scroll-view
            scroll-y="true"
            style="height: 50vh; margin-bottom: 140rpx"
          >
            <view class="line flex justify-between">
              <text class="text-gray">物料编号</text>
              <text>{{ materlist.materialCode }}</text>
            </view>
            <view class="line flex justify-between">
              <text class="text-gray">物料名称</text>
              <text>{{ materlist.materialName }}</text>
            </view>
            <view class="line flex justify-between">
              <text class="text-gray">容器编号</text>
              <text>{{ materlist.containerCode }}</text>
            </view>
 
            <view class="line flex justify-between">
              <text class="text-gray">关联单号</text>
              <text>{{ materlist.relationNo }}</text>
            </view>
            <view class="line flex justify-between ">
              <text class="text-gray">异常原因:</text>
              <input class="textyc" v-model="materlist.exceptionReason"></input>
            </view>
            <view class="line flex justify-between">
              <text class="text-gray">异常数量:</text>
              <input
                type="number" class="textyc"
                v-model="materlist.exceptionQuality"
              ></input>
            </view>
          </scroll-view>
        </view>
        <button-modal
          :cleaningShow="true"
          allTitle="重置"
          cleaningTitle="异常汇报"
          @allsubmit="init(1)"
          @submit="init(2)"
        />
      </u-popup>
      <button-modal
        :empTytowerShow="true"
        cleaningTitle="返回"
        garmenTitle="下一步"
        @submit="next"
        @reset="rest"
      />
    </view>
    <view class="" v-if="!renameFocus">
      <view>
        <view
          v-for="(item, eindex) in arr"
          :key="eindex"
          class="fontSize32rpx padding10 margin_top10rpx background_fff"
        >
          <u-row>
            <u-col span="12" class="flex">
              <view
                class="flex justify-center align-center"
                style="
                  background-color: #f18202;
                  color: #fff;
                  border-radius: 50vh;
                  width: 20px;
                  height: 20px;
                "
              >
                {{ eindex + 1 }}
              </view>
              <view class="padding_left10rpx color_f18202">
                {{ item.materialCode }}-{{ item.materialName }}
              </view>
            </u-col>
          </u-row>
          <u-row v-if="orderType == 2">
            <u-col span="12">
              <view class="color_80 padding_left25rpx">
                下架单号:{{ item.relationNo }}
              </view>
            </u-col>
          </u-row>
          <u-row v-if="orderType == 2">
            <u-col span="12">
              <view class="color_80 padding_left25rpx">
                物料跟踪码:{{ item.snCode }}
              </view>
            </u-col>
          </u-row>
          <u-row>
            <u-col span="12">
              <view class="color_80 padding_left25rpx">
                库位编号:{{ item.containerCode }}
              </view>
            </u-col>
          </u-row>
          <u-row>
            <u-col span="8">
              <view class="color_80 padding_left25rpx">
                需求分拣:{{ item.quantity }}
              </view>
            </u-col>
            <u-col span="4" class="color_80">
              已分拣数:{{ item.pickQuantity }}
            </u-col>
          </u-row>
          <u-row>
            <u-col span="8">
              <view class="color_80 padding_left25rpx">
                实际分拣:{{ item.uncollectedQuantity }}
              </view>
            </u-col>
            <u-col span="4">
              <view class="color_f18202">
                剩余:{{
                  Number(
                    item.quantity - item.pickQuantity - item.uncollectedQuantity
                  ).toFixed(3)
                }}
              </view>
            </u-col>
          </u-row>
        </view>
      </view>
    </view>
    <button-modal
      v-if="!renameFocus"
      :empTytowerShow="true"
      cleaningTitle="上一步"
      garmenTitle="分拣完成"
      @submit="submit"
      @reset="back"
    />
  </view>
</template>
 
<script>
import ButtonModal from "../../components/buttonModal.vue";
import ModalCode from "../../components/ModalCode.vue";
import {
  getOutWarehousePO,
  addWarehouseDetailsPO,
  addSortExceptionFlagConfirm,
} from "../../api/sort.js";
import { getDate } from "../../utils/dateTime.js";
import { getAllOrderDo } from "../../api/deliver.js";
export default {
  data() {
    return {
      curFoucus: true,
      ermNum: "",
      contLabel: 1,
      containerVisibleDo: false,
      containerListDo: [],
      containerVisible: false,
      containerList: [],
      renameFocus: true,
      detailshow: false,
      rescode: 0,
      resmessage: "",
      modalshow: false,
      action: this.$myHOST + "/sysFileInfo/uploadImages",
      singlist: [], //物料详情
      arr: [],
      materlist: {}, //物料详情数据
      warehouse: {
        containerCode: "",
        DoOrderNo: "",
        SNCode: "",
      },
      activeIndex: 100,
      detailable: false,
      materialCode: "", //物料编号
      warehouseRules: {},
      options: [
        {
          text: "详情",
          style: {
            backgroundColor: "#fc9f35",
          },
        },
      ],
      operator: "",
      Datetime: getDate(),
      orderType: "",
    };
  },
  components: {
    ButtonModal,
    ModalCode,
  },
  onLoad(option) {
    if (option.orderType) {
      this.orderType = option.orderType;
    }
  },
  onReady() {
    this.$refs.warehouseRef.setRules(this.warehouseRules);
  },
  mounted() {
    this.operator = JSON.parse(uni.getStorageSync("userInfo")).name;
  },
  computed: {
    containerCode() {
      return this.warehouse.containerCode;
    },
  },
  watch: {
    containerCode(val) {
      if (!val) {
        this.detailable = false;
      }
    },
  },
  methods: {
    //DO容器选择 0712
    containerConfirmDo(context) {
      this.warehouse.DoOrderNo = context[0].value;
      this.orderBlurDo();
    },
    //DO容器聚焦事件
    containerFocusDo() {
      getAllOrderDo({
        OrderType: 5,
        page: 1,
        pageSize: 20,
        orderStatus: 1, //处理中
      }).then((res) => {
        if (res.result && res.result.items) {
          var arr = res.result.items;
          this.containerListDo = arr.reduce((curr, item) => {
            curr.push({
              label: item.orderNo,
              // label: item.orderNo + '; 时间:' + item.createTime ,
              value: item.orderNo,
            });
            return curr;
          }, []);
        }
        this.containerVisibleDo = true;
      });
    },
    // DO单号
    orderBlurDo() {
      if (this.warehouse.DoOrderNo == "") {
        return;
      }
      this.containerFocus();
    },
 
    //打印
    init(param) {
      if (param == 1) {
        // 重置
        this.materlist.exceptionReason = "";
        this.materlist.exceptionQuality = 0;
        return;
      }
 
      if (!this.materlist.exceptionReason) {
        this.detailshow = false;
        this.rescode = 400;
        this.resmessage = `异常原因不能为空`;
        this.$refs.resmodal.show = true;
        return;
      }
 
      if (!this.materlist.exceptionQuality) {
        this.detailshow = false;
        this.rescode = 400;
        this.resmessage = `异常数量大于0`;
        this.$refs.resmodal.show = true;
        return;
      }
      if(Number(this.materlist.exceptionQuality) > Number(this.materlist.uncollectedQuantity)   ){
        this.detailshow = false;
        this.rescode = 400;
        this.resmessage = `异常数量大于实际分拣数`;
        this.$refs.resmodal.show = true;
        return;
      }
      if (param == 2) {
        // 异常汇报
        this.detailshow = false;
        debugger;
        addSortExceptionFlagConfirm({
          ContainerCode: this.materlist.containerCode,
          ExceptionReason: this.materlist.exceptionReason,
          SortExceptionFlagDetailsConfirmList: [
            {
              ContainerSortId: this.materlist.id,
              ...this.materlist,
            },
          ],
        }).then((res) => {
          this.rescode = res.code;
          this.resmessage = res.message;
          this.$refs.resmodal.show = true;
          if (res.code == 200) {
            this.renameFocus = true;
            this.resmessage = "异常汇报成功";
            this.warehouse.containerCode = this.materlist.containerCode;
            this.materlist = {};
            this.getOutWarehouse(1)
          }
        });
      }
    },
    //获取print date print time
    getCurrentDate() {
      let date = new Date();
      let year = date.getFullYear(); //年
      let month = date.getMonth() + 1; //月
      month = month >= 10 ? month : "0" + month;
      let day = date.getDate(); //日
      day = day >= 10 ? day : "0" + day;
      let hour = date.getHours(); //时
      hour = hour >= 10 ? hour : "0" + hour;
      let min = date.getMinutes(); //分
      min = min >= 10 ? min : "0" + min;
      let second = date.getSeconds(); //秒
      second = second >= 10 ? second : "0" + second;
      return {
        date: `${day}.${month}.${year}`,
        time: `${hour}:${min}:${second}`,
        formate: `${year}/${month}/${day}`,
      };
    },
    //容器选择 8888
    containerConfirm(context) {
      this.getOutWarehouse();
    },
    //容器聚焦事件
    containerFocus() {
      this.getContainerList();
    },
    //获取当前区域的需要分拣的容器列表
    getContainerList() {
      if (this.warehouse.DoOrderNo == "") {
        uni.showToast({
          title: "请选择或者DO单号",
          icon: "none",
          duration: 2000,
        });
        return;
      }
      this.getOutWarehouse();
    },
    //查询物料
    getOutWarehouse() {
      this.$refs.warehouseRef.validate((valid) => {
        if (valid) {
          if (!this.warehouse.containerCode) {
            uni.showToast({
              title: "容器编号必填!",
              icon: "none",
              duration: 2000,
            });
            return;
          }
          this.focu = false;
          let params = {
            ContainerCode: this.warehouse.containerCode,
            RelationNo: this.warehouse.DoOrderNo,
            SNCode: this.warehouse.SNCode,
            OrderType: 5,
          };
          getOutWarehousePO(params).then((res) => {
            if (res.code == 200) {
              var resArr = res.result;
              if (resArr.length == 0) {
                this.resmessage = "查无物料数据";
                this.rescode = 400;
                this.$refs.resmodal.show = true;
                this.singlist = [];
              } else {
                // 整体拣货
                if (this.orderType == 1) {
                  resArr.map((item) => {
                    item.uncollectedQuantity = Number(
                      Number(item.quantity) - Number(item.pickQuantity)
                    ).toFixed(3);
                    item.showItem = false;
                    return item;
                  });
                }
                // 逐件拣货
                if (this.orderType == 2) {
                  resArr.map((item) => {
                    item.uncollectedQuantity = Number(
                      Number(item.quantity) - Number(item.pickQuantity)
                    ).toFixed(3);
                    item.showItem = false;
                    return item;
                  });
                }
                this.singlist = resArr;
              }
            } else {
              this.resmessage = res.message;
              this.rescode = res.code;
              this.$refs.resmodal.show = true;
            }
          });
        }
      });
    },
    //判断此物料编号是否存在
    getMaterialDetails() {
      // this.materialCode = getAttrValue(this.materialCode, 'PARTSNUMBER')
      if (this.warehouse.materialCode !== "") {
        //获取当前物料 + 批次的所有数据
        const arr = this.singlist.reduce((curr, item, index) => {
          if (item.materialCode == this.warehouse.materialCode) {
            curr.push(index);
          }
          return curr;
        }, []);
 
        if (arr.length > 0) {
          arr.forEach((item) => {
            this.singlist[item].showItem = true;
            this.singlist.unshift(...this.singlist.splice(item, 1));
          });
        } else {
          uni.showModal({
            title: "提示",
            content: "当前分拣单中不需分拣此物料",
            showCancel: false,
          });
        }
      }
    },
    //详情
    longpress(index, eindex) {
      this.singlist[index].exceptionQuality = 0;
      this.materlist = this.singlist[index];
      this.activeIndex = index;
      this.detailshow = true;
    },
    // 如果打开一个的时候,不需要关闭其他,则无需实现本方法
    open(index) {
      // 先将正在被操作的swipeAction标记为打开状态,否则由于props的特性限制,
      // 原本为'false',再次设置为'false'会无效
      this.singlist[index].show = true;
      this.singlist.map((val, idx) => {
        if (index != idx) this.singlist[idx].show = false;
      });
    },
    //改变组盘数量
    changeNum(val) {
      if (
        parseFloat(val.uncollectedQuantity) < 0 ||
        val.uncollectedQuantity == ""
      ) {
        uni.showModal({
          title: "提示",
          content: "分拣数量不能小于0",
          showCancel: false,
        });
      }
      // val.uncollectedQuantity  = Number(val.uncollectedQuantity.toString().match(/^\d+(?:\.\d{0,2})?/)) // 保留两位小数
      // let num1 =  Number(Number(val.quantity) - Number(val.sortingQuantity)).toFixed(3) //必须保留3位小数 -否则会造成剩余物料是小数的时候,无法收货
      // 越库-数量不计入 造成bug
      if (parseFloat(val.uncollectedQuantity) > Number(val.quantity)) {
        uni.showModal({
          title: "提示",
          content: "分拣数量不能大于需求数",
          showCancel: false,
        });
      }
    },
    //确认
    next() {
      if (this.singlist.length == 0) {
        this.rescode = 400;
        this.resmessage = `没有可操作的物料`;
        this.$refs.resmodal.show = true;
        return;
      } else {
        if (this.orderType == 1) {
          this.arr = this.singlist.reduce((curr, item) => {
            let { uncollectedQuantity, quantity, ...rest } = item;
            if (Number(item.uncollectedQuantity) > 0) {
              curr.push(item);
            }
            return curr;
          }, []);
        } else {
          this.arr = this.singlist;
        }
        console.log(this.arr);
        this.renameFocus = false;
      }
    },
    submit() {
      let sortingLists = this.arr.reduce((curr, item) => {
        let { uncollectedQuantity, quantity, ...rest } = item;
        if (Number(item.uncollectedQuantity) > 0) {
          curr.push({
            ...rest,
            OccQuality: item.uncollectedQuantity,
            ContainerSortId: item.id,
          });
        }
        return curr;
      }, []);
      if (sortingLists.length <= 0) {
        uni.showToast({
          title: "没有需要提交的数据!",
          icon: "none",
          duration: 2000,
        });
        return;
      }
      let params = {
        ContainerCode: this.warehouse.containerCode,
        SortDetailsConfirmlist: sortingLists,
      };
      uni.showModal({
        title: "提示",
        content: "确定是否分拣?",
        showCancel: true,
        cancelColor: "#333333",
        success: (res) => {
          if (res.confirm) {
            addWarehouseDetailsPO(params).then((res) => {
              this.rescode = res.code;
              this.resmessage = res.message;
              this.$refs.resmodal.show = true;
              if (res.code == 200) {
                this.renameFocus = true;
                this.resmessage = "拣货成功";
                this.resetData();
              }
            });
          } else if (res.cancel) {
          }
        },
      });
    },
    //数据重置
    resetData() {
      this.warehouse.gridNumber = 1;
      this.warehouse.useNumber = 0;
      this.warehouse.exitNumber = 0;
      this.materialCode = "";
      this.arr = [];
      this.singlist = [];
    },
    //回库
    rest() {
      uni.navigateTo({
        url: `/pages/index/index`,
      });
    },
    //上一步
    back() {
      this.renameFocus = true;
    },
  },
};
</script>
 
<style lang="scss" scoped>
.bg_item {
  background: #ffebcd !important;
}
 
.textyc{
    margin-top: 10px;
}
</style>