update - 默认查询条件

master
yinq 11 months ago
parent 474eb526fc
commit 16383ad35d

@ -1,7 +1,7 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="所属产线" prop="productLineCode"> <el-form-item label="所属产线" prop="productLineCode" >
<el-select v-model="queryParams.productLineCode" placeholder="请选择所属产线"> <el-select v-model="queryParams.productLineCode" placeholder="请选择所属产线">
<el-option <el-option
v-for="item in productLineList" v-for="item in productLineList"
@ -44,8 +44,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['base:processStation:add']" v-hasPermi="['base:processStation:add']"
>新增 >新增</el-button>
</el-button>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -56,8 +55,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['base:processStation:edit']" v-hasPermi="['base:processStation:edit']"
>修改 >修改</el-button>
</el-button>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -68,8 +66,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['base:processStation:remove']" v-hasPermi="['base:processStation:remove']"
>删除 >删除</el-button>
</el-button>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -79,8 +76,7 @@
size="mini" size="mini"
@click="handleExport" @click="handleExport"
v-hasPermi="['base:processStation:export']" v-hasPermi="['base:processStation:export']"
>导出 >导出</el-button>
</el-button>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -89,14 +85,13 @@
icon="el-icon-close" icon="el-icon-close"
size="mini" size="mini"
@click="handleClose" @click="handleClose"
>关闭 >关闭</el-button>
</el-button>
</el-col> </el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar>
</el-row> </el-row>
<el-table v-loading="loading" :data="processStationList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="processStationList" @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="processCode" v-if="columns[1].visible"/> <el-table-column label="生产工序编号" align="center" prop="processCode" v-if="columns[1].visible"/>
<el-table-column label="生产工序名称" align="center" prop="processName" v-if="columns[2].visible"/> <el-table-column label="生产工序名称" align="center" prop="processName" v-if="columns[2].visible"/>
@ -131,16 +126,14 @@
type="text" type="text"
icon="el-icon-s-grid" icon="el-icon-s-grid"
@click="findStation(scope.row)" @click="findStation(scope.row)"
>下级工位 >下级工位</el-button>
</el-button>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['base:processStation:edit']" v-hasPermi="['base:processStation:edit']"
>修改 >修改</el-button>
</el-button>
<!-- <el-button--> <!-- <el-button-->
<!-- size="mini"--> <!-- size="mini"-->
<!-- type="text"--> <!-- type="text"-->
@ -164,10 +157,10 @@
<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="100px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form-item label="生产工序编号" prop="processCode"> <el-form-item label="生产工序编号" prop="processCode">
<el-input v-model="form.processCode" placeholder="请输入生产工序编号"/> <el-input v-model="form.processCode" placeholder="请输入生产工序编号" />
</el-form-item> </el-form-item>
<el-form-item label="生产工序名称" prop="processName"> <el-form-item label="生产工序名称" prop="processName">
<el-input v-model="form.processName" placeholder="请输入生产工序名称"/> <el-input v-model="form.processName" placeholder="请输入生产工序名称" />
</el-form-item> </el-form-item>
<el-form-item label="所属产线"> <el-form-item label="所属产线">
<el-select v-model="form.productLineCode" placeholder="请输入所属产线"> <el-select v-model="form.productLineCode" placeholder="请输入所属产线">
@ -190,13 +183,13 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="单位生产时间" prop="productionTime"> <el-form-item label="单位生产时间" prop="productionTime">
<el-input v-model="form.productionTime" placeholder="请输入单位生产时间"/> <el-input v-model="form.productionTime" placeholder="请输入单位生产时间" />
</el-form-item> </el-form-item>
<el-form-item label="日产能" prop="capacityDay"> <el-form-item label="日产能" prop="capacityDay">
<el-input v-model="form.capacityDay" placeholder="请输入日产能"/> <el-input v-model="form.capacityDay" placeholder="请输入日产能" />
</el-form-item> </el-form-item>
<el-form-item label="月产能" prop="capacityMonth"> <el-form-item label="月产能" prop="capacityMonth">
<el-input v-model="form.capacityMonth" placeholder="请输入月产能"/> <el-input v-model="form.capacityMonth" placeholder="请输入月产能" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -208,18 +201,11 @@
</template> </template>
<script> <script>
import { import { listProcessStation, getProcessStation, delProcessStation, addProcessStation, updateProcessStation } from "@/api/base/processStation";
listProcessStation, import { findProductLineList } from "@/api/base/productLine";
getProcessStation,
delProcessStation,
addProcessStation,
updateProcessStation
} from "@/api/base/processStation";
import {findProductLineList} from "@/api/base/productLine";
export default { export default {
name: "ProcessStation", name: "ProcessStation",
dicts: ['is_flag', 'process_type'], dicts: ['is_flag','process_type'],
data() { data() {
return { return {
// //
@ -247,7 +233,7 @@ export default {
processCode: null, processCode: null,
processName: null, processName: null,
processType: 1, processType: 1,
productLineCode: null, productLineCode: 'CX_02',
productionTime: null, productionTime: null,
capacityDay: null, capacityDay: null,
capacityMonth: null, capacityMonth: null,
@ -261,23 +247,24 @@ export default {
// //
form: {}, form: {},
// //
rules: {}, rules: {
},
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: true}, { key: 5, label: `单位生产时间`, visible: true },
{key: 6, label: `日产能`, visible: true}, { key: 6, label: `日产能`, visible: true },
{key: 7, label: `月产能`, visible: true}, { key: 7, label: `月产能`, visible: true },
{key: 8, label: `启用标识`, visible: false}, { key: 8, label: `启用标识`, visible: false },
{key: 9, label: `创建人`, visible: false}, { key: 9, label: `创建人`, visible: false },
{key: 10, label: `创建时间`, visible: false}, { key: 10, label: `创建时间`, visible: false },
{key: 11, label: `更新人`, visible: false}, { key: 11, label: `更新人`, visible: false },
{key: 12, label: `更新时间`, visible: false}, { key: 12, label: `更新时间`, visible: false },
{key: 13, label: `工位编号`, visible: true}, { key: 13, label: `工位编号`, visible: true },
{key: 14, label: `工位名称`, visible: true}, { key: 14, label: `工位名称`, visible: true },
], ],
// 线 // 线
productLineList: [], productLineList: [],
@ -285,38 +272,23 @@ export default {
findStationList: [], findStationList: [],
}; };
}, },
async created() { created() {
if (this.$route.params != null) { if (this.$route.params != null && this.$route.params.productLineCode != null){
this.queryParams.productLineCode = this.$route.params && this.$route.params.productLineCode; this.queryParams.productLineCode = this.$route.params && this.$route.params.productLineCode;
}else{
this.queryParams.productLineCode = 'CX_02'
} }
this.getList();
this.loading = true;
await findProductLineList({productLineType: 1}).then(response => {
this.productLineList = response.data;
})
await findProductLineList({productLineType: 2}).then(response => {
this.findStationList = response.data;
});
await listProcessStation(this.queryParams).then(response => {
this.processStationList = response.rows;
this.total = response.total;
this.loading = false;
});
}, },
methods: { methods: {
/** 查询生产工序/工位信息列表 */ /** 查询生产工序/工位信息列表 */
async getList() { getList() {
this.loading = true; this.loading = true;
await findProductLineList({productLineType: 1}).then(response => { findProductLineList({productLineType: 1}).then(response => {
this.productLineList = response.data; this.productLineList = response.data;
}) });
await findProductLineList({productLineType: 2}).then(response => { findProductLineList({productLineType: 2}).then(response => {
this.findStationList = response.data; this.findStationList = response.data;
}); });
await listProcessStation(this.queryParams).then(response => { listProcessStation(this.queryParams).then(response => {
this.processStationList = response.rows; this.processStationList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
@ -361,7 +333,7 @@ export default {
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map(item => item.objId) this.ids = selection.map(item => item.objId)
this.single = selection.length !== 1 this.single = selection.length!==1
this.multiple = !selection.length this.multiple = !selection.length
}, },
/** 新增按钮操作 */ /** 新增按钮操作 */
@ -371,13 +343,13 @@ export default {
this.title = "添加生产工序/工位信息"; this.title = "添加生产工序/工位信息";
}, },
/** 查看下级工位 */ /** 查看下级工位 */
findStation: function (row) { findStation: function(row) {
const processCode = row.processCode; const processCode = row.processCode;
this.$router.push("/base/productProcess-station/index/" + processCode); this.$router.push("/base/productProcess-station/index/" + processCode);
}, },
/** 返回按钮操作 */ /** 返回按钮操作 */
handleClose() { handleClose() {
const obj = {path: "/base/productLine"}; const obj = { path: "/base/productLine" };
this.$tab.closeOpenPage(obj); this.$tab.closeOpenPage(obj);
}, },
/** 修改按钮操作 */ /** 修改按钮操作 */

@ -251,6 +251,7 @@ export default {
plantCode: null, plantCode: null,
isFlag: null, isFlag: null,
stationType: null, stationType: null,
parentId: 'CX_02',
createdBy: null, createdBy: null,
createdTime: null, createdTime: null,
executionSort: null, executionSort: null,
@ -290,13 +291,13 @@ export default {
if (this.$route.params.processCode != null){ if (this.$route.params.processCode != null){
this.queryParams.processCode = this.$route.params && this.$route.params.processCode; this.queryParams.processCode = this.$route.params && this.$route.params.processCode;
} }
this.getList();
findFactoryList().then(response => { findFactoryList().then(response => {
this.factoryList = response.data; this.factoryList = response.data;
}); });
findProductLineList({productLineType: 1}).then(response => { findProductLineList({productLineType: 1}).then(response => {
this.productLineList = response.data; this.productLineList = response.data;
}); });
this.getList();
}, },
methods: { methods: {
/** 查询工位信息列表 */ /** 查询工位信息列表 */

@ -78,30 +78,38 @@
<el-table v-loading="loading" :data="reportList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="reportList" @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="OBJ_ID" v-if="columns[0].visible"/>
<el-table-column label="产线" align="center" prop="PRODUCT_LINE_CODE" v-if="columns[1].visible"/> <el-table-column label="枪编号" align="center" prop="GUN_CODE" v-if="columns[1].visible"/>
<el-table-column label="夹具箱型" align="center" prop="FIXTUREBOXTYPE" v-if="columns[2].visible"/> <el-table-column label="产线编号" align="center" prop="PRODUCT_LINE_CODE" v-if="columns[2].visible"/>
<el-table-column label="夹具状态" align="center" prop="FIXTURESTATUS" v-if="columns[3].visible"> <el-table-column label="枪POL注料温度" align="center" prop="POL_TEMP" v-if="columns[3].visible">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.BEGIN_DATE, '{y}-{m}-{d}') }}</span> <span>{{ parseTime(scope.row.BEGIN_DATE, '{y}-{m}-{d}') }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="产量" align="center" prop="PRODUCTION" v-if="columns[4].visible"/> <el-table-column label="枪POL注料压力" align="center" prop="POL_HP" v-if="columns[4].visible"/>
<el-table-column label="固化时间" align="center" prop="CURINGTIMESETTINGVALUE" v-if="columns[5].visible"/> <el-table-column label="枪POL注料流量" align="center" prop="POL_VOL" v-if="columns[5].visible"/>
<el-table-column label="1小时" align="center" prop="ANHOUR" v-if="columns[6].visible"/> <el-table-column label="枪POL原料用量" align="center" prop="POL_USAGE" v-if="columns[6].visible"/>
<el-table-column label="2小时" align="center" prop="TWOHOUR" v-if="columns[7].visible"/> <el-table-column label="枪ISO注料温度" align="center" prop="ISO_TEMP" v-if="columns[7].visible"/>
<el-table-column label="3小时" align="center" prop="THREEHOUR" v-if="columns[8].visible"/> <el-table-column label="枪ISO注料压力" align="center" prop="ISO_HP" v-if="columns[8].visible"/>
<el-table-column label="4小时" align="center" prop="FOURHOUR" v-if="columns[9].visible"/> <el-table-column label="枪ISO注料流量" align="center" prop="ISO_VOL" v-if="columns[9].visible"/>
<el-table-column label="5小时" align="center" prop="FIVEHOUR" v-if="columns[10].visible"/> <el-table-column label="枪ISO原料用量" align="center" prop="ISO_USAGE" v-if="columns[10].visible"/>
<el-table-column label="6小时" align="center" prop="SIXHOUR" v-if="columns[11].visible"/> <el-table-column label="枪注料工位号" align="center" prop="POUR_NU" v-if="columns[11].visible"/>
<el-table-column label="7小时" align="center" prop="SEVENHOUR" v-if="columns[12].visible"/> <el-table-column label="枪设定注料时间" align="center" prop="SET_TIME" v-if="columns[12].visible"/>
<el-table-column label="8小时" align="center" prop="EIGHTHOUR" v-if="columns[13].visible"/> <el-table-column label="枪设定注料重量" align="center" prop="SET_WEIGHT" v-if="columns[13].visible"/>
<el-table-column label="9小时" align="center" prop="NINEHOUR" v-if="columns[14].visible"/> <el-table-column label="枪设定注料比例" align="center" prop="SET_RATIO" v-if="columns[14].visible"/>
<el-table-column label="10小时" align="center" prop="TENHOUR" v-if="columns[15].visible"/> <el-table-column label="枪实际注料重量" align="center" prop="POUR_WEIGHT" v-if="columns[15].visible"/>
<el-table-column label="11小时" align="center" prop="ELEVENHOUR" v-if="columns[16].visible"/> <el-table-column label="枪实际注料比例" align="center" prop="POUR_RATIO" v-if="columns[16].visible"/>
<el-table-column label="12小时" align="center" prop="TWELVEHOUR" v-if="columns[17].visible"/> <el-table-column label="枪中压循环时间" align="center" prop="MP_TIME" v-if="columns[17].visible"/>
<el-table-column label="班组开始时间" align="center" prop="STARTTIME" v-if="columns[18].visible"/> <el-table-column label="枪高压循环时间" align="center" prop="HP_TIME" v-if="columns[18].visible"/>
<el-table-column label="班组结束时间" align="center" prop="ENDTIME" v-if="columns[19].visible"/> <el-table-column label="枪液压压力" align="center" prop="HYDR_PRESS" v-if="columns[19].visible"/>
<el-table-column label="枪液压温度" align="center" prop="HYDR_TEMP" v-if="columns[20].visible"/>
<el-table-column label="枪开枪时间" align="center" prop="MIXPIST_ON" v-if="columns[21].visible"/>
<el-table-column label="枪关枪时间" align="center" prop="MIXPIST_OFF" v-if="columns[22].visible"/>
<el-table-column label="枪总产量" align="center" prop="TOTAL_YIELD" v-if="columns[23].visible"/>
<el-table-column label="枪注料结束信号" align="center" prop="POUR_END" v-if="columns[24].visible"/>
<el-table-column label="创建时间" align="center" prop="CREATE_TIME" v-if="columns[25].visible"/>
<el-table-column label="工位编号" align="center" prop="STATIONNUMBER" v-if="columns[26].visible"/>
<el-table-column label="系统状态" align="center" prop="SYSTEMSTATUS" v-if="columns[27].visible"/>
</el-table> </el-table>
<!-- <pagination--> <!-- <pagination-->
@ -166,25 +174,33 @@ export default {
rules: {}, rules: {},
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: true }, { key: 3, label: `枪POL注料温度`, visible: true },
{ key: 4, label: `产量`, visible: true }, { key: 4, label: `枪POL注料压力`, visible: true },
{ key: 5, label: `固化时间`, visible: true }, { key: 5, label: `枪POL注料流量`, visible: true },
{ key: 6, label: `1小时`, visible: true }, { key: 6, label: `枪POL原料用量`, visible: true },
{ key: 7, label: `2小时`, visible: true }, { key: 7, label: `枪ISO注料温度`, visible: true },
{ key: 8, label: `3小时`, visible: true }, { key: 8, label: `枪ISO注料压力`, visible: true },
{ key: 9, label: `4小时`, visible: true }, { key: 9, label: `枪ISO注料流量`, visible: true },
{ key: 10, label: `5小时`, visible: true }, { key: 10, label: `枪ISO原料用量`, visible: true },
{ key: 11, label: `6小时`, visible: true }, { key: 11, label: `枪注料工位号`, visible: true },
{ key: 12, label: `7小时`, visible: true }, { key: 12, label: `枪设定注料时间`, visible: true },
{ key: 13, label: `8小时`, visible: true }, { key: 13, label: `枪设定注料重量`, visible: true },
{ key: 14, label: `9小时`, visible: true }, { key: 14, label: `枪设定注料比例`, visible: true },
{ key: 15, label: `10小时`, visible: true }, { key: 15, label: `枪实际注料重量`, visible: true },
{ key: 16, label: `11小时`, visible: true }, { key: 16, label: `枪实际注料比例`, visible: true },
{ key: 17, label: `12小时`, 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 },
{ key: 20, label: `枪液压温度`, visible: true },
{ key: 21, label: `枪开枪时间`, visible: true },
{ key: 22, label: `枪关枪时间`, visible: true },
{ key: 23, label: `枪总产量`, visible: true },
{ key: 24, label: `枪注料结束信号`, visible: true },
{ key: 25, label: `创建时间`, visible: true },
{ key: 26, label: `工位编号`, visible: true },
{ key: 27, label: `系统状态`, visible: true },
], ],
// 线 // 线
productLineList: [], productLineList: [],

@ -325,7 +325,7 @@ export default {
{ key: 1, label: `箱体码`, visible: true }, { key: 1, label: `箱体码`, visible: true },
{ key: 2, label: `物料名称`, visible: true }, { key: 2, label: `物料名称`, visible: true },
{ key: 3, label: `工序编号`, visible: true }, { key: 3, label: `工序编号`, visible: true },
{ key: 4, label: `检测项编号`, visible: true }, { key: 4, label: `检测项编号`, visible: false },
{ key: 5, label: `质量缺陷编码`, visible: true }, { key: 5, label: `质量缺陷编码`, visible: true },
{ key: 6, label: `质量缺陷名称`, visible: true }, { key: 6, label: `质量缺陷名称`, visible: true },
{ key: 7, label: `处理措施`, visible: true }, { key: 7, label: `处理措施`, visible: true },

@ -41,8 +41,18 @@
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button> <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['system:portLog:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
type="warning" type="warning"

Loading…
Cancel
Save