库存检验修改

master
shaoyong 10 months ago
parent 3297b42385
commit 87311bc2d8

@ -140,7 +140,7 @@
<el-table-column label="单位" align="center" prop="unit" /> <el-table-column label="单位" align="center" prop="unit" />
<el-table-column label="供应商编码" align="center" prop="supplierCode" width="120"/> <el-table-column label="供应商编码" align="center" prop="supplierCode" width="120"/>
<el-table-column label="供应商名称" align="center" prop="supplierName" width="240"/> <el-table-column label="供应商名称" align="center" prop="supplierName" width="240"/>
<el-table-column label="时间" align="center" prop="incomeTime" width="180"> <el-table-column label="库时间" align="center" prop="incomeTime" width="180">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.incomeTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span> <span>{{ parseTime(scope.row.incomeTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template> </template>
@ -225,9 +225,8 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="来料批次号" prop="incomeBatchNo"> <el-form-item label="批次号" prop="incomeBatchNo">
<el-input v-model="form.incomeBatchNo" placeholder="请输入库存批次号"> <el-input v-model="form.incomeBatchNo" placeholder="请输入批次号">
<el-button slot="append" @click="handleSelectWorkOrder" icon="el-icon-search"></el-button>
</el-input> </el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
@ -235,7 +234,9 @@
<el-row> <el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="物料名称" prop="materialName"> <el-form-item label="物料名称" prop="materialName">
<el-input v-model="form.materialName" placeholder="请选择物料名称"/> <el-input v-model="form.materialName" placeholder="请选择物料名称">
<el-button slot="append" @click="handleSelectMaterial" icon="el-icon-search"></el-button>
</el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
@ -244,8 +245,13 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="检测地点" prop="checkLoc"> <el-form-item label="入库时间" prop="incomeTime">
<el-input v-model="form.checkLoc" placeholder="请输入检测地点" /> <el-date-picker clearable
v-model="form.incomeTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择入库时间">
</el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -288,6 +294,11 @@
<el-input v-model="form.checkManCode" placeholder="请输入检测人工号" disabled/> <el-input v-model="form.checkManCode" placeholder="请输入检测人工号" disabled/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="检测地点" prop="checkLoc">
<el-input v-model="form.checkLoc" placeholder="请输入检测地点" />
</el-form-item>
</el-col>
</el-row> </el-row>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -296,10 +307,10 @@
</div> </div>
</el-dialog> </el-dialog>
<!--订单选择弹窗--> <!--订单选择弹窗-->
<ItemSelectWorkOrder <ItemSelectMaterial
ref="itemSelectWorkOrder" ref="itemSelectMaterial"
@onSelected="onSelectWorkOrder" @onSelected="onSelectMaterial"
></ItemSelectWorkOrder> ></ItemSelectMaterial>
<!--供应商选择弹窗--> <!--供应商选择弹窗-->
<ItemSelectSupplier <ItemSelectSupplier
ref="itemSelectSupplier" ref="itemSelectSupplier"
@ -321,7 +332,7 @@
<script> <script>
import { listQcInventory, getQcInventory, addQcInventory, updateQcInventory, delQcInventory } from "@/api/quality/qcInventory.js"; import { listQcInventory, getQcInventory, addQcInventory, updateQcInventory, delQcInventory } from "@/api/quality/qcInventory.js";
import { getCheckTypes } from "@/api/quality/qcProduce"; import { getCheckTypes } from "@/api/quality/qcProduce";
import ItemSelectWorkOrder from "./selectLLWorkOrder"; import ItemSelectMaterial from "./selectMaterial.vue"
import ItemSelectSupplier from "./selectSupplier"; import ItemSelectSupplier from "./selectSupplier";
import ItemSelectUser from "../qcIncome/selectUser.vue"; import ItemSelectUser from "../qcIncome/selectUser.vue";
import ItemSelectProject from "../qcIncome/checkProjectType.vue"; import ItemSelectProject from "../qcIncome/checkProjectType.vue";
@ -329,7 +340,7 @@ import moment from 'moment';
import { getDefectTypeListByDefectType } from "@/api/quality/defectType.js"; import { getDefectTypeListByDefectType } from "@/api/quality/defectType.js";
export default { export default {
name: "Inventory", name: "Inventory",
components: { ItemSelectWorkOrder,ItemSelectSupplier,ItemSelectUser,ItemSelectProject}, components: { ItemSelectMaterial,ItemSelectSupplier,ItemSelectUser,ItemSelectProject},
dicts: ["unit","check_status","check_result"], dicts: ["unit","check_status","check_result"],
data() { data() {
return { return {
@ -390,7 +401,7 @@ export default {
{ required: true, message: "检验类型不能为空", trigger: "blur" } { required: true, message: "检验类型不能为空", trigger: "blur" }
], ],
incomeBatchNo: [ incomeBatchNo: [
{ required: true, message: "来料批次号不能为空", trigger: "blur" } { required: true, message: "批次号不能为空", trigger: "blur" }
], ],
orderNo: [ orderNo: [
{ required: true, message: "订单号不能为空", trigger: "blur" } { required: true, message: "订单号不能为空", trigger: "blur" }
@ -599,20 +610,14 @@ export default {
}, },
/**工单选择弹出框**/ /**工单选择弹出框**/
handleSelectWorkOrder() { handleSelectMaterial() {
this.$refs.itemSelectWorkOrder.showFlag = true; this.$refs.itemSelectMaterial.showFlag = true;
}, },
// //
onSelectWorkOrder(obj) { onSelectMaterial(obj) {
this.form.orderNo = obj.orderNo; console.log(obj);
this.form.materialName = obj.materialName; this.form.materialName = obj.name;
this.form.materialCode = obj.materialCode; this.form.materialCode = obj.code;
this.form.quality = obj.quality;
this.form.incomeBatchNo = obj.incomeBatchNo;
this.form.unit = obj.unit;
this.form.supplierCode = obj.supplierCode;
this.form.supplierName = obj.supplierName;
this.form.incomeTime = obj.incomeTime;
}, },
/**供应商选择弹出框**/ /**供应商选择弹出框**/

@ -1,138 +0,0 @@
<template>
<el-dialog title="来料DN单号选择"
v-if="showFlag"
:visible.sync="showFlag"
:modal= false
width="1000px"
>
<el-row :gutter="20">
<el-col :span="24" :xs="24">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="105px" align="left">
<el-form-item label="来料单号">
<el-input
v-model="queryParams.orderNo"
placeholder="来料单号"
clearable
style="width: 240px"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-table v-loading="loading" :data="itemList" @selection-change="handleBomSelectionChange" ref="myTable" >
<el-table-column width="50" align="center" type="selection"/>
<el-table-column label="id" align="left" prop="recordId" width="100" v-if="false"/>
<el-table-column label="来料单号" align="left" prop="orderNo" width="180"/>
<el-table-column label="质检状态" align="left" prop="qualityStatus" width="100"/>
<el-table-column label="批次号" align="left" prop="incomeBatchNo" width="120"/>
<el-table-column label="产品编码" align="left" prop="materialCode" width="180" />
<el-table-column label="产品名称" align="left" prop="materialName" width="180"/>
<el-table-column label="供应商编码" align="left" prop="supplierCode" :show-overflow-tooltip="true" />
<el-table-column label="供应商名称" align="left" prop="supplierName" :show-overflow-tooltip="true" />
<el-table-column label="排产数量" align="left" prop="quality" width="100" />
<el-table-column label="单位" align="left" prop="unit" :show-overflow-tooltip="true" />
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
</el-col>
</el-row>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitLLOrderForm"> </el-button>
<el-button @click="showFlag=false"> </el-button>
</div>
</el-dialog>
</template>
<script>
import { getLLWorkOrder } from "@/api/quality/income";
export default {
name: "itemSelectWorkOrder",
data() {
return {
showFlag:false,
//
selectedRows: {},
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
// BOM
itemList: null,
//
bomCode: undefined,
defaultProps: {
id: "id",
label: "label"
},
//
queryParams: {
pageNum: 1,
pageSize: 10,
workorderCode: ''
},
selectionRow:{}
};
},
created() {
this.getList();
},
methods: {
/** 查询表格列表*/
getList() {
this.loading = true;
getLLWorkOrder(this.queryParams).then(response => {
this.itemList = response.rows;
this.total = response.total;
this.loading = false;
}
);
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleBomSelectionChange(selection) {
if(selection.length>1){
this.$modal.msgSuccess("只能选一个");
}
this.selectionRow = selection[0]
},
submitLLOrderForm() {
this.$emit('onSelected', this.selectionRow);
this.showFlag = false;
}
}
};
</script>

@ -1,5 +1,5 @@
<template> <template>
<el-dialog title="BOM物料选择" <el-dialog title="物料选择"
v-if="showFlag" v-if="showFlag"
:visible.sync="showFlag" :visible.sync="showFlag"
:modal= false :modal= false
@ -144,7 +144,6 @@ export default {
}, },
submitBomForm() { submitBomForm() {
this.selectedRows.code = this.ids; this.selectedRows.code = this.ids;
this.selectedRows.name = this.idsName; this.selectedRows.name = this.idsName;

Loading…
Cancel
Save