Hdsmesin-46 feat SO手持页面增加
parent
3f91338b2c
commit
9ededbe1e9
@ -0,0 +1,110 @@
|
||||
<template>
|
||||
<view class="page-so">
|
||||
<view class="header">
|
||||
<view class="left">
|
||||
<u-icon class="icon" name="arrow-left" @click="uni.navigateBack()" />
|
||||
</view>
|
||||
<view class="title">{{ $t('message.so') }}</view>
|
||||
<view class="right"></view>
|
||||
</view>
|
||||
<view class="container">
|
||||
<u-row :gutter="30">
|
||||
<u-col :span="12" v-for="(item, index) in childData" :key="index">
|
||||
<u-button
|
||||
@click.native="
|
||||
uni.navigateTo({
|
||||
url: item.href,
|
||||
})
|
||||
"
|
||||
>
|
||||
<u-icon size="80" :name="item.iconClass"></u-icon>
|
||||
<text class="name"> {{ index + 1 + ' ' + $t('message.' + item.engResourceName) }}</text>
|
||||
</u-button>
|
||||
</u-col>
|
||||
</u-row>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import { Component } from 'vue-property-decorator';
|
||||
import { BasePage } from '@/components/base/page';
|
||||
@Component
|
||||
export default class So extends BasePage {
|
||||
childData: any;
|
||||
onLoad(option: { childData: any }) {
|
||||
this.childData = JSON.parse(option.childData);
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.page-so {
|
||||
background-color: #f4f7fc;
|
||||
padding-top: 88rpx;
|
||||
min-height: 100%;
|
||||
|
||||
.header {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
padding-top: 18px;
|
||||
left: 0;
|
||||
right: 0;
|
||||
z-index: 99;
|
||||
display: -webkit-box;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
background-color: #255cea;
|
||||
/* height: 46px; */
|
||||
line-height: 46px;
|
||||
color: #fff;
|
||||
font-size: 17px;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
box-shadow: 0 1px 2px #6b90ef;
|
||||
.title {
|
||||
flex: 3;
|
||||
}
|
||||
.left,
|
||||
.right {
|
||||
flex: 1;
|
||||
}
|
||||
.icon {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 88rpx;
|
||||
height: 88rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.container {
|
||||
margin-top: 36rpx;
|
||||
padding: 30rpx 15rpx 0;
|
||||
.u-row {
|
||||
}
|
||||
.u-col {
|
||||
margin-bottom: 30rpx;
|
||||
}
|
||||
.u-btn {
|
||||
height: 160rpx;
|
||||
padding: 0 28rpx;
|
||||
border: 1px solid #f0f5fc;
|
||||
color: #42465a;
|
||||
font-size: 30rpx;
|
||||
font-weight: 400;
|
||||
&:after {
|
||||
border-color: #f0f5fc;
|
||||
border-radius: 4rpx;
|
||||
}
|
||||
.name {
|
||||
flex: 1;
|
||||
margin-left: 28rpx;
|
||||
text-align: left;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,73 @@
|
||||
/*
|
||||
* @Author: zhou lei
|
||||
* @Date: 2021-11-11 11:09:57
|
||||
* @LastEditTime: 2021-12-14 10:13:18
|
||||
* @LastEditors: zhou lei
|
||||
* @Description:
|
||||
* @FilePath: /wms_haiwai_app/src/pages/raw/commission/goOut/config.ts
|
||||
* 联系方式:910592680@qq.com 18669792120 科海达信息技术有限公司
|
||||
*/
|
||||
/**
|
||||
* 看单明细表格列
|
||||
*/
|
||||
import vm from '@/main';
|
||||
export const headers = [
|
||||
{
|
||||
label: vm.$t('message.Pi_OrderNo'),
|
||||
key: 'order1',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.Line'),
|
||||
key: 'order2',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.matcode'),
|
||||
key: 'productCode',
|
||||
width: 300,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.po_MaterielDes'),
|
||||
key: 'productDescZh',
|
||||
width: 430,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.product_barCode'),
|
||||
key: 'barcode',
|
||||
width: 260,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.CommissionedLocation'),
|
||||
key: 'locCode',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.Operation'),
|
||||
key: 'createdBy',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.operatingTime'),
|
||||
key: 'createdDate',
|
||||
width: 470,
|
||||
},
|
||||
];
|
||||
|
||||
export const detailHeader = [
|
||||
{
|
||||
label: vm.$t('message.po_MaterielNo'),
|
||||
key: 'materialCode',
|
||||
width: 301,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.CommissionedLocation'),
|
||||
key: 'locCode',
|
||||
width: 186,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.product_Number'),
|
||||
key: 'qty',
|
||||
width: 186,
|
||||
},
|
||||
];
|
@ -0,0 +1,73 @@
|
||||
<template>
|
||||
<view class="page-receipt-detail">
|
||||
<view class="header">
|
||||
<view class="left">
|
||||
<u-icon class="icon" name="arrow-left" @click="uni.navigateBack({})" />
|
||||
</view>
|
||||
<view class="title">{{ $t('message.Pi_QueryResults') }}</view>
|
||||
<view class="right"></view>
|
||||
</view>
|
||||
<view class="table-wrapper">
|
||||
<wyb-table class="table" ref="table" width="100%" show-left-and-right-border :headers="headers" :contents="model.detailedList" :show-vert-border="false"></wyb-table>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script lang="ts">
|
||||
import { Component } from 'vue-property-decorator';
|
||||
import { BasePage } from '@/components/base/page';
|
||||
import { headers } from './config';
|
||||
import model from './model';
|
||||
@Component
|
||||
export default class RawSoDetail extends BasePage {
|
||||
model = model;
|
||||
headers = headers;
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.page-receipt-detail {
|
||||
background: #f2f2f2 linear-gradient(0deg, #f2f2f2 0%, #4a78ea 51%, #1753ea 100%) no-repeat;
|
||||
background-size: 100% 600rpx;
|
||||
padding: 30rpx;
|
||||
min-height: 100%;
|
||||
padding-top: 118rpx;
|
||||
padding-bottom: 162rpx;
|
||||
|
||||
.header {
|
||||
position: fixed;
|
||||
top: 36rpx;
|
||||
left: 0;
|
||||
right: 0;
|
||||
display: flex;
|
||||
height: 88rpx;
|
||||
line-height: 88rpx;
|
||||
color: #fff;
|
||||
font-size: 34rpx;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
.title {
|
||||
flex: 3;
|
||||
}
|
||||
.left,
|
||||
.right {
|
||||
flex: 1;
|
||||
}
|
||||
.icon {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 88rpx;
|
||||
height: 88rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.table-wrapper {
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.form {
|
||||
background-color: #fff;
|
||||
padding: 40rpx;
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,212 @@
|
||||
import { Action, getModule, Module, MutationAction, VuexModule } from 'vuex-module-decorators';
|
||||
import store from '@/store';
|
||||
import http from '@/utils/request';
|
||||
import { url } from '@/utils/url';
|
||||
import { session } from '@/store/modules/session';
|
||||
// import vm from '@/main';
|
||||
|
||||
class OrderInInfo {
|
||||
stoAmount?: 0;
|
||||
stoNo?: string; //STO采购单号
|
||||
orderAmount?: string; //单据总数
|
||||
Allocated?: string; //已分配
|
||||
Unallocated?: string; //未分配
|
||||
}
|
||||
|
||||
@Module({
|
||||
namespaced: true,
|
||||
dynamic: true,
|
||||
store,
|
||||
name: 'product.outbound.Semi-finished-SO',
|
||||
})
|
||||
export class ReturningModule extends VuexModule {
|
||||
/**
|
||||
* 月台列表
|
||||
*/
|
||||
returningTypeList: any[] = [];
|
||||
detailedList: any;
|
||||
/**
|
||||
* 物料列表
|
||||
*/
|
||||
materielList: any[] = [];
|
||||
locationCodeList: any[] = [];
|
||||
LocList: any[] = [];
|
||||
//条码扫描的返回的结果
|
||||
oneMaterielDetail: any = {};
|
||||
/**
|
||||
* 订单号查询结果
|
||||
*/
|
||||
orderInInfo: OrderInInfo = new OrderInInfo();
|
||||
//记账按钮的code码
|
||||
code = '';
|
||||
/**
|
||||
* 委外出库单号查询
|
||||
* @param orderNo
|
||||
*/
|
||||
@Action
|
||||
async queryOrder(form: any) {
|
||||
const result = await http.post(url.material.commission.goOut.queryOrder, {
|
||||
...form,
|
||||
loginName: session.loginName,
|
||||
factoryCode: session.factoryCode,
|
||||
});
|
||||
const orderInInfo = result.data.records[0] || {};
|
||||
return { orderInInfo };
|
||||
}
|
||||
/**
|
||||
* 库位
|
||||
*/
|
||||
// @MutationAction
|
||||
// async queryByFactoryCodeAndWorkAreaCode() {
|
||||
// const list: [] = await http.post(url.material.commission.goOut.queryByFactoryCodeAndWorkAreaCode, {
|
||||
// factoryCode: session.factoryCode,
|
||||
// whCode: session.warehouseCode,
|
||||
// loginName: session.loginName,
|
||||
// });
|
||||
// const locationCodeList = list.map((item: any) => ({
|
||||
// label: item.locationCode,
|
||||
// value: item.locationCode,
|
||||
// }));
|
||||
// return { locationCodeList };
|
||||
// }
|
||||
/**
|
||||
* 获取物料
|
||||
*
|
||||
* @returns
|
||||
* @memberof ReturningModule
|
||||
*/
|
||||
@MutationAction
|
||||
async outInfo(poNo: string) {
|
||||
const list: [] = await http.post(url.material.commission.goOut.outInfo, {
|
||||
factoryCode: session.factoryCode,
|
||||
poNo: poNo,
|
||||
loginName: session.loginName,
|
||||
});
|
||||
const locationCodeList = list.map((item: any) => ({
|
||||
label: item.locationCode,
|
||||
value: item.locationCode,
|
||||
}));
|
||||
return { locationCodeList };
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交
|
||||
*/
|
||||
@Action
|
||||
async materialComplete(form: any) {
|
||||
const res = await http.post(url.material.commission.goOut.materialComplete, {
|
||||
factoryCode: session.factoryCode,
|
||||
loginName: session.loginName,
|
||||
...form,
|
||||
});
|
||||
console.log(res, '>>>>>res');
|
||||
}
|
||||
|
||||
/**
|
||||
* 扫条码
|
||||
*/
|
||||
@Action
|
||||
async tluSubmit(list: any[]) {
|
||||
const obj = {
|
||||
barcode: list[0].barCode,
|
||||
loginName: session.loginName,
|
||||
};
|
||||
let oneMaterielDetail: any = {};
|
||||
const { data }: any = await http.post(url.outbound.stoOutbound.checkScan, obj);
|
||||
console.log('shneme a ', data.records);
|
||||
oneMaterielDetail = data.records[0];
|
||||
data.records[0].materialCode = list[0].productCode;
|
||||
data.records[0].materialDesc = list[0].productDescZh;
|
||||
console.log('aaaaa', oneMaterielDetail);
|
||||
return oneMaterielDetail;
|
||||
}
|
||||
/**
|
||||
* 确认按钮
|
||||
* @param orderNo
|
||||
*/
|
||||
@MutationAction
|
||||
async confirm(list: any[]) {
|
||||
const { code, data } = await http.post(url.outbound.stoOutbound.Bookkeeping, list);
|
||||
console.log('res数据', data, code);
|
||||
// if (code == '1') {
|
||||
// uni.showToast({ icon: 'success', title: msg });
|
||||
// } else {
|
||||
// uni.showToast({ icon: 'none', title: msg });
|
||||
// }
|
||||
const materielList: any = [];
|
||||
return { code, materielList };
|
||||
}
|
||||
//委外出库 关闭订单
|
||||
@MutationAction
|
||||
async closeCode(poNo: any) {
|
||||
const res: any = await http.post(url.outbound.stoOutbound.close, {
|
||||
poNo,
|
||||
loginName: session.loginName,
|
||||
factoryCode: session.factoryCode,
|
||||
});
|
||||
const code: any = res.code;
|
||||
return { code };
|
||||
}
|
||||
|
||||
//委外出库 初始化获取库位
|
||||
// @Action({ commit: 'updateCheckedOrderInInfoListKw' })
|
||||
@MutationAction
|
||||
async queryCodeAndWorkAreaCode(content: any) {
|
||||
const res: any = await http.post('/wmspda/fg/queryByFactoryCodeAndWorkAreaCode', content);
|
||||
console.log('>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>', res);
|
||||
const LocList = res;
|
||||
console.log('LocList', LocList);
|
||||
return { LocList };
|
||||
}
|
||||
@MutationAction
|
||||
async queryItemLoc(params: any = {}) {
|
||||
const res: any = await http.post(url.sortscan.save.queryWlByMat, params);
|
||||
const LocList = [];
|
||||
res.forEach((item: any) => {
|
||||
const arr: any = {
|
||||
label: item.locationCode,
|
||||
value: item.locationCode + '(' + item.sendSpot + ')' + '(' + item.amount + ')',
|
||||
};
|
||||
LocList.push(arr);
|
||||
});
|
||||
return { LocList };
|
||||
}
|
||||
@Action
|
||||
async queryOutsourcing(nxOutCode: any) {
|
||||
const res = await http.post(url.so.soOutbound.findInfoByDN, {
|
||||
nxOutCode,
|
||||
proOutType: 'raw',
|
||||
loginName: session.loginName,
|
||||
factoryCode: session.factoryCode,
|
||||
});
|
||||
return res;
|
||||
}
|
||||
|
||||
@Action
|
||||
async submitOutsourcing(upload: any) {
|
||||
const res = await http.post(url.so.soOutbound.confirm, upload);
|
||||
return res;
|
||||
}
|
||||
//查询明细
|
||||
@Action({ commit: 'updateCheckedOrderInInfoListKw' })
|
||||
async querydetaildlist(content: any) {
|
||||
const res: any = await http.post('/wmspda/fg/querySfgListInfoByDnNo/russia', content);
|
||||
console.log('明细》》》》》》》》》', res.list);
|
||||
this.detailedList = res.data;
|
||||
return res;
|
||||
}
|
||||
ContainerCode: any = '';
|
||||
@MutationAction
|
||||
async searchBarcode(params: any) {
|
||||
const res: any = await http.post(url.auth.query.barcode, {
|
||||
factoryCode: session.factoryCode,
|
||||
loginName: session.loginName,
|
||||
barcode: params.barcode,
|
||||
productCode: params.productCode,
|
||||
});
|
||||
const ContainerCode = res.data;
|
||||
return { ContainerCode };
|
||||
}
|
||||
}
|
||||
|
||||
export default getModule(ReturningModule);
|
@ -0,0 +1,78 @@
|
||||
/*
|
||||
* @Author: zhou lei
|
||||
* @Date: 2021-11-11 11:09:57
|
||||
* @LastEditTime: 2021-12-14 10:13:18
|
||||
* @LastEditors: zhou lei
|
||||
* @Description:
|
||||
* @FilePath: /wms_haiwai_app/src/pages/raw/commission/goOut/config.ts
|
||||
* 联系方式:910592680@qq.com 18669792120 科海达信息技术有限公司
|
||||
*/
|
||||
/**
|
||||
* 看单明细表格列
|
||||
*/
|
||||
import vm from '@/main';
|
||||
export const headers = [
|
||||
{
|
||||
label: vm.$t('message.Pi_OrderNo'),
|
||||
key: 'order1',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.Line'),
|
||||
key: 'order2',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.matcode'),
|
||||
key: 'productCode',
|
||||
width: 300,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.po_MaterielDes'),
|
||||
key: 'productDescZh',
|
||||
width: 430,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.product_barCode'),
|
||||
key: 'barcode',
|
||||
width: 260,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.CommissionedLocation'),
|
||||
key: 'locCode',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.Operation'),
|
||||
key: 'createdBy',
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.operatingTime'),
|
||||
key: 'createdDate',
|
||||
width: 470,
|
||||
},
|
||||
];
|
||||
|
||||
export const detailHeader = [
|
||||
{
|
||||
label: vm.$t('message.po_MaterielNo'),
|
||||
key: 'materialCode',
|
||||
width: 301,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.CommissionedLocation'),
|
||||
key: 'locCode',
|
||||
width: 186,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.product_Number'),
|
||||
key: 'qty',
|
||||
width: 186,
|
||||
},
|
||||
{
|
||||
label: vm.$t('message.product_barCode'),
|
||||
key: 'barcode',
|
||||
width: 300,
|
||||
},
|
||||
];
|
@ -0,0 +1,73 @@
|
||||
<template>
|
||||
<view class="page-receipt-detail">
|
||||
<view class="header">
|
||||
<view class="left">
|
||||
<u-icon class="icon" name="arrow-left" @click="uni.navigateBack({})" />
|
||||
</view>
|
||||
<view class="title">{{ $t('message.Pi_QueryResults') }}</view>
|
||||
<view class="right"></view>
|
||||
</view>
|
||||
<view class="table-wrapper">
|
||||
<wyb-table class="table" ref="table" width="100%" show-left-and-right-border :headers="headers" :contents="model.detailedList" :show-vert-border="false"></wyb-table>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script lang="ts">
|
||||
import { Component } from 'vue-property-decorator';
|
||||
import { BasePage } from '@/components/base/page';
|
||||
import { headers } from './config';
|
||||
import model from './model';
|
||||
@Component
|
||||
export default class SpSoDetail extends BasePage {
|
||||
model = model;
|
||||
headers = headers;
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.page-receipt-detail {
|
||||
background: #f2f2f2 linear-gradient(0deg, #f2f2f2 0%, #4a78ea 51%, #1753ea 100%) no-repeat;
|
||||
background-size: 100% 600rpx;
|
||||
padding: 30rpx;
|
||||
min-height: 100%;
|
||||
padding-top: 118rpx;
|
||||
padding-bottom: 162rpx;
|
||||
|
||||
.header {
|
||||
position: fixed;
|
||||
top: 36rpx;
|
||||
left: 0;
|
||||
right: 0;
|
||||
display: flex;
|
||||
height: 88rpx;
|
||||
line-height: 88rpx;
|
||||
color: #fff;
|
||||
font-size: 34rpx;
|
||||
font-weight: 500;
|
||||
text-align: center;
|
||||
.title {
|
||||
flex: 3;
|
||||
}
|
||||
.left,
|
||||
.right {
|
||||
flex: 1;
|
||||
}
|
||||
.icon {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 88rpx;
|
||||
height: 88rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.table-wrapper {
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.form {
|
||||
background-color: #fff;
|
||||
padding: 40rpx;
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,212 @@
|
||||
import { Action, getModule, Module, MutationAction, VuexModule } from 'vuex-module-decorators';
|
||||
import store from '@/store';
|
||||
import http from '@/utils/request';
|
||||
import { url } from '@/utils/url';
|
||||
import { session } from '@/store/modules/session';
|
||||
// import vm from '@/main';
|
||||
|
||||
class OrderInInfo {
|
||||
stoAmount?: 0;
|
||||
stoNo?: string; //STO采购单号
|
||||
orderAmount?: string; //单据总数
|
||||
Allocated?: string; //已分配
|
||||
Unallocated?: string; //未分配
|
||||
}
|
||||
|
||||
@Module({
|
||||
namespaced: true,
|
||||
dynamic: true,
|
||||
store,
|
||||
name: 'product.outbound.Semi-finished-SO',
|
||||
})
|
||||
export class ReturningModule extends VuexModule {
|
||||
/**
|
||||
* 月台列表
|
||||
*/
|
||||
returningTypeList: any[] = [];
|
||||
detailedList: any;
|
||||
/**
|
||||
* 物料列表
|
||||
*/
|
||||
materielList: any[] = [];
|
||||
locationCodeList: any[] = [];
|
||||
LocList: any[] = [];
|
||||
//条码扫描的返回的结果
|
||||
oneMaterielDetail: any = {};
|
||||
/**
|
||||
* 订单号查询结果
|
||||
*/
|
||||
orderInInfo: OrderInInfo = new OrderInInfo();
|
||||
//记账按钮的code码
|
||||
code = '';
|
||||
/**
|
||||
* 委外出库单号查询
|
||||
* @param orderNo
|
||||
*/
|
||||
@Action
|
||||
async queryOrder(form: any) {
|
||||
const result = await http.post(url.material.commission.goOut.queryOrder, {
|
||||
...form,
|
||||
loginName: session.loginName,
|
||||
factoryCode: session.factoryCode,
|
||||
});
|
||||
const orderInInfo = result.data.records[0] || {};
|
||||
return { orderInInfo };
|
||||
}
|
||||
/**
|
||||
* 库位
|
||||
*/
|
||||
// @MutationAction
|
||||
// async queryByFactoryCodeAndWorkAreaCode() {
|
||||
// const list: [] = await http.post(url.material.commission.goOut.queryByFactoryCodeAndWorkAreaCode, {
|
||||
// factoryCode: session.factoryCode,
|
||||
// whCode: session.warehouseCode,
|
||||
// loginName: session.loginName,
|
||||
// });
|
||||
// const locationCodeList = list.map((item: any) => ({
|
||||
// label: item.locationCode,
|
||||
// value: item.locationCode,
|
||||
// }));
|
||||
// return { locationCodeList };
|
||||
// }
|
||||
/**
|
||||
* 获取物料
|
||||
*
|
||||
* @returns
|
||||
* @memberof ReturningModule
|
||||
*/
|
||||
@MutationAction
|
||||
async outInfo(poNo: string) {
|
||||
const list: [] = await http.post(url.material.commission.goOut.outInfo, {
|
||||
factoryCode: session.factoryCode,
|
||||
poNo: poNo,
|
||||
loginName: session.loginName,
|
||||
});
|
||||
const locationCodeList = list.map((item: any) => ({
|
||||
label: item.locationCode,
|
||||
value: item.locationCode,
|
||||
}));
|
||||
return { locationCodeList };
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交
|
||||
*/
|
||||
@Action
|
||||
async materialComplete(form: any) {
|
||||
const res = await http.post(url.material.commission.goOut.materialComplete, {
|
||||
factoryCode: session.factoryCode,
|
||||
loginName: session.loginName,
|
||||
...form,
|
||||
});
|
||||
console.log(res, '>>>>>res');
|
||||
}
|
||||
|
||||
/**
|
||||
* 扫条码
|
||||
*/
|
||||
@Action
|
||||
async tluSubmit(list: any[]) {
|
||||
const obj = {
|
||||
barcode: list[0].barCode,
|
||||
loginName: session.loginName,
|
||||
};
|
||||
let oneMaterielDetail: any = {};
|
||||
const { data }: any = await http.post(url.outbound.stoOutbound.checkScan, obj);
|
||||
console.log('shneme a ', data.records);
|
||||
oneMaterielDetail = data.records[0];
|
||||
data.records[0].materialCode = list[0].productCode;
|
||||
data.records[0].materialDesc = list[0].productDescZh;
|
||||
console.log('aaaaa', oneMaterielDetail);
|
||||
return oneMaterielDetail;
|
||||
}
|
||||
/**
|
||||
* 确认按钮
|
||||
* @param orderNo
|
||||
*/
|
||||
@MutationAction
|
||||
async confirm(list: any[]) {
|
||||
const { code, data } = await http.post(url.outbound.stoOutbound.Bookkeeping, list);
|
||||
console.log('res数据', data, code);
|
||||
// if (code == '1') {
|
||||
// uni.showToast({ icon: 'success', title: msg });
|
||||
// } else {
|
||||
// uni.showToast({ icon: 'none', title: msg });
|
||||
// }
|
||||
const materielList: any = [];
|
||||
return { code, materielList };
|
||||
}
|
||||
//委外出库 关闭订单
|
||||
@MutationAction
|
||||
async closeCode(poNo: any) {
|
||||
const res: any = await http.post(url.outbound.stoOutbound.close, {
|
||||
poNo,
|
||||
loginName: session.loginName,
|
||||
factoryCode: session.factoryCode,
|
||||
});
|
||||
const code: any = res.code;
|
||||
return { code };
|
||||
}
|
||||
|
||||
//委外出库 初始化获取库位
|
||||
// @Action({ commit: 'updateCheckedOrderInInfoListKw' })
|
||||
@MutationAction
|
||||
async queryCodeAndWorkAreaCode(content: any) {
|
||||
const res: any = await http.post('/wmspda/fg/queryByFactoryCodeAndWorkAreaCode', content);
|
||||
console.log('>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>', res);
|
||||
const LocList = res;
|
||||
console.log('LocList', LocList);
|
||||
return { LocList };
|
||||
}
|
||||
@MutationAction
|
||||
async queryItemLoc(params: any = {}) {
|
||||
const res: any = await http.post(url.sortscan.save.queryWlByMat, params);
|
||||
const LocList = [];
|
||||
res.forEach((item: any) => {
|
||||
const arr: any = {
|
||||
label: item.locationCode,
|
||||
value: item.locationCode + '(' + item.sendSpot + ')' + '(' + item.amount + ')',
|
||||
};
|
||||
LocList.push(arr);
|
||||
});
|
||||
return { LocList };
|
||||
}
|
||||
@Action
|
||||
async queryOutsourcing(nxOutCode: any) {
|
||||
const res = await http.post(url.so.soOutbound.findInfoByDN, {
|
||||
nxOutCode,
|
||||
proOutType: 'sp',
|
||||
loginName: session.loginName,
|
||||
factoryCode: session.factoryCode,
|
||||
});
|
||||
return res;
|
||||
}
|
||||
|
||||
@Action
|
||||
async submitOutsourcing(upload: any) {
|
||||
const res = await http.post(url.so.soOutbound.confirm, upload);
|
||||
return res;
|
||||
}
|
||||
//查询明细
|
||||
@Action({ commit: 'updateCheckedOrderInInfoListKw' })
|
||||
async querydetaildlist(content: any) {
|
||||
const res: any = await http.post('/wmspda/fg/querySfgListInfoByDnNo/russia', content);
|
||||
console.log('明细》》》》》》》》》', res.list);
|
||||
this.detailedList = res.data;
|
||||
return res;
|
||||
}
|
||||
ContainerCode: any = '';
|
||||
@MutationAction
|
||||
async searchBarcode(params: any) {
|
||||
const res: any = await http.post(url.auth.query.barcode, {
|
||||
factoryCode: session.factoryCode,
|
||||
loginName: session.loginName,
|
||||
barcode: params.barcode,
|
||||
productCode: params.productCode,
|
||||
});
|
||||
const ContainerCode = res.data;
|
||||
return { ContainerCode };
|
||||
}
|
||||
}
|
||||
|
||||
export default getModule(ReturningModule);
|
Loading…
Reference in New Issue