From d111b3ab62e3a10053d3f339497e03e62459148e Mon Sep 17 00:00:00 2001
From: zjj <3272660260@qq.com>
Date: 星期一, 21 七月 2025 13:51:53 +0800
Subject: [PATCH] #
---
pages/outbound/wavePickItem.vue | 68 ++++++++++++++++++++++++++++------
1 files changed, 56 insertions(+), 12 deletions(-)
diff --git a/pages/outbound/wavePickItem.vue b/pages/outbound/wavePickItem.vue
index b1e1546..25f9817 100644
--- a/pages/outbound/wavePickItem.vue
+++ b/pages/outbound/wavePickItem.vue
@@ -1,10 +1,10 @@
<template>
<view class="has-foot">
<form>
- <view class="cu-form-group" v-show="!isconfirm">
+ <!-- <view class="cu-form-group" v-show="!isconfirm">
<view class="title">娉㈡鍙�</view>
<text class="text-black ">{{wave.code}}</text>
- </view>
+ </view> -->
<view class="cu-form-group" v-show="!isconfirm">
<view class="title">瀹瑰櫒鍙�</view>
<input placeholder="璇锋壂鎻忓鍣ㄥ彿" v-model="barcode" focus></input>
@@ -17,7 +17,7 @@
<view class="cu-list det menu sm-border padding">
- <block v-for="(item, index) in list" :key="index">
+ <block v-for="(item, index) in list">
<view class="cu-list det menu ">
@@ -70,20 +70,20 @@
<text class="text-gray">宸叉嫞鏁伴噺:<text class="text-black ">{{item2.qty}}</text></text>
</view>
</view>
- <view class="cu-item">
+ <view class="cu-item" v-show="item2.anfme !== item2.qty">
<view class="content">
<view class="cu-form-group padding-lr-0">
<view class="title text-blue"><text
class="text-red text-xl vertical-middle">*</text>鎷�:</view>
- <uni-number-box style="width: 70%;" :max="max" v-model="item2.receiptQty"
- :step='1'></uni-number-box>
+ <uni-number-box style="width: 70%;" :max="max" v-model="item2.demandQty"
+ :step='1' ></uni-number-box>
</view>
</view>
</view>
</view>
<view class="cu-item">
<view class="content">
- <text class="text-gray">鏈鎷h揣鏁伴噺:<text class="text-black ">{{item.asnOrderItems.reduce((total, item) => total + (Number(item.receiptQty) ||0 ) , 0)}}</text></text>
+ <text class="text-gray">鏈鎷h揣鏁伴噺:<text class="text-black ">{{item.asnOrderItems.reduce((total, item) => total + (Number(item.demandQty) ||0 ) , 0)}}</text></text>
</view>
</view>
@@ -95,7 +95,7 @@
<view class="cu-bar btn-group foot" v-show="!isconfirm">
<button class="cu-btn text-blue line-blue shadow" @click="clear">娓呯┖</button>
- <button class="cu-btn bg-blue shadow-blur" @click="next">涓嬩竴姝�</button>
+ <button class="cu-btn bg-blue shadow-blur" :disabled="repeatClick" @click="complete">鎷h揣瀹屾垚</button>
</view>
@@ -119,8 +119,9 @@
wave:'',
list: [],
isconfirm: false,
- barcode:'80003642',
+ barcode:'',
max: 99999999,
+ repeatClick:false
}
},
@@ -141,12 +142,15 @@
that.wave = data.data
})
- this.search()
+
},
methods: {
-
- clearCode() {
+ clear() {
this.barcode = ''
+ this.list = []
+ },
+ clearCode() {
+ this.barcode = ''
},
async search() {
this.list = []
@@ -188,6 +192,46 @@
},
+ async complete() {
+
+ let that = this
+ if(that.barcode === '' || that.barcode === null){
+ uni.showToast({
+ title: "瀹瑰櫒鍙蜂负绌�",
+ icon: "error",
+ })
+ return ;
+ }
+ if(that.list === [] || that.list.length === 0){
+ uni.showToast({
+ title: "鎷h揣鏄庣粏涓虹┖",
+ icon: "error",
+ })
+ return ;
+ }
+ this.repeatClick = true
+ const {
+ code,
+ data,
+ msg
+ } = await request('/saveWavePick',{
+ container:that.barcode,
+ containerWaveDtos:that.list
+ })
+ if (code === 200) {
+ uni.showToast({
+ title: msg,
+ icon: "none",
+ })
+ that.clear()
+ } else {
+ uni.showToast({
+ title: msg,
+ icon: "none",
+ })
+ }
+ this.repeatClick = false
+ },
}
}
</script>
--
Gitblit v1.9.1