From 63e5a1095c2a976551f8241d6045b0612bcb5441 Mon Sep 17 00:00:00 2001
From: yyb <995253665@qq.com>
Date: 星期二, 03 二月 2026 14:31:36 +0800
Subject: [PATCH] 订单取消下发扫码校验
---
pages/product/WorkshopOrderCancellationIssued/index.vue | 111 +++++++++++++++++++++++++++++++++----------------------
1 files changed, 66 insertions(+), 45 deletions(-)
diff --git a/pages/product/WorkshopOrderCancellationIssued/index.vue b/pages/product/WorkshopOrderCancellationIssued/index.vue
index a576f90..1aa157c 100644
--- a/pages/product/WorkshopOrderCancellationIssued/index.vue
+++ b/pages/product/WorkshopOrderCancellationIssued/index.vue
@@ -29,7 +29,7 @@
></u-icon>
</view>
</view>
- <view class="packing-registration-param-item param-extra">
+ <!-- <view class="packing-registration-param-item param-extra">
<view class="packing-registration-param-item-left">
<text class="item-one">宸ュ崟</text>
</view>
@@ -79,7 +79,7 @@
size="28"
></u-icon>
</view>
- </view>
+ </view> -->
<view class="packing-registration-param-item param-extra">
<view class="packing-registration-param-item-left">
<text class="item-one">鍙栨秷涓嬪彂璁板綍锛�</text>
@@ -114,10 +114,10 @@
</view>
<view class="row-list">
<view class="_label">
- <view class="_label-name">鍙栨秷涓嬪彂鏁伴噺锛�</view>
+ <view class="_label-name">鍙栨秷鏁伴噺锛�</view>
</view>
<view class="_content">
- {{ item.suppliedQuantity }}
+ {{ item.stockQuantity }}
</view>
</view>
</view>
@@ -133,6 +133,7 @@
:show-confirm-button="true"
@confirm="confirm"
@cancel="cancel"
+
>
<view class="popup-content">
<view class="packing-registration-param">
@@ -181,12 +182,12 @@
</view>
<view class="packing-registration-param-item param-extra">
<view class="packing-registration-param-item-left">
- <text class="item-one">鍙栨秷涓嬪彂鏁伴噺</text>
+ <text class="item-one">鍙栨秷鏁伴噺</text>
</view>
<view class="packing-registration-param-item-right">
<u-input
class="item-one item-two"
- v-model="modalList.returnQuantity"
+ v-model="modalList.stockQuantity"
/>
</view>
</view>
@@ -246,24 +247,44 @@
uni.$off("scan"); // 姣忔杩涙潵鍏� 绉婚櫎鍏ㄥ眬鑷畾涔変簨浠剁洃鍚櫒
uni.$on("scan", function (data) {
console.log("onscan");
- if (that.registerInfo.workstationId == "") {
- uni.showToast({
- icon: "none",
- title: "璇峰厛閫夋嫨鏈哄彴锛�",
- duration: 2 * 1000,
- });
- return;
- }
+ // if (that.registerInfo.workstationId == "") {
+ // uni.showToast({
+ // icon: "none",
+ // title: "璇峰厛閫夋嫨鏈哄彴锛�",
+ // duration: 2 * 1000,
+ // });
+ // return;
+ // }
if (data.code) {
//鎵爜鎴愬姛鍚庣殑鍥炶皟锛屼綘鍙互鍐欒嚜宸辩殑閫昏緫浠g爜鍦ㄨ繖閲�
console.log("鎵爜缁撴灉锛�", data.code);
let codeInfo = JSON.parse(data.code);
that.codeInfoId = codeInfo.id;
- if (codeInfo) {
- // 鎵弿鎶ュ伐鍗曚簩缁寸爜
- that.scanHandle(codeInfo);
- that.$forceUpdate();
- }
+ if (codeInfo.PN) {
+ // 鎵弿鎶ュ伐鍗曚簩缁寸爜
+ that.scanHandle(codeInfo);
+ that.$forceUpdate();
+ // that.getHandelList();
+ }
+ if (codeInfo.moOn) {
+ console.log('1111111111')
+ this.$u.api.WorkshopOrderIssued.getManuOrder({
+ moOn: codeInfo.moOn,
+ }).then((res) => {
+ console.log('111111111',res)
+ if (res.code === 0) {
+ that.registerInfo = {
+ operationTaskId: "",
+ id:res.data.id,
+ moNo: res.data.ifsOrderNo,
+ optaskNo: "",
+ workstationId: "",
+ }
+ }
+ })
+ .catch((err) => {
+ })
+ }
}
});
},
@@ -323,22 +344,22 @@
this.$refs.uModal.clearLoading(); // 娓呴櫎鍔犺浇鐘舵��
return;
}
- if (!this.modalList.returnQuantity) {
- this.$u.toast("璇疯緭鍏ュ彇娑堜笅鍙戞暟閲�");
+ if (!this.modalList.stockQuantity) {
+ this.$u.toast("璇疯緭鍏ュ彇娑堟暟閲�");
this.$refs.uModal.clearLoading(); // 娓呴櫎鍔犺浇鐘舵��
return;
}
// 澶勭悊纭閫昏緫
- this.$u.api.WorkshopOrderCancellationIssued.feeding([
- this.modalList,
- ]).then((res) => {
+ this.$u.api.WorkshopOrderCancellationIssued.rejectPDA(
+ this.modalList
+ ).then((res) => {
console.log("res", res);
if (res.code === 0) {
this.$u.toast("鎻愪氦鎴愬姛");
this.showModal = false;
const obj = {
- suppliedQuantity: this.modalList.suppliedQuantity,
- outBatchNo: this.modalList.returnQuantity,
+ stockQuantity: this.modalList.stockQuantity,
+ outBatchNo: this.modalList.outBatchNo,
};
this.hasScanSnList.push(obj);
}
@@ -406,21 +427,21 @@
},
// 鎵爜鍚庢暟鎹洖鏄�
scanHandle(val) {
- const { outBatchNo } = val;
- const { workstationId, operationTaskId } = this.registerInfo;
+ const { BN } = val;
+ const { id } = this.registerInfo;
const obj = {
- outBatchNo: outBatchNo,
- feedingWorkstationId: workstationId,
- operationTaskId: operationTaskId,
+ outBatchNo: BN,
+ moId: id,
};
- this.$u.api.WorkshopOrderCancellationIssued.checkReturnPartPDA(obj).then(
- (res) => {
- console.log("res", res);
- if (res.code === 0) {
- this.getHandymanItem(obj);
- }
- }
- );
+ this.getReturnInfo(obj);
+ // this.$u.api.WorkshopOrderCancellationIssued.checkReturnPartPDA(obj).then(
+ // (res) => {
+ // console.log("res", res);
+ // if (res.code === 0) {
+ // this.getHandymanItem(obj);
+ // }
+ // }
+ // );
},
// 鑾峰彇鍩烘湰淇℃伅
getReturnInfo(obj) {
@@ -482,7 +503,7 @@
}
.packing-registration-param-view {
- height: 450rpx;
+ height: 200rpx;
background-color: #fff;
border-radius: 10rpx;
padding: 0rpx 23rpx;
@@ -498,8 +519,8 @@
.packing-registration-param-item-left {
.item-one {
- font-size: 30rpx;
- color: #666666;
+ font-size: small;
+ color: #232222;
}
}
@@ -514,7 +535,7 @@
}
.item-two {
- font-size: 30rpx;
+ font-size: small;
color: #a6b4cc;
margin-right: 6rpx;
}
@@ -599,7 +620,7 @@
._label-name {
margin-left: 11rpx;
- font-size: 26rpx;
+ font-size: small;
font-weight: 500;
color: #666666;
}
@@ -609,7 +630,7 @@
flex: 1.5;
text-align: right;
color: #909399;
- font-size: 24rpx;
+ font-size: small;
}
.row-list .s1 {
--
Gitblit v1.9.3