Commit f1be7edb authored by 何远江's avatar 何远江

bug修改

parent 33494f5c
......@@ -66,6 +66,8 @@ const install = (Vue, vm) => {
sapSearchAllot: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/pda_allot/search_allot?sap-language=ZH&sap-client='+ client, params),
// 工厂调拨下架
sapAllot: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/PDA_ALLOT_PD/ALLOT_PD?sap-language=ZH&sap-client='+ client, params),
// 跨工厂工作中心调拨查询
sapSearchArbpl: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/SEARCH_ARBPL/SEARCH_ARBPL?sap-language=ZH&sap-client='+ client, params),
},
mesApi:{
......@@ -82,7 +84,12 @@ const install = (Vue, vm) => {
// 完工入库
pdaFindPackageLinkInfo: (params = {}) => vm.$u.post(config.adminPath + '/apiPda/search/findPackageLinkInfo', params),
// 调拨料回传mes
pdaAllocation: (params = {}) => vm.$u.post(config.adminPath + '/apiPda/allocation/pdaAllocation', params)
pdaAllocation: (params = {}) => vm.$u.post(config.adminPath + '/apiPda/allocation/pdaAllocation', params),
// 工作中心领料查询
pdaWortstation: (params = {}) => vm.$u.get(config.adminPath + '/apiPda/workstationMaterial/pdaWortstation', params),
// 工作中心领料回传mes
pdaworkstationUpadteNum: (params = {}) => vm.$u.post(config.adminPath + '/apiPda/workstationMaterial/pdaworkstationUpadteNum', params),
}
};
......
......@@ -4,7 +4,7 @@
filterable
v-model="warehouseCode"
dataKey="label"
placeholder="请选择仓库别"
placeholder="请选择库存地点"
dataValue="value"
:localdata="warehouseData"
@change="onWarehouseChange"
......
......@@ -103,6 +103,27 @@
"enablePullDownRefresh": false
}
},
{
"path": "pages/workCenter/workCenterList",
"style": {
"navigationBarTitleText": "工作中心发料",
"enablePullDownRefresh": false
}
},
{
"path": "pages/costCenter/costCenter",
"style": {
"navigationBarTitleText": "成本中心发料",
"enablePullDownRefresh": false
}
},
{
"path": "pages/costCenter/costCenterList",
"style": {
"navigationBarTitleText": "成本中心发料",
"enablePullDownRefresh": false
}
},
{
"path": "pages/salesReturns/salesReturns",
"style": {
......
......@@ -8,7 +8,7 @@
</view>
</view>
<view class="btn">
<uni-easyinput prefixIcon="search" :disabled="isDisabled" v-model="wxparams" :focus="isFocus"
<uni-easyinput prefixIcon="search" :disabled="isDisabled" v-model.trim="wxparams" :focus="isFocus"
placeholder="请扫描产品包装条码/外箱码" @input="handleInputPlnr"></uni-easyinput>
</view>
<view class="total">
......@@ -141,7 +141,7 @@
handleInputPlnr(e) {
if (!e) return
if (this.catchPl.length > 0) {
if (!this.catchPl.inculdes(e)) {
if (!this.catchPl.includes(e)) {
this.getPlnr(e);
} else {
this.reset()
......@@ -158,25 +158,25 @@
// 查询相同工厂,相同物料编码的条目,且还未分配满数量的
let goods = this.goodsList.find(v => item.MATNR == v.MATNR && item.WERKS == v.RESWK && v
.total != v.MENGE)
// 如果有满足条件的物料
while (goods != undefined) {
// 需求量
const reqNum = goods.MENGE - (goods.total || 0)
const reqNum = goods.MENGE - (goods.total || 0)
// 如果需求量大于等于剩余量,直接分配
if (reqNum >= remainder) {
goods.details.push({...item, PACMG: remainder})
goods.details.push({...item, PACMG: remainder})
// 累加已经分配的数量
goods.total += remainder
// 终止循环条件
goods.total += remainder
// 终止循环条件
goods = undefined
} else {
// 如果需求量小于剩余量,需要使用拆分
goods.details.push({...item, PACMG: reqNum})
goods.details.push({...item, PACMG: reqNum})
goods.total += reqNum
remainder -= reqNum
// 还有剩余数量,需要继续遍历添加
goods = this.goodsList.find(v => item.MATNR == v.MATNR && item.WERKS == v.RESWK && v
// 还有剩余数量,需要继续遍历添加
goods = this.goodsList.find(v => item.MATNR == v.MATNR && item.WERKS == v.RESWK && v
.total != v.MENGE)
}
}
......@@ -204,6 +204,7 @@
if (res.BLPL.length == 0) {
return this.$u.toast("未查询到该条码信息")
}
this.catchPl.push(plnr)
this.setPL(res.BLPL)
this.reset()
});
......@@ -347,4 +348,4 @@
.checkedCase {
margin-top: 10rpx;
}
</style>
</style>
......@@ -130,6 +130,11 @@
text: '工作中心发料',
url: '/pages/workCenter/workCenter'
},
{
src: require('@/static/images/clycxj.png'),
text: '成本中心发料',
url: '/pages/costCenter/costCenter'
},
]
}]
};
......
......@@ -106,7 +106,7 @@ export default {
data.forEach(ele => {
ele.ERFMG = ele.TOMNG
// 添加仓库别
ele.NLBER = this.warehouseCode
ele.UMLGO = this.warehouseCode
});
this.$u.api.sapApi
.sapRrm([
......
......@@ -160,7 +160,7 @@ export default {
return;
}
let arr = this.list.filter(ele=>ele.quantityIssued)
// "windCase": null,是否结案 Y是 N否
// "windCase": null,是否结案 Y是 N否
arr.forEach((ele,index) => {
ele.windCase = this.checkedBox ? 'Y': 'N'
ele.AUFNR = ele.workorderCode
......@@ -170,7 +170,7 @@ export default {
ele.RSNUM = ele.requirementNumber || '10'
ele.RSPOS = ele.requirementProjectNumber || '2'
// 添加仓库别
ele.NLBER = this.warehouseCode
ele.UMLGO = this.warehouseCode
})
const params = {
'zencode': 'A009',
......
......@@ -4,7 +4,7 @@
<NavBar title="采购入库扫描"></NavBar>
<FactorySelect v-model="warehouseCode" @change="warehouseChange" />
<view class="btn">
<uni-easyinput v-if="vuex_user_factory !== '1010'" prefixIcon="search" class="topSearch" v-model="nlpla" focus placeholder="请扫描位" @change="handleInputNlpla"></uni-easyinput>
<uni-easyinput v-if="vuex_user_factory !== '1010'" prefixIcon="search" class="topSearch" v-model="nlpla" focus placeholder="请扫描位" @change="handleInputNlpla"></uni-easyinput>
<uni-easyinput
prefixIcon="search"
:disabled="isDisabled"
......@@ -105,6 +105,7 @@ export default {
uni.navigateBack();
},
goSubmit() {
// 根据不同工厂,不同选择
if (this.goodsList.length === 0) {
return;
}
......@@ -113,7 +114,7 @@ export default {
ele.ERFMG = ele.TOMNG
ele.ERFME = ele.MEINS
// 添加仓库别
ele.NLBER = this.warehouseCode
ele.UMLGO = this.warehouseCode
});
this.$u.api.sapApi
.sapRrm([
......
......@@ -6,7 +6,7 @@
<view class="items">交货单号:{{ vbeln }}</view>
<view class="items">{{saleInfo.KUNNR}} | {{ saleInfo.NAME1 }}</view>
<view class="items">计划日期:{{ saleInfo.WADAT }}</view>
<view class="items">装箱数:{{ catchPL && catchPL.length || 0 }} / {{ Number(saleInfo.XSNUM) }}</view>
<view class="items">装箱数:{{ plslen }} / {{ Number(saleInfo.XSNUM) }}</view>
</view>
<view class="">
<view class="btn">
......@@ -100,6 +100,11 @@
catchPL() {
return this.vuex_sales_outbound[this.vbeln] || null
},
plslen() {
return this.goodsList.reduce((acc,cur) => {
return acc + (cur.ZPLDT?.length || 0)
},0)
},
saleInfo() {
return this.goodsList[0] || {}
}
......@@ -245,7 +250,7 @@
getPlnr(plnr) {
let params = {
ZCODE: plnr.includes("BL") ? plnr : "",
plnr: plnr.includes("BL") ? "" : plnr,
plnr: plnr.includes("BL") ? "" : plnr,
ztype: '005'
};
this.$u.api.sapApi.sapBlpl(params).then((res) => {
......
......@@ -138,7 +138,7 @@ export default {
ITEM: this.goodsList.map(item => {
return {
...item,
NLBER: this.warehouseCode // 添加仓库别
UMLGO: this.warehouseCode // 添加仓库别
}
})
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment