| | |
| | | <text>剩余可出库数量:</text>{{item['数量'] - item['已关联数量']}} |
| | | </view> |
| | | </view> |
| | | <view class="more" v-if="operations != index"> |
| | | <!-- <view class="more" v-if="operations != index"> |
| | | <view class="part" @tap.stop="operations = operations==index?-1:index"> |
| | | <uni-icons type="more-filled" style="color: #888;margin-right: 10rpx;" |
| | | size="14"></uni-icons>操作 |
| | | </view> |
| | | </view> |
| | | </view> --> |
| | | |
| | | <view class="op" v-if="operations == index"> |
| | | <!-- <view class="op" v-if="operations == index"> |
| | | <input class="input1" type="number" v-model="SeOutNumber" /> |
| | | <button class="op3" size="mini" plain @tap.stop="submit(item)">出库</button> |
| | | <button class="op5" size="mini" plain |
| | | @tap.stop="operations = -1,this.SeOutNumber = 0">取消操作</button> |
| | | </view> |
| | | @tap.stop="operations = -1,SeOutNumber = 0">取消操作</button> |
| | | </view> --> |
| | | </uni-card> |
| | | </view> |
| | | </view> |
| | |
| | | MpaasScan |
| | | } from '@/utils/mpaasScan.js' |
| | | export default { |
| | | |
| | | data() { |
| | | return { |
| | | operations: -1, |
| | |
| | | arrayHStockPlaceName: [], |
| | | HIsStockMgr: false, |
| | | scrollTop: 0, |
| | | HBarCode: '101.2100233250718000007', |
| | | HBarCode: '', |
| | | HMaterialID: '', |
| | | HBillNo: '', |
| | | HCustomer: '', |
| | |
| | | HBillSubType: 1205, |
| | | HDate: getDateTime.dateTimeStr('y-m-d'), |
| | | BillType: 1402, |
| | | HBillerID: uni.getStorageSync('HBillerID'), |
| | | HRedBlueFlag: false, |
| | | |
| | | |
| | | // 通过item赋值 |
| | |
| | | }] |
| | | } |
| | | }, |
| | | props: { |
| | | HBillType: { |
| | | type: [String, Number], |
| | | required: true |
| | | }, |
| | | HSourceBillType: { |
| | | type: [String, Number], |
| | | required: true |
| | | }, |
| | | HStockOrgID: { |
| | | type: [String, Number], |
| | | required: true |
| | | }, |
| | | }, |
| | | methods: { |
| | | popupChangeHandler(e) { |
| | | if (e.show === true) { |
| | | this.getBillList() |
| | | } else { |
| | | // 清理资源 |
| | | this.size = 20 |
| | | this.curPage = 1 |
| | | this.length = 0 |
| | | this.page = 0 |
| | | this.HSourceBillNo = '' |
| | | this.HMater = '' |
| | | this.HCustom = '' |
| | | this.HBillList = [] |
| | | } |
| | | }, |
| | | exit() { |
| | | this.$refs.popup.close(); |
| | | }, |
| | | search() { |
| | | this.getBillList() |
| | | }, |
| | | showPopup() { |
| | | this.$refs.popup.open(); |
| | | }, |
| | | clickCard(interid, billno) { |
| | | uni.$emit('BillSelectComplete', { |
| | | HInterID: interid, |
| | | HBillNo: billno |
| | | }) |
| | | // this.exit() |
| | | }, |
| | | clearPage() { |
| | | this.HMaterialID= '' |
| | | this.HBillNo= '' |
| | | this.HCustomer= '' |
| | | this.HSeller= '' |
| | | this.SeOutNumber= 0 |
| | | this.operations= -1 |
| | | this.HMaterialID = '' |
| | | this.HBillNo = '' |
| | | this.HCustomer = '' |
| | | this.HSeller = '' |
| | | this.SeOutNumber = 0 |
| | | this.operations = -1 |
| | | }, |
| | | toScanCode() { |
| | | var mpaasScanModule = uni.requireNativePlugin("Mpaas-Scan-Module") |
| | |
| | | console.log('barCodeMeta: ', barCodeMeta); |
| | | this.HMaterialID = barCodeMeta[0]['HMaterID'] |
| | | this.getMater() |
| | | console.log('执行: getMater') |
| | | this.cmdSearch() |
| | | } catch (err) { |
| | | return |
| | |
| | | HBillNo, |
| | | HInterID |
| | | } = MaxNum[0] |
| | | |
| | | |
| | | this.hform.HBillNo = HBillNo |
| | | this.hform.HInterID = HInterID |
| | | this.hform.HSourceBillNo = item['单据号'] |
| | | this.hform.HSourceBillType = item['HBillType'] |
| | | this.hform.HMainSourceBillNo = item['单据号'] |
| | | this.hform.HMainSourceBillType = item['HBillType'] |
| | | this.hform.HMainSourceInterID = item['hmainid'] |
| | | this.hform.HMainSourceEntryID = item['hsubid'] |
| | | this.hform.HEmpName = item['业务员'] |
| | |
| | | this.hform.HDeptID = item['HDeptID'] |
| | | this.hform.HDeptName = item['部门'] |
| | | this.hform.HSupName = item['客户'] |
| | | this.hform.HSupID = item['HSupID'] |
| | | this.hform.HSupID = item['HCusID'] |
| | | this.hform.HLinkMan = item['HLinkMan'] |
| | | this.hform.HLinkPhone = item['联系电话'] |
| | | this.hform.HManagerID = item['HManagerID'] |
| | |
| | | this.hform.HExRate = Number(item['汇率']) |
| | | this.hform.HSellSID = '0' |
| | | this.hform.HSellSName = item['销售方式'] |
| | | let HQty = this.SeOutNumber; |
| | | this.hform.HChecker = getUserInfo()["Czymc"] |
| | | let HQty = this.SeOutNumber; |
| | | let HPrice = item['单价']; //单价 |
| | | let HMoney = HQty * HPrice; |
| | | console.log(this.materMeta) |
| | | console.log("materMeta", this.materMeta) |
| | | this.subform[0] = { |
| | | 'HMaterID': this.materMeta['HItemID'], |
| | | "物料代码": this.materMeta['物料代码'], |
| | |
| | | } |
| | | await this.$nextTick() |
| | | |
| | | |
| | | |
| | | let sMainStr = JSON.stringify(this.hform) |
| | | let sSubStr = JSON.stringify(this.subform) |
| | | let sMainSub = sMainStr + ';' + sSubStr + ';' + getUserInfo()["Czymc"] + ';' + 1; |
| | | let sMainSub = sMainStr + ';' + sSubStr + ';' + getUserInfo()["Czymc"] + ';' + 1; |
| | | |
| | | CommonUtils.doRequest2({ |
| | | method: 'POST', |
| | |
| | | data: { |
| | | msg: sMainSub |
| | | }, |
| | | resFunction: (res) => { |
| | | resFunction: async (res) => { |
| | | let { |
| | | count, |
| | | Message |
| | | } = res.data |
| | | if (count = 1) { |
| | | uni.showModal({ |
| | | title: '提交成功', |
| | | content: '是否继续出库?', |
| | | success: (res) => { |
| | | if (res.confirm) { |
| | | this.clearPage() |
| | | this.getCode() |
| | | } else if (res.cancel) { |
| | | uni.navigateBack() |
| | | } |
| | | } |
| | | }); |
| | | }else { |
| | | if (count == 1) { |
| | | await this.set_CheckBill() |
| | | } else { |
| | | uni.showToast({ |
| | | icon: 'none', |
| | | title: Message |
| | | }) |
| | | } |
| | | |
| | | |
| | | } |
| | | }) |
| | | |
| | |
| | | errFunction: () => { |
| | | reject() |
| | | } |
| | | }) |
| | | }) |
| | | }, |
| | | set_CheckBill() { |
| | | return new Promise((resolve, reject) => { |
| | | CommonUtils.doRequest2({ |
| | | url: "/Kf_SellOutBill/AuditKf_SellOutBill", |
| | | data: { |
| | | "HInterID": this.hform.HInterID, |
| | | "IsAudit": 0, |
| | | "CurUserName": getUserInfo()['Czymc'] |
| | | }, |
| | | resFunction: (res) => { |
| | | let { |
| | | count, |
| | | Message, |
| | | data |
| | | } = res.data |
| | | if (count == 1) { |
| | | uni.showModal({ |
| | | title: '提交成功', |
| | | content: '是否继续出库?', |
| | | success: (res) => { |
| | | if (res.confirm) { |
| | | this.clearPage() |
| | | this.getCode() |
| | | } else if (res.cancel) { |
| | | uni.navigateBack() |
| | | } |
| | | } |
| | | }); |
| | | } else { |
| | | uni.showToast({ |
| | | icon: 'none', |
| | | title: '提交成功,自动审核失败,请手动审核' |
| | | }) |
| | | } |
| | | }, |
| | | }) |
| | | }) |
| | | }, |
| | |
| | | sWhere: ` and 1 = 1 and HItemID = ${this.HMaterialID}`, |
| | | user: getUserInfo()['Czymc'], |
| | | // Organization: uni.getStorageSync('Organization'), |
| | | Organization: '', |
| | | Organization: uni.getStorageSync('Organization'), |
| | | page: 1, |
| | | size: 50, |
| | | }, |
| | |
| | | Message, |
| | | data |
| | | } = res.data |
| | | if (count > 0) { |
| | | if (count == 1) { |
| | | this.materMeta = data[0] |
| | | |
| | | |
| | | this.$forceUpdate() |
| | | } else { |
| | | uni.showToast({ |
| | |
| | | <style lang="scss" scoped> |
| | | .page { |
| | | /* #ifdef APP */ |
| | | height: calc(100vh); |
| | | height: calc(80vh); |
| | | /* #endif */ |
| | | /* #ifndef APP */ |
| | | height: calc(100vh - 44px); |
| | | height: calc(80vh - 44px); |
| | | /* #endif */ |
| | | box-sizing: border-box; |
| | | padding: 20rpx 10rpx; |