projects/mes-zhp #101
@ -1,3 +1,10 @@
|
||||
/*
|
||||
* @Author: zhp
|
||||
* @Date: 2023-10-17 09:26:38
|
||||
* @LastEditTime: 2023-11-20 15:50:08
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
*/
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 创建质量检测信息基础
|
||||
@ -52,3 +59,11 @@ export function exportQualityInspectionDetExcel(query) {
|
||||
responseType: 'blob'
|
||||
})
|
||||
}
|
||||
|
||||
export function getQualityInspectionDetList(query) {
|
||||
return request({
|
||||
url: '/base/quality-inspection-det/listAll',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
* @Author: zwq
|
||||
* @Date: 2021-07-19 15:18:30
|
||||
* @LastEditors: zhp
|
||||
* @LastEditTime: 2023-11-15 16:04:06
|
||||
* @LastEditTime: 2023-11-22 13:58:30
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
@ -14,6 +14,8 @@
|
||||
}">
|
||||
<img src="../../assets/img/logo.png" style="width:1.1em;position:relative;top:.4em" alt="">
|
||||
许昌安彩AGV原片周转看板
|
||||
<h3 class="unit">单位:河南汇融科技服务有限公司</h3>
|
||||
<h3 class="time">{{ times }}</h3>
|
||||
<!-- <el-button
|
||||
type="text"
|
||||
class="title-button"
|
||||
@ -87,11 +89,11 @@
|
||||
<!-- <div style="width: 45%;position: absolute; top: 3em; right: 3em;">
|
||||
<top-radio-group />
|
||||
</div> -->
|
||||
<el-row :gutter="9 * beilv">
|
||||
<el-col :style="{ margin: 8 + 'px' + ' 0' }" :span="24">
|
||||
<!-- <el-row :gutter="9 * beilv"> -->
|
||||
<!-- <el-col :style="{ margin: 8 + 'px' + ' 0' }" :span="24"> -->
|
||||
<base-table :page="1" :limit="9" :show-index="false" :beilv="1" :table-config="inventoryTableProps"
|
||||
:table-data="inventoryList" />
|
||||
</el-col>
|
||||
<!-- </el-col> -->
|
||||
<!-- <el-col :style="{ margin: 8 + 'px' + ' 0' }" :span="12">
|
||||
<base-table3
|
||||
:page="2"
|
||||
@ -101,7 +103,7 @@
|
||||
:table-data="qualityList2"
|
||||
/>
|
||||
</el-col> -->
|
||||
</el-row>
|
||||
<!-- </el-row> -->
|
||||
</base-container>
|
||||
</el-col>
|
||||
<el-col :style="{ margin: 8 + 'px' + ' 0' }" :span="12">
|
||||
@ -666,7 +668,8 @@ export default {
|
||||
return {
|
||||
beilv: 1,
|
||||
beilv2: 1,
|
||||
clientWidth:0,
|
||||
clientWidth: 0,
|
||||
times:undefined,
|
||||
value: 100,
|
||||
qualityYearTableProps,
|
||||
cxNameList,
|
||||
@ -748,6 +751,7 @@ export default {
|
||||
// this.fetchList('order-process')
|
||||
// this.fetchList('line-chart-data')
|
||||
this.init()
|
||||
this.getTimes()
|
||||
this.windowWidth(document.documentElement.clientWidth)
|
||||
},
|
||||
mounted() {
|
||||
@ -776,6 +780,30 @@ export default {
|
||||
// removeEventListener('resize', resizeFun)
|
||||
// },
|
||||
methods: {
|
||||
getTimes() {
|
||||
setInterval(this.getTimesInterval, 1000);
|
||||
},
|
||||
getTimesInterval: function () {
|
||||
let _this = this;
|
||||
let year = new Date().getFullYear(); //获取当前时间的年份
|
||||
let month = new Date().getMonth() + 1; //获取当前时间的月份
|
||||
let day = new Date().getDate(); //获取当前时间的天数
|
||||
let hours = new Date().getHours(); //获取当前时间的小时
|
||||
let minutes = new Date().getMinutes(); //获取当前时间的分数
|
||||
let seconds = new Date().getSeconds(); //获取当前时间的秒数
|
||||
//当小于 10 的是时候,在前面加 0
|
||||
if (hours < 10) {
|
||||
hours = "0" + hours;
|
||||
}
|
||||
if (minutes < 10) {
|
||||
minutes = "0" + minutes;
|
||||
}
|
||||
if (seconds < 10) {
|
||||
seconds = "0" + seconds;
|
||||
}
|
||||
//拼接格式化当前时间
|
||||
this.times = year + "-" + month + "-" + day + " " + hours + ":" + minutes + ":" + seconds;
|
||||
},
|
||||
windowWidth(value) {
|
||||
this.clientWidth = value
|
||||
},
|
||||
@ -846,7 +874,19 @@ export default {
|
||||
background-size: 100% 100%;
|
||||
color: #00fff0;
|
||||
text-align: center;
|
||||
|
||||
position: relative;
|
||||
.unit{
|
||||
position: absolute;
|
||||
left: 260px;
|
||||
top:25px;
|
||||
font-size: 20px;
|
||||
}
|
||||
.time{
|
||||
position: absolute;
|
||||
left: 1360px;
|
||||
top:25px;
|
||||
font-size: 20px;
|
||||
}
|
||||
.title-button {
|
||||
color: #00fff0;
|
||||
font-size: 20px;
|
||||
|
@ -6,13 +6,37 @@
|
||||
-->
|
||||
|
||||
<template>
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="dataForm"
|
||||
label-width="120px"
|
||||
v-loading="formLoading">
|
||||
<el-form ref="form" :model="dataForm" label-width="120px" v-loading="formLoading">
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="产线" prop="productionLineId"
|
||||
:rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-select v-model="dataForm.productionLineId" placeholder="请选择产线" filterable
|
||||
@change="handleProductlineChange">
|
||||
<el-option v-for="opt in productionLineList" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="工段" prop="sectionId" :rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-select v-model="dataForm.sectionId" placeholder="请选择工段" filterable @change="$emit('update', dataForm)">
|
||||
<el-option v-for="opt in workshopSectionList" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item label="按钮盒识别码" prop="buttonId" :rules="[
|
||||
{ required: true, message: '不能为空', trigger: 'blur' },
|
||||
{
|
||||
type: 'number',
|
||||
message: '请输入整数',
|
||||
trigger: 'blur',
|
||||
transform: (val) => Number.isInteger(Number(val)) && Number(val),
|
||||
},
|
||||
]">
|
||||
<el-input v-model="dataForm.buttonId" @change="$emit('update', dataForm)" placeholder="请输入整数" />
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
label="产线"
|
||||
prop="productionLineId"
|
||||
@ -78,20 +102,8 @@
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item label="按钮盒模式" prop="model">
|
||||
<el-input
|
||||
v-model="dataForm.model"
|
||||
@change="$emit('update', dataForm)"
|
||||
placeholder="请输入按钮盒模式" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item
|
||||
label="按钮值"
|
||||
prop="keyValue"
|
||||
:rules="[
|
||||
{ required: true, message: '按钮值不能为空', trigger: 'blur' },
|
||||
<el-form-item label="按钮值" prop="keyValue" :rules="[
|
||||
{ required: true, message: '不能为空', trigger: 'blur' },
|
||||
{
|
||||
type: 'number',
|
||||
message: '请输入100以内的整数',
|
||||
@ -103,23 +115,17 @@
|
||||
Number(val),
|
||||
},
|
||||
]">
|
||||
<el-input
|
||||
v-model="dataForm.keyValue"
|
||||
type="number"
|
||||
min="0"
|
||||
max="100"
|
||||
@change="$emit('update', dataForm)"
|
||||
<el-input v-model="dataForm.keyValue" type="number" min="0" max="100" @change="$emit('update', dataForm)"
|
||||
placeholder="请输入按钮盒模式" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item label="检测内容" prop="inspectionDetContent">
|
||||
<el-input
|
||||
type="textarea"
|
||||
v-model="dataForm.inspectionDetContent"
|
||||
placeholder="请输入检测内容"
|
||||
@change="$emit('update', dataForm)"></el-input>
|
||||
<el-form-item label="检测内容" prop="inspectionDetId">
|
||||
<el-select v-model="dataForm.inspectionDetId" placeholder="请选择检测内容" filterable
|
||||
@change="$emit('update', dataForm)">
|
||||
<el-option v-for="opt in inspectionDetList" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@ -145,11 +151,13 @@ export default {
|
||||
return {
|
||||
formLoading: true,
|
||||
productionLineList: [],
|
||||
inspectionDetList:[],
|
||||
workshopSectionList: [],
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.getProductionLineList();
|
||||
this.getProductionLineList()
|
||||
this.getQualityInspectionDetList()
|
||||
// this.getWorksectionList();
|
||||
// this.getCode('/base/equipment-group-alarm/getCode').then((code) => {
|
||||
// this.formLoading = false;
|
||||
@ -189,7 +197,20 @@ export default {
|
||||
}
|
||||
this.formLoading = false;
|
||||
},
|
||||
|
||||
async getQualityInspectionDetList() {
|
||||
this.formLoading = true;
|
||||
const res = await this.$axios({
|
||||
url: '/base/quality-inspection-det/listAll',
|
||||
method: 'get',
|
||||
});
|
||||
if (res.code == 0) {
|
||||
this.inspectionDetList = res.data.map((item) => ({
|
||||
label: item.content,
|
||||
value: item.id,
|
||||
}));
|
||||
}
|
||||
this.formLoading = false;
|
||||
},
|
||||
async getWorksectionList(id) {
|
||||
this.formLoading = true;
|
||||
const res = await this.$axios({
|
||||
|
@ -120,9 +120,14 @@ export default {
|
||||
bind: { type: 'number', min: 0, max: 100 },
|
||||
},
|
||||
{
|
||||
textarea: true,
|
||||
select: true,
|
||||
label: '检测内容',
|
||||
prop: 'inspectionDetContent',
|
||||
url: '/base/quality-inspection-det/listAll',
|
||||
prop: 'inspectionDetId',
|
||||
rules: [{ required: true, message: '不能为空', trigger: 'blur' }],
|
||||
bind: {
|
||||
filterable: true,
|
||||
},
|
||||
},
|
||||
],
|
||||
],
|
||||
@ -217,7 +222,7 @@ export default {
|
||||
form: {
|
||||
id: null,
|
||||
buttonId: null,
|
||||
inspectionDetContent: null,
|
||||
inspectionDetId: null,
|
||||
productionLineId: null,
|
||||
sectionId: null,
|
||||
model: null,
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-11-06 15:15:30
|
||||
* @LastEditTime: 2023-11-06 16:00:24
|
||||
* @LastEditTime: 2023-11-20 15:23:59
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
@ -10,18 +10,18 @@
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="报废原因编码" prop="code">
|
||||
<el-input v-model="dataForm.code" placeholder="请输入报废类型编码" />
|
||||
<el-input v-model="dataForm.code" placeholder="请输入报废原因编码" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="报废原因" prop="content">
|
||||
<el-input v-model="dataForm.content" placeholder="请输入报废类型" />
|
||||
<el-input v-model="dataForm.content" placeholder="请输入报废原因" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="报废类型" prop="description">
|
||||
<el-form-item label="报废类型" prop="typeId">
|
||||
<el-select v-model="dataForm.typeId" placeholder="请选择报废类型">
|
||||
<el-option v-for="dict in typeList" :key="dict.id" :label="dict.name" :value="dict.id" />
|
||||
</el-select>
|
||||
@ -68,6 +68,7 @@ export default {
|
||||
// materialId: [{ required: true, message: "", trigger: "blur" }],
|
||||
code: [{ required: true, message: "报废原因编码不能为空", trigger: "blur" }],
|
||||
content: [{ required: true, message: "报废原因不能为空", trigger: "blur" }],
|
||||
typeId: [{ required: true, message: "报废类型不能为空", trigger: "change" }],
|
||||
}
|
||||
};
|
||||
},
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-11-06 15:15:30
|
||||
* @LastEditTime: 2023-11-07 18:56:20
|
||||
* @LastEditTime: 2023-11-21 14:11:18
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
@ -23,8 +23,8 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="数量" prop="sum">
|
||||
<el-input v-model="dataForm.sum" placeholder="请输入数量" />
|
||||
<el-form-item label="数量" prop="num">
|
||||
<el-input v-model="dataForm.num" placeholder="请输入数量" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@ -176,9 +176,9 @@ export default {
|
||||
getDetList().then((res) => {
|
||||
console.log(res);
|
||||
// console.log(response);
|
||||
this.workOrderList = res.data.map((item) => {
|
||||
this.detList = res.data.map((item) => {
|
||||
return {
|
||||
name: item.name,
|
||||
name: item.content,
|
||||
id: item.id
|
||||
}
|
||||
})
|
||||
|
@ -1,8 +1,6 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<!-- 搜索工作栏 -->
|
||||
<SearchBar :formConfigs="searchBarFormConfig" ref="search-bar" @headBtnClick="handleSearchBarBtnClick" />
|
||||
|
||||
<!-- 列表 -->
|
||||
<el-row>
|
||||
<el-col class="custom-tabs">
|
||||
@ -20,6 +18,7 @@
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane :label="'\u3000图形数据\u3000'" name="chart" style="overflow: inherit">
|
||||
<SearchBar :formConfigs="searchBarFormConfig" ref="search-bar" @headBtnClick="handleSearchBarBtnClick" />
|
||||
<div id="main" style="height: 500px;width: 1000px;"></div>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
@ -75,13 +74,13 @@ export default {
|
||||
},
|
||||
activeName: 'table',
|
||||
searchBarFormConfig: [
|
||||
// {
|
||||
// type: 'select',
|
||||
// label: '工单号',
|
||||
{
|
||||
type: 'label',
|
||||
label: '当前检测数据柱状图',
|
||||
// placeholder: '请选择工单号',
|
||||
// param: 'workOrderId',
|
||||
// selectOptions: [],
|
||||
// },
|
||||
},
|
||||
// {
|
||||
// type: 'select',
|
||||
// label: '产品',
|
||||
@ -95,40 +94,40 @@ export default {
|
||||
// placeholder: '请输入检测内容',
|
||||
// param: 'inspectionDetContent',
|
||||
// },
|
||||
{
|
||||
type: 'datePicker',
|
||||
label: '时间段',
|
||||
dateType: 'daterange', // datetimerange
|
||||
// format: 'yyyy-MM-dd HH:mm:ss',
|
||||
format: 'yyyy-MM-dd',
|
||||
valueFormat: 'timestamp',
|
||||
rangeSeparator: '-',
|
||||
startPlaceholder: '开始日期',
|
||||
endPlaceholder: '结束日期',
|
||||
defaultTime: ['00:00:00', '23:59:59'],
|
||||
param: 'checkTime',
|
||||
// width: 350,
|
||||
},
|
||||
{
|
||||
type: 'button',
|
||||
btnName: '查询',
|
||||
name: 'search',
|
||||
color: 'primary',
|
||||
},
|
||||
{
|
||||
type: 'separate',
|
||||
},
|
||||
// {
|
||||
// type: this.$auth.hasPermi(
|
||||
// 'base:quality-inspection-record:create'
|
||||
// )
|
||||
// ? 'button'
|
||||
// : '',
|
||||
// btnName: '新增',
|
||||
// name: 'add',
|
||||
// plain: true,
|
||||
// color: 'success',
|
||||
// type: 'datePicker',
|
||||
// label: '时间段',
|
||||
// dateType: 'daterange', // datetimerange
|
||||
// // format: 'yyyy-MM-dd HH:mm:ss',
|
||||
// format: 'yyyy-MM-dd',
|
||||
// valueFormat: 'timestamp',
|
||||
// rangeSeparator: '-',
|
||||
// startPlaceholder: '开始日期',
|
||||
// endPlaceholder: '结束日期',
|
||||
// defaultTime: ['00:00:00', '23:59:59'],
|
||||
// param: 'checkTime',
|
||||
// // width: 350,
|
||||
// },
|
||||
// {
|
||||
// type: 'button',
|
||||
// btnName: '查询',
|
||||
// name: 'search',
|
||||
// color: 'primary',
|
||||
// },
|
||||
// {
|
||||
// type: 'separate',
|
||||
// },
|
||||
// // {
|
||||
// // type: this.$auth.hasPermi(
|
||||
// // 'base:quality-inspection-record:create'
|
||||
// // )
|
||||
// // ? 'button'
|
||||
// // : '',
|
||||
// // btnName: '新增',
|
||||
// // name: 'add',
|
||||
// // plain: true,
|
||||
// // color: 'success',
|
||||
// // },
|
||||
],
|
||||
// tableBtn: [
|
||||
// this.$auth.hasPermi('base:quality-inspection-record:update')
|
||||
@ -316,6 +315,7 @@ export default {
|
||||
data: arrYAxis,
|
||||
type: 'bar',
|
||||
showBackground: true,
|
||||
barWidth:'20',
|
||||
backgroundStyle: {
|
||||
color: 'rgba(180, 180, 180, 0.2)'
|
||||
}
|
||||
|
@ -6,91 +6,40 @@
|
||||
-->
|
||||
|
||||
<template>
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="innerDataForm"
|
||||
label-width="100px"
|
||||
v-loading="formLoading">
|
||||
<el-form ref="form" :model="innerDataForm" label-width="100px" v-loading="formLoading">
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item
|
||||
label="检测内容"
|
||||
prop="inspectionDetId"
|
||||
:rules="[{ required: true, message: '检测内容不能为空', trigger: 'blur' }]">
|
||||
<el-select
|
||||
v-model="innerDataForm.inspectionDetId"
|
||||
placeholder="请选择检测内容"
|
||||
filterable
|
||||
clearable
|
||||
@change="handleInspectionDetChange">
|
||||
<el-option
|
||||
v-for="opt in inspectionDetList"
|
||||
:key="opt.value"
|
||||
:label="opt.label"
|
||||
:value="opt.value" />
|
||||
<el-form-item label="工单号" prop="workOrderId" :rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-select v-model="innerDataForm.workOrderId" placeholder="请选择工单号" filterable clearable>
|
||||
<el-option v-for="opt in workOrderList" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item
|
||||
label="来源"
|
||||
prop="source"
|
||||
:rules="[{ required: true, message: '来源不能为空', trigger: 'blur' }]">
|
||||
<el-select
|
||||
v-model="innerDataForm.source"
|
||||
placeholder="请选择来源"
|
||||
filterable
|
||||
clearable
|
||||
@change="$emit('update', innerDataForm)">
|
||||
<el-option
|
||||
v-for="opt in [
|
||||
{ label: '手动', value: 1 },
|
||||
{ label: '自动', value: 2 },
|
||||
]"
|
||||
:key="opt.value"
|
||||
:label="opt.label"
|
||||
:value="opt.value" />
|
||||
<el-form-item label="检测内容" prop="inspectionDetId"
|
||||
:rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-select v-model="innerDataForm.inspectionDetId" placeholder="请选择检测内容" filterable clearable
|
||||
@change="handleInspectionDetChange">
|
||||
<el-option v-for="opt in inspectionDetList" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item
|
||||
label="产线"
|
||||
prop="productionLineId"
|
||||
:rules="[{ required: true, message: '产线不能为空', trigger: 'blur' }]">
|
||||
<el-select
|
||||
v-model="innerDataForm.productionLineId"
|
||||
placeholder="请选择产线"
|
||||
filterable
|
||||
clearable
|
||||
<el-form-item label="产线" prop="productionLineId"
|
||||
:rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-select v-model="innerDataForm.productionLineId" placeholder="请选择产线" filterable clearable
|
||||
@change="handleProductlineChange">
|
||||
<el-option
|
||||
v-for="opt in productionLineList"
|
||||
:key="opt.value"
|
||||
:label="opt.label"
|
||||
:value="opt.value" />
|
||||
<el-option v-for="opt in productionLineList" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item
|
||||
label="工段"
|
||||
prop="sectionId"
|
||||
:rules="[{ required: true, message: '工段不能为空', trigger: 'blur' }]">
|
||||
<el-select
|
||||
v-model="innerDataForm.sectionId"
|
||||
placeholder="请选择工段"
|
||||
clearable
|
||||
filterable
|
||||
<el-form-item label="工段" prop="sectionId" :rules="[{ required: false, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-select v-model="innerDataForm.sectionId" placeholder="请选择工段" clearable filterable
|
||||
@change="$emit('update', innerDataForm)">
|
||||
<el-option
|
||||
v-for="opt in sectionList"
|
||||
:key="opt.value"
|
||||
:label="opt.label"
|
||||
:value="opt.value" />
|
||||
<el-option v-for="opt in sectionList" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
@ -98,45 +47,36 @@
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="检测人员" prop="checkPerson">
|
||||
<el-input
|
||||
v-model="innerDataForm.checkPerson"
|
||||
clearable
|
||||
@change="$emit('update', innerDataForm)"
|
||||
<el-input v-model="innerDataForm.checkPerson" clearable @change="$emit('update', innerDataForm)"
|
||||
placeholder="请输入检测人员" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item
|
||||
label="检测时间"
|
||||
prop="checkTime"
|
||||
:rules="[{ required: true, message: '检测时间不能为空', trigger: 'blur' }]">
|
||||
<el-date-picker
|
||||
v-model="innerDataForm.checkTime"
|
||||
type="datetime"
|
||||
placeholder="请选择检测时间"
|
||||
value-format="timestamp"
|
||||
@change="$emit('update', innerDataForm)"></el-date-picker>
|
||||
<el-form-item label="检测时间" prop="checkTime" :rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-date-picker v-model="innerDataForm.checkTime" type="datetime" placeholder="请选择检测时间"
|
||||
value-format="timestamp" @change="$emit('update', innerDataForm)"></el-date-picker>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-row :gutter="20">
|
||||
<el-col>
|
||||
<el-form-item label="描述" prop="explainText">
|
||||
<el-input
|
||||
v-model="innerDataForm.explainText"
|
||||
placeholder="请输入描述信息"
|
||||
@change="$emit('update', innerDataForm)"
|
||||
type="textarea"></el-input>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="来源" prop="source" :rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
|
||||
<el-select v-model="innerDataForm.source" placeholder="请选择来源" filterable clearable
|
||||
@change="$emit('update', innerDataForm)">
|
||||
<el-option v-for="opt in [
|
||||
{ label: '手动', value: 1 },
|
||||
{ label: '自动', value: 2 },
|
||||
]" :key="opt.value" :label="opt.label" :value="opt.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="20">
|
||||
<el-col>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input
|
||||
v-model="innerDataForm.remark"
|
||||
@change="$emit('update', innerDataForm)"
|
||||
placeholder="请输入备注"></el-input>
|
||||
<el-input v-model="innerDataForm.remark" @change="$emit('update', innerDataForm)" placeholder="请输入备注">
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@ -164,12 +104,13 @@ export default {
|
||||
inspectionDetList: [],
|
||||
productionLineList: [],
|
||||
sectionList: [],
|
||||
workOrderList:[],
|
||||
innerDataForm: {},
|
||||
cacheInspectionDetList: null,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
Promise.all([this.getProductLineList(), this.getInspectionDetList()]).then(
|
||||
Promise.all([this.getProductLineList(), this.getInspectionDetList(), this.getWorkOrderList()]).then(
|
||||
() => {
|
||||
this.formLoading = false;
|
||||
}
|
||||
@ -231,6 +172,14 @@ export default {
|
||||
}));
|
||||
},
|
||||
|
||||
async getWorkOrderList() {
|
||||
const response = await this.$axios('base/core-work-order/listbyfilter');
|
||||
this.workOrderList = response.data.map((item) => ({
|
||||
label: item.name,
|
||||
value: item.id,
|
||||
}));
|
||||
},
|
||||
|
||||
// 获取检测内容列表
|
||||
async getInspectionDetList() {
|
||||
const response = await this.$axios(
|
||||
|
@ -113,7 +113,7 @@ export default {
|
||||
bind: {
|
||||
filterable: true,
|
||||
},
|
||||
rules: [{ required: true, message: '工段不能为空', trigger: 'blur' }],
|
||||
rules: [{ required: false, message: '不能为空', trigger: 'blur' }],
|
||||
},
|
||||
],
|
||||
[
|
||||
@ -141,16 +141,19 @@ export default {
|
||||
searchBarFormConfig: [
|
||||
{
|
||||
type: 'select',
|
||||
label: '产线',
|
||||
placeholder: '请选择产线',
|
||||
param: 'productionLineId',
|
||||
label: '工单号',
|
||||
placeholder: '请选择工单号',
|
||||
param: 'workOrderId',
|
||||
selectOptions: [],
|
||||
filterable:true
|
||||
},
|
||||
{
|
||||
type: 'input',
|
||||
type: 'select',
|
||||
label: '检测内容',
|
||||
placeholder: '请输入检测内容',
|
||||
selectOptions: [],
|
||||
param: 'inspectionDetContent',
|
||||
filterable: true
|
||||
},
|
||||
{
|
||||
type: 'datePicker',
|
||||
@ -208,6 +211,11 @@ export default {
|
||||
fixed: true,
|
||||
width: 180,
|
||||
filter: (val) => moment(val).format('yyyy-MM-DD HH:mm:ss'),
|
||||
},
|
||||
{
|
||||
// width: 128,
|
||||
prop: 'workOrderName',
|
||||
label: '工单Id',
|
||||
},
|
||||
{
|
||||
// width: 128,
|
||||
@ -247,6 +255,7 @@ export default {
|
||||
productionLineId: undefined,
|
||||
sectionId: undefined,
|
||||
checkPerson: undefined,
|
||||
workOrderId:undefined,
|
||||
checkTime: undefined,
|
||||
source: undefined,
|
||||
explainText: undefined,
|
||||
@ -256,15 +265,16 @@ export default {
|
||||
queryParams: {
|
||||
pageNo: 1,
|
||||
pageSize: 10,
|
||||
workOrderId:null,
|
||||
inspectionDetContent: null,
|
||||
checkTime: [],
|
||||
productionLineId: null,
|
||||
// productionLineId: null,
|
||||
},
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getList();
|
||||
// this.getProductLineList();
|
||||
this.getProductLineList()
|
||||
},
|
||||
watch: {
|
||||
form: {
|
||||
@ -300,7 +310,7 @@ export default {
|
||||
methods: {
|
||||
/** 获取搜索栏的产线列表 */
|
||||
getProductLineList() {
|
||||
this.$axios('/base/production-line/listAll').then((response) => {
|
||||
this.$axios('/base/core-work-order/listbyfilter').then((response) => {
|
||||
this.searchBarFormConfig[0].selectOptions = response.data.map(
|
||||
(item) => {
|
||||
return {
|
||||
@ -309,6 +319,16 @@ export default {
|
||||
};
|
||||
}
|
||||
);
|
||||
})
|
||||
this.$axios('/base/quality-inspection-det/listAll').then((response) => {
|
||||
this.searchBarFormConfig[1].selectOptions = response.data.map(
|
||||
(item) => {
|
||||
return {
|
||||
name: item.content,
|
||||
id: item.content,
|
||||
};
|
||||
}
|
||||
);
|
||||
});
|
||||
},
|
||||
/** 查询列表 */
|
||||
|
@ -206,6 +206,16 @@ export default {
|
||||
computed: {
|
||||
tableProps() {
|
||||
return [
|
||||
{
|
||||
// width: 128,
|
||||
prop: 'workOrderId',
|
||||
label: '工单号',
|
||||
},
|
||||
{
|
||||
// width: 128,
|
||||
prop: 'productionName',
|
||||
label: '产品',
|
||||
},
|
||||
{
|
||||
// width: 160,
|
||||
prop: 'inspectionContent',
|
||||
@ -214,8 +224,8 @@ export default {
|
||||
...this.dynamicProps,
|
||||
{
|
||||
// width: 128,
|
||||
prop: 'sumInput',
|
||||
label: '检测类型总数',
|
||||
prop: 'sumScrap',
|
||||
label: '未检测总数',
|
||||
},
|
||||
{
|
||||
// width: 128,
|
||||
@ -342,6 +352,8 @@ export default {
|
||||
inspectionContent: item.inspectionContent,
|
||||
...keyValuePairs,
|
||||
sumInput: item.sumInput,
|
||||
productionName: item.productionName,
|
||||
workOrderId: item.workOrderId,
|
||||
scrapRatio: item.scrapRatio,
|
||||
};
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user