From edd7f4270d1c1ae41228bb35973b6a9a47057c74 Mon Sep 17 00:00:00 2001
From: wtt <1985833171@qq.com>
Date: 星期二, 19 八月 2025 11:29:42 +0800
Subject: [PATCH] 工序出战汇报,委外接收发出单添加序列号选择
---
pages/weiwaigxOut/form.vue | 148 ++++++++++++++++++++++++++++++++++++++++++++----
1 files changed, 134 insertions(+), 14 deletions(-)
diff --git a/pages/weiwaigxOut/form.vue b/pages/weiwaigxOut/form.vue
index c63fdbf..b5b053c 100644
--- a/pages/weiwaigxOut/form.vue
+++ b/pages/weiwaigxOut/form.vue
@@ -11,10 +11,17 @@
size="20" @click="toScanCode"></uni-icons>
</view>
<view class="form-item">
+ <view class="title">搴忓垪鍙�:</view>
+ <view class="right">
+ <uni-combox :candidates="arrayHSEQName" placeholder="璇烽�夋嫨搴忓垪" v-model="hform.HSEQName"
+ @input="HSEQNameChange"></uni-combox>
+ </view>
+ </view>
+ <view class="form-item">
<view class="title"><text>*</text>娴佹按鍙�:</view>
<view class="right" style="width: 380rpx;">
<input v-model="hform.HProcNo" placeholder="璇疯緭鍏�(鎴栨壂鎻�)娴佹按鍙�"
- @blur="getHProcNoData(hform.HBarCode,hform.HProcNo)" />
+ @blur="getHProcNoData2(hform.HBarCode,hform.HProcNo,hform.HSEQNumber)" />
</view>
<uni-icons type="scan"
style="margin-left: 10rpx;background-color: #3A78FF;padding: 6rpx;color: #fff;border-radius: 100%;"
@@ -402,7 +409,8 @@
HGroupNameList: [],
arrayHDept: [], // 閮ㄩ棬
HDeptList: [],
-
+ arrayHSEQName:[],//搴忓垪
+ HSEQNameList:[],
isEdit: false,
hform: {
HStockOrgID: uni.getStorageSync('OrganizationID'),
@@ -435,7 +443,8 @@
HProcID: 0,
HPRDOrg: '',
HOrderProcNO: '',
-
+ HSEQName:'',
+ HSEQNumber:0,
// HPRDOrg:'',
// HICMOBillNo:'',
// HICMOInterID:'',
@@ -567,9 +576,16 @@
var str = ret.resp_result
if (str.includes('@')) {
const parts = str.split('@');
- this.hform.HBarCode = parts[0]
- this.hform.HProcNo = parts[1]
- this.getHBarCodeData(parts[0], 1)
+ if(parts.length==3){
+ this.hform.HBarCode = parts[0]
+ this.hform.HProcNo = parts[1]
+ this.hform.HSEQNumber = parts[2]
+ this.getHBarCodeData(parts[0], 2)
+ }else{
+ this.hform.HBarCode = parts[0]
+ this.hform.HProcNo = parts[1]
+ this.getHBarCodeData(parts[0], 1)
+ }
// this.getHProcNoData(parts[0],parts[1])
} else {
this.hform.HBarCode = ret.resp_result
@@ -581,9 +597,16 @@
var str = this.hform.HBarCode
if (str.includes('@')) {
const parts = str.split('@');
- this.hform.HBarCode = parts[0]
- this.hform.HProcNo = parts[1]
- this.getHBarCodeData(parts[0], 1)
+ if(parts.length==3){
+ this.hform.HBarCode = parts[0]
+ this.hform.HProcNo = parts[1]
+ this.hform.HSEQNumber = parts[2]
+ this.getHBarCodeData(parts[0], 2)
+ }else{
+ this.hform.HBarCode = parts[0]
+ this.hform.HProcNo = parts[1]
+ this.getHBarCodeData(parts[0], 1)
+ }
// this.getHProcNoData(parts[0],parts[1])
} else {
this.getHBarCodeData(this.hform.HBarCode)
@@ -599,7 +622,7 @@
}, (ret) => {
console.log(ret.resp_result)
this.hform.HProcNo = ret.resp_result
- this.getHProcNoData(this.hform.HBarCode, ret.resp_result)
+ this.getHProcNoData2(this.hform.HBarCode, ret.resp_result,this.hform.HProcNumber)
})
},
//鏃ユ湡
@@ -840,7 +863,65 @@
}
}
},
-
+ //搴忓垪鑾峰彇
+ getHSEQList(e){
+ uni.request({
+ url: this.serverUrl + 'Cj_StationOutBill/getAllHSEQ',
+ data: {
+ HInterID:this.hform.HProcExchHinteID
+ },
+ success: (res) => {
+ if (res.data.code == 1) {
+ this.HSEQNameList = res.data.data
+ for (var i = 0; i < res.data.data.length; i++) {
+ this.arrayHSEQName[i] = res.data.data[i].HSEQName
+ }
+ this.$forceUpdate();
+ //娌℃湁搴忓垪鍙烽粯璁や富搴忓垪
+ if(e==1){
+ //璁剧疆涓诲簭鍒�
+ this.setMainHSEQ();
+ this.getHProcNoData2(this.hform.HBarCode,this.hform.HProcNo,this.hform.HSEQNumber)
+ }else if(e==2){
+ this.getHProcNoData2(this.hform.HBarCode,this.hform.HProcNo,this.hform.HSEQNumber)
+ }else{
+ //璁剧疆涓诲簭鍒�
+ this.setMainHSEQ();
+ }
+ } else {
+ uni.showToast({
+ title: res.data.Message,
+ icon: 'none'
+ })
+ }
+ },
+ fail: (res) => {
+ console.log(res);
+ uni.showToast({
+ title: '鎺ュ彛璇锋眰澶辫触',
+ icon: 'none'
+ })
+ },
+ });
+ },
+ //閫夋嫨搴忓垪
+ HSEQNameChange(e) {
+ for (var i = 0; i < this.HSEQNameList.length; i++) {
+ if (this.HSEQNameList[i].HSEQName == e) {
+ this.hform.HSEQNumber = this.HSEQNameList[i].HSEQNumber
+ }
+ }
+ },
+ //璁剧疆涓诲簭鍒�
+ setMainHSEQ(){
+ for (var i = 0; i < this.HSEQNameList.length; i++) {
+ if (this.HSEQNameList[i].HSEQType == 'M') {
+ this.hform.HSEQNumber = this.HSEQNameList[i].HSEQNumber
+ this.hform.HSEQName = this.HSEQNameList[i].HSEQName
+ break;
+ }
+ }
+ },
//缂栬緫
ifEdit() {
//鏄惁缂栬緫
@@ -986,10 +1067,9 @@
this.hform.HProcExchHinteID = data.hmainid
this.hform.HPRDOrg = data.缁勭粐鍚嶇О
this.hform.HPRDOrgID = data.HPRDORGID
+ //璁剧疆搴忓垪
+ this.getHSEQList(e);
- if (e) {
- this.getHProcNoData(this.hform.HBarCode, this.hform.HProcNo)
- }
} else {
uni.showToast({
title: res.data.Message,
@@ -1044,6 +1124,46 @@
},
});
},
+ getHProcNoData2(HBarCode, HProcNo,HSEQNumber) {
+ uni.request({
+ url: this.serverUrl + '/Cj_StationEntrustInBill/txtHProcNo_KeyDown_Sec',
+ data: {
+ sBillNo: HBarCode,
+ sProcNo: HProcNo,
+ HSEQNumber:HSEQNumber
+ },
+ success: (res) => {
+ console.log(3, res);
+ if (res.data.code == 1) {
+ var data = res.data.data[0]
+ this.hform.lngBillSubKey = data.hsubid
+ this.hform.HProcName = data.宸ュ簭
+ this.hform.HProcID = data.HProcID
+ this.hform.HCenterName = data.宸ヤ綔涓績
+ this.hform.HCenterID = data.HCenterID
+ this.hform.HNotReportQty = data['鏈姤宸ユ暟閲�']
+ this.hform.HProcNumber = data['宸ュ簭浠g爜']
+ this.hform.HSEQName = data.搴忓垪鍚嶇О
+ if (!this.hform.HSupName) {
+ this.hform.HSupName = data.渚涘簲鍟�
+ this.hform.HSupID = data.HSupID
+ }
+ } else {
+ uni.showToast({
+ title: res.data.Message,
+ icon: 'none'
+ })
+ }
+ },
+ fail: (res) => {
+ console.log(res);
+ uni.showToast({
+ title: '鎺ュ彛璇锋眰澶辫触',
+ icon: 'none'
+ })
+ },
+ });
+ },
//鏂板
getNewData() {
uni.request({
--
Gitblit v1.9.1