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

装箱功能修改

parent c43b1c9e
......@@ -57,6 +57,8 @@ const install = (Vue, vm) => {
sapLgpla: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/search/sch_LGPLA?sap-language=ZH&sap-client=' + client, params),
// 装箱
sapCasePlnr: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/pda_case/pda_case_plnr?sap-language=ZH&sap-client=' + client, params),
// 装箱信息查询
sapCaseInfo: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/pda_case/pda_case_sch?sap-language=ZH&sap-client=' + client, params),
sapCasePlnr2: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/pda_case/pda_case_plnr2?sap-language=ZH&sap-client=' + client, params),
// 待盘点
sapInventory: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/search/sch_inventory?sap-language=ZH&sap-client='+ client, params),
......
<template>
<!-- <view class="bottomBtn" :class="{'btnContent': btnArr.length === 1}"> -->
<view class="bottomBtn">
<view v-for="(item, index) in btnArr" :key="index">
<view v-for="(item, index) in btnArr" :key="index" class="btns">
<u-button class="widthBtn" :class="item.style" :type="item.type" @click='handleClick(item)'>
{{item.text}}
</u-button>
......@@ -30,24 +30,29 @@ export default {
</script>
<style scoped>
.bottomBtn {
width: 100%;
position: fixed;
display: flex;
bottom: 0;
left: 0;
z-index: 10;
width: 750rpx;
height: 140rpx;
justify-content: space-around;
align-items: center;
background: #fff;
.u-btn {
width: 300rpx ;
padding: 0 10rpx;
/* .u-btn {
flex: 1;
} */
.btns {
flex: 1;
margin-right: 10rpx;
}
}
.btnContent{
justify-content: space-around;
}
.widthBtn{
/* .widthBtn{
width: 300rpx ;
}
} */
</style>
\ No newline at end of file
......@@ -230,6 +230,8 @@
}
this.$u.toast(res[0].MESSAGE)
this.goBack()
} else {
this.$u.toast('提交盘点数据未返回成功消息!')
}
})
},
......
<template>
<view class="metering">
<!-- <uni-forms :modelValue="form">
<uni-forms-item label="长" name="long">
<uni-easyinput type="text" v-model="form.long" placeholder="请输入姓名" />
</uni-forms-item>
</uni-forms> -->
<u-row gutter="16" class="itemRow">
<view class="btn">
<uni-easyinput
prefixIcon="search"
class="topSearch"
v-model="blpl"
:disabled="isEdit"
placeholder="请扫描箱码"
@change="handleInputNlpla"
></uni-easyinput>
</view>
<u-row gutter="16" class="itemRow" style="margin-top: 10rpx;">
<u-col span="3">
长(cm):
</u-col>
<u-col span="6">
<uni-easyinput v-model="form.long" @input="updateWeight"></uni-easyinput>
<uni-easyinput v-model="form.LONG" @input="updateWeight"></uni-easyinput>
</u-col>
</u-row>
<u-row gutter="16" class="itemRow">
......@@ -18,7 +23,7 @@
宽(cm):
</u-col>
<u-col span="6">
<uni-easyinput v-model="form.wide" @input="updateWeight"></uni-easyinput>
<uni-easyinput v-model="form.WIDE" @input="updateWeight"></uni-easyinput>
</u-col>
</u-row>
<u-row gutter="16" class="itemRow">
......@@ -26,7 +31,7 @@
高(cm):
</u-col>
<u-col span="6">
<uni-easyinput v-model="form.high" @input="updateWeight"></uni-easyinput>
<uni-easyinput v-model="form.HIGH" @input="updateWeight"></uni-easyinput>
</u-col>
</u-row>
<u-row gutter="16" class="itemRow">
......@@ -34,7 +39,7 @@
毛重(kg):
</u-col>
<u-col span="6">
<uni-easyinput v-model="form.brgew"></uni-easyinput>
<uni-easyinput v-model="form.BRGEW"></uni-easyinput>
</u-col>
</u-row>
<u-row gutter="16" class="itemRow">
......@@ -42,7 +47,7 @@
箱重(kg):
</u-col>
<u-col span="6">
<uni-easyinput v-model="form.zxntgew" @input="updateWeight"></uni-easyinput>
<uni-easyinput v-model="form.ZXNTGEW" @input="updateWeight"></uni-easyinput>
</u-col>
</u-row>
<u-row gutter="16" class="itemRow">
......@@ -58,7 +63,7 @@
装箱备注:
</u-col>
<u-col span="8">
<u-input v-model="form.zxtext" type="textarea" :border="true" height="70" ></u-input>
<u-input v-model="form.ZXTEXT" type="textarea" :border="true" height="70" ></u-input>
</u-col>
</u-row>
<u-row gutter="16" class="itemRow">
......@@ -66,7 +71,7 @@
备注:
</u-col>
<u-col span="8">
<u-input v-model="form.ztext" type="textarea" :border="true" height="70" ></u-input>
<u-input v-model="form.ZTEXT" type="textarea" :border="true" height="70" ></u-input>
</u-col>
</u-row>
......@@ -79,7 +84,7 @@ export default {
},
data() {
return {
blpl: '',
};
},
created() {
......@@ -90,14 +95,41 @@ export default {
default: function () {
return {};
}
},
isEdit: {
type: Boolean,
default: false
},
isBL: {
type: Boolean,
default: false
}
},
watch: {
form: {
handler(nv) {
if (this.isBL) {
this.blpl = nv.ZCODE
} else {
this.blpl = nv.PLNR
}
},
deep:true
}
},
computed:{
weight(){
return (this.form.brgew-0) - (this.form.zxntgew-0)
return (this.form.BRGEW-0) - (this.form.ZXNTGEW-0)
}
},
methods: {
handleInputNlpla(e) {
console.log(e, 'handleInputNlpla');
this.$emit('plinput', e)
},
setWeightEdit() {
},
updateWeight(e) {
console.log(e, '----')
const reg = /^\d+\*\d+\*\d+\-\d+(\.\d+)+$/
......@@ -106,11 +138,11 @@ export default {
console.log('扫码11111');
const arr = e.split('*')
setTimeout(() => {
this.form.long = arr[0]
this.form.wide = arr[1]
this.form.LONG = arr[0]
this.form.WIDE = arr[1]
const data = arr[2].split('-')
this.form.high = data[0]
this.form.zxntgew = data[1]
this.form.HIGH = data[0]
this.form.ZXNTGEW = data[1]
}, 500)
}
}
......
const mockData = {
bls: [
{
"ZCODE": "BL24070000041",
"PLNR": "10000820240402000001|10000320004",
"WERKS": "1000",
"KUNNR": "",
"ZZXFS": "BL+PL",
"ZSTATUS": "N",
"ZXSPE": "56*41*32",
"ZXVOLUM": 0.073,
"ZXNTGEW": 1.250,
"NTGEW": 20.750,
"BRGEW": 22.000,
"ZXTEXT": "",
"ZTEXT": "",
"ZIFSHMARK": "Y",
"VBELN": "",
"UNAME": "TS-LIUQI",
"DATUM": "20240709",
"UZEIT": "084744",
"MNAME": "",
"MDATE": "00000000",
"MTIME": "000000",
"AUNAME": "",
"AUDATE": "00000000",
"AUTIME": "000000"
},
{
"ZCODE": "BL24070000041",
"PLNR": "10000820240402000003|10000320003",
"WERKS": "1000",
"KUNNR": "",
"ZZXFS": "BL+PL",
"ZSTATUS": "N",
"ZXSPE": "56*41*32",
"ZXVOLUM": 0.073,
"ZXNTGEW": 1.250,
"NTGEW": 20.750,
"BRGEW": 22.000,
"ZXTEXT": "",
"ZTEXT": "",
"ZIFSHMARK": "Y",
"VBELN": "",
"UNAME": "TS-LIUQI",
"DATUM": "20240709",
"UZEIT": "084744",
"MNAME": "",
"MDATE": "00000000",
"MTIME": "000000",
"AUNAME": "",
"AUDATE": "00000000",
"AUTIME": "000000"
},
{
"ZCODE": "BL24060000034",
"PLNR": "PL16",
"WERKS": "1000",
"KUNNR": "0000600009",
"ZZXFS": "BL+PL",
"ZSTATUS": "N",
"ZXSPE": "10*10*10",
"ZXVOLUM": 0.001,
"ZXNTGEW": 1.000,
"NTGEW": 10.000,
"BRGEW": 11.000,
"ZXTEXT": "123",
"ZTEXT": "321",
"ZIFSHMARK": "Y",
"VBELN": "",
"UNAME": "admin",
"DATUM": "20240621",
"UZEIT": "195225",
"MNAME": "CHENWL",
"MDATE": "20240708",
"MTIME": "174601",
"AUNAME": "",
"AUDATE": "00000000",
"AUTIME": "000000"
},
{
"ZCODE": "BL24060000034",
"PLNR": "PL17",
"WERKS": "1000",
"KUNNR": "0000600009",
"ZZXFS": "BL+PL",
"ZSTATUS": "N",
"ZXSPE": "10*10*10",
"ZXVOLUM": 0.001,
"ZXNTGEW": 1.000,
"NTGEW": 10.000,
"BRGEW": 11.000,
"ZXTEXT": "123",
"ZTEXT": "321",
"ZIFSHMARK": "Y",
"VBELN": "",
"UNAME": "admin",
"DATUM": "20240621",
"UZEIT": "195225",
"MNAME": "CHENWL",
"MDATE": "20240708",
"MTIME": "174601",
"AUNAME": "",
"AUDATE": "00000000",
"AUTIME": "000000"
}
],
pls: [
{
"ZCODE": "BL24070000085",
"PLNR": "PL0006000400001000000455021",
"WERKS": "1000",
"KUNNR": "0000600247",
"ZZXFS": "PL",
"ZSTATUS": "N",
"ZXSPE": "56*41*32",
"ZXVOLUM": 0.073,
"ZXNTGEW": 1.250,
"NTGEW": 48.750,
"BRGEW": 50.000,
"ZXTEXT": "",
"ZTEXT": "",
"ZIFSHMARK": "Y",
"VBELN": "",
"UNAME": "admin",
"DATUM": "20240709",
"UZEIT": "162212",
"MNAME": "TS-LIUQI",
"MDATE": "20240726",
"MTIME": "154440",
"AUNAME": "",
"AUDATE": "00000000",
"AUTIME": "000000"
},
{
"ZCODE": "BL24070000072",
"PLNR": "10000001240424000004|10000000002",
"WERKS": "1000",
"KUNNR": "0000600005",
"ZZXFS": "PL",
"ZSTATUS": "N",
"ZXSPE": "56*41*32",
"ZXVOLUM": 0.073,
"ZXNTGEW": 1.250,
"NTGEW": 20.750,
"BRGEW": 22.000,
"ZXTEXT": "",
"ZTEXT": "",
"ZIFSHMARK": "Y",
"VBELN": "",
"UNAME": "TS-LIUQI",
"DATUM": "20240709",
"UZEIT": "084744",
"MNAME": "",
"MDATE": "00000000",
"MTIME": "000000",
"AUNAME": "",
"AUDATE": "00000000",
"AUTIME": "000000"
},
{
"ZCODE": "BL24070000071",
"PLNR": "10000001240424000004|10000000001",
"WERKS": "1000",
"KUNNR": "0000600005",
"ZZXFS": "PL",
"ZSTATUS": "N",
"ZXSPE": "56*41*32",
"ZXVOLUM": 0.073,
"ZXNTGEW": 1.250,
"NTGEW": 20.750,
"BRGEW": 22.000,
"ZXTEXT": "",
"ZTEXT": "",
"ZIFSHMARK": "Y",
"VBELN": "",
"UNAME": "TS-LIUQI",
"DATUM": "20240709",
"UZEIT": "084744",
"MNAME": "",
"MDATE": "00000000",
"MTIME": "000000",
"AUNAME": "",
"AUDATE": "00000000",
"AUTIME": "000000"
}
]
}
/**
* 模拟查询PL和BL
* @param {*} val
* @param {*} type false:PL, true:BL
*/
export const requestMock = (val, type = false) => {
const datas = mockData[type ? 'bls' : 'pls']
return datas.filter(item => {
if (type) {
return item.ZCODE == val
}
return item.PLNR == val
})
}
\ No newline at end of file
This diff is collapsed.
......@@ -6,14 +6,13 @@
<!-- <scanningList :item='item'/> -->
<view class="listItemTitle">
<view>
<view class="item">PL号:{{ list[index] }}</view>
<view class="item">PL号:{{ item.PLNR }}</view>
<!-- <view class="item">物料编号:{{ item.MATNR }}</view>
<view class="item">物料描述:{{ item.MAKTX }}</view>
<view class="item">数量:{{ item.MAKTX }}</view> -->
</view>
<u-button size="mini" type="primary" plain @click="deleGonds(index)">
<u-button v-if="!isEdit" size="mini" type="primary" plain @click="deleGonds(index)">
<u-icon name="trash" size="28"></u-icon>
删除
</u-button>
</view>
</view>
......@@ -43,6 +42,10 @@ export default {
return [];
}
},
isEdit: {
type: Boolean,
default: false
}
},
data() {
return {
......@@ -102,6 +105,7 @@ export default {
});
},
deleGonds(idx) {
console.log(idx, '--0000----');
this.$emit('deleGonds',idx)
},
// 加载更多
......@@ -157,7 +161,7 @@ export default {
padding: 20rpx;
border-bottom: 2px solid #f8f8f8;
.u-btn {
width: 150rpx;
// width: 150rpx;
margin: 0px;
margin-top: 10rpx;
}
......
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