Commit 7132b2f8 authored by 沈翠玲's avatar 沈翠玲

换标接口对接

parent b780621d
......@@ -49,10 +49,14 @@ const install = (Vue, vm) => {
sapSchDn: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/search/sch_dn?sap-language=ZH&sap-client=' + client, params),
// 销售拣货单
sapPickingDn: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/picking_dn?sap-language=ZH&sap-client=' + client, params),
// 换标
sapMigoCS: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/pda_migo_cs?sap-client=' + client, params),
// 销售拣货过账
sapDelv: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/post_delv?sap-language=ZH&sap-client=' + client, params),
// 销售拣货查询bl pl
sapBlpl: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/search/sch_BLPL?sap-language=ZH&sap-client=' + client, params),
// 换标查询
sapSchblpl: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/search/sch_blpl?sap-client=' + client, params),
// 查询仓位
sapLgpla: (params = {}, client = sapClient) => vm.$u.post(config.adminPath + '/sap/bc/erp_ep/search/sch_LGPLA?sap-language=ZH&sap-client=' + client, params),
// 装箱
......
......@@ -137,7 +137,7 @@
},
{
src: require('@/static/images/xsjh.png'),
text: '换',
text: '换',
url: '/pages/salesOutbound/exchangeGoods'
},
]
......
<template>
<view>
<StickyNavBar>
<NavBar title="换"></NavBar>
<NavBar title="换"></NavBar>
<view class="btn">
<uni-easyinput
prefixIcon="search"
......@@ -22,7 +22,7 @@
摄像头对准
</view>
<view class="cardBoxTip3">
单号二维码
单号二维码
</view>
<view class="cardBoxTip2">
<text class="tipLeft">
......
<template>
<view class="lists page">
<StickyNavBar class="listTitle">
<NavBar title="换"></NavBar>
<NavBar title="换"></NavBar>
<view class="headerTitle">
<view class="items">交货单号:{{ vbeln }}</view>
<view class="items">{{ saleInfo.KUNNR }} | {{ saleInfo.NAME1 }}</view>
......@@ -106,7 +106,11 @@ export default {
},
computed: {
totalNum() {
const count = this.goodsList.filter((item) => item.checkedBox).length;
const count = this.goodsList.filter((ele) => {
return (
ele.sumNum == ele?.ZPLDT?.reduce((acc, cur) => acc + cur.PACMG, 0)
);
}).length;
return count || 0;
},
/**
......@@ -138,6 +142,8 @@ export default {
return this.$u.toast("当前单据已经提交成功!无需继续提交!");
}
const flag = this.goodsList.every((ele) => {
console.log('ele.sumNum', ele.sumNum, ele?.ZPLDT?.reduce((acc, cur) => acc + cur.PACMG, 0))
return (
ele.sumNum == ele?.ZPLDT?.reduce((acc, cur) => acc + cur.PACMG, 0)
);
......@@ -165,7 +171,7 @@ export default {
// return
this.$u.api.sapApi.sapPickingDn(params).then((res) => {
this.$u.api.sapApi.sapMigoCS(params).then((res) => {
this.loading = false;
if (!Array.isArray(res)) {
return;
......@@ -263,6 +269,7 @@ export default {
const item = this.goodsList.find(
(v) => v.ZSIZE == ele.ZSIZE && ele.MATNR == v.MATNR
);
console.log('itemitem', item)
ele.POSNR = item.POSNR
if (item) {
if (Reflect.has(item, "ZPLDT")) {
......@@ -277,10 +284,10 @@ export default {
const isBL = plnr.startsWith("B");
let params = {
ZCODE: isBL ? plnr : "",
plnr: isBL ? "" : plnr,
PLNR: isBL ? "" : plnr,
ztype: "005",
};
this.$u.api.sapApi.sapBlpl(params).then((res) => {
this.$u.api.sapApi.sapSchblpl(params).then((res) => {
if (res && res.MSG[0].TYPE === "S") {
this.setSalesBoundPL(res.BLPL);
} else {
......
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