| | |
| | | params: { 'HInterID': rowHmainid } |
| | | }).then(response => { |
| | | if (response.data.count == 1) { |
| | | var result = response.data |
| | | var data = response.data.data[0] |
| | | this.form.BillType = data.HSourceBillType |
| | | var data = response.data.data[0][0] |
| | | if (this.copyType == 1) { |
| | | this.getHBillNo() |
| | | } |
| | |
| | | // this.form.HMangerName= data.主管 |
| | | // this.form.HInnerBillNo= data.内部单据号 |
| | | |
| | | // //子表 赋值 |
| | | // for (var i = 0; i < result.data.length; i++) { |
| | | // // const data = result.data[i]; |
| | | // // this.editData.push(result.data[i]) |
| | | // } |
| | | //子表 赋值 |
| | | var result = response.data.data[1] |
| | | for (var i = 0; i < result.length; i++) { |
| | | const data = result[i] |
| | | this.editData.push( |
| | | { |
| | | HSourceBillNo: data.HSourceBillNo |
| | | , HSourceBillType: data.HSourceBillType |
| | | , HSourceInterID: data.HSourceInterID |
| | | , HSourceEntryID: data.HSourceEntryID |
| | | , HMaterID:data.HMaterID |
| | | , 物料代码: data.物料代码 |
| | | , 物料名称: data.物料名称 |
| | | , 规格型号: data.规格型号 |
| | | , HUnitID: data.HUnitID |
| | | , 计量单位: data.计量单位 |
| | | , HPropertyID:data.HPropertyID |
| | | , 辅助属性:data.辅助属性 |
| | | , HAuxPropID: data.HAuxPropID |
| | | , 物料辅助属性: data.物料辅助属性 |
| | | , HSecUnitRate:data.HSecUnitRate |
| | | , HQtyMust: data.HQtyMust |
| | | , HQty: data.HQty |
| | | , HPieceQty: data.HPieceQty |
| | | , HPrice: data.HPrice |
| | | , HMoney: data.HMoney |
| | | , HWHID: data.HWHID |
| | | , 收料仓库: data.收料仓库 |
| | | , HSPID: data.HSPID |
| | | , 仓位名称: data.仓位名称 |
| | | , HBatchNo:data.HBatchNo |
| | | , HPOOrderInterID: data.HPOOrderInterID |
| | | , HPOOrderEntryID: data.HPOOrderEntryID |
| | | , HPOOrderBillNo: data.HPOOrderBillNo |
| | | , HSeOrderInterID: data.HSeOrderInterID |
| | | , HSeOrderEntryID: data.HSeOrderEntryID |
| | | , HSeOrderBillNo: data.HSeOrderBillNo |
| | | , HRemark: data.HRemark |
| | | } |
| | | ) |
| | | } |
| | | |
| | | if (data.状态 != '创建' && this.copyType != 1) { |
| | | this.$modal.msgError("此条数据不是创建状态,不能修改"); |
| | |
| | | }, |
| | | //#endregion |
| | | |
| | | //#region 根据客户获取客户余额 |
| | | getCustomerBalance(HCusID) { |
| | | axios.get(this.baseURL + '/Xs_CusRatingChangeBill/getCustomerBalance', { |
| | | params: { "HCusID": HCusID, 'CurUserName': sessionStorage["HUserName"] } |
| | | }).then(response => { |
| | | var data = response.data.data[0]; |
| | | this.form.HCusBalance = data.HCusBalance |
| | | this.form.HCreditRating_Now = data.HCreditRating_Now |
| | | this.form.HAvailableBalance = data.HAvailableBalance |
| | | }).catch(error => { |
| | | this.$modal.msgError("接口请求失败!"); |
| | | }); |
| | | }, |
| | | //#endregion |
| | | |
| | | //#region 根据客户带出联系人、联系电话 |
| | | getCustomerByCusID(HCusID) { |
| | | axios.get(this.baseURL + "/Xs_SeOrderBill/getCustomerByCusID", { |
| | |
| | | }, |
| | | //#endregion |
| | | |
| | | //#region 根据主内码与子内码获取源单销售订单数据 |
| | | getPushSourceBillInit(HSourceInterID, HSourceEntryID) { |
| | | axios.get(this.baseURL + '/Xs_SeOrderBill/loadXs_SeOrderBill_Push', { |
| | | params: { |
| | | "HInterID": HSourceInterID |
| | | , "HSubID": HSourceEntryID |
| | | }, |
| | | }).then(response => { |
| | | let result = response.data |
| | | if (result.code == 1) { // 说明验证成功了, |
| | | this.temp = result.data[0]; |
| | | } else { |
| | | this.temp = result.data; |
| | | } |
| | | }).catch(error => { |
| | | this.$modal.msgError("接口请求失败!"); |
| | | }); |
| | | }, |
| | | //#endregion |
| | | //#endregion |
| | | |
| | | } |