update - 切换订单

master
yinq 7 months ago
parent c858bae5d5
commit 66023beb4f

@ -123,18 +123,18 @@
<el-table-column label="不合格原因" align="center" prop="failureReason" v-if="columns[7].visible" width="100"/> <el-table-column label="不合格原因" align="center" prop="failureReason" v-if="columns[7].visible" width="100"/>
<!-- <el-table-column label="不合格类型" align="center" prop="failureType" v-if="columns[8].visible"/>--> <!-- <el-table-column label="不合格类型" align="center" prop="failureType" v-if="columns[8].visible"/>-->
<el-table-column label="质管员审核时间" align="center" prop="qualityUserTime" width="180" v-if="columns[9].visible"/> <el-table-column label="质管员审核时间" align="center" prop="qualityUserTime" width="180" v-if="columns[9].visible"/>
<el-table-column label="生产经理标识" align="center" prop="productionManagerFlag" v-if="columns[10].visible" width="100"> <el-table-column label="生产经理标识" align="center" prop="productionManagerFlag" v-if="columns[10].visible" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.agree_flag" :value="scope.row.productionManagerFlag"/> <dict-tag :options="dict.type.agree_flag" :value="scope.row.productionManagerFlag"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="生产经理审核时间" align="center" prop="productionManagerTime" width="180" v-if="columns[11].visible"/> <el-table-column label="生产经理审核时间" align="center" prop="productionManagerTime" width="180" v-if="columns[11].visible"/>
<el-table-column label="质量经理标识" align="center" prop="qualityManagerFlag" v-if="columns[12].visible" width="100"> <el-table-column label="质量经理标识" align="center" prop="qualityManagerFlag" v-if="columns[12].visible" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.agree_flag" :value="scope.row.qualityManagerFlag"/> <dict-tag :options="dict.type.agree_flag" :value="scope.row.qualityManagerFlag"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="质量经理审核时间" align="center" prop="qualityManagerTime" width="180" v-if="columns[13].visible"/> <el-table-column label="质量经理审核时间" align="center" prop="qualityManagerTime" width="180" v-if="columns[13].visible"/>
<!-- <el-table-column label="备注" align="center" prop="remark" v-if="columns[17].visible"/>--> <!-- <el-table-column label="备注" align="center" prop="remark" v-if="columns[17].visible"/>-->
<!-- <el-table-column label="创建人" align="center" prop="createdBy" v-if="columns[18].visible"/>--> <!-- <el-table-column label="创建人" align="center" prop="createdBy" v-if="columns[18].visible"/>-->
<!-- <el-table-column label="创建时间" align="center" prop="createdTime" width="180" v-if="columns[19].visible">--> <!-- <el-table-column label="创建时间" align="center" prop="createdTime" width="180" v-if="columns[19].visible">-->
@ -165,7 +165,7 @@
v-if="productionManagerVisible && scope.row.productionManagerFlag == null v-if="productionManagerVisible && scope.row.productionManagerFlag == null
&& scope.row.qualityUserFlag != null && scope.row.productionUserFlag === '1'" && scope.row.qualityUserFlag != null && scope.row.productionUserFlag === '1'"
@click="productionManagerUpdate(scope.row)" @click="productionManagerUpdate(scope.row)"
>生产经理评审 >生产经理评审
</el-button> </el-button>
<el-button <el-button
size="mini" size="mini"
@ -174,7 +174,7 @@
v-if="qualityManagerVisible && scope.row.qualityManagerFlag == null v-if="qualityManagerVisible && scope.row.qualityManagerFlag == null
&& scope.row.productionManagerFlag != null && scope.row.productionUserFlag === '1'" && scope.row.productionManagerFlag != null && scope.row.productionUserFlag === '1'"
@click="qualityManagerUpdate(scope.row)" @click="qualityManagerUpdate(scope.row)"
>质量经理评审 >质量经理评审
</el-button> </el-button>
<!-- <el-button--> <!-- <el-button-->
<!-- size="mini"--> <!-- size="mini"-->
@ -272,7 +272,7 @@
</div> </div>
</el-dialog> </el-dialog>
<!-- 生产经理管理对话框 --> <!-- 生产经理管理对话框 -->
<el-dialog :title="title" :visible.sync="productionManagerOpen" width="500px" append-to-body> <el-dialog :title="title" :visible.sync="productionManagerOpen" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form-item label="SAP订单" prop="orderCode"> <el-form-item label="SAP订单" prop="orderCode">
@ -307,7 +307,7 @@
<el-form-item label="不合格原因" prop="failureReason"> <el-form-item label="不合格原因" prop="failureReason">
<el-input v-model="form.failureReason" type="textarea" placeholder="请输入不合格原因" disabled/> <el-input v-model="form.failureReason" type="textarea" placeholder="请输入不合格原因" disabled/>
</el-form-item> </el-form-item>
<el-form-item label="生产经理标识" prop="productionManagerFlag"> <el-form-item label="生产经理标识" prop="productionManagerFlag">
<el-radio-group v-model="form.productionManagerFlag"> <el-radio-group v-model="form.productionManagerFlag">
<el-radio <el-radio
v-for="dict in dict.type.agree_flag" v-for="dict in dict.type.agree_flag"
@ -324,7 +324,7 @@
</div> </div>
</el-dialog> </el-dialog>
<!-- 质量经理管理对话框 --> <!-- 质量经理管理对话框 -->
<el-dialog :title="title" :visible.sync="qualityManagerOpen" width="500px" append-to-body> <el-dialog :title="title" :visible.sync="qualityManagerOpen" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form-item label="SAP订单" prop="orderCode"> <el-form-item label="SAP订单" prop="orderCode">
@ -359,7 +359,7 @@
<el-form-item label="不合格原因" prop="failureReason"> <el-form-item label="不合格原因" prop="failureReason">
<el-input v-model="form.failureReason" type="textarea" placeholder="请输入不合格原因" disabled/> <el-input v-model="form.failureReason" type="textarea" placeholder="请输入不合格原因" disabled/>
</el-form-item> </el-form-item>
<el-form-item label="生产经理标识" prop="productionManagerFlag"> <el-form-item label="生产经理标识" prop="productionManagerFlag">
<el-radio-group v-model="form.productionManagerFlag" disabled> <el-radio-group v-model="form.productionManagerFlag" disabled>
<el-radio <el-radio
v-for="dict in dict.type.agree_flag" v-for="dict in dict.type.agree_flag"
@ -369,7 +369,7 @@
</el-radio> </el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item label="质量经理标识" prop="qualityManagerFlag"> <el-form-item label="质量经理标识" prop="qualityManagerFlag">
<el-radio-group v-model="form.qualityManagerFlag"> <el-radio-group v-model="form.qualityManagerFlag">
<el-radio <el-radio
v-for="dict in dict.type.agree_flag" v-for="dict in dict.type.agree_flag"
@ -420,9 +420,9 @@ export default {
handleAddVisible: false, handleAddVisible: false,
// //
qualityUserVisible: false, qualityUserVisible: false,
// //
productionManagerVisible: false, productionManagerVisible: false,
// //
qualityManagerVisible: false, qualityManagerVisible: false,
// //
total: 0, total: 0,
@ -468,7 +468,7 @@ export default {
}, },
// //
form: { form: {
// 1=2=3=4= // 1=2=3=4=
currentUserPost: null currentUserPost: null
}, },
// //
@ -491,10 +491,10 @@ export default {
{ key: 7, label: `不合格原因`, visible: true }, { key: 7, label: `不合格原因`, visible: true },
{ key: 8, label: `不合格类型`, visible: true }, { key: 8, label: `不合格类型`, visible: true },
{ key: 9, label: `质管员审核时间`, visible: true }, { key: 9, label: `质管员审核时间`, visible: true },
{ key: 10, label: `生产经理标识`, visible: true }, { key: 10, label: `生产经理标识`, visible: true },
{ key: 11, label: `生产经理审核时间`, visible: true }, { key: 11, label: `生产经理审核时间`, visible: true },
{ key: 12, label: `质量经理标识`, visible: true }, { key: 12, label: `质量经理标识`, visible: true },
{ key: 13, label: `质量经理审核时间`, visible: true } { key: 13, label: `质量经理审核时间`, visible: true }
// { key: 17, label: ``, visible: true }, // { key: 17, label: ``, visible: true },
// { key: 18, label: ``, visible: true }, // { key: 18, label: ``, visible: true },
// { key: 19, label: ``, visible: true }, // { key: 19, label: ``, visible: true },
@ -610,7 +610,7 @@ export default {
this.title = '质管员评审' this.title = '质管员评审'
}) })
}, },
/** 生产经理评审按钮操作 */ /** 生产经理评审按钮操作 */
productionManagerUpdate(row) { productionManagerUpdate(row) {
this.reset() this.reset()
const objId = row.objId || this.ids const objId = row.objId || this.ids
@ -619,10 +619,10 @@ export default {
this.form.currentUserPost = 3; this.form.currentUserPost = 3;
this.form.productionManagerTime = new Date().getTime(); this.form.productionManagerTime = new Date().getTime();
this.productionManagerOpen = true this.productionManagerOpen = true
this.title = '生产经理评审' this.title = '生产经理评审'
}) })
}, },
/** 质量经理评审按钮操作 */ /** 质量经理评审按钮操作 */
qualityManagerUpdate(row) { qualityManagerUpdate(row) {
this.reset() this.reset()
const objId = row.objId || this.ids const objId = row.objId || this.ids
@ -631,7 +631,7 @@ export default {
this.form.currentUserPost = 4; this.form.currentUserPost = 4;
this.form.qualityManagerTime = new Date().getTime(); this.form.qualityManagerTime = new Date().getTime();
this.qualityManagerOpen = true this.qualityManagerOpen = true
this.title = '质量经理评审' this.title = '质量经理评审'
}) })
}, },
/** 提交按钮 */ /** 提交按钮 */
@ -648,11 +648,11 @@ export default {
return; return;
} }
if (this.form.currentUserPost === 3 && this.form.productionManagerFlag == null){ if (this.form.currentUserPost === 3 && this.form.productionManagerFlag == null){
this.$modal.msgError('请选择生产经理标识!') this.$modal.msgError('请选择生产经理标识!')
return; return;
} }
if (this.form.currentUserPost === 4 && this.form.qualityManagerFlag == null){ if (this.form.currentUserPost === 4 && this.form.qualityManagerFlag == null){
this.$modal.msgError('请选择质量经理标识!') this.$modal.msgError('请选择质量经理标识!')
return; return;
} }
if (this.form.currentUserPost === 2 && this.form.qualityUserFlag === '2'){ if (this.form.currentUserPost === 2 && this.form.qualityUserFlag === '2'){

@ -10,10 +10,10 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<!-- <el-form-item label="切换工位编号" prop="switchStationCode">--> <!-- <el-form-item label="切换工位" prop="switchStationCode">-->
<!-- <el-input--> <!-- <el-input-->
<!-- v-model="queryParams.switchStationCode"--> <!-- v-model="queryParams.switchStationCode"-->
<!-- placeholder="请输入切换工位编号"--> <!-- placeholder="请输入切换工位"-->
<!-- clearable--> <!-- clearable-->
<!-- @keyup.enter.native="handleQuery"--> <!-- @keyup.enter.native="handleQuery"-->
<!-- />--> <!-- />-->
@ -29,7 +29,7 @@
<!-- <el-form-item label="切换订单标识" prop="isSwitch">--> <!-- <el-form-item label="切换订单标识" prop="isSwitch">-->
<!-- <el-select v-model="queryParams.isSwitch" placeholder="请选择切换订单标识" clearable>--> <!-- <el-select v-model="queryParams.isSwitch" placeholder="请选择切换订单标识" clearable>-->
<!-- <el-option--> <!-- <el-option-->
<!-- v-for="dict in dict.type.is_flag"--> <!-- v-for="dict in dict.type.is_switch"-->
<!-- :key="dict.value"--> <!-- :key="dict.value"-->
<!-- :label="dict.label"--> <!-- :label="dict.label"-->
<!-- :value="dict.value"--> <!-- :value="dict.value"-->
@ -85,7 +85,7 @@
<el-form-item label="打印标识" prop="isPrint"> <el-form-item label="打印标识" prop="isPrint">
<el-select v-model="queryParams.isPrint" placeholder="请选择打印标识" clearable> <el-select v-model="queryParams.isPrint" placeholder="请选择打印标识" clearable>
<el-option <el-option
v-for="dict in dict.type.is_flag" v-for="dict in dict.type.is_switch"
:key="dict.value" :key="dict.value"
:label="dict.label" :label="dict.label"
:value="dict.value" :value="dict.value"
@ -110,18 +110,18 @@
<!-- >新增--> <!-- >新增-->
<!-- </el-button>--> <!-- </el-button>-->
<!-- </el-col>--> <!-- </el-col>-->
<el-col :span="1.5"> <!-- <el-col :span="1.5">-->
<el-button <!-- <el-button-->
type="success" <!-- type="success"-->
plain <!-- plain-->
icon="el-icon-edit" <!-- icon="el-icon-edit"-->
size="mini" <!-- size="mini"-->
:disabled="single" <!-- :disabled="single"-->
@click="handleUpdate" <!-- @click="handleUpdate"-->
v-hasPermi="['report:switchOrder:edit']" <!-- v-hasPermi="['report:switchOrder:edit']"-->
>修改 <!-- >修改-->
</el-button> <!-- </el-button>-->
</el-col> <!-- </el-col>-->
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
type="danger" type="danger"
@ -151,10 +151,19 @@
<el-table v-loading="loading" :data="switchOrderList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="switchOrderList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center"/> <el-table-column type="selection" width="55" align="center"/>
<el-table-column label="主键标识" align="center" prop="objId" v-if="columns[0].visible"/> <el-table-column label="主键标识" align="center" prop="objId" v-if="columns[0].visible"/>
<el-table-column label="箱体码" align="center" prop="materialBarcode" v-if="columns[1].visible"/>
<el-table-column label="切换工位编号" align="center" prop="switchStationCode" v-if="columns[2].visible"/>
<el-table-column label="订单编号" align="center" prop="orderCode" v-if="columns[10].visible"/> <el-table-column label="订单编号" align="center" prop="orderCode" v-if="columns[10].visible"/>
<el-table-column label="切换工位" align="center" prop="switchStationName" v-if="columns[2].visible"/>
<el-table-column label="箱体码" align="center" prop="materialBarcode" v-if="columns[1].visible" width="190"/>
<el-table-column label="切换订单标识" align="center" prop="isSwitch" v-if="columns[4].visible">
<template slot-scope="scope">
<dict-tag :options="dict.type.is_switch" :value="scope.row.isSwitch"/>
</template>
</el-table-column>
<el-table-column label="打印标识" align="center" prop="isPrint" v-if="columns[11].visible">
<template slot-scope="scope">
<dict-tag :options="dict.type.is_switch" :value="scope.row.isPrint"/>
</template>
</el-table-column>
<el-table-column label="创建人" align="center" prop="createBy" v-if="columns[5].visible"/> <el-table-column label="创建人" align="center" prop="createBy" v-if="columns[5].visible"/>
<el-table-column label="创建时间" align="center" prop="createTime" width="180" v-if="columns[6].visible"> <el-table-column label="创建时间" align="center" prop="createTime" width="180" v-if="columns[6].visible">
<template slot-scope="scope"> <template slot-scope="scope">
@ -168,16 +177,6 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="备注" align="center" prop="remark" v-if="columns[9].visible"/> <el-table-column label="备注" align="center" prop="remark" v-if="columns[9].visible"/>
<el-table-column label="切换订单标识" align="center" prop="isSwitch" v-if="columns[4].visible">
<template slot-scope="scope">
<dict-tag :options="dict.type.is_flag" :value="scope.row.isSwitch"/>
</template>
</el-table-column>
<el-table-column label="打印标识" align="center" prop="isPrint" v-if="columns[11].visible">
<template slot-scope="scope">
<dict-tag :options="dict.type.is_flag" :value="scope.row.isPrint"/>
</template>
</el-table-column>
<el-table-column label="原订单编号" align="center" prop="oldOrderCode" v-if="columns[3].visible"/> <el-table-column label="原订单编号" align="center" prop="oldOrderCode" v-if="columns[3].visible"/>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope"> <template slot-scope="scope">
@ -187,16 +186,16 @@
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['report:switchOrder:edit']" v-hasPermi="['report:switchOrder:edit']"
>修改订单 >修改SAP订单
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['report:switchOrder:remove']"
>删除
</el-button> </el-button>
<!-- <el-button-->
<!-- size="mini"-->
<!-- type="text"-->
<!-- icon="el-icon-delete"-->
<!-- @click="handleDelete(scope.row)"-->
<!-- v-hasPermi="['report:switchOrder:remove']"-->
<!-- >删除-->
<!-- </el-button>-->
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -211,26 +210,26 @@
<!-- 添加或修改切换订单管理对话框 --> <!-- 添加或修改切换订单管理对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<!-- <el-form-item label="主键标识" prop="objId">--> <!-- <el-form-item label="主键标识" prop="objId">-->
<!-- <el-input v-model="form.objId" placeholder="请输入主键标识"/>--> <!-- <el-input v-model="form.objId" placeholder="请输入主键标识"/>-->
<!-- </el-form-item>--> <!-- </el-form-item>-->
<el-form-item label="箱体码" prop="materialBarcode"> <el-form-item label="箱体码" prop="materialBarcode">
<el-input v-model="form.materialBarcode" placeholder="请输入箱体码"/> <el-input v-model="form.materialBarcode" placeholder="请输入箱体码" disabled/>
</el-form-item> </el-form-item>
<el-form-item label="订单编号" prop="orderCode"> <el-form-item label="原订单编号" prop="orderCode">
<el-input v-model="form.orderCode" placeholder="请输入订单编号"/> <el-input v-model="form.orderCode" placeholder="请输入原订单编号" disabled/>
</el-form-item>
<el-form-item label="切换工位" prop="switchStationName">
<el-input v-model="form.switchStationName" placeholder="请输入切换工位" disabled/>
</el-form-item>
<el-form-item label="新订单编号" prop="oldOrderCode">
<el-input v-model="form.oldOrderCode" placeholder="请输入新订单编号" />
</el-form-item> </el-form-item>
<!-- <el-form-item label="切换工位" prop="switchStationCode">-->
<!-- <el-input v-model="form.switchStationCode" placeholder="请输入切换工位编号"/>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="原订单编号" prop="oldOrderCode">-->
<!-- <el-input v-model="form.oldOrderCode" placeholder="请输入原订单编号"/>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="切换订单标识" prop="isSwitch">--> <!-- <el-form-item label="切换订单标识" prop="isSwitch">-->
<!-- <el-radio-group v-model="form.isSwitch">--> <!-- <el-radio-group v-model="form.isSwitch">-->
<!-- <el-radio--> <!-- <el-radio-->
<!-- v-for="dict in dict.type.is_flag"--> <!-- v-for="dict in dict.type.is_switch"-->
<!-- :key="dict.value"--> <!-- :key="dict.value"-->
<!-- :label="dict.value"--> <!-- :label="dict.value"-->
<!-- >{{ dict.label }}--> <!-- >{{ dict.label }}-->
@ -243,7 +242,7 @@
<!-- <el-form-item label="打印标识" prop="isPrint">--> <!-- <el-form-item label="打印标识" prop="isPrint">-->
<!-- <el-radio-group v-model="form.isPrint">--> <!-- <el-radio-group v-model="form.isPrint">-->
<!-- <el-radio--> <!-- <el-radio-->
<!-- v-for="dict in dict.type.is_flag"--> <!-- v-for="dict in dict.type.is_switch"-->
<!-- :key="dict.value"--> <!-- :key="dict.value"-->
<!-- :label="dict.value"--> <!-- :label="dict.value"-->
<!-- >{{ dict.label }}--> <!-- >{{ dict.label }}-->
@ -270,7 +269,7 @@ import {
export default { export default {
name: 'SwitchOrder', name: 'SwitchOrder',
dicts: ['is_flag'], dicts: ['is_switch'],
data() { data() {
return { return {
// //
@ -302,6 +301,7 @@ export default {
objId: null, objId: null,
materialBarcode: null, materialBarcode: null,
switchStationCode: null, switchStationCode: null,
switchStationName: null,
oldOrderCode: null, oldOrderCode: null,
isSwitch: null, isSwitch: null,
createBy: null, createBy: null,
@ -314,11 +314,15 @@ export default {
// //
form: {}, form: {},
// //
rules: {}, rules: {
oldOrderCode: [
{ required: true, message: '新订单编号不能为空', trigger: 'blur' }
],
},
columns: [ columns: [
{ key: 0, label: `主键标识`, visible: false }, { key: 0, label: `主键标识`, visible: false },
{ key: 1, label: `箱体码`, visible: true }, { key: 1, label: `箱体码`, visible: true },
{ key: 2, label: `切换工位编号`, visible: true }, { key: 2, label: `切换工位`, visible: true },
{ key: 3, label: `原订单编号`, visible: false }, { key: 3, label: `原订单编号`, visible: false },
{ key: 4, label: `切换订单标识`, visible: true }, { key: 4, label: `切换订单标识`, visible: true },
{ key: 5, label: `创建人`, visible: false }, { key: 5, label: `创建人`, visible: false },
@ -416,7 +420,7 @@ export default {
if (valid) { if (valid) {
if (this.form.objId != null) { if (this.form.objId != null) {
updateSwitchOrder(this.form).then(response => { updateSwitchOrder(this.form).then(response => {
this.$modal.msgSuccess('修改成功') this.$modal.msgSuccess('修改SAP订单成功,请到打印机旁进行补打条码!')
this.open = false this.open = false
this.getList() this.getList()
}) })

Loading…
Cancel
Save