| | |
| | | }, |
| | | //选择源单类型 |
| | | HMainSourceBillTypeChange(e) { |
| | | this.HMainSourceBillType = this.arrayHMainSourceBillType[e.detail.value] |
| | | let index = this.arrayHMainSourceBillType.findIndex(e => e == this.HMainSourceBillType) |
| | | this.HMainSourceBillType = e.detail.value |
| | | let index = this.arrayHMainSourceBillType.findIndex(elem => elem == this.HMainSourceBillType) |
| | | if (index != -1) { |
| | | this.hform.HMainSourceBillType = this.arrayHMainSourceBillValue[index] |
| | | // this.getHYDList() |
| | | } |
| | | |
| | | console.log(this.HMainSourceBillType, this.hform.HMainSourceBillType) |
| | | }, |
| | | |
| | | //获取供应商数据 |
| | |
| | | this.hform.HMainSourceBillType = data.hSourceBillTypeField |
| | | this.showHMainSourceBillType = false |
| | | } |
| | | // if (data.hSourceBillTypeField == "1402") { |
| | | // this.HMainSourceBillType = '发货通知单' |
| | | // this.hform.HMainSourceBillType = 1402 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "1243") { |
| | | // this.HMainSourceBillType = '调拨申请单' |
| | | // this.hform.HMainSourceBillType = 1243 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "1214") { |
| | | // this.HMainSourceBillType = '生产发料通知单' |
| | | // this.hform.HMainSourceBillType = 1214 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "3720") { |
| | | // this.HMainSourceBillType = '生产用料清单' |
| | | // this.hform.HMainSourceBillType = 3720 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "1604") { |
| | | // this.HMainSourceBillType = '委外用料清单' |
| | | // this.hform.HMainSourceBillType = 1604 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "1214") { |
| | | // this.HMainSourceBillType = '生产发料通知单' |
| | | // this.hform.HMainSourceBillType = 1214 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "3721") { |
| | | // this.HMainSourceBillType = '生产备料单' |
| | | // this.hform.HMainSourceBillType = 3721 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "1242") { |
| | | // this.HMainSourceBillType = '出库申请单' |
| | | // this.hform.HMainSourceBillType = 1242 |
| | | // this.showHMainSourceBillType = false |
| | | // } else { |
| | | // this.HMainSourceBillType = '手工录入' |
| | | // this.hform.HMainSourceBillType = -1 |
| | | // this.showHMainSourceBillType = false |
| | | // } |
| | | if (data.hMulSourceFlagField == 0) { |
| | | this.showHSourceBillNo = false |
| | | } |
| | |
| | | this.hform.HMainSourceBillType = data.hSourceBillTypeField |
| | | this.showHMainSourceBillType = false |
| | | } |
| | | // if (data.hSourceBillTypeField == "1103") { |
| | | // this.HMainSourceBillType = '收料通知单' |
| | | // this.hform.HMainSourceBillType = 1103 |
| | | // this.showHMainSourceBillType = false |
| | | // } else if (data.hSourceBillTypeField == "1102") { |
| | | // this.HMainSourceBillType = '采购订单' |
| | | // this.hform.HMainSourceBillType = 1102 |
| | | // this.showHMainSourceBillType = false |
| | | // } else { |
| | | // this.HMainSourceBillType = '手工录入' |
| | | // this.hform.HMainSourceBillType = -1 |
| | | // this.showHMainSourceBillType = false |
| | | // } |
| | | if (data.hMulSourceFlagField == 0) { |
| | | this.showHSourceBillNo = false |
| | | } |
| | |
| | | }) |
| | | |
| | | } |
| | | |
| | | |
| | | // uni.request({ |
| | | // url: this.serverUrl + '/WEBSController/get_BarCode_MoveStock_New_Json', |
| | | // data: { |
| | | // sBarCode: sBarCode, |
| | | // HInterID: this.hform.HInterID, |
| | | // HBillType: this.hform.HBillType, |
| | | // HBillNo: this.hform.HBillNo, |
| | | // HMaker: this.hform.HMaker, |
| | | // HWhID: sHWHID, |
| | | // HSPID: sHSPID, |
| | | // HSCWHID: sHSCWHID, |
| | | // HSCSPID: sHOUTSPID, |
| | | // HQty: sHQty, |
| | | // // HRedBlueFlag: this.hform.HRedBlueFlag, |
| | | // SourceFlag: HSourceFlag, |
| | | // HSourceBillNo: sSourceBillNo, |
| | | // HSourceBillType: sSourceBillType, |
| | | // HStockInOrgID: this.hform.HStockOrgID, |
| | | // HStockOutOrgID: this.hform.HStockOutOrgID, |
| | | // HScanStyle: "", |
| | | // HCustom1: "", |
| | | // HCustom2: "" |
| | | // }, |
| | | // success: (res) => { |
| | | // console.log('扫码返回', res.data); |
| | | // this.hform.HBarCode = '' |
| | | // if (res.data.count == 1) { |
| | | // this.playSound(1) |
| | | // var data = res.data.data |
| | | // if (data.hBarTypeField == '仓库条码') { |
| | | // this.hform.HWHName = data.hWhNameField |
| | | // this.hform.HWHID = data.hWhIDField |
| | | // this.hform.HStockPlaceName = '' |
| | | // this.hform.HStockPlaceID = 0 |
| | | // if (data.hSPFlagField == 0) { |
| | | // this.showHStockPlaceName = false |
| | | // } else { |
| | | // this.showHStockPlaceName = true |
| | | // } |
| | | // } else if (data.hBarTypeField == '仓位条码') { |
| | | // this.hform.HWHName = data.hWhNameField |
| | | // this.hform.HWHID = data.hWhIDField |
| | | // this.hform.HStockPlaceName = data.hSPNameField |
| | | // this.hform.HStockPlaceID = data.hSPIDField |
| | | // } else if (data.hBarTypeField == '部门条码') { |
| | | // this.hform.HDeptName = data.hDeptNameField |
| | | // this.hform.HDeptID = data.hDeptIDField |
| | | // this.tabs = 1 |
| | | // } else if (data.hBarTypeField == '源单条码') { |
| | | // this.hform.HSupName = data.hSupNameField |
| | | // this.hform.HSupID = data.hSupIDField |
| | | // if (data.hDeptIDField != 0) { |
| | | // this.hform.HDeptID = data.hDeptIDField |
| | | // this.hform.HDeptName = data.hDeptNameField |
| | | // } |
| | | // this.hform.HSourceBillNo = data.hSourceBillNoField |
| | | // //获取源单类型、源单单号 |
| | | // this.hform.HMainSourceBillType = data.hSourceBillTypeField |
| | | // |
| | | // let index = this.arrayHMainSourceBillValue.findIndex(e => e == data |
| | | // .hSourceBillTypeField) |
| | | // if (index != -1) { |
| | | // this.HMainSourceBillType = this.arrayHMainSourceBillType[index] |
| | | // this.hform.HMainSourceBillType = data.hSourceBillTypeField |
| | | // this.showHMainSourceBillType = false |
| | | // } |
| | | // // if (data.hSourceBillTypeField == "1402") { |
| | | // // this.HMainSourceBillType = '发货通知单' |
| | | // // this.hform.HMainSourceBillType = 1402 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "1243") { |
| | | // // this.HMainSourceBillType = '调拨申请单' |
| | | // // this.hform.HMainSourceBillType = 1243 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "1214") { |
| | | // // this.HMainSourceBillType = '生产发料通知单' |
| | | // // this.hform.HMainSourceBillType = 1214 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "3720") { |
| | | // // this.HMainSourceBillType = '生产用料清单' |
| | | // // this.hform.HMainSourceBillType = 3720 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "1604") { |
| | | // // this.HMainSourceBillType = '委外用料清单' |
| | | // // this.hform.HMainSourceBillType = 1604 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "1214") { |
| | | // // this.HMainSourceBillType = '生产发料通知单' |
| | | // // this.hform.HMainSourceBillType = 1214 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "3721") { |
| | | // // this.HMainSourceBillType = '生产备料单' |
| | | // // this.hform.HMainSourceBillType = 3721 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "1242") { |
| | | // // this.HMainSourceBillType = '出库申请单' |
| | | // // this.hform.HMainSourceBillType = 1242 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else { |
| | | // // this.HMainSourceBillType = '手工录入' |
| | | // // this.hform.HMainSourceBillType = -1 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } |
| | | // if (data.hMulSourceFlagField == 0) { |
| | | // this.showHSourceBillNo = false |
| | | // } |
| | | // //客户不可编辑 |
| | | // this.showHSupName = false |
| | | // this.tabs = 2 |
| | | // } else { //物料条码 |
| | | // this.tabs = 2 |
| | | // if (!this.hform.HSourceBillNo) { |
| | | // this.hform.HSupName = data.hSupNameField |
| | | // this.hform.HSupID = data.hSupIDField |
| | | // this.hform.HSourceBillNo = data.hSourceBillNoField |
| | | // if (data.hDeptIDField != 0) { |
| | | // this.hform.HDeptID = data.hDeptIDField |
| | | // this.hform.HDeptName = data.hDeptNameField |
| | | // } |
| | | // console.log(data) |
| | | // //获取源单类型、源单单号 |
| | | // this.hform.HMainSourceBillType = data.hSourceBillTypeField || -1 |
| | | // |
| | | // let index = this.arrayHMainSourceBillValue.findIndex(e => e == |
| | | // data |
| | | // .hSourceBillTypeField) |
| | | // if (index != -1) { |
| | | // this.HMainSourceBillType = this.arrayHMainSourceBillType[ |
| | | // index] |
| | | // this.hform.HMainSourceBillType = data.hSourceBillTypeField |
| | | // this.showHMainSourceBillType = false |
| | | // } |
| | | // // if (data.hSourceBillTypeField == "1103") { |
| | | // // this.HMainSourceBillType = '收料通知单' |
| | | // // this.hform.HMainSourceBillType = 1103 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else if (data.hSourceBillTypeField == "1102") { |
| | | // // this.HMainSourceBillType = '采购订单' |
| | | // // this.hform.HMainSourceBillType = 1102 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } else { |
| | | // // this.HMainSourceBillType = '手工录入' |
| | | // // this.hform.HMainSourceBillType = -1 |
| | | // // this.showHMainSourceBillType = false |
| | | // // } |
| | | // if (data.hMulSourceFlagField == 0) { |
| | | // this.showHSourceBillNo = false |
| | | // } |
| | | // //供应商不可编辑 |
| | | // this.showHSupName = false |
| | | // } |
| | | // } |
| | | // //显示表体明细 |
| | | // this.DisBillEntryList() |
| | | // //清空数量 |
| | | // this.hform.HQty = '' |
| | | // //光标对准 |
| | | // this.barCodeFocus = false |
| | | // this.$nextTick(() => { |
| | | // this.barCodeFocus = true |
| | | // this.hform.HBarCode = "" |
| | | // }) |
| | | // } else { |
| | | // this.playSound(0) |
| | | // uni.showToast({ |
| | | // title: res.data.Message, |
| | | // icon: 'none' |
| | | // }) |
| | | // this.barCodeFocus = false |
| | | // this.$nextTick(() => { |
| | | // this.barCodeFocus = true |
| | | // this.hform.HBarCode = "" |
| | | // }) |
| | | // } |
| | | // }, |
| | | // fail: (res) => { |
| | | // this.playSound(0) |
| | | // this.barCodeFocus = true |
| | | // console.log(res); |
| | | // uni.showToast({ |
| | | // title: '接口请求失败', |
| | | // icon: 'none' |
| | | // }) |
| | | // this.barCodeFocus = false |
| | | // this.$nextTick(() => { |
| | | // this.barCodeFocus = true |
| | | // this.hform.HBarCode = "" |
| | | // }) |
| | | // }, |
| | | // }); |
| | | } |
| | | }, |
| | | //物料信息 |
| | |
| | | this.hform.HMainSourceBillType = data.HSourceBillType |
| | | this.hform.HSourceBillNo = data.HSourceBillNo |
| | | |
| | | |
| | | let index = this.arrayHMainSourceBillValue.findIndex(e => e == data |
| | | .HSourceBillType) |
| | | if (index != -1) { |
| | | this.HMainSourceBillType = this.arrayHMainSourceBillType[index] |
| | | this.hform.HMainSourceBillType = data.HSourceBillType |
| | | if (this.HMainSourceBillType != -1) { |
| | | this.HMainSourceBillTypeChange({detail: {value: this.arrayHMainSourceBillType[index]}}) |
| | | if (index != -1) { |
| | | this.showHSupName = false |
| | | } |
| | | } |
| | | // if (data.HSourceBillType == 1402) { |
| | | // this.hform.HMainSourceBillType = 1402 |
| | | // this.HMainSourceBillType = '发货通知单' |
| | | // this.showHSupName = false |
| | | // } else if (data.HSourceBillType == 1243) { |
| | | // this.hform.HMainSourceBillType = 1243 |
| | | // this.HMainSourceBillType = '调拨申请单' |
| | | // this.showHSupName = false |
| | | // } else if (data.HSourceBillType == 3720) { |
| | | // this.hform.HMainSourceBillType = 3720 |
| | | // this.HMainSourceBillType = '生产用料清单' |
| | | // this.showHSupName = false |
| | | // } else if (data.HSourceBillType == 1604) { |
| | | // this.hform.HMainSourceBillType = 1604 |
| | | // this.HMainSourceBillType = '委外用料清单' |
| | | // this.showHSupName = false |
| | | // } else if (data.HSourceBillType == 1214) { |
| | | // this.hform.HMainSourceBillType = 1214 |
| | | // this.HMainSourceBillType = '生产发料通知单' |
| | | // this.showHSupName = false |
| | | // } else if (data.HSourceBillType == 3721) { |
| | | // this.hform.HMainSourceBillType = 3721 |
| | | // this.HMainSourceBillType = '生产备料单' |
| | | // this.showHSupName = false |
| | | // } else if (data.HSourceBillType == 1242) { |
| | | // this.hform.HMainSourceBillType = 1242 |
| | | // this.HMainSourceBillType = '出库申请单' |
| | | // this.showHSupName = false |
| | | // } else { |
| | | // this.hform.HMainSourceBillType = -1 |
| | | // this.HMainSourceBillType = '手工录入' |
| | | // } |
| | | this.showHMainSourceBillType = false |
| | | |
| | | //非多源单模式 |