Squashed commit of the following:

commit 57fbc39721
Author: zhoulei <zhoulei@kehaida.com>
Date:   Fri Nov 12 17:03:18 2021 +0800

    修正语法问题部分

commit 3c4d1b09e3
Author: zhoulei <zhoulei@kehaida.com>
Date:   Thu Nov 11 15:23:29 2021 +0800

    委外入库和出库页面

commit bf3401be34
Author: zhoulei <zhoulei@kehaida.com>
Date:   Wed Nov 10 11:22:31 2021 +0800

    原材料盘点页面和多语言

# Conflicts:
#	src/pages.json
#	src/pages/raw/ingoods/index.vue
master
hou 4 years ago
parent f1bf749747
commit 1a9a1d04b3

@ -51,6 +51,7 @@ export default {
rawMenu_InTheLibrary: "库内",
rawMenu_ReturnGoods: "退货",
rawMenu_SignOut: "退出",
//po收货
po_ReceivingGoods: "PO收货",
po_ReturnGoods: "DN退货",
@ -186,12 +187,35 @@ export default {
Scrap: "成品报废",
CollectionAndBorrowing: "成品领用借用",
Inventory: "成品盘点",
raw_Inventory:'原材料盘点',
RowWarehouse: "原材料库内",
SemiProductZC: "半成品转储",
RowScrap: "原材料报废",
RowRelocation: "原材料移库",
RowCollectionAndBorrowing: "原材料领用借用",
// 原材料盘点
InventoryOrderNo:'单号',
InventoryMaterielNo:'物料号',
InventoryMateriel:'物料名',
InventoryTotalNumber:'盘点总数',
InventoryPleaseScan: "请扫描单号",
// 委外-入库
CommissionEntrant:'委外入库',
CommissionedSingleNumber:'单号',
CommissionedMaterielNo:'物料号',
CommissionedMaterielDesc:'物料描述',
CommissionedDemandData:'需求数据',
CommissionedCumulativeData:'累计数据',
CommissionedLocation:'库位',
CommissionedThisNumber:'本次数量',
CommissionedEntrantDetails:'入库明细',
// 委外-出库
CommissionGoOut:'委外出库',
CommissionedGoOutDetails:'出库明细',
//移库
Warehouse_QueryCriteria: "查询条件",
Warehouse_TransferOrderNo: "移库单号",

@ -191,12 +191,36 @@ export default {
Scrap: "FG scrap",
CollectionAndBorrowing: "FG cost center",
Inventory: "FG PSV",
raw_Inventory:'raw Inventory',
RowWarehouse: "RAW WH",
SemiProductZC: "SFG transfer",
RowScrap: "RAW scrap",
RowRelocation: "RAW transfer",
RowCollectionAndBorrowing: "RAW cost center",
// 原材料盘点
InventoryOrderNo:'单号',
InventoryMaterielNo:'MAT code',
InventoryMateriel:'MAT name',
InventoryTotalNumber:'Total',
InventoryPleaseScan: "Please scan No.",
// 委外-入库
CommissionEntrant:'委外入库',
CommissionedSingleNumber:'单号',
CommissionedMaterielNo:'物料号',
CommissionedMaterielDesc:'物料描述',
CommissionedDemandData:'需求数据',
CommissionedCumulativeData:'累计数据',
CommissionedLocation:'库位',
CommissionedThisNumber:'本次数量',
CommissionedEntrantDetails:'入库明细',
// 委外-出库
CommissionGoOut:'委外出库',
CommissionedGoOutDetails:'出库明细',
//移库
Warehouse_QueryCriteria: "Query criteria",
Warehouse_TransferOrderNo: "Transfer order No",

@ -1,14 +1,654 @@
{
"easycom": {
"^u-(.*)": "uview-ui/components/u-$1/u-$1.vue"
},
"__pages_comment": "pages数组中第一项表示应用启动页参考https://uniapp.dcloud.io/collocation/pages",
"pages": [
{
"path": "pages/index/index",
"style": {
"navigationBarTitleText": "首页"
"easycom": {
"^u-(.*)": "uview-ui/components/u-$1/u-$1.vue"
},
"__pages_comment": "pages数组中第一项表示应用启动页参考https://uniapp.dcloud.io/collocation/pages",
"pages": [{
"path": "pages/index/index",
"style": {
"navigationBarTitleText": "首页"
}
},
{
"path": "pages/product/index",
"style": {
"navigationBarTitleText": "成品主菜单",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/inbound/index3",
"style": {
"navigationBarTitleText": "成品入库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/outbound/index",
"style": {
"navigationBarTitleText": "出库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/outbound/internal/index",
"style": {
"navigationBarTitleText": "内销出库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/outbound/foreign/index",
"style": {
"navigationBarTitleText": "外销出库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/warehouse/index",
"style": {
"navigationBarTitleText": "库内",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/warehouse/wholeTransfer/index",
"style": {
"navigationBarTitleText": "成品移库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/warehouse/wholeScrap/index",
"style": {
"navigationBarTitleText": "成品报废",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/warehouse/wholeCollect/index",
"style": {
"navigationBarTitleText": "成品领用",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/warehouse/wholeLnventory/index",
"style": {
"navigationBarTitleText": "成品盘点",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/outbound/stoOutbound/index",
"style": {
"navigationBarTitleText": "STO出库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/outbound/stoOutbound/detail",
"style": {
"navigationBarTitleText": "STO出库明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/index",
"style": {
"navigationBarTitleText": "原材料主菜单",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/appointment/index",
"style": {
"navigationBarTitleText": "预约",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/appointment/checkin/index",
"style": {
"navigationBarTitleText": "预约登记",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/appointment/checkout/index",
"style": {
"navigationBarTitleText": "预约离开",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/index",
"style": {
"navigationBarTitleText": "收货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/receipt/index",
"style": {
"navigationBarTitleText": "看单收货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/receipt/detail",
"style": {
"navigationBarTitleText": "看单明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/receipt/detail-ex",
"style": {
"navigationBarTitleText": "看单明细未通过明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/index",
"style": {
"navigationBarTitleText": "交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/index",
"style": {
"navigationBarTitleText": "库内",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/rowTransfer/index",
"style": {
"navigationBarTitleText": "移库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/rowTransfer/details",
"style": {
"navigationBarTitleText": "移库明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/rowScrap/index",
"style": {
"navigationBarTitleText": "报废",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/rowScrap/details",
"style": {
"navigationBarTitleText": "报废明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/rowCollect/index",
"style": {
"navigationBarTitleText": "成本中心",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/rowCollect/details",
"style": {
"navigationBarTitleText": "成本中心明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/poReceipt/index",
"style": {
"navigationBarTitleText": "PO单收货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/poReceipt/idetailed",
"style": {
"navigationBarTitleText": "PO退货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/poReceipt/detail",
"style": {
"navigationBarTitleText": "PO单收货明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/dnReceipt/index",
"style": {
"navigationBarTitleText": "DN单收货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/dnReceipt/idetailed",
"style": {
"navigationBarTitleText": "DN单收货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/dnReceipt/detail",
"style": {
"navigationBarTitleText": "DN单收货明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/dnReturnGoods/index",
"style": {
"navigationBarTitleText": "DN退货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/dnReturnGoods/idetailed",
"style": {
"navigationBarTitleText": "DN退货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/ingoods/dnReturnGoods/detail",
"style": {
"navigationBarTitleText": "DN单退货明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/picking/index",
"style": {
"navigationBarTitleText": "拣配查询",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/picking/query",
"style": {
"navigationBarTitleText": "拣配查询",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/picking/idetailed",
"style": {
"navigationBarTitleText": "DN退货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/picking/result",
"style": {
"navigationBarTitleText": "拣配查询结果",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/picking/summary",
"style": {
"navigationBarTitleText": "汇总拣配",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/picking/total",
"style": {
"navigationBarTitleText": "汇总拣配",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/picking/order",
"style": {
"navigationBarTitleText": "按单拣配",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/feeding/index",
"style": {
"navigationBarTitleText": "补料",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/feeding/detail",
"style": {
"navigationBarTitleText": "补料明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/returning/index",
"style": {
"navigationBarTitleText": "退料",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/appointment/checkin/list",
"style": {
"navigationBarTitleText": "登记清单",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/kan-dan/index",
"style": {
"navigationBarTitleText": "看单交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/kan-dan/details",
"style": {
"navigationBarTitleText": "看单交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/aggregating/index",
"style": {
"navigationBarTitleText": "汇总查询",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/aggregating/result",
"style": {
"navigationBarTitleText": "汇总交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/aggregating/summary",
"style": {
"navigationBarTitleText": "汇总交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/aggregating/order",
"style": {
"navigationBarTitleText": "按单交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/aggregating/accessory",
"style": {
"navigationBarTitleText": "辅料交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/virtual/index",
"style": {
"navigationBarTitleText": "虚拟单交接",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/virtual/result",
"style": {
"navigationBarTitleText": "虚拟单明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/handover/virtual/summary",
"style": {
"navigationBarTitleText": "虚拟单交接-确认",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/login/login/index",
"style": {
"navigationBarTitleText": "登录",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/login/server/index",
"style": {
"navigationBarTitleText": "服务器设置",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/login/area/index",
"style": {
"navigationBarTitleText": "登录区选择",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/inbound/offline-in/index",
"style": {
"navigatpaionBarTitleText": "成品下线入库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/inbound/finishProductOffline/index",
"style": {
"navigatpaionBarTitleText": "成品下线",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/product/inbound/semiFinishProductOffline2/index",
"style": {
"navigatpaionBarTitleText": "半成品下线-其他",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/index",
"style": {
"navigationBarTitleText": "半成品主菜单",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/inbound/index",
"style": {
"navigationBarTitleText": "半成品入库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/DumpList/index",
"style": {
"navigationBarTitleText": "转储单",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/DumpList/DumpListFH/index",
"style": {
"navigationBarTitleText": "转储单发货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/DumpList/DumpListFH/detail",
"style": {
"navigationBarTitleText": "转储单发货明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/DumpList/DumpListSH/index",
"style": {
"navigationBarTitleText": "转储单收货",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/DumpList/DumpListSH/detail",
"style": {
"navigationBarTitleText": "转储单收货明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/outbound/index",
"style": {
"navigatpaionBarTitleText": "半成品出库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/SemiProduct/inbound/index",
"style": {
"navigatpaionBarTitleText": "半成品入库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/warehouse/rowInventory/index",
"style": {
"navigationBarTitleText": "原材料盘点",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/commission/index",
"style": {
"navigationBarTitleText": "委外",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/commission/entrant/index",
"style": {
"navigationBarTitleText": "委外入库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/commission/entrant/detail",
"style": {
"navigationBarTitleText": "入库明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/commission/goOut/index",
"style": {
"navigationBarTitleText": "委外出库",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/raw/commission/goOut/detail",
"style": {
"navigationBarTitleText": "出库明细",
"navigationStyle": "custom", //
"navigationBarTextStyle": "white" // white-black-
}
},
{
"path": "pages/demo/index",
"style": {
"navigationBarTitleText": "演示"
}
}
<<<<<<< HEAD
},
{
"path": "pages/product/index",
@ -655,12 +1295,13 @@
"style": {
"navigationBarTitleText": "演示"
}
=======
],
"globalStyle": {
"navigationBarTextStyle": "black",
"navigationBarTitleText": "uni-app",
"navigationBarBackgroundColor": "#F8F8F8",
"backgroundColor": "#F8F8F8"
>>>>>>> 57fbc39721f016bc5ee6b99c82721d1cb9433b00
}
],
"globalStyle": {
"navigationBarTextStyle": "black",
"navigationBarTitleText": "uni-app",
"navigationBarBackgroundColor": "#F8F8F8",
"backgroundColor": "#F8F8F8"
}
}
}

@ -0,0 +1,21 @@
/**
*
*/
import vm from '@/main';
export const headers = [
{
label: vm.$t('message.product_barCode'),
key: 'barcode',
width: 300,
},
{
label: vm.$t('message.product_FGCode'),
key: 'materialCode',
width: 300,
},
{
label: vm.$t('message.product_FGDes'),
key: 'materialDesc',
width: 300,
},
];

@ -0,0 +1,182 @@
<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.CommissionedEntrantDetails') }}</view>
<view class="right"></view>
</view>
<view class="table-wrapper">
<wyb-table
class="table"
ref="table"
width="100%"
enable-check="multiple"
show-left-and-right-border
:headers="headers"
:contents="model.materielList"
:show-vert-border="false"
></wyb-table>
</view>
<view class="bottom-bar">
<div class="extra">
<u-row class="bottom-info">
<u-col :span="12"
>{{ $t('message.po_Total') }} {{ model.materielList.length }}
{{ $t('message.po_Records') }}</u-col
>
<!-- <u-col :span="2">数量</u-col>-->
<!-- <u-col :span="4"><u-input v-model="locationCode"></u-input></u-col>-->
<!-- <u-col :span="3">-->
<!-- <u-button-->
<!-- size="mini"-->
<!-- type="warning"-->
<!-- :loading="$wait.is('*changeOrderInLocation')"-->
<!-- @click="changeLocation"-->
<!-- >-->
<!-- 拒收-->
<!-- </u-button>-->
<!-- </u-col>-->
</u-row>
</div>
<!-- <div class="container">-->
<!-- <u-row>-->
<!-- <u-col :span="4">-->
<!-- <u-button type="primary" @click="model.checkAllOrderInInfoList(!model.isCheckedAll)">-->
<!-- {{-->
<!-- model.isCheckedAll-->
<!-- ? this.$t('message.po_noSelectAll')-->
<!-- : this.$t('message.po_SelectAll')-->
<!-- }}-->
<!-- </u-button>-->
<!-- </u-col>-->
<!-- <u-col :span="4">-->
<!-- <u-button type="success" :loading="$wait.is('*submitOrderInEnter')" @click="onSubmit">-->
<!-- {{ $t('message.po_Submit') }}-->
<!-- </u-button>-->
<!-- </u-col>-->
<!-- <u-col :span="4">-->
<!-- <u-button @click="uni.navigateBack()">{{ $t('message.po_Return') }}</u-button>-->
<!-- </u-col>-->
<!-- </u-row>-->
<!-- </div>-->
</view>
</view>
</template>
<script lang="ts">
import { Component } from 'vue-property-decorator';
import { BasePage } from '@/components/base/page';
import model from './model';
import { headers } from './config';
@Component
export default class RawReceiptDetail extends BasePage {
/**
* 页面Module
*/
model = model;
/**
* 库位
*/
locationCode = '';
/**
* 表头
*/
headers = headers;
/**
* 逐条修改
*/
// changeLocation() {
// if (!this.model.hasChecked) {
// uni.showToast({
// icon: 'none',
// title: '',
// });
// return;
// }
// this.model.changeOrderInLocation(this.locationCode);
// }
/**
* 提交
*/
// async onSubmit() {
// await this.model.submitOrderInEnter();
// this.locationCode = '';
// }
}
</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;
.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;
}
.bottom-bar {
z-index: 21;
position: fixed;
bottom: 0;
left: 0;
right: 0;
.container {
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.extra {
background-color: #fff;
margin: 5px;
border-radius: 5px;
padding: 0 10px;
}
}
}
</style>

@ -0,0 +1,447 @@
<template>
<view class="page-raw-returning">
<view class="header" :style="{ backgroundColor: `rgba(23, 83, 234, ${scrollTop / 100})` }">
<view class="left">
<u-icon class="icon" name="arrow-left" @click="back" />
</view>
<view class="title">{{ $t('message.CommissionEntrant') }}</view>
<view class="right"></view>
</view>
<u-form class="form" ref="form" :model="form" :error-type="['toast']" label-width="150rpx">
<u-form-item :required="true" :label="$t('message.CommissionedSingleNumber')" prop="orderNo">
<u-search
:placeholder="$t('message.po_PleaseInput')"
v-model="form.orderNo"
@search="model.queryOrderInInfo"
:show-action="false"
></u-search>
</u-form-item>
<u-row gutter="0">
<u-col :span="6">
<u-form-item :required="true" :label="$t('message.CommissionedMaterielNo')">
<u-input
v-model="form.orderNo"
type="select"
@click="materialCodeSelect = true"
:placeholder="$t('message.po_PleaseInput')"
/>
<u-select
:confirm-text="$t('message.product_Confirm')"
:cancel-text="$t('message.product_Cancel')"
v-model="materialCodeSelect"
:list="model.materielList"
@confirm="materialConfirm"
></u-select>
</u-form-item>
</u-col>
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedMaterielDesc')">
<u-input v-model="form.productCode" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
</u-row>
<u-row gutter="0">
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedDemandData')">
<u-input v-model="form.productDescZh" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedCumulativeData')">
<u-input v-model="form.scanAmount" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
</u-row>
<u-row gutter="0">
<u-col :span="6">
<u-form-item :required="true" :label="$t('message.CommissionedLocation')">
<u-input
v-model="form.qty"
type="select"
@click="materialCodeSelect = true"
:placeholder="$t('message.po_PleaseInput')"
/>
<u-select
:confirm-text="$t('message.product_Confirm')"
:cancel-text="$t('message.product_Cancel')"
v-model="materialCodeSelect"
:list="model.materielList"
@confirm="materialConfirm"
></u-select>
</u-form-item>
</u-col>
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedThisNumber')">
<u-input v-model="form.scanAmount" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
</u-row>
<u-row>
<u-col :span="8"></u-col>
<u-col :span="4">
<u-button :style="{margin:'24rpx 0'}" type="primary" size="medium" class="confirm" @click="confirm">{{$t('message.product_add')}}</u-button>
</u-col>
</u-row>
<u-col :span="12">
<view class="table-wrapper">
<u-table class="library-table">
<u-tr class="u-tr">
<u-th class="u-th">{{ $t("message.po_MaterielNo") }}</u-th>
<u-th class="u-th">{{ $t("message.po_MaterielDes") }}</u-th>
<u-th class="u-th">{{ $t("message.operation") }}</u-th>
</u-tr>
<u-tr class="u-tr" v-for="(item, index) in LocationList" :key="index">
<u-td class="u-td">{{ item.productCode }}</u-td>
<u-td class="u-td">{{ item.productDescZh }}</u-td>
<u-td class="u-td">
<div class="u-td" @click="deleteItem(index)">
{{ $t("message.product_Delete") }}
</div>
</u-td>
</u-tr>
</u-table>
<!-- <wyb-table
class="table"
ref="table"
width="100%"
enable-check="multiple"
show-left-and-right-border
:headers="headers"
:contents="materialList"
:show-vert-border="false"
@onCheck="onCheck"
></wyb-table> -->
</view>
</u-col>
</u-form>
<view class="bottom-bar">
<u-row class="button-bar">
<u-col :span="4">
<u-button type="primary" @click="toPage(page.raw.commission.entrant.detail)">
{{
$t('message.CommissionedEntrantDetails')
}}
</u-button>
</u-col>
<u-col :span="4">
<u-button type="primary" @click="resetHandle">{{ $t('message.product_Upload') }}</u-button>
</u-col>
<u-col :span="4">
<u-button type="error" @click="onOk">{{ $t('message.po_Return') }}</u-button>
</u-col>
<!-- <u-col :span="3">-->
<!-- <u-button type="success" @click="uni.navigateBack()"></u-button>-->
<!-- </u-col>-->
</u-row>
</view>
</view>
</template>
<script lang="ts">
import { Component, Ref } from 'vue-property-decorator';
import { BasePage } from '@/components/base/page';
import { VForm, VFormRules } from 'vue/types/form';
import model from './model';
import { session } from '@/store/modules/session';
import { headers } from './config';
@Component
export default class stoOutboundDom extends BasePage {
/**
* 表单引用
*/
@Ref('form') readonly $form!: VForm;
/**
* 表格引用
*/
@Ref('table') readonly $table: any;
LocationList: any = [];
/**
* 页面Module
*/
model = model;
/**
* search焦点获取
*/
firstFocus = false;
/**
* 表头
*/
headers = headers;
/**
* 表单数据
*/
form = {
dockCode: null, // code
dockName: null, // name
orderNo: null,
qty: 0,
orderAmount: '',
productCode: 'test', // name
productDescZh: 'test',
scanAmount: '',
barCode: '',
};
materialList: any = []; //
//
selectMaterielList: any = [];
/**
* 工位退料人名称
*/
operatorName = '';
/**
* 退料类型选择
*/
returningTypeSelect = false;
//
materialCodeSelect = false;
/**
* 表单验证规则
*/
rules: VFormRules<any> = {
orderNo: [{ required: true, message: this.$t('message.product_Tip4') as string }],
};
confirm() {
// if (this.wlCode == "" || this.number == "") {
// uni.showToast({
// icon: "none",
// title: "",
// });
// return;
// }
this.LocationList.push(this.form)
}
deleteItem(index: any) {
this.LocationList.splice(index, 1);
}
// onReadyonLoad
async onReady() {
this.$form.setRules(this.rules);
model.queryReturningTypeList();
}
onCheck(e: any) {
console.log('e.data', e.data);
this.selectMaterielList = [];
e.data.forEach((line: any) => {
const { lineData: item } = line;
this.selectMaterielList.push(item);
});
}
back() {
this.form.barCode = '';
this.model.orderInInfo.stoAmount = 0;
this.selectMaterielList = [];
uni.navigateBack({ delta: 1 });
this.$table.onEmpty();
}
materialConfirm(v: any) {
console.log('v[0].value', v[0]);
// this.form.productCode = v[0].value;
this.model.materielList.forEach((item: any) => {
if (v[0].value == item.stoItem) {
this.form.productCode = item.materialCode;
this.form.productDescZh = item.materialDesc;
this.form.orderAmount = item.orderAmount;
this.form.scanAmount = item.scanAmount;
}
});
console.log('this.form', this.form);
}
/**
* 清空
*/
resetHandle() {
this.materialList = [];
this.$table.onCheckAllTap();
this.model.materielList.forEach((item: any) => {
if (this.form.productCode == item.label) {
this.form.productDescZh = item.materialDesc;
this.form.orderAmount = item.orderAmount;
this.form.scanAmount = item.scanAmount;
}
});
}
/**
* 条码回车
*/
onSubmit() {
this.$form.validate(async (valid: boolean) => {
if (this.form.productCode.slice(0, 9) != this.form.barCode.slice(0, 9)) {
uni.showToast({ icon: 'none', title: this.$t('message.product_Tip5') as string });
return;
}
if (parseInt(this.form.orderAmount) <= parseInt(this.form.scanAmount)) {
uni.showToast({ icon: 'none', title: this.$t('message.product_Tip6') as string });
return;
}
let list = [
{
order3: this.form.orderNo,
productCode: this.form.productCode,
productDescZh: this.form.productDescZh,
barCode: this.form.barCode,
dockCode: this.form.dockCode,
dockName: this.form.dockName,
orderType: 3,
type: 0,
keepBy: session.loginName as string,
loginName: session.loginName as string,
},
];
if (valid) {
const res = await this.model.tluSubmit(list);
console.log('fanhui ', res);
// if (res.barcode) {
// // this.materialList.push(res);
// this.form.scanAmount = res.scanAmount;
// }
if (this.materialList.length == 0) {
await this.materialList.push(res);
this.form.scanAmount += 1;
this.$table.onCheckAllTap();
} else {
let flag = 0;
for (let i = 0; i < this.materialList.length; i++) {
console.log('11111', this.materialList[i]);
if (this.form.barCode == this.materialList[i].barcode) {
flag = 1;
break;
}
}
if (flag == 0) {
await this.$table.onCheckAllTap();
await this.materialList.push(res);
this.form.scanAmount += 1;
this.$table.onCheckAllTap();
} else {
uni.showToast({ icon: 'none', title: this.$t('message.product_Tip7') as string });
}
}
}
});
const item = {
...this.form,
barCode: String(''),
};
this.firstFocus = false;
setTimeout(() => {
this.form = item;
this.firstFocus = true;
}, 0);
}
onOk() {
// if (this.selectMaterielList.length == 0) {
// uni.showToast({ icon: 'none', title: this.$t('message.product_Tip2') as string });
// } else {
this.$form.validate(async (valid: boolean) => {
if (!valid) return;
let selctlist: any = [];
this.selectMaterielList.forEach((item: any, index: any) => {
// item.originWl = item.locCode;
selctlist[index] = {
barCode: item.barcode,
keepBy: session.loginName,
loginName: session.loginName,
order3: this.form.orderNo,
orderType: 3,
type: 0,
productCode: item.productCode,
productDescZh: item.productDescZh,
originWl: item.locCode,
dockCode: item.dockCode,
dockName: item.dockName,
whCode: item.whCode,
regionCode: item.regionCode,
};
});
await this.model.confirm(selctlist);
// this.$form.resetFields();
// // this.form.barCode = '';
// this.selectMaterielList = [];
console.log('aaaaaaa', this.model);
if (this.model.code == '1') {
this.materialList = [];
// this.model.materielList = [];
this.$table.onCheckAllTap();
uni.showToast({ icon: 'success', title: 'success' });
}
});
this.form.barCode = '';
this.form.productCode = '';
// this.form.orderNo = null;
this.form.scanAmount = '';
this.form.orderAmount = '';
this.form.productDescZh = '';
this.selectMaterielList = [];
this.$table.onEmpty();
}
// }
}
</script>
<style lang="scss" scoped>
.page-raw-returning {
background: #f2f2f2
linear-gradient(0deg, #f2f2f2 0%, #4a78ea 51%, #1753ea 100%) no-repeat;
background-size: 100% 600rpx;
padding: 118rpx 30rpx 162rpx;
min-height: 100%;
.header {
position: fixed;
top: 36rpx;
left: 0;
right: 0;
z-index: 99;
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;
}
}
.form {
background-color: #fff;
padding: 40rpx;
border-radius: 10rpx;
box-shadow: 0 0 20rpx 0 rgba(128, 128, 128, 0.2);
.u-form-item {
padding: 30rpx 0;
line-height: 35rpx;
}
}
.bottom-bar {
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 99;
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.button-bar {
}
}
</style>

@ -0,0 +1,122 @@
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.stoOutbound',
})
export class ReturningModule extends VuexModule {
/**
*
*/
returningTypeList: any[] = [];
/**
*
*/
materielList: any[] = [];
//条码扫描的返回的结果
oneMaterielDetail: any = {};
/**
*
*/
orderInInfo: OrderInInfo = new OrderInInfo();
//记账按钮的code码
code = '';
/**
*
*/
@MutationAction
async queryReturningTypeList() {
const list: [] = await http.post(url.outbound.stoOutbound.yuetaiType, {
factoryCode: session.factoryCode,
whCode: session.warehouseCode,
loginName: session.loginName,
});
const returningTypeList = list.map((item: any) => ({
label: item.dockName,
value: item.dockCode,
}));
return { returningTypeList };
}
/**
*
* @param orderNo
*/
@MutationAction
async queryOrderInInfo(stoNo: string) {
const result = await http.post(url.outbound.stoOutbound.info, {
stoNo,
deleteFlag: 2,
finalState: 3,
loginName: session.loginName,
});
let stoAmount = 0;
result.data.records.forEach((item: any) => {
stoAmount += item.orderAmount;
});
const materielList = result.data.records.map((item: any) => ({
label: item.materialCode,
value: item.stoItem,
...item,
}));
console.log('materielList', materielList);
if (result.data.records[0]) {
result.data.records[0].stoAmount = stoAmount;
}
const orderInInfo = result.data.records[0] || {};
return { orderInInfo, materielList };
}
/**
*
*/
@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 };
}
}
export default getModule(ReturningModule);

@ -0,0 +1,21 @@
/**
*
*/
import vm from '@/main';
export const headers = [
{
label: vm.$t('message.product_barCode'),
key: 'barcode',
width: 300,
},
{
label: vm.$t('message.product_FGCode'),
key: 'materialCode',
width: 300,
},
{
label: vm.$t('message.product_FGDes'),
key: 'materialDesc',
width: 300,
},
];

@ -0,0 +1,182 @@
<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.CommissionedGoOutDetails') }}</view>
<view class="right"></view>
</view>
<view class="table-wrapper">
<wyb-table
class="table"
ref="table"
width="100%"
enable-check="multiple"
show-left-and-right-border
:headers="headers"
:contents="model.materielList"
:show-vert-border="false"
></wyb-table>
</view>
<view class="bottom-bar">
<div class="extra">
<u-row class="bottom-info">
<u-col :span="12"
>{{ $t('message.po_Total') }} {{ model.materielList.length }}
{{ $t('message.po_Records') }}</u-col
>
<!-- <u-col :span="2">数量</u-col>-->
<!-- <u-col :span="4"><u-input v-model="locationCode"></u-input></u-col>-->
<!-- <u-col :span="3">-->
<!-- <u-button-->
<!-- size="mini"-->
<!-- type="warning"-->
<!-- :loading="$wait.is('*changeOrderInLocation')"-->
<!-- @click="changeLocation"-->
<!-- >-->
<!-- 拒收-->
<!-- </u-button>-->
<!-- </u-col>-->
</u-row>
</div>
<!-- <div class="container">-->
<!-- <u-row>-->
<!-- <u-col :span="4">-->
<!-- <u-button type="primary" @click="model.checkAllOrderInInfoList(!model.isCheckedAll)">-->
<!-- {{-->
<!-- model.isCheckedAll-->
<!-- ? this.$t('message.po_noSelectAll')-->
<!-- : this.$t('message.po_SelectAll')-->
<!-- }}-->
<!-- </u-button>-->
<!-- </u-col>-->
<!-- <u-col :span="4">-->
<!-- <u-button type="success" :loading="$wait.is('*submitOrderInEnter')" @click="onSubmit">-->
<!-- {{ $t('message.po_Submit') }}-->
<!-- </u-button>-->
<!-- </u-col>-->
<!-- <u-col :span="4">-->
<!-- <u-button @click="uni.navigateBack()">{{ $t('message.po_Return') }}</u-button>-->
<!-- </u-col>-->
<!-- </u-row>-->
<!-- </div>-->
</view>
</view>
</template>
<script lang="ts">
import { Component } from 'vue-property-decorator';
import { BasePage } from '@/components/base/page';
import model from './model';
import { headers } from './config';
@Component
export default class RawReceiptDetail extends BasePage {
/**
* 页面Module
*/
model = model;
/**
* 库位
*/
locationCode = '';
/**
* 表头
*/
headers = headers;
/**
* 逐条修改
*/
// changeLocation() {
// if (!this.model.hasChecked) {
// uni.showToast({
// icon: 'none',
// title: '',
// });
// return;
// }
// this.model.changeOrderInLocation(this.locationCode);
// }
/**
* 提交
*/
// async onSubmit() {
// await this.model.submitOrderInEnter();
// this.locationCode = '';
// }
}
</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;
.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;
}
.bottom-bar {
z-index: 21;
position: fixed;
bottom: 0;
left: 0;
right: 0;
.container {
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.extra {
background-color: #fff;
margin: 5px;
border-radius: 5px;
padding: 0 10px;
}
}
}
</style>

@ -0,0 +1,418 @@
<template>
<view class="page-raw-returning">
<view class="header" :style="{ backgroundColor: `rgba(23, 83, 234, ${scrollTop / 100})` }">
<view class="left">
<u-icon class="icon" name="arrow-left" @click="back" />
</view>
<view class="title">{{ $t('message.CommissionGoOut') }}</view>
<view class="right"></view>
</view>
<u-form class="form" ref="form" :model="form" :error-type="['toast']" label-width="150rpx">
<u-form-item :required="true" :label="$t('message.CommissionedSingleNumber')" prop="orderNo">
<u-search
:placeholder="$t('message.po_PleaseInput')"
v-model="form.orderNo"
@search="model.queryOrderInInfo"
:show-action="false"
></u-search>
</u-form-item>
<u-row gutter="0">
<u-col :span="6">
<u-form-item :required="true" :label="$t('message.CommissionedMaterielNo')">
<u-input
v-model="form.productCode"
type="select"
@click="materialCodeSelect = true"
:placeholder="$t('message.po_PleaseInput')"
/>
<u-select
:confirm-text="$t('message.product_Confirm')"
:cancel-text="$t('message.product_Cancel')"
v-model="materialCodeSelect"
:list="model.materielList"
@confirm="materialConfirm"
></u-select>
</u-form-item>
</u-col>
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedMaterielDesc')">
<u-input v-model="form.scanAmount" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
</u-row>
<u-row gutter="0">
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedDemandData')">
<u-input v-model="form.orderAmount" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedCumulativeData')">
<u-input v-model="form.scanAmount" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
</u-row>
<u-row gutter="0">
<u-col :span="6">
<u-form-item :required="true" :label="$t('message.CommissionedLocation')">
<u-input
v-model="form.productCode"
type="select"
@click="materialCodeSelect = true"
:placeholder="$t('message.po_PleaseInput')"
/>
<u-select
:confirm-text="$t('message.product_Confirm')"
:cancel-text="$t('message.product_Cancel')"
v-model="materialCodeSelect"
:list="model.materielList"
@confirm="materialConfirm"
></u-select>
</u-form-item>
</u-col>
<u-col :span="6">
<u-form-item :label="$t('message.CommissionedThisNumber')">
<u-input v-model="form.scanAmount" :placeholder="$t('message.po_PleaseInput')" />
</u-form-item>
</u-col>
</u-row>
<u-row>
<u-col :span="8"></u-col>
<u-col :span="4">
<u-button :style="{margin:'24rpx 0'}" type="primary">{{$t('message.product_add')}}</u-button>
</u-col>
</u-row>
<u-col :span="12">
<view class="table-wrapper">
<wyb-table
class="table"
ref="table"
width="100%"
enable-check="multiple"
show-left-and-right-border
:headers="headers"
:contents="materialList"
:show-vert-border="false"
@onCheck="onCheck"
></wyb-table>
</view>
</u-col>
</u-form>
<view class="bottom-bar">
<u-row class="button-bar">
<u-col :span="4">
<u-button type="primary" @click="toPage(page.raw.commission.goOut.detail)">
{{
$t('message.CommissionedGoOutDetails')
}}
</u-button>
</u-col>
<u-col :span="4">
<u-button type="primary" @click="resetHandle">{{ $t('message.product_Upload') }}</u-button>
</u-col>
<u-col :span="4">
<u-button type="error" @click="onOk">{{ $t('message.po_Return') }}</u-button>
</u-col>
<!-- <u-col :span="3">-->
<!-- <u-button type="success" @click="uni.navigateBack()"></u-button>-->
<!-- </u-col>-->
</u-row>
</view>
</view>
</template>
<script lang="ts">
import { Component, Ref } from 'vue-property-decorator';
import { BasePage } from '@/components/base/page';
import { VForm, VFormRules } from 'vue/types/form';
import model from './model';
import { session } from '@/store/modules/session';
import { headers } from './config';
@Component
export default class stoOutboundDom extends BasePage {
/**
* 表单引用
*/
@Ref('form') readonly $form!: VForm;
/**
* 表格引用
*/
@Ref('table') readonly $table: any;
/**
* 页面Module
*/
model = model;
/**
* search焦点获取
*/
firstFocus = false;
/**
* 表头
*/
headers = headers;
/**
* 表单数据
*/
form = {
dockCode: null, // code
dockName: null, // name
orderNo: null,
qty: 0,
orderAmount: '',
productCode: '', // name
productDescZh: '',
scanAmount: '',
barCode: '',
};
materialList: any = []; //
//
selectMaterielList: any = [];
/**
* 工位退料人名称
*/
operatorName = '';
/**
* 退料类型选择
*/
returningTypeSelect = false;
//
materialCodeSelect = false;
/**
* 表单验证规则
*/
rules: VFormRules<any> = {
orderNo: [{ required: true, message: this.$t('message.product_Tip4') as string }],
};
// onReadyonLoad
async onReady() {
this.$form.setRules(this.rules);
model.queryReturningTypeList();
}
onCheck(e: any) {
console.log('e.data', e.data);
this.selectMaterielList = [];
e.data.forEach((line: any) => {
const { lineData: item } = line;
this.selectMaterielList.push(item);
});
}
back() {
this.form.barCode = '';
this.model.orderInInfo.stoAmount = 0;
this.selectMaterielList = [];
uni.navigateBack({ delta: 1 });
this.$table.onEmpty();
}
materialConfirm(v: any) {
console.log('v[0].value', v[0]);
// this.form.productCode = v[0].value;
this.model.materielList.forEach((item: any) => {
if (v[0].value == item.stoItem) {
this.form.productCode = item.materialCode;
this.form.productDescZh = item.materialDesc;
this.form.orderAmount = item.orderAmount;
this.form.scanAmount = item.scanAmount;
}
});
console.log('this.form', this.form);
}
/**
* 清空
*/
resetHandle() {
this.materialList = [];
this.$table.onCheckAllTap();
this.model.materielList.forEach((item: any) => {
if (this.form.productCode == item.label) {
this.form.productDescZh = item.materialDesc;
this.form.orderAmount = item.orderAmount;
this.form.scanAmount = item.scanAmount;
}
});
}
/**
* 条码回车
*/
onSubmit() {
this.$form.validate(async (valid: boolean) => {
if (this.form.productCode.slice(0, 9) != this.form.barCode.slice(0, 9)) {
uni.showToast({ icon: 'none', title: this.$t('message.product_Tip5') as string });
return;
}
if (parseInt(this.form.orderAmount) <= parseInt(this.form.scanAmount)) {
uni.showToast({ icon: 'none', title: this.$t('message.product_Tip6') as string });
return;
}
let list = [
{
order3: this.form.orderNo,
productCode: this.form.productCode,
productDescZh: this.form.productDescZh,
barCode: this.form.barCode,
dockCode: this.form.dockCode,
dockName: this.form.dockName,
orderType: 3,
type: 0,
keepBy: session.loginName as string,
loginName: session.loginName as string,
},
];
if (valid) {
const res = await this.model.tluSubmit(list);
console.log('fanhui ', res);
// if (res.barcode) {
// // this.materialList.push(res);
// this.form.scanAmount = res.scanAmount;
// }
if (this.materialList.length == 0) {
await this.materialList.push(res);
this.form.scanAmount += 1;
this.$table.onCheckAllTap();
} else {
let flag = 0;
for (let i = 0; i < this.materialList.length; i++) {
console.log('11111', this.materialList[i]);
if (this.form.barCode == this.materialList[i].barcode) {
flag = 1;
break;
}
}
if (flag == 0) {
await this.$table.onCheckAllTap();
await this.materialList.push(res);
this.form.scanAmount += 1;
this.$table.onCheckAllTap();
} else {
uni.showToast({ icon: 'none', title: this.$t('message.product_Tip7') as string });
}
}
}
});
const item = {
...this.form,
barCode: String(''),
};
this.firstFocus = false;
setTimeout(() => {
this.form = item;
this.firstFocus = true;
}, 0);
}
onOk() {
// if (this.selectMaterielList.length == 0) {
// uni.showToast({ icon: 'none', title: this.$t('message.product_Tip2') as string });
// } else {
this.$form.validate(async (valid: boolean) => {
if (!valid) return;
let selctlist: any = [];
this.selectMaterielList.forEach((item: any, index: any) => {
// item.originWl = item.locCode;
selctlist[index] = {
barCode: item.barcode,
keepBy: session.loginName,
loginName: session.loginName,
order3: this.form.orderNo,
orderType: 3,
type: 0,
productCode: item.productCode,
productDescZh: item.productDescZh,
originWl: item.locCode,
dockCode: item.dockCode,
dockName: item.dockName,
whCode: item.whCode,
regionCode: item.regionCode,
};
});
await this.model.confirm(selctlist);
// this.$form.resetFields();
// // this.form.barCode = '';
// this.selectMaterielList = [];
console.log('aaaaaaa', this.model);
if (this.model.code == '1') {
this.materialList = [];
// this.model.materielList = [];
this.$table.onCheckAllTap();
uni.showToast({ icon: 'success', title: 'success' });
}
});
this.form.barCode = '';
this.form.productCode = '';
// this.form.orderNo = null;
this.form.scanAmount = '';
this.form.orderAmount = '';
this.form.productDescZh = '';
this.selectMaterielList = [];
this.$table.onEmpty();
}
// }
}
</script>
<style lang="scss" scoped>
.page-raw-returning {
background: #f2f2f2
linear-gradient(0deg, #f2f2f2 0%, #4a78ea 51%, #1753ea 100%) no-repeat;
background-size: 100% 600rpx;
padding: 118rpx 30rpx 162rpx;
min-height: 100%;
.header {
position: fixed;
top: 36rpx;
left: 0;
right: 0;
z-index: 99;
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;
}
}
.form {
background-color: #fff;
padding: 40rpx;
border-radius: 10rpx;
box-shadow: 0 0 20rpx 0 rgba(128, 128, 128, 0.2);
.u-form-item {
padding: 30rpx 0;
line-height: 35rpx;
}
}
.bottom-bar {
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 99;
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.button-bar {
}
}
</style>

@ -0,0 +1,122 @@
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.stoOutbound',
})
export class ReturningModule extends VuexModule {
/**
*
*/
returningTypeList: any[] = [];
/**
*
*/
materielList: any[] = [];
//条码扫描的返回的结果
oneMaterielDetail: any = {};
/**
*
*/
orderInInfo: OrderInInfo = new OrderInInfo();
//记账按钮的code码
code = '';
/**
*
*/
@MutationAction
async queryReturningTypeList() {
const list: [] = await http.post(url.outbound.stoOutbound.yuetaiType, {
factoryCode: session.factoryCode,
whCode: session.warehouseCode,
loginName: session.loginName,
});
const returningTypeList = list.map((item: any) => ({
label: item.dockName,
value: item.dockCode,
}));
return { returningTypeList };
}
/**
*
* @param orderNo
*/
@MutationAction
async queryOrderInInfo(stoNo: string) {
const result = await http.post(url.outbound.stoOutbound.info, {
stoNo,
deleteFlag: 2,
finalState: 3,
loginName: session.loginName,
});
let stoAmount = 0;
result.data.records.forEach((item: any) => {
stoAmount += item.orderAmount;
});
const materielList = result.data.records.map((item: any) => ({
label: item.materialCode,
value: item.stoItem,
...item,
}));
console.log('materielList', materielList);
if (result.data.records[0]) {
result.data.records[0].stoAmount = stoAmount;
}
const orderInInfo = result.data.records[0] || {};
return { orderInInfo, materielList };
}
/**
*
*/
@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 };
}
}
export default getModule(ReturningModule);

@ -0,0 +1,138 @@
<template>
<view class="page-raw-warehouse">
<view class="header">
<view class="left">
<u-icon class="icon" name="arrow-left" @click="toPage(page.raw.index)" />
</view>
<view class="title">{{ $t('message.RowWarehouse') }}</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="
uni.navigateTo({
url: item.href,
})
"
>
<u-icon size="80" :name="item.iconClass"></u-icon>
<text class="name">
{{
session.lang == 'en'
? index + 1 + ' ' + item.engResourceName
: index + 1 + ' ' + item.resourceName
}}</text
>
</u-button>
</u-col>-->
<u-col :span="12">
<u-button @click="toPage(page.raw.commission.entrant.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>
<text class="name">1.{{ '委外入库' }}</text>
</u-button>
</u-col>
<u-col :span="12">
<u-button @click="toPage(page.raw.commission.goOut.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>
<text class="name">2.{{ '委外出库' }}</text>
</u-button>
</u-col>
<!--
<u-col :span="12">
<u-button @click="toPage(page.raw.warehouse.rowScrap.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>
<text class="name">2.{{ $t('message.RowScrap') }}</text>
</u-button>
</u-col>
<u-col :span="12">
<u-button @click="toPage(page.raw.warehouse.rowCollect.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>
<text class="name">3.{{ $t('message.RowCollectionAndBorrowing') }}</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 RawAppointment extends BasePage {
childData: any;
onLoad(option: { childData: any }) {
this.childData = option//JSON.parse(option.childData);
}
}
</script>
<style lang="scss" scoped>
.page-raw-warehouse {
background-color: #f4f7fc;
padding-top: 88rpx;
min-height: 100%;
.header {
position: fixed;
top: 36rpx;
left: 0;
right: 0;
z-index: 99;
display: flex;
background-color: #255cea;
height: 88rpx;
line-height: 88rpx;
color: #fff;
font-size: 34rpx;
font-weight: 500;
text-align: center;
box-shadow: 0 1rpx 5rpx #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>

@ -30,6 +30,12 @@
>
</u-button>
</u-col>
<u-col :span="12">
<u-button @click="toPage(page.raw.commission.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>
<text class="name">5.{{ '委外' }}</text>
</u-button>
</u-col>
<!-- <u-col :span="12">
<u-button @click="toPage(page.raw.ingoods.index)">
<u-icon size="80" name="/static/icons/icon-02.png"></u-icon>

@ -27,8 +27,12 @@
>
</u-button>
</u-col>
<<<<<<< HEAD
<u-button @click="DNReceiving">DN</u-button>
<u-button @click="POReceiving">PO</u-button>
=======
>>>>>>> 57fbc39721f016bc5ee6b99c82721d1cb9433b00
<!-- <u-col :span="12">
<u-button @click="toPage(page.raw.ingoods.poReceipt.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>

@ -27,12 +27,13 @@
>
</u-button>
</u-col>
<!-- <u-col :span="12">
<u-button @click="toPage(page.raw.warehouse.rowTransfer.index)">
<u-col :span="12">
<u-button @click="toPage(page.raw.warehouse.rowInventory.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>
<text class="name">1.{{ $t('message.RowRelocation') }}</text>
<text class="name">4.{{ '原材料盘点' }}</text>
</u-button>
</u-col>
<!--
<u-col :span="12">
<u-button @click="toPage(page.raw.warehouse.rowScrap.index)">
<u-icon size="80" name="/static/icons/icon-14.png"></u-icon>

@ -0,0 +1,99 @@
/**
*
*/
import vm from '@/main';
export const headers = [
{
label: vm.$t('message.po_MaterielNo'),
key: 'materialCode',
},
{
label: vm.$t('message.po_MaterielDes'),
key: 'materialDesc',
width: 350,
},
{
label: vm.$t('message.po_DemandQuantity'),
key: 'requestAmount',
},
{
label: vm.$t('message.po_ActualQuantity'),
key: 'receiptAmount',
},
// {
// label: vm.$t('message.po_RemainingQuantity'),
// key: 'splitAmount',
// },
{
label: vm.$t('message.po_Location'),
key: 'location',
},
// {
// label: '物料详情',
// key: 'materialDesc',
// },
// {
// label: '收货数量',
// key: 'receiptAmount',
// },
// {
// label: '发货数量',
// key: 'requestAmount',
// },
// {
// label: '过账信息',
// key: 'accountingMessage',
// },
// {
// label: '应',
// key: 'y',
// },
// {
// label: '过账状态',
// key: 'accountingStatus',
// },
// {
// label: '采购订单号',
// key: 'poNo',
// },
// {
// label: '行号',
// key: 'poLine',
// },
// {
// label: '单位',
// key: 'dw',
// },
// {
// label: 'sap库存地点',
// key: 'kw',
// },
// {
// label: 'ID',
// key: 'rawOrderInId',
// },
// {
// label: '工厂',
// key: 'factoryCodeSap',
// },
// {
// label: '质检状态',
// key: 'qualityStatus',
// },
// {
// label: '供应商',
// key: 'supplyCode',
// },
// {
// label: '采购组',
// key: 'buyerGroup',
// },
// {
// label: '工位',
// key: 'sendSpot',
// },
// {
// label: 'mrp',
// key: 'mrpCode',
// },
];

@ -0,0 +1,134 @@
<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">看单明细未通过明细</view>
<view class="right"></view>
</view>
<view class="table-wrapper">
<wyb-table
class="table"
ref="table"
width="100%"
enable-check="multiple"
show-left-and-right-border
:headers="headers"
:contents="model.orderInInfoListEx"
:show-vert-border="false"
></wyb-table>
</view>
<view class="bottom-bar">
<div class="extra">
<u-row class="bottom-info">
<u-col :span="3">{{ model.orderInInfoListEx.length }}</u-col>
<u-col :span="2"></u-col>
<u-col :span="4"></u-col>
<u-col :span="3"></u-col>
</u-row>
</div>
<div class="container">
<u-row>
<u-col :span="3"></u-col>
<u-col :span="3"></u-col>
<u-col :span="3"></u-col>
<u-col :span="3">
<u-button @click="uni.navigateBack()"></u-button>
</u-col>
</u-row>
</div>
</view>
</view>
</template>
<script lang="ts">
import { Component } from 'vue-property-decorator';
import { BasePage } from '@/components/base/page';
import model from './model';
import { headers } from './config';
@Component
export default class RawReceiptDetailEx extends BasePage {
/**
* 页面Module
*/
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;
.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;
}
.bottom-bar {
z-index: 21;
position: fixed;
bottom: 0;
left: 0;
right: 0;
.container {
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.extra {
background-color: #fff;
height: 72rpx;
line-height: 72rpx;
margin: 5px;
padding: 0 10px;
border-radius: 5px;
}
}
}
</style>

@ -0,0 +1,317 @@
<template>
<view class="page-receipt-detail">
<view class="header">
<view class="left">
<u-icon class="icon" name="arrow-left" @click="gohome" />
</view>
<view class="title">{{ $t("message.dn_Detailed") }}</view>
<view class="right"></view>
</view>
<view class="table-wrapper">
<wyb-table
class="table"
ref="table"
width="100%"
enable-check="single"
show-left-and-right-border
:headers="headers"
:contents="model.orderInInfoList"
:show-vert-border="false"
></wyb-table>
</view>
<view class="bottom-bar">
<!-- <div>
<u-button type="primary" class="appoint" size="medium" @click="appoint"
>指定库位</u-button
>
</div> -->
<div class="container">
<u-row>
<u-col :span="3">
<u-button
type="warning"
@click="model.checkAllOrderInInfoList(!model.isCheckedAll)"
>
{{
model.isCheckedAll
? this.$t("message.po_noSelectAll")
: this.$t("message.po_SelectAll")
}}
</u-button>
</u-col>
<u-col :span="3">
<u-button type="primary" class="appoint" @click="appoint">{{
$t("message.Pi_distribution")
}}</u-button>
</u-col>
<u-col :span="3">
<u-button
type="success"
:loading="$wait.is('*submitOrderInEnter')"
@click="onSubmit"
>
{{ $t("message.po_Submit") }}
</u-button>
</u-col>
<u-col :span="3">
<u-button type="error" @click="gohome">{{
$t("message.po_Return")
}}</u-button>
</u-col>
</u-row>
</div>
</view>
</view>
</template>
<script lang="ts">
// inventory
import { Component } from "vue-property-decorator";
import { BasePage } from "@/components/base/page";
import model from "./model";
import { headers } from "./config";
import jPicker from "@/components/J-Picker/jPicker.vue";
import { session } from "@/store/modules/session";
import { truncate } from "lodash";
// @Component
@Component({
components: {
jPicker,
},
})
export default class RawReceiptDetail extends BasePage {
/**
* 页面Module
*/
model = model;
factoryCode = session.factoryCode;
locationCode = "";
/**
* 实际数量
*/
number = "";
/**
* 表头
*/
headers = headers;
dnNo = "";
onShow() {
this.model.queryLocation();
let ant: any = JSON.parse(sessionStorage.getItem("material") as string);
let index: any = JSON.parse(sessionStorage.getItem("index") as string);
this.model.orderInInfoList[index] = ant;
this.dnNo = JSON.parse(sessionStorage.getItem("dnNo") as string);
sessionStorage.removeItem("material");
sessionStorage.removeItem("index");
}
gohome() {
this.toPage(this.page.raw.ingoods.dnReceipt.index);
sessionStorage.removeItem("material");
sessionStorage.removeItem("index");
sessionStorage.removeItem("dnNo");
}
bookTypeChange(e: any) {
this.locationCode = e.pickerName.value;
}
/**
* 逐条修改
*/
changeNumber() {
if (!this.model.hasChecked) {
uni.showToast({
icon: "none",
title: this.$t("message.dn_Select") as string,
});
return;
}
//
this.model.orderInInfoList.forEach((item: any) => {
if (item.checked) {
if (this.locationCode) {
item.location = this.locationCode;
}
if (this.number > item.requestAmount) {
uni.showToast({
icon: "none",
title: this.$t("message.dn_Tip") as string,
});
return;
} else if (this.number == "") {
item.receiptAmount = item.requestAmount;
} else if (this.number < item.requestAmount) {
uni.showToast({
icon: "none",
title: this.$t("message.dn_Tip3") as string,
});
item.receiptAmount = this.number;
} else {
item.receiptAmount = this.number;
}
}
});
}
appoint() {
let selectStatus = model.orderInInfoList.map((item) => {
if (item.checked == true) {
return true;
} else {
return false;
}
});
let i: number = 0;
selectStatus.forEach((item) => {
if (item == true) {
i++;
}
});
if (i > 1) {
uni.showToast({
icon: "none",
title: "只能选择一个DN单" as string,
});
} else if (i == 0) {
uni.showToast({
icon: "none",
title: "请选择一个DN单" as string,
});
} else {
let mater: number = selectStatus.indexOf(true);
sessionStorage.setItem(
"mater",
JSON.stringify(model.orderInInfoList[mater]) as string
);
sessionStorage.setItem("index", JSON.stringify(mater) as string);
this.redirectTo(this.page.raw.ingoods.dnReceipt.idetailed);
}
}
/**
* 提交
*/
async onSubmit() {
let selectStatus = model.orderInInfoList.map((item) => {
if (item.checked == true) {
return true;
} else {
return false;
}
});
// let LocStatus = model.orderInInfoList.map((item) => {
// if (
// item.checked == true &&
// (item.location == null || item.location == "")
// ) {
// return true;
// } else {
// return false;
// }
// });
// if (LocStatus[0]) {
// uni.showToast({
// icon: "none",
// title: this.$t("message.Warehouse_Tip2") as string,
// });
// return;
// }
await this.model.submitOrderInEnter();
this.locationCode = "";
// setTimeout(() => {
// uni.navigateBack({ delta: 1 });
// }, 2000);
this.model.orderInInfo.carNo = "";
this.model.orderInInfo.bookingTime = "";
this.model.orderInInfo.supplyCode = "";
this.model.orderInInfo.poType = "";
this.model.orderInInfo.location = "";
this.model.queryOrderInInfo(this.dnNo);
// if (selectStatus[0]) {
// await this.model.submitOrderInEnter();
// this.locationCode = "";
// setTimeout(() => {
// uni.navigateBack({ delta: 1 });
// }, 2000);
// this.model.orderInInfo.carNo = "";
// this.model.orderInInfo.bookingTime = "";
// this.model.orderInInfo.supplyCode = "";
// this.model.orderInInfo.poType = "";
// this.model.orderInInfo.location = "";
// } else {
// uni.showToast({
// icon: "none",
// title: this.$t("message.product_Tip2") as string,
// });
// return;
// }
}
}
</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;
.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;
}
.bottom-bar {
z-index: 21;
position: fixed;
bottom: 0;
left: 0;
right: 0;
.container {
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.extra {
background-color: #fff;
margin: 5px;
border-radius: 5px;
padding: 0 10px;
}
}
}
</style>

@ -0,0 +1,390 @@
<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.product_Location") }}</view>
<view class="right"></view>
</view>
<div class="content">
<div class="content-item">
<div class="item-left">{{ $t("message.po_MaterielNo") }}</div>
<div class="item-right">{{ this.material.materialCode }}</div>
</div>
<div class="content-item">
<div class="item-left">{{ $t("message.po_MaterielDes") }}</div>
<div class="item-right">{{ this.material.materialDesc }}</div>
</div>
<div class="content-item">
<div class="item-left">{{ $t("message.po_DemandQuantity") }}</div>
<div class="item-right">{{ this.material.requestAmount }}</div>
</div>
<div class="content-item">
<div class="item-left">{{ $t("message.po_ActualQuantity") }}</div>
<div class="item-right">{{ this.material.receiptAmount }}</div>
</div>
<div class="content-item">
<div class="item-left">{{ $t("message.po_Location") }}</div>
<div class="item-right">{{ this.material.location }}</div>
</div>
</div>
<div class="library">
<div class="title">{{ $t("message.product_Location") }}:</div>
<jPicker
sureColor="#ff0000"
@bindpicker="bookTypeChange"
showKey="value"
valKey="value"
:val="wlCode"
class="search"
:options="list"
/>
</div>
<div class="library-num">
<div class="title">{{ $t("message.dn_Number") }}:</div>
<input type="text" placeholder="请输入数量" v-model="number" />
<u-button type="primary" size="medium" class="confirm" @click="confirm">{{
$t("message.product_add")
}}</u-button>
</div>
<u-table class="library-table">
<u-tr class="u-tr">
<u-th class="u-th">{{ $t("message.product_Location") }}</u-th>
<u-th class="u-th">{{ $t("message.product_Number") }}</u-th>
<u-th class="u-th">{{ $t("message.operation") }}</u-th>
</u-tr>
<u-tr class="u-tr" v-for="(item, index) in LocationList" :key="index">
<u-td class="u-td">{{ item.value.value }}</u-td>
<u-td class="u-td">{{ item.num }}</u-td>
<u-td class="u-td">
<div class="u-td" @click="deleteItem(index)">
{{ $t("message.product_Delete") }}
</div>
</u-td>
</u-tr>
</u-table>
<view class="bottom-bar">
<div class="extra">
<u-row class="bottom-info">
<u-button type="primary" class="main" @click="Reservoir">{{
$t("message.product_Confirm")
}}</u-button>
<u-col :span="2" v-if="factoryCode == '6662'">
{ {$t('message.product_Location')}}
</u-col>
</u-row>
</div>
</view>
</view>
</template>
<script lang="ts">
import { Component } from "vue-property-decorator";
import { BasePage } from "@/components/base/page";
import model from "./model";
import { headers } from "./config";
import jPicker from "@/components/J-Picker/jPicker.vue";
import { session } from "@/store/modules/session";
import combox from "@/components/J-Picker/jPicker.vue";
import { forEach } from "lodash";
// @Component
@Component({
components: {
jPicker,
combox,
},
})
export default class RawReceiptDetail extends BasePage {
/**
* 页面Module
*/
model = model;
factoryCode = session.factoryCode;
locationCode = "";
candidates = ["库位1", "库位2", "库位3"];
/**
* 实际数量
*/
number = "";
wlCode: any = "";
material = <any>{};
list: any = [];
LocationList: any = [];
documentNo = "";
/**
* 表头
*/
headers = headers;
async onReady() {
this.model.queryLocation();
let means: any = JSON.parse(
localStorage.getItem("__GWMS_APP_STATE_DATA__") as any
);
let user: any = session.user;
let sendSpot = JSON.parse(localStorage.getItem("sendSpot") as any);
let content = {
loginName: means.session.user.loginName,
sendSpot: sendSpot,
factoryCode: means.session.user.factoryCode,
workArea: user.list[0].workareaCode,
};
let res: any = await this.model.queryByFactoryCodeAndWorkAreaCode(content);
res.forEach((item: any) => {
let pickerName: any = {};
pickerName.label = item.locationCode;
pickerName.value = item.locationCode + "(" + item.sendSpot + ")";
pickerName.sendSpot = item.sendSpot;
this.list.push(pickerName);
});
let ant: any = sessionStorage.getItem("mater");
this.material = JSON.parse(ant);
this.number = this.material.requestAmount;
sessionStorage.removeItem("mater");
if (this.material.hasOwnProperty("wllist")) {
this.material.wllist.forEach((item: any) => {
let arr: object = {
value: item.wlCode,
};
let obj: any = {
value: arr,
num: item.receiptAmount,
};
this.LocationList.push(obj as never);
});
}
}
confirm() {
if (this.wlCode == "" || this.number == "") {
uni.showToast({
icon: "none",
title: "请输入正确的库位和数量",
});
return;
}
if (parseFloat(this.number) <= 0) {
uni.showToast({
icon: "none",
title: "请输入正确的库位和数量",
});
return;
}
if (this.LocationList.length != 0) {
this.LocationList.forEach((item: any) => {
if (item.value.sendSpot != this.wlCode.sendSpot) {
uni.showToast({
icon: "none",
title: "请重新选择库位",
});
return;
}
if (item.value.sendSpot == this.wlCode.sendSpot) {
let num: number = 0;
this.LocationList.forEach((item: any) => {
num += parseFloat(item.num);
});
num += parseFloat(this.number);
if (num > parseFloat(this.material.requestAmount)) {
uni.showToast({
icon: "none",
title: "实际数量不能大于需求数量",
});
return;
}
let arr: object = {
value: this.wlCode,
num: this.number,
};
this.LocationList.push(arr as never);
this.material.receiptAmount = num;
this.number = "";
return;
}
});
}
if (this.LocationList.length == 0) {
if (this.number > this.material.requestAmount) {
uni.showToast({
icon: "none",
title: "实际数量不能大于需求数量",
});
return;
}
let arr: object = {
value: this.wlCode,
num: this.number,
};
this.LocationList.push(arr as never);
this.material.receiptAmount = this.number;
this.number = "";
return;
}
}
deleteItem(index: any) {
this.LocationList.splice(index, 1);
}
bookTypeChange(e: any) {
this.wlCode = e.pickerName;
}
Reservoir() {
let wllist: Array<string> = [];
let requestAmountNum = 0;
this.LocationList.forEach((item: any) => {
let objString = JSON.stringify(this.material);
let TEM = JSON.parse(objString);
TEM.wlCode = item.value.label;
TEM.receiptAmount = item.num;
wllist.push(TEM);
let pras = parseInt(item.num);
requestAmountNum += pras;
});
this.material.wllist = null;
this.material.wllist = wllist;
this.material.receiptAmount = requestAmountNum;
sessionStorage.setItem("material", JSON.stringify(this.material));
this.redirectTo(this.page.raw.ingoods.dnReceipt.detail);
}
}
</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;
.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;
}
}
.content {
width: 100%;
height: 500rpx;
.content-item {
width: 100%;
height: 100rpx;
display: flex;
text-align: center;
line-height: 100rpx;
background-color: white;
.item-left {
width: 30%;
}
.item-right {
width: 70%;
}
}
}
.library {
height: 60rpx;
position: relative;
padding-bottom: 10rpx;
.search {
position: absolute;
width: 80%;
right: 38rpx;
top: 15rpx;
height: 60rpx;
background-color: white;
}
.title {
width: 20%;
height: 100%;
text-align: left;
position: absolute;
line-height: 50rpx;
top: 15rpx;
left: 0;
}
}
.library-num {
position: relative;
margin-top: 15rpx;
.title {
width: 100rpx;
height: 100%;
line-height: 50rpx;
}
input {
display: block;
width: 40%;
padding: 10rpx;
position: absolute;
left: 100rpx;
top: 0;
background-color: white;
}
.confirm {
position: absolute;
top: 0;
right: 20rpx;
margin-left: 30rpx;
}
}
.library-table {
margin-top: 30rpx;
}
.table-wrapper {
background-color: #fff;
}
.form {
background-color: #fff;
padding: 40rpx;
border-radius: 10rpx;
}
.bottom-bar {
z-index: 21;
position: fixed;
bottom: 0;
left: 0;
right: 0;
.container {
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.extra {
margin: 5px;
border-radius: 5px;
padding: 0 10px;
.main {
margin-right: 0;
}
}
}
}
</style>

@ -0,0 +1,204 @@
<template>
<view class="page-raw-receipt">
<view
class="header"
:style="{ backgroundColor: `rgba(23, 83, 234, ${scrollTop / 100})` }"
>
<view class="left">
<u-icon class="icon" name="arrow-left" @click="index" />
</view>
<view class="title">{{ $t("message.raw_Inventory") }}</view>
<view class="right"></view>
</view>
<u-form class="form" ref="form" :model="form" label-width="180rpx">
<u-form-item
:required="true"
:label="this.$t('message.InventoryOrderNo')"
prop="documentNo"
>
<u-search
:placeholder="this.$t('message.InventoryPleaseScan')"
v-model="form.documentNo"
@search="model.queryOrderInInfo"
:show-action="false"
></u-search>
</u-form-item>
<u-form-item :label="this.$t('message.InventoryMaterielNo')">
<u-input
v-model="model.orderInInfo.carNo"
:placeholder="this.$t('message.po_PleaseInput')"
/>
</u-form-item>
<u-form-item :label="this.$t('message.InventoryMateriel')">
<u-input
v-model="model.orderInInfo.bookingTime"
:placeholder="this.$t('message.po_PleaseInput')"
/>
</u-form-item>
<u-form-item :label="this.$t('message.InventoryTotalNumber')">
<u-input
v-model="model.orderInInfo.supplyCode"
:placeholder="this.$t('message.po_PleaseInput')"
/>
</u-form-item>
</u-form>
<view class="bottom-bar">
<u-row class="button-bar">
<u-col :span="6">
<u-button type="primary" @click="onSubmit">{{
$t("message.workArea_Confirm")
}}</u-button>
</u-col>
<u-col :span="6">
<u-button type="error" @click="back">{{
$t("message.po_Return")
}}</u-button>
</u-col>
</u-row>
</view>
</view>
</template>
<script lang="ts">
import { Component, Ref } from "vue-property-decorator";
import { BasePage } from "@/components/base/page";
import { VForm, VFormRules } from "vue/types/form";
import model from "./model";
interface OptionType {
label: string;
value: string;
}
@Component
export default class dnReceiptDom extends BasePage {
/**
* 表单引用
*/
@Ref("form") readonly $form!: VForm;
/**
* 页面Module
*/
model = model;
index() {
this.toPage(this.page.raw.index);
}
/**
* 表单数据
*/
form = {
documentNo: null,
cboPlace: {} as OptionType,
};
cboPlaceSelect = false;
rules: VFormRules<any> = {
documentNo: [
{ required: true, message: this.$t("message.dn_PleaseScan") as string },
],
// cboPlace: [{ required: true, message: this.$t('message.Warehouse_Tip10') as string }],
};
value = "";
show = false;
// onReadyonLoad
onReady() {
this.$form.setRules(this.rules);
this.model.queryLocation();
//
this.$form.resetFields();
this.model.orderInInfo.carNo = "";
this.model.orderInInfo.bookingTime = "";
this.model.orderInInfo.supplyCode = "";
this.model.orderInInfo.poType = "";
this.model.orderInInfo.location = "";
}
back() {
uni.navigateBack({ delta: 1 });
}
onSubmit() {
this.$form.validate((valid: boolean) => {
if (!valid) return;
// if (!this.model.hasDnInfo) {
// uni.showToast({
// icon: 'none',
// title: this.$t('message.dn_PleaseScan') as string,
// });
// return;
// }
sessionStorage.setItem(
"dnNo",
JSON.stringify(this.form.documentNo) as any
);
this.toPage(this.page.raw.ingoods.dnReceipt.detail);
});
}
}
</script>
<style lang="scss" scoped>
.page-raw-receipt {
background: #f2f2f2
linear-gradient(0deg, #f2f2f2 0%, #4a78ea 51%, #1753ea 100%) no-repeat;
background-size: 100% 600rpx;
padding: 118rpx 30rpx 162rpx;
min-height: 100%;
.header {
position: fixed;
top: 36rpx;
left: 0;
right: 0;
z-index: 99;
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;
}
}
.form {
background-color: #fff;
padding: 40rpx;
border-radius: 10rpx;
box-shadow: 0 0 20rpx 0 rgba(128, 128, 128, 0.2);
.u-form-item {
padding: 30rpx 0;
line-height: 35rpx;
}
}
.bottom-bar {
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 99;
background: #ffffff;
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
padding: 20rpx;
}
.button-bar {
}
}
</style>

@ -0,0 +1,213 @@
import {
Action,
getModule,
Module,
Mutation,
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 httpjson from "@/utils/location";
class OrderInInfo {
checked?: boolean;
dnNo?: string;
kw?: string;
userDefined10?: string;
orderStatus?: string;
carNo?: string;
bookingTime?: string;
supplyCode?: string;
poType?: string;
location?: string;
}
@Module({
namespaced: true,
dynamic: true,
store,
name: "raw.ingoods.dnReceipt",
})
export class ReceiptModule extends VuexModule {
sendSpot = "";
/**
* sap
*/
cboPlaceList = [];
/**
*
*/
dnNo = "";
/**
*
*/
orderInInfo: OrderInInfo = new OrderInInfo();
/**
*
*/
orderInInfoList: OrderInInfo[] = [];
/**
*
*/
orderInInfoListEx: OrderInInfo[] = [];
/**
*
*/
returningTypeList: any[] = [];
/**
*
*/
get hasDnInfo() {
return !!this.orderInInfo.dnNo;
}
/**
*
*/
get isCheckedAll() {
return !this.orderInInfoList.filter((_) => !_.checked).length;
}
/**
*
*/
get hasChecked() {
return this.orderInInfoList.filter((_) => _.checked).length > 0;
}
/**
*
* @param kw
*/
@Mutation
updateOrderInInfoListKw(kw: string) {
this.orderInInfoList = this.orderInInfoList.map((item) => {
item.kw = kw;
return item;
});
}
/**
*
* @param kw
*/
@Mutation
updateCheckedOrderInInfoListKw(kw: string) {
this.orderInInfoList = this.orderInInfoList.map((item) => {
if (item.checked) {
item.kw = kw;
}
return item;
});
}
/**
* /
*/
@Mutation
checkAllOrderInInfoList(checked: boolean) {
this.orderInInfoList = this.orderInInfoList.map((item) => {
item.checked = checked;
return item;
});
}
/**
*
*/
@MutationAction
async queryLocation() {
const result: any = await http.post(url.auth.query.location1, {
factoryCode: session.factoryCode,
loginName: session.loginName,
userDefined3: 1,
});
console.log("result", result);
const cboPlaceList = result.data.records.map((_: any) => ({
label: _.sendSpot,
value: _.sendSpot,
}));
return { cboPlaceList };
}
/**
*
* DN
* @param dnNo
*/
@MutationAction
async queryOrderInInfo(dnNo: string) {
const { list }: any = await http.post(url.material.DNorderin.info, {
dnNo,
factoryCode: session.factoryCode,
loginName: session.loginName,
});
const orderInInfo = list[0] || {};
const orderInInfoList = list.filter(
(_: OrderInInfo) => _.userDefined10 === "1"
);
const orderInInfoListEx = list.filter(
(_: OrderInInfo) => _.userDefined10 === "0"
);
// orderInInfoList.forEach((item: any) => {
// item.receiptAmount = item.requestAmount;
// });
localStorage.setItem("sendSpot", JSON.stringify(list[0].sendSpot) as any);
return { dnNo, orderInInfo, orderInInfoList, orderInInfoListEx };
}
/**
*
*/
@MutationAction
async submitOrderInEnter() {
const list = (this.state as any).orderInInfoList.map((item: any) => {
item.orderStatus = item.checked ? "2" : "1";
return item;
});
const result: any = await http.post(url.material.DNorderin.enter, {
dnNo: this.dnNo,
factoryCode: session.factoryCode,
loginName: session.loginName,
list,
});
uni.showToast({
icon: "none",
title: result.msg,
});
const orderInInfoList = result.list.sort(
(a: any, b: any) =>
Number(a.accountingStatus) - Number(b.accountingStatus)
);
return { orderInInfoList };
}
/**
*
*/
@Action({ commit: "updateCheckedOrderInInfoListKw" })
async changeOrderInLocation(kw: string) {
await http.post("/material/orderin/enter", {
warehouseCode: session.warehouseCode,
factoryCode: session.factoryCode,
loginName: session.loginName,
locationCode: kw,
});
return kw;
}
@Action({ commit: "updateCheckedOrderInInfoListKw" })
async queryByFactoryCodeAndWorkAreaCode(content: any) {
let res = await http.post(
"/wmspda/fg/queryByFactoryCodeAndWorkAreaCode",
content
);
return res;
}
}
export default getModule(ReceiptModule);

@ -139,7 +139,21 @@ export const page = {
index: "/pages/raw/warehouse/rowCollect/index",
details: "/pages/raw/warehouse/rowCollect/details",
},
rowInventory: {
index: "/pages/raw/warehouse/rowInventory/index",
},
},
commission:{
index: "/pages/raw/commission/index",
entrant:{
index: "/pages/raw/commission/entrant/index",
detail: "/pages/raw/commission/entrant/detail",
},
goOut:{
index: "/pages/raw/commission/goOut/index",
detail: "/pages/raw/commission/goOut/detail",
}
}
},
SemiProduct: {
index: "/pages/SemiProduct/index",

Loading…
Cancel
Save