update - 工序/工位维护

master
yinq 1 year ago
parent c5f59d2984
commit 863c416f43

@ -246,6 +246,20 @@ export const dynamicRoutes = [
},
],
},
{
path: "/base/subordinate-workers",
component: Layout,
hidden: true,
permissions: ["base:processStation:list"],
children: [
{
path:"index/:productLineCode",
component:() => import("@/views/base/processStation/index"),
name:"SubordinateWorkers",
meta: {title: "工序信息",activeMenu: "/base/processStation"},
},
],
},
]
// 防止连续点击多次路由报错

@ -1,26 +1,28 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="工序/工位编号" prop="processCode">
<el-input
v-model="queryParams.processCode"
placeholder="请输入工序/工位编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-form-item label="所属产线" prop="productLineCode" >
<el-select v-model="queryParams.productLineCode" placeholder="请选择产线工位">
<el-option
v-for="item in productLineList"
:key="item.productLineCode"
:label="item.productLineName"
:value="item.productLineCode"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="工序/工位名称" prop="processName">
<!-- <el-form-item label="工序编号" prop="processCode">-->
<!-- <el-input-->
<!-- v-model="queryParams.processCode"-->
<!-- placeholder="请输入工序编号"-->
<!-- clearable-->
<!-- @keyup.enter.native="handleQuery"-->
<!-- />-->
<!-- </el-form-item>-->
<el-form-item label="工序名称" prop="processName">
<el-input
v-model="queryParams.processName"
placeholder="请输入工序/工位名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="所属产线" prop="productLineCode">
<el-input
v-model="queryParams.productLineCode"
placeholder="请输入所属产线"
placeholder="请输入工序名称"
clearable
@keyup.enter.native="handleQuery"
/>
@ -74,6 +76,15 @@
v-hasPermi="['base:processStation:export']"
>导出</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-close"
size="mini"
@click="handleClose"
>关闭</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar>
</el-row>
@ -254,6 +265,7 @@ export default {
};
},
created() {
this.queryParams.productLineCode = this.$route.params && this.$route.params.productLineCode;
this.getList();
},
methods: {
@ -295,6 +307,7 @@ export default {
updatedTime: null,
parentId: null
};
this.queryParams.productLineCode = null
this.resetForm("form");
},
/** 搜索按钮操作 */
@ -319,6 +332,11 @@ export default {
this.open = true;
this.title = "添加生产工序/工位信息";
},
/** 返回按钮操作 */
handleClose() {
const obj = { path: "/base/productLine" };
this.$tab.closeOpenPage(obj);
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();

@ -95,22 +95,28 @@
size="mini"
type="text"
icon="el-icon-d-arrow-right"
@click="findStation(scope.row)"
>查看所属工位</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['base:productLine:edit']"
>修改</el-button>
@click="findSubordinateWorkers(scope.row)"
>下级工序</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['base:productLine:remove']"
>删除</el-button>
icon="el-icon-s-grid"
@click="findStation(scope.row)"
>所属工位</el-button>
<!-- <el-button-->
<!-- size="mini"-->
<!-- type="text"-->
<!-- icon="el-icon-edit"-->
<!-- @click="handleUpdate(scope.row)"-->
<!-- v-hasPermi="['base:productLine:edit']"-->
<!-- >修改</el-button>-->
<!-- <el-button-->
<!-- size="mini"-->
<!-- type="text"-->
<!-- icon="el-icon-delete"-->
<!-- @click="handleDelete(scope.row)"-->
<!-- v-hasPermi="['base:productLine:remove']"-->
<!-- >删除</el-button>-->
</template>
</el-table-column>
</el-table>
@ -301,11 +307,18 @@ export default {
this.title = "修改产线信息";
});
},
/** 查看所属工位 */
findStation: function(row) {
const productLineCode = row.productLineCode;
this.$router.push("/base/product-station/index/" + productLineCode);
},
/** 查看下级工序 */
findSubordinateWorkers: function(row) {
const productLineCode = row.productLineCode;
this.$router.push("/base/subordinate-workers/index/" + productLineCode);
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {

@ -1,13 +1,15 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="产线编号" prop="parentId">
<el-input
v-model="queryParams.parentId"
placeholder="请输入产线编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-form-item label="产线编号" prop="parentId" >
<el-select v-model="queryParams.parentId" placeholder="请选择产线" disabled>
<el-option
v-for="item in productLineList"
:key="item.productLineCode"
:label="item.productLineName"
:value="item.productLineCode"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="工位名称" prop="productLineName">
<el-input
@ -301,7 +303,8 @@ export default {
createdBy: null,
createdTime: null,
updatedBy: null,
updatedTime: null
updatedTime: null,
parentId: null
};
this.resetForm("form");
},

Loading…
Cancel
Save