作者 张晓杰

库存管理出入库修改、贸易库存入库修该改

... ... @@ -83,7 +83,7 @@ export const JeecgListMixin = {
this.ipagination.current = 1;
}
var params = this.getQueryParams();//查询条件
console.log('params========',params)
// console.log('params========',params)
this.loading = true;
getAction(this.url.list, params).then((res) => {
if (res.success) {
... ...
... ... @@ -5,18 +5,18 @@
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="品名">
<j-input placeholder="请输入品名" v-model="queryParam.productName"></j-input>
<a-form-item label="物料描述">
<j-input placeholder="请输入物料描述" v-model="queryParam.productName"></j-input>
</a-form-item>
</a-col>
<a-col :xl="4" :lg="5" :md="6" :sm="24">
<!-- <a-col :xl="4" :lg="5" :md="6" :sm="24">
<a-form-item label="采购性质">
<j-dict-select-tag placeholder="请选择采购性质" v-model="queryParam.buyingClassify" dictCode="buying_classify" />
</a-form-item>
</a-col>
</a-col> -->
<template v-if="toggleSearchStatus">
<a-col :xl="8" :lg="9" :md="10" :sm="24">
<a-form-item label="入库时间">
<a-form-item label="到货日期">
<j-date placeholder="请选择开始日期" class="query-group-cust" v-model="queryParam.operTime_begin"></j-date>
<span class="query-group-split-cust"></span>
<j-date placeholder="请选择结束日期" class="query-group-cust" v-model="queryParam.operTime_end"></j-date>
... ... @@ -52,21 +52,24 @@
<a-table ref="table" size="middle" :scroll="{ x: true }" bordered rowKey="id" :columns="columns"
:dataSource="dataSource" :pagination="ipagination" :loading="loading" class="j-table-force-nowrap"
@change="handleTableChange">
<template slot="htmlSlot" slot-scope="text">
<!-- <template slot="htmlSlot" slot-scope="text">
<div v-html="text"></div>
</template>
<template slot="imgSlot" slot-scope="text, record">
</template> -->
<!-- <template slot="imgSlot" slot-scope="text, record">
<span v-if="!text" style="font-size: 12px; font-style: italic;">无图片</span>
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt=""
style="max-width: 80px; font-size: 12px; font-style: italic" />
</template>
<template slot="fileSlot" slot-scope="text">
</template> -->
<!-- <template slot="fileSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px; font-style: italic;">无文件</span>
<a-button v-else :ghost="true" type="primary" icon="download" size="small" @click="downloadFile(text)">
下载
</a-button>
</template> -->
<template slot="buyingClassifySlot" slot-scope="text, record">
<span v-if="text == 'M'">加工</span>
<span v-else>采购</span>
</template>
<span v-if="deleteFlg" slot="action" slot-scope="text, record">
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
... ... @@ -251,7 +254,7 @@ export default {
// 表头
columns: [
{
title: '#',
title: '序号',
dataIndex: '',
key: 'rowIndex',
width: 60,
... ... @@ -261,43 +264,50 @@ export default {
},
},
{
title: '零件编号',
title:'入库储位',
align:"center",
dataIndex: 'storageLocation',
width:80
},
{
title: '物料编码',
align: 'center',
dataIndex: 'partNumber',
},
{
title: '品名',
title: '物料描述',
align: 'center',
dataIndex: 'productName',
},
{
title: '规格',
title: '到货数量',
align: 'center',
dataIndex: 'spec',
dataIndex: 'operNumber',
},
{
title: '型号',
title: '到货厂家',
align: 'center',
dataIndex: 'type',
dataIndex: 'supplierName',
},
{
title: '采购性质',
title: '到货日期',
align: 'center',
dataIndex: 'buyingClassify',
sorter: true,
dataIndex: 'operTime',
customRender: function (text) {
return !text ? '' : text.length > 10 ? text.substr(0, 10) : text
},
},
{
title: '数量',
title: '合格证',
align: 'center',
dataIndex: 'operNumber',
dataIndex: 'certificate',
scopedSlots: {customRender: 'fileSlot'}
},
{
title: '入库时间',
title: '备注',
align: 'center',
sorter: true,
dataIndex: 'operTime',
customRender: function (text) {
return !text ? '' : text.length > 10 ? text.substr(0, 10) : text
},
dataIndex: 'remark',
},
{
title: '操作',
... ...
... ... @@ -5,8 +5,8 @@
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="品名">
<j-input placeholder="请输入品名" v-model="queryParam.productName"></j-input>
<a-form-item label="物料描述">
<j-input placeholder="请输入物料描述" v-model="queryParam.productName"></j-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
... ... @@ -14,14 +14,14 @@
<j-input placeholder="请输入工作令" v-model="queryParam.workOrder"></j-input>
</a-form-item>
</a-col>
<a-col :xl="4" :lg="5" :md="6" :sm="24">
<!-- <a-col :xl="4" :lg="5" :md="6" :sm="24">
<a-form-item label="采购性质">
<j-dict-select-tag placeholder="请选择采购性质" v-model="queryParam.buyingClassify" dictCode="buying_classify" />
</a-form-item>
</a-col>
</a-col> -->
<template v-if="toggleSearchStatus">
<a-col :xl="8" :lg="9" :md="10" :sm="24">
<a-form-item label="出库时间">
<a-form-item label="出库日期">
<j-date placeholder="请选择开始日期" class="query-group-cust" v-model="queryParam.operTime_begin"></j-date>
<span class="query-group-split-cust"></span>
<j-date placeholder="请选择结束日期" class="query-group-cust" v-model="queryParam.operTime_end"></j-date>
... ... @@ -226,63 +226,49 @@ export default {
}
},
{
title: '零件编号',
align: "center",
dataIndex: 'partNumber'
},
{
title: '出库人',
align: "center",
dataIndex: 'createBy'
},
{
title: '领料人',
title: '出库日期',
align: "center",
dataIndex: 'ling'
sorter: true,
dataIndex: 'operTime',
customRender: function (text) {
return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text)
}
},
{
title: '领料环节',
title: '物料编码',
align: "center",
dataIndex: 'lingSysOrgCode'
dataIndex: 'partNumber'
},
{
title: '品名',
title: '物料描述',
align: "center",
dataIndex: 'productName'
},
{
title: '规格',
title: '出货数量',
align: "center",
dataIndex: 'spec'
},
{
title: '型号',
align: "center",
dataIndex: 'type'
dataIndex: 'operNumber'
},
{
title: '采购性质',
title: '出货分公司',
align: "center",
dataIndex: 'buyingClassify'
dataIndex: 'company'
},
{
title: '数量',
title: '出货工作令',
align: "center",
dataIndex: 'operNumber'
dataIndex: 'workOrder'
},
{
title: '工作令',
title: '出货厂家',
align: "center",
dataIndex: 'workOrder'
dataIndex: 'shippingManufacturer'
},
{
title: '出库时间',
title: '出货储位',
align: "center",
sorter: true,
dataIndex: 'operTime',
customRender: function (text) {
return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text)
}
dataIndex: 'storageLocation'
},
{
title: '操作',
... ... @@ -292,6 +278,41 @@ export default {
width: 147,
scopedSlots: { customRender: 'action' }
}
// {
// title: '规格',
// align: "center",
// dataIndex: 'spec'
// },
// {
// title: '型号',
// align: "center",
// dataIndex: 'type'
// },
// {
// title: '采购性质',
// align: "center",
// dataIndex: 'buyingClassify'
// },
// {
// title: '工作令',
// align: "center",
// dataIndex: 'workOrder'
// },
// {
// title: '出库人',
// align: "center",
// dataIndex: 'createBy'
// },
// {
// title: '领料人',
// align: "center",
// dataIndex: 'ling'
// },
// {
// title: '领料环节',
// align: "center",
// dataIndex: 'lingSysOrgCode'
// },
],
url: {
list: "/depot/tblDepot/outList",
... ... @@ -328,13 +349,6 @@ export default {
callRobotMoveShowDialog: false,
cabinOptions:[],
pointOptions:[],
// templateIdOptions:[
// {id:"dock_cabin_to_move_and_lift_down",value:"调度底盘去某个上仓举起并移动到另外点位放下"},
// {id:"docking_cabin_and_docking_down",value:"调度底盘移动上舱举起并移动到另外一个舱位放下"},
// {id:"docking_cabin_and_move_target",value:"调度底盘移动上舱举起并移动到目标点"},
// {id:"move_target_and_lift_down",value:"托举上舱移动到目的地并且放下上舱"},
// {id:"dock_cabin_and_move_target_with_wait_action",value:"让某舱到某目的地"}
// ],
templateIdOptions:[
{id:"docking_cabin_and_move_target",value:"上舱移动到目的地"},
{id:"dock_cabin_to_move_and_lift_down",value:"上舱移动到目的地并放下上舱"},
... ... @@ -387,9 +401,6 @@ export default {
let method = ''
httpurl += this.url.cancleRobotMove
method = 'post'
// console.log(this.model)
// console.log(httpurl)
// return
httpAction(httpurl, this.model, method)
.then((res) => {
if (res.success) {
... ...
... ... @@ -5,28 +5,33 @@
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="品名">
<j-input placeholder="请输入品名" v-model="queryParam.productName"></j-input>
<a-form-item label="储位">
<j-input placeholder="请输入储位" v-model="queryParam.storageLocation"></j-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="物料描述">
<j-input placeholder="请输入物料描述" v-model="queryParam.materialDescription"></j-input>
</a-form-item>
</a-col>
<!-- <a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="采购性质">
<j-dict-select-tag placeholder="请选择采购性质" v-model="queryParam.buyingClassify" dictCode="buying_classify" />
</a-form-item>
</a-col>
</a-col> -->
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
<a @click="handleToggleSearch" style="margin-left: 8px">
<!-- <a @click="handleToggleSearch" style="margin-left: 8px">
{{ toggleSearchStatus ? '收起' : '展开' }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'" />
</a>
</a> -->
</span>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-button type="primary" icon="download" @click="handleExportXls('库存报表' + parseTime(new Date().getTime(),'{y}-{m}-{d} {h}:{i}:{s}'))" style="margin-right: 10px;">导出</a-button>
<a-button type="primary" icon="edit" @click="priceVisible = true">安全库存设置</a-button>
</a-col>
</a-row>
</a-form>
... ... @@ -35,6 +40,18 @@
<!-- 操作按钮区域 -->
<div class="table-operator">
<a-button type="primary" icon="edit" @click="priceVisible = true">安全库存设置</a-button>
<!-- <a-upload
name="file"
:showUploadList="false"
:multiple="false"
:headers="tokenHeader"
:action="importExcelUrl"
@change="handleImportExcel"
>
<a-button type="primary" icon="import">导入</a-button>
</a-upload> -->
<a-button type="primary" icon="download" @click="handleExportXls('库存报表' + parseTime(new Date().getTime(),'{y}-{m}-{d} {h}:{i}:{s}'))" style="margin-right: 10px;">导出</a-button>
<!-- <a-button type="primary" icon="download" @click="handleExportXls('tbl_inventory')">导出</a-button> -->
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrlBoh" @change="handleImportExcel">
<a-button type="primary" icon="import">导入更新BOH</a-button>
... ... @@ -88,43 +105,40 @@
</span>
<span slot="action" slot-scope="text, record">
<a @click="handleDetail(record)">库存明细</a> &nbsp;
<a @click="updateBoh(record)">更新BOH</a>
<a @click="updateBoh(record)">更新BOH</a> &nbsp;
<a @click="updateSL(record)">更新储位</a>
</span>
</a-table>
</div>
<!-- <tbl-inventory-modal ref="modalForm" @ok="modalFormOk"></tbl-inventory-modal> -->
<view-depot-stock-modal ref="modalForm" @ok="modalFormOk"></view-depot-stock-modal>
<template v-if="priceVisible">
<safety-stock-edit :visible.sync="priceVisible"></safety-stock-edit>
</template>
<view-depot-stock-modal ref="modalForm" @ok="modalFormOk"></view-depot-stock-modal>
<j-modal
:title="title"
title="更新BOH"
:width="width"
:visible="visibleBoh"
switchFullscreen
@ok="handleOkBohInfo"
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
@cancel="handleCancelBoh"
cancelText="关闭">
<!-- :okButtonProps="{ class:{'jee-hidden': disableSubmit} }" -->
<a-spin :spinning="confirmLoading">
<j-form-container :disabled="disabled">
<j-form-container >
<a-form-model ref="form" :model="model" slot="detail">
<a-row>
<a-col :span="24">
<a-form-model-item label="编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="partNumber">
<a-input v-model="model.partNumber" placeholder="请输入编号" disabled="disabled"></a-input>
<a-form-model-item label="物料编码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="partNumber">
<a-input v-model="model.materialCode" placeholder="请输入物料编码" disabled="disabled"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="品名" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productName">
<a-input v-model="model.productName" placeholder="请输入品名" disabled="disabled" ></a-input>
<a-form-model-item label="物料描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productName">
<a-input v-model="model.materialDescription" placeholder="请输入物料描述" disabled="disabled" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<!-- <a-col :span="24">
<a-form-model-item label="规格" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="spec">
<a-input v-model="model.spec" placeholder="请输入规格" disabled="disabled" ></a-input>
</a-form-model-item>
... ... @@ -143,10 +157,10 @@
<a-form-model-item label="类别" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="meterialType">
<a-input v-model="model.meterialType" placeholder="请输入类别" disabled="disabled"></a-input>
</a-form-model-item>
</a-col>
</a-col> -->
<a-col :span="24">
<a-form-model-item label="当前库存量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="currentInventory">
<a-input-number v-model="model.currentInventory" placeholder="请输入当前库存量" style="width: 100%" disabled="disabled"/>
<a-form-model-item label="当前库存量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="actualInventory">
<a-input-number v-model="model.actualInventory" placeholder="请输入当前库存量" style="width: 100%" disabled="disabled"/>
</a-form-model-item>
</a-col>
<a-col :span="24">
... ... @@ -160,6 +174,50 @@
</a-spin>
</j-modal>
<j-modal
title="更新储位"
:width="width"
:visible="visibleSL"
switchFullscreen
@ok="handleOkSLInfo"
@cancel="handleCancelSL"
cancelText="关闭">
<!-- :okButtonProps="{ class:{'jee-hidden': disableSubmit} }" -->
<a-spin :spinning="confirmLoading">
<j-form-container>
<a-form-model ref="form" :model="model" slot="detail">
<a-row>
<a-col :span="24">
<a-form-model-item label="储位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="storageLocation">
<a-input v-model="model.storageLocation" placeholder="请输入储位"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="物料编码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialCode">
<a-input v-model="model.materialCode" placeholder="请输入编号" disabled="disabled"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="物料描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialDescription">
<a-input v-model="model.materialDescription" placeholder="请输入物料描述" disabled="disabled" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="实际库存量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="actualInventory">
<a-input-number v-model="model.actualInventory" placeholder="请输入实际库存量" style="width: 100%" disabled="disabled"/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="库存BOH" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="inventoryBoh">
<a-input-number v-model="model.inventoryBoh" placeholder="请输入库存BOH" style="width: 100%" disabled="disabled"/>
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</j-form-container>
</a-spin>
</j-modal>
</a-card>
</template>
... ... @@ -184,10 +242,15 @@
return {
confirmLoading: false,
description: 'tbl_inventory管理页面',
kcmxWidth: 1000,
visibleInfo:false,
storageLocation:'',
materialCode:'',
width:600,
// 表头
columns: [
{
title: '#',
title: '序号',
dataIndex: '',
key:'rowIndex',
width:60,
... ... @@ -197,55 +260,53 @@
}
},
{
title: '编号',
align: "center",
dataIndex: 'partNumber',
// customRender: (text, record) => {//根据状态判断字体
// console.log(this.safetyStock)
// }
},
{
title:'品名',
title:'储位',
align:"center",
dataIndex: 'productName'
dataIndex: 'storageLocation',
// width:100
},
{
title:'规格',
align:"center",
dataIndex: 'spec'
},
{
title:'型号',
align:"center",
dataIndex: 'type'
title: '物料编码',
align: "center",
dataIndex: 'materialCode',
// width:150
// customRender: (text, record) => {//根据状态判断字体
// console.log(this.safetyStock)
// }C
},
{
title:'采购性质',
title:'物料描述',
align:"center",
dataIndex: 'buyingClassify'
dataIndex: 'materialDescription',
// width:200
},
// {
// title:'厂商',
// align:"center",
// dataIndex: 'supplierName'
// },
{
title:'类别',
title:'单位',
align:"center",
dataIndex: 'meterialType',
scopedSlots: { customRender: 'meterialTypeSlot' },
dataIndex: 'measurementUnit'
},
{
title:'当前库存量',
title:'BOH',
align:"center",
dataIndex: 'currentInventory'
dataIndex: 'inventoryBoh'
},
{
title:'BOH',
title:'实际库存量',
align:"center",
dataIndex: 'inventoryBoh'
dataIndex: 'actualInventory',
// width:100
},
{
title: '操作',
dataIndex: 'action',
align:"center",
fixed:"right",
width:147,
width:200,
scopedSlots: { customRender: 'action' }
}
],
... ... @@ -256,7 +317,8 @@
exportXlsUrl: "/depot/tblInventory/exportXls",
importExcelUrl: "depot/tblInventory/importExcel",
importExcelUrlBoh:"depot/tblInventory/importExcelBoh",
updateBoh:"/depot/tblInventory/updateBoh"
updateBoh:"/depot/tblInventory/updateBoh",
updateSl:"/depot/tblInventory/updateSL"
},
dictOptions:{},
superFieldList:[],
... ... @@ -264,6 +326,7 @@
safetyStock: null,
model:{},
visibleBoh:false,
visibleSL:false,
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
... ... @@ -312,12 +375,28 @@
}
})
},
updateBoh(recode){
console.log("..............",recode)
handleInventoryInfo(record){
this.materialCode = record.materialCode;
this.storageLocation = record.storageLocation
this.visibleInfo = true;
},
handleCancelInfo(){
this.visibleInfo = false;
},
updateBoh(record){
this.model= {}
this.model = recode;
this.model = record;
console.log("..............",this.model)
this.visibleBoh = true;
},
updateSL(record){
this.model= {}
this.model = record;
console.log("..............",this.model)
this.visibleSL = true;
},
handleOkBohInfo(){
this.$refs.form.validate((valid) => {
if (valid){
... ... @@ -330,7 +409,8 @@
}
})
console.log("提交表单内容")
this.visibleBoh = false
// this.visibleBoh = false
this.handleCancelBoh()
}
})
},
... ... @@ -338,6 +418,27 @@
this.visibleBoh = false;
this.model = {}
},
handleOkSLInfo(){
this.$refs.form.validate((valid) => {
if (valid){
postAction(this.url.updateSl,this.model).then(res=>{
this.reSeach();
if (res.success){
this.$message.success("更新成功")
}else {
this.$message.error(res.message)
}
})
console.log("提交表单内容")
// this.visibleSl = false
this.handleCancelSL()
}
})
},
handleCancelSL(){
this.visibleSL = false;
this.model = {}
},
initDictConfig() {
},
getSuperFieldList() {
... ...
... ... @@ -4,8 +4,13 @@
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
<a-row>
<a-col :span="24">
<a-form-model-item label="编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="partNumber">
<a-input v-model="model.partNumber" placeholder="请输入编号" @blur="autoInput" @keyup.enter.native="autoInput"
<a-form-model-item label="入库储位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="storageLocation">
<a-input v-model="model.storageLocation" placeholder="请输入入库储位"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="物料编码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="partNumber">
<a-input v-model="model.partNumber" placeholder="请输入物料编码" @blur="autoInput" @keyup.enter.native="autoInput"
@input="inputMathen" >
</a-input>
<div class="select" v-if="isShow" :style="`height:${menuHeight}`" @mouseenter="flag = true"
... ... @@ -17,8 +22,8 @@
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="品名" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productName">
<a-input v-model="model.productName" placeholder="请输入品名" disabled></a-input>
<a-form-model-item label="物料描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productName">
<a-input v-model="model.productName" placeholder="请输入物料描述" disabled></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
... ... @@ -38,9 +43,14 @@
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operNumber">
<a-form-model-item label="单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="measurementUnit">
<a-input v-model="model.measurementUnit" placeholder="请输入单位" disabled></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="到货数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operNumber">
<a-input-number v-model="model.operNumber" :min="0" :max="9999" :precision="0" :formatter="limitNumber"
:parser="limitNumber" placeholder="请输入数量" style="width: 100%" />
:parser="limitNumber" placeholder="请输入到货数量" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
... ... @@ -48,6 +58,22 @@
<j-date placeholder="请选择入库时间" v-model="model.operTime" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="到货厂家" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplierName">
<a-input v-model="model.supplierName" placeholder="请输入到货厂家"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="合格证" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="remark">
<!-- <a-input v-model="model.certificate" placeholder="请输入合格证"></a-input> -->
<j-upload v-model="model.certificate" ></j-upload>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="remark">
<a-input v-model="model.remark" placeholder="请输入备注"></a-input>
</a-form-model-item>
</a-col>
<!-- <a-col :span="24">
<a-form-model-item label="选择机器人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="robotName">
<a-select size="small" v-model="model.robotName" placeholder="请选择机器人" allowClear>
... ... @@ -109,11 +135,12 @@ export default {
},
confirmLoading: false,
validatorRules: {
partNumber: [{ required: true, message: '请输入零件编号!' }],
productName: [{ required: true, message: '请输入品名!' }],
partNumber: [{ required: true, message: '请输入物料编码!' }],
productName: [{ required: true, message: '请输入物料描述!' }],
spec: [{ required: true, message: '请输入规格!' }],
type: [{ required: true, message: '请输入型号!' }],
buyingClassify: [{ required: true, message: '请输入采购性质!' }],
operTime: [{ required: true, message: '请输入入库时间!' }],
operNumber: [{ required: true, message: '请输入数量!' }],
robotName: [{ required: true, message: '请选择机器人!' }],
pointId: [{ required: true, message: '请选择目标点位!' }],
... ...
... ... @@ -3,7 +3,7 @@
<j-form-container :disabled="formDisabled">
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
<a-row>
<a-col :span="24">
<!-- <a-col :span="24">
<a-form-model-item label="领料人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="ling">
<a-input v-model="model.ling" placeholder="请输入领料人"></a-input>
</a-form-model-item>
... ... @@ -12,10 +12,10 @@
<a-form-model-item label="领料环节" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="lingSysOrgCode">
<a-input v-model="model.lingSysOrgCode" placeholder="请输入领料环节"></a-input>
</a-form-model-item>
</a-col>
</a-col> -->
<a-col :span="24">
<a-form-model-item label="编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="partNumber">
<a-input v-model="model.partNumber" placeholder="请输入编号" @blur="autoInput" @keyup.enter.native="autoInput"
<a-form-model-item label="物料编码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="partNumber">
<a-input v-model="model.partNumber" placeholder="请输入物料编码" @blur="autoInput" @keyup.enter.native="autoInput"
@input="inputMathen">
</a-input>
<div class="select" v-if="isShow" :style="`height:${menuHeight}`" @mouseenter="flag = true"
... ... @@ -27,8 +27,8 @@
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="品名" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productName">
<a-input v-model="model.productName" placeholder="请输入品名" disabled></a-input>
<a-form-model-item label="物料描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productName">
<a-input v-model="model.productName" placeholder="请输入物料描述" disabled></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
... ... @@ -48,14 +48,29 @@
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operNumber">
<a-form-model-item label="出货数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operNumber">
<a-input-number v-model="model.operNumber" :min="0" :max="9999" :precision="0" :formatter="limitNumber"
:parser="limitNumber" placeholder="请输入数量" style="width: 100%" />
:parser="limitNumber" placeholder="请输入出货数量" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24" >
<a-form-model-item label="出货分公司" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="company">
<a-input v-model="model.company" placeholder="请输入出货分公司"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24" >
<a-form-model-item label="出货工作令" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="workOrder">
<a-input v-model="model.workOrder" placeholder="请输入出货工作令"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24" >
<a-form-model-item label="出货厂家" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shippingManufacturer">
<a-input v-model="model.shippingManufacturer" placeholder="请输入出货厂家"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24" > <!-- v-if="workOrderFlg" -->
<a-form-model-item label="工作令" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="workOrder">
<a-input v-model="model.workOrder" placeholder="请输入工作令"></a-input>
<a-col :span="24" >
<a-form-model-item label="出货储位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="storageLocation">
<a-input v-model="model.storageLocation" placeholder="请输入出货储位"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
... ... @@ -292,6 +307,8 @@ export default {
this.model.spec = res.result.spec
this.model.type = res.result.type
this.model.buyingClassify = res.result.buyingClassify
this.model.storageLocation = res.result.storageLocation
// this.model.
this.model.depotType = '出库'
this.confirmLoading = false
this.isShow = false;
... ...
... ... @@ -50,6 +50,18 @@
<a-badge v-if="record.depotType === '出库'" :count="text" :overflowCount="Number.MAX_SAFE_INTEGER"/>
<a-badge v-else :count="text" :number-style="{ backgroundColor: '#52c41a' } " :overflowCount="Number.MAX_SAFE_INTEGER"/>
</template>
<template slot="depotTypeSlot" slot-scope="text,record">
<span v-if = "text == '出库'"><a-tag color="red">
出库
</a-tag></span>
<span v-if = "text == '入库'"><a-tag color="green">
入库
</a-tag></span>
<span v-if = "text == '更新'"><a-tag color="orange">
更新
</a-tag></span>
</template>
</a-table>
</a-spin>
</template>
... ... @@ -92,7 +104,8 @@
/* table加载状态 */
loading:false,
defaultQuery:{
partNumber:''
partNumber:'',
storageLocation:''
},
labelCol: {
xs: { span: 24 },
... ... @@ -111,7 +124,7 @@
// 表头
columns: [
{
title: '#',
title: '序号',
dataIndex: '',
key:'rowIndex',
width:60,
... ... @@ -121,16 +134,38 @@
}
},
{
title:'编号',
title:'储位',
align:"center",
dataIndex: 'storageLocation',
// width:100
},
{
title:'物料编码',
align:"center",
dataIndex: 'partNumber'
},
{
title:'品名',
title:'物料描述',
align:"center",
dataIndex: 'productName'
},
{
title:'数量',
align:"center",
dataIndex: 'operNumber',
scopedSlots: { customRender: 'numberSlot' }
},
{
title:'到货厂家',
align:"center",
dataIndex: 'supplierName'
},
{
title:'合格证',
align:"center",
dataIndex: 'certificate'
},
{
title:'入库/出库时间',
align:"center",
dataIndex: 'operTime'
... ... @@ -141,12 +176,6 @@
dataIndex: 'workOrder'
},
{
title:'数量',
align:"center",
dataIndex: 'operNumber',
scopedSlots: { customRender: 'numberSlot' }
},
{
title:'当前库存',
align:"center",
dataIndex: 'currentInventory',
... ... @@ -160,8 +189,13 @@
{
title:'状态',
align:"center",
dataIndex: 'depotType'
},
dataIndex: 'depotType',
scopedSlots: { customRender: 'depotTypeSlot' }
},{
title:'备注',
align:"center",
dataIndex: 'remark'
}
],
}
},
... ... @@ -188,8 +222,10 @@
this.edit(this.modelDefault);
},
edit (record) {
this.queryParam.partNumber = record.partNumber;
this.defaultQuery.partNumber = record.partNumber;
this.queryParam.partNumber = record.materialCode;
// this.queryParam.storageLocation=this.storageLocation;
this.defaultQuery.partNumber = record.materialCode;
// this.defaultQuery.storageLocation = record.storageLocation;
this.visible = true;
},
loadData() {
... ...
... ... @@ -23,7 +23,7 @@
data () {
return {
title:'',
width:1000,
width:1500,
visible: false,
disableSubmit: false
}
... ...
... ... @@ -36,14 +36,8 @@
<!-- 操作按钮区域 -->
<div class="table-operator">
<!-- <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
<a-button type="primary" icon="download" @click="handleExportXls('贸易库存表')">导出</a-button>
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button>
</a-upload> -->
<a-button @click="handleInventoryIn" type="primary" >入库记录</a-button>
<a-button @click="handleInventoryOut" type="primary" >出库记录</a-button>
<a-button @click="handleInventoryDefective" type="primary" >不良品库</a-button>
<a-upload
name="file"
:showUploadList="false"
... ... @@ -54,8 +48,6 @@
>
<a-button type="primary" icon="import">更新BOH</a-button>
</a-upload>
<!-- 高级查询区域 -->
<!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query> -->
<a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay">
<a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
... ... @@ -185,7 +177,7 @@
<j-form-container :disabled="formDisabled">
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
<a-row>
<a-col :span="12">
<a-col :span="24">
<a-form-model-item label="物料编码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialCode">
<a-input
v-model="model.materialCode"
... ... @@ -194,117 +186,63 @@
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="合同/订单号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="hth">
<a-input-search
v-model="model.hth"
placeholder="请输入合同/订单号"
@search="searchHth"
/>
</a-form-model-item>
</a-col>
<!-- <a-col :span="1">-->
<!-- <a >查询</a>-->
<!-- </a-col>-->
<a-col :span="12">
<a-form-model-item label="物料长描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialReview">
<a-col :span="24">
<a-form-model-item label="物料长描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialDescription">
<a-input
v-model="model.materialReview"
v-model="model.materialDescription"
placeholder="请输入物料长描述"
disabled="disabled"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="物流单号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="wldh">
<a-input
v-model="model.wldh"
placeholder="请输入物流单号"
disabled="disabled"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="unit">
<a-col :span="24">
<a-form-model-item label="单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="measurementUnit">
<a-input
v-model="model.unit"
v-model="model.measurementUnit"
placeholder="请输入单位"
disabled="disabled"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="供货商名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="cs">
<a-col :span="24">
<a-form-model-item label="品牌" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="brand">
<a-input
v-model="model.cs"
placeholder="请输入供货商名称"
v-model="model.brand"
placeholder="请输入品牌"
disabled="disabled"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="品牌" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="brand">
<a-col :span="24">
<a-form-model-item label="供货商名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplierName">
<a-input
v-model="model.brand"
placeholder="请输入品牌"
disabled="disabled"
v-model="model.supplierName"
placeholder="请输入供货商名称"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="仓库" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="warehouse">
<a-col :span="24">
<a-form-model-item label="入库储位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="warehouse">
<a-input
v-model="model.warehouse"
placeholder="请输入仓库"
placeholder="请输入入库储位"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="入库数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="rksl">
<a-input
v-model="model.rksl"
<a-col :span="24">
<a-form-model-item label="入库数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="inventoryQuantity">
<a-input-number :min="0"
:parser="limitNumber" :precision="0" :formatter="limitNumber"
v-model="model.inventoryQuantity"
placeholder="请输入入库数量"
></a-input>
></a-input-number>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="采购员" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operator">
<a-input
v-model="model.operator"
placeholder="请输入采购员"
></a-input>
<a-col :span="24">
<a-form-model-item label="入库时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operTime">
<j-date placeholder="请选择入库时间" v-model="model.operTime" style="width: 100%" />
</a-form-model-item>
</a-col>
<!-- <a-col :span="12">-->
<!-- <a-form-model-item label="不良品数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="blpsl">-->
<!-- <a-input type="number"-->
<!-- v-model="model.blpsl"-->
<!-- placeholder="请输入不良品数量"-->
<!-- ></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<!-- <a-col :span="12">-->
<!-- <a-form-model-item label="异常原因" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="iszt">-->
<!-- <a-select-->
<!-- ref="select"-->
<!-- v-model:value="model.ycyy"-->
<!-- >-->
<!-- <a-select-option value="1">来料不良</a-select-option>-->
<!-- <a-select-option value="2">货损</a-select-option>-->
<!-- <a-select-option value="3">来料少件</a-select-option>-->
<!-- <a-select-option value="4">发错货</a-select-option>-->
<!-- </a-select>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
</a-row>
</a-form-model>
... ... @@ -333,7 +271,7 @@
<j-form-container :disabled="formDisabled">
<a-form-model ref="form" :model="model2" :rules="validatorOutRules" slot="detail">
<a-row>
<a-col :span="12">
<a-col :span="24">
<a-form-model-item label="物料编码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialCode">
<a-input
v-model="model2.materialCode"
... ... @@ -342,54 +280,25 @@
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="供应商合同号/订单号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="expressDeliveryNumber">
<a-col :span="24">
<a-form-model-item label="物料长描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialDescription">
<a-input
v-model="model2.expressDeliveryNumber"
placeholder="请输入供应商合同号/订单号"
/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="物料长描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="materialReview">
<a-input
v-model="model2.materialReview"
v-model="model2.materialDescription"
placeholder="请输入物料长描述"
disabled="disabled"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="中标合同编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="deliveryContractNumber">
<a-col :span="24">
<a-form-model-item label="单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="measurementUnit">
<a-input
v-model="model2.deliveryContractNumber"
placeholder="请输入中标合同编号"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="unit">
<a-input
v-model="model2.unit"
v-model="model2.measurementUnit"
placeholder="请输入单位"
disabled="disabled"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="需求单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="demandUnit">
<a-input
v-model="model2.demandUnit"
placeholder="请输入需求单位"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-col :span="24">
<a-form-model-item label="品牌" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="brand">
<a-input
v-model="model2.brand"
... ... @@ -398,36 +307,40 @@
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="仓库" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="warehouse">
<a-input
v-model="model2.warehouse"
placeholder="请输入仓库"
></a-input>
<a-col :span="24" >
<a-form-model-item label="出货分公司" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="company">
<a-input v-model="model.company" placeholder="请输入出货分公司"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-col :span="24" >
<a-form-model-item label="出货工作令" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="workOrder">
<a-input v-model="model.workOrder" placeholder="请输入出货工作令"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24" >
<a-form-model-item label="出货厂家" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shippingManufacturer">
<a-input v-model="model.shippingManufacturer" placeholder="请输入出货厂家"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24" >
<a-form-model-item label="出货储位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="warehouse">
<a-input v-model="model.warehouse" placeholder="请输入出货储位"></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="出库时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="operTime">
<j-date placeholder="请选择出库时间" v-model="model.operTime" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="出库数量" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="outboundQuantity">
<a-input
v-model="model2.outboundQuantity"
placeholder="请输入出库数量"
></a-input>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="销售员" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="salesman">
<a-input
v-model="model2.salesman"
placeholder="请输入销售员"
></a-input>
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</j-form-container>
</a-spin>
... ... @@ -585,11 +498,11 @@
align:"center",
dataIndex: 'actualInventory'
},
{
title:'在途数量',
align:"center",
dataIndex: 'quantityInTransit'
},
// {
// title:'在途数量',
// align:"center",
// dataIndex: 'quantityInTransit'
// },
// {
// title:'总数量',
// align:"center",
... ... @@ -610,27 +523,27 @@
// align:"center",
// dataIndex: 'totalPrice'
// },
{
title:'首次入库时间',
align:"center",
dataIndex: 'firstStorageTime',
customRender:function (text) {
return !text?"":(text.length>10?text.substr(0,10):text)
}
},
{
title:'最后一次出库时间',
align:"center",
dataIndex: 'lastOutboundTime',
customRender:function (text) {
return !text?"":(text.length>10?text.substr(0,10):text)
}
},
{
title:'在库天数',
align:"center",
dataIndex: 'daysInStock'
},
// {
// title:'首次入库时间',
// align:"center",
// dataIndex: 'firstStorageTime',
// customRender:function (text) {
// return !text?"":(text.length>10?text.substr(0,10):text)
// }
// },
// {
// title:'最后一次出库时间',
// align:"center",
// dataIndex: 'lastOutboundTime',
// customRender:function (text) {
// return !text?"":(text.length>10?text.substr(0,10):text)
// }
// },
// {
// title:'在库天数',
// align:"center",
// dataIndex: 'daysInStock'
// },
{
title: '操作',
dataIndex: 'action',
... ... @@ -643,7 +556,8 @@
url: {
out: '/trade/tblTradeInventory/out',
searchHth: '/trade/tblTradeBidSub/queryHtInfoByHthAndWlbm',
store: '/trade/tblTradeInventory/add',
// store: '/trade/tblTradeInventory/add',//旧
store: '/trade/tblTradeInventoryIn/addTradeInventory',
list: "/trade/tblTradeInventory/list",
delete: "/trade/tblTradeInventory/delete",
deleteBatch: "/trade/tblTradeInventory/deleteBatch",
... ... @@ -652,7 +566,7 @@
importExcelUrlBoh: 'trade/tblTradeInventory/importExcelBoh',
updateBoh: '/trade/tblTradeInventory/updateBoh'
},
} ,
dictOptions:{},
superFieldList:[],
model: {
... ... @@ -661,7 +575,6 @@
blpsl: 0,
},
model2: {
},
materialCode:'',
materialReview:'',
... ... @@ -692,25 +605,25 @@
hth: [{ required: true, message: '请输入合同/订单号!' },],
materialReview: [{ required: true, message: '请输入物料长描述!' },],
wldh: [{ required: true, message: '请输入物流单号!' },],
unit: [{ required: true, message: '请输入单位!' },],
measurementUnit: [{ required: true, message: '请输入单位!' },],
// iszt: [{ required: true, message: '请选择是否在途!' },],
cs: [{ required: true, message: '请输入供货商名称!' },],
supplierName: [{ required: true, message: '请输入供货商名称!' },],
brand: [{ required: true, message: '请输入品牌!' },],
warehouse: [{ required: true, message: '请输入仓库!' },],
rksl: [{ required: true, message: '请输入入库数量!' },],
inventoryQuantity: [{ required: true, message: '请输入入库数量!' },],
operator: [{ required: true, message: '请输入采购员!' },],
},
validatorOutRules: {
materialCode: [{ required: true, message: '请输入物料编码!' },],
// materialCode: [{ required: true, message: '请输入物料编码!' },],
expressDeliveryNumber: [{ required: true, message: '请输入供应商合同号/订单号!' },],
materialReview: [{ required: true, message: '请输入物料长描述!' },],
// materialReview: [{ required: true, message: '请输入物料长描述!' },],
deliveryContractNumber: [{ required: true, message: '请输入中标合同编号!' },],
unit: [{ required: true, message: '请输入单位!' },],
demandUnit: [{ required: true, message: '请输入需求单位!' },],
brand: [{ required: true, message: '请输入品牌!' },],
warehouse: [{ required: true, message: '请输入仓库!' },],
// workOrder: [{ required: true, message: '请输入工作令!' },],
outboundQuantity: [{ required: true, message: '请输入出库数量!' },],
salesman: [{ required: true, message: '请输入销售员!' },],
operTime: [{ required: true, message: '请输入出货时间!' },],
},
purchaseId: '',
... ... @@ -742,6 +655,15 @@
}
})
},
limitNumber(value) {
if (typeof value === 'string') {
return !isNaN(Number(value)) ? value.replace(/\./g, '') : 0
} else if (typeof value === 'number') {
return !isNaN(value) ? String(value).replace(/\./g, '') : 0
} else {
return 0
}
},
searchHth(){
getAction(this.url.searchHth,{
hth: this.model.hth,
... ... @@ -770,33 +692,34 @@
handleInventoryDefective(){
this.visibleDefective = true;
},
updateInventoryBoh(recode){
console.log("..............",recode)
updateInventoryBoh(record){
console.log("..............",record)
this.model2= {}
this.model2 = recode;
this.model2.materialDescription = recode.materialReview;
this.model2 = record;
this.model2.materialDescription = record.materialReview;
this.visibleBoh = true;
},
handleInventoryInfo(recode){
this.materialCode = recode.materialCode;
handleInventoryInfo(record){
this.materialCode = record.materialCode;
this.visibleInfo = true;
},
handleInventoryInfoIn(recode){
handleInventoryInfoIn(record){
this.model = {}
console.log(recode)
this.model.materialCode = recode.materialCode;
this.model.materialReview = recode.materialReview;
this.model.unit = recode.unit;
this.model.brand = recode.brand;
console.log(record)
this.model = record
// this.model.materialCode = record.materialCode;
this.model.materialDescription = record.materialReview;
this.model.measurementUnit = record.unit;
// this.model.brand = record.brand;
this.visibleInfoIn = true;
},
handleInventoryInfoOut(recode){
handleInventoryInfoOut(record){
this.model2= {}
console.log("..............",recode)
this.model2.materialCode = recode.materialCode;
this.model2.materialReview = recode.materialReview;
this.model2.unit = recode.unit;
this.model2.brand = recode.brand;
console.log("..............",record)
this.model2.materialCode = record.materialCode;
this.model2.materialDescription = record.materialReview;
this.model2.measurementUnit = record.unit;
this.model2.brand = record.brand;
this.visibleInfoOut = true;
},
handleCancel(){
... ... @@ -855,19 +778,8 @@
handleOkInfoIn(){
this.$refs.form.validate((valid) => {
if (valid){
postAction(this.url.store,{
materialCode: this.model.materialCode, //物料编码
materialDescription: this.model.materialReview, //长描述
measurementUnit: this.model.unit, //单位
brand: this.model.brand,//品牌
hth: this.model.hth, //合同号
wldh: this.model.wldh, //物流单号
warehouse: this.model.warehouse, //仓库
operator: this.model.operator, //采购员
rksl: this.model.rksl, //入库数量
cs: this.model.cs, //厂商
purchaseId: this.purchaseId //订单id
}).then(res=>{
postAction(this.url.store,this.model
).then(res=>{
this.reSeach();
if (res.success){
this.$message.success("提交成功")
... ...