소스 검색

update 检测信息记录

pull/36/head
lb 11 달 전
부모
커밋
90695acefd
4개의 변경된 파일63개의 추가작업 그리고 20개의 파일을 삭제
  1. +6
    -6
      src/views/equipment/analysis/efficiency/index.vue
  2. +24
    -0
      src/views/equipment/timing-diagram/status/index.vue
  3. +32
    -13
      src/views/quality/monitoring/qualityInspectionRecord/dialogForm.vue
  4. +1
    -1
      src/views/quality/monitoring/qualityStatistics/components/graphs/line.vue

+ 6
- 6
src/views/equipment/analysis/efficiency/index.vue 파일 보기

@@ -118,12 +118,12 @@ export default {
{
width: 128,
prop: 'workTime',
label: '工作时长',
label: '工作时长[h]',
},
{
width: 128,
prop: 'workRate',
label: '百分比',
label: '百分比[%]',
filter: (val) => (val != null ? +val.toFixed(3) : '-'),
},
],
@@ -134,9 +134,9 @@ export default {
{
width: 128,
prop: 'stopTime',
label: '停机时长',
label: '停机时长[h]',
},
{ width: 128, prop: 'stopRate', label: '百分比' },
{ width: 128, prop: 'stopRate', label: '百分比[%]' },
],
},
{
@@ -145,10 +145,10 @@ export default {
{
width: 128,
prop: 'downTime',
label: '故障时长',
label: '故障时长[h]',
filter: (val) => (val != null ? +val.toFixed(3) : '-'),
},
{ width: 128, prop: 'downRate', label: '百分比' },
{ width: 128, prop: 'downRate', label: '百分比[%]' },
{
width: 128,
prop: 'timeEfficiency',


+ 24
- 0
src/views/equipment/timing-diagram/status/index.vue 파일 보기

@@ -24,6 +24,7 @@
:formConfigs="searchBarFormConfig"
ref="search-bar"
:remove-blue="true"
@select-changed="handleSearchBarSelectChange"
@headBtnClick="handleSearchBarBtnClick" />
</el-row>

@@ -195,6 +196,7 @@ export default {
placeholder: '请选择产线',
selectOptions: [],
param: 'lineId',
onchange: true,
},
{
type: 'select',
@@ -592,6 +594,28 @@ export default {
}
},

handleSearchBarSelectChange({ param, value }) {
switch (param) {
case 'lineId':
this.$axios({
url: '/base/workshop-section/listByParentId',
method: 'get',
params: {
id: value,
},
}).then(({ code, data }) => {
if (code == 0) {
this.searchBarFormConfig[1].selectOptions = data.map((item) => {
return {
name: item.name,
id: item.id,
};
});
}
});
}
},

handleSearchBarBtnClick({ btnName, ...payload }) {
switch (btnName) {
case 'search':


+ 32
- 13
src/views/quality/monitoring/qualityInspectionRecord/dialogForm.vue 파일 보기

@@ -8,7 +8,7 @@
<template>
<el-form
ref="form"
:model="dataForm"
:model="innerDataForm"
label-width="100px"
v-loading="formLoading">
<el-row :gutter="20">
@@ -18,11 +18,11 @@
prop="inspectionDetId"
:rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
<el-select
v-model="dataForm.inspectionDetId"
v-model="innerDataForm.inspectionDetId"
placeholder="请选择检测内容"
filterable
clearable
@change="$emit('update', dataForm)">
@change="handleInspectionDetChange">
<el-option
v-for="opt in inspectionDetList"
:key="opt.value"
@@ -38,11 +38,11 @@
prop="source"
:rules="[{ required: true, message: '不能为空', trigger: 'blur' }]">
<el-select
v-model="dataForm.source"
v-model="innerDataForm.source"
placeholder="请选择来源"
filterable
clearable
@change="$emit('update', dataForm)">
@change="$emit('update', innerDataForm)">
<el-option
v-for="opt in [
{ label: '手动', value: 1 },
@@ -165,6 +165,7 @@ export default {
productionLineList: [],
sectionList: [],
innerDataForm: {},
cacheInspectionDetList: null,
};
},
mounted() {
@@ -175,15 +176,18 @@ export default {
);
},
watch: {
'innerDataForm.productionLineId': {
handler: async function (plId) {
if (plId) await this.getWorksectionList(plId);
},
immediate: true,
},
// 'innerDataForm.productionLineId': {
// handler: async function (plId) {
// if (plId) await this.getWorksectionList(plId);
// },
// immediate: true,
// },
dataForm: {
handler: function (dataForm) {
this.innerDataForm = JSON.parse(JSON.stringify(dataForm));
this.innerDataForm = Object.assign({}, dataForm);

if (dataForm.productionLineId)
this.getWorksectionList(dataForm.productionLineId);
},
immediate: true,
},
@@ -196,16 +200,28 @@ export default {
resetFields(args) {
return this.$refs.form.resetFields(args);
},

handleInspectionDetChange(value) {
const { id, content } = this.cacheInspectionDetList.find(
(item) => item.id == value
);
this.innerDataForm.inspectionDetId = id;
this.innerDataForm.inspectionDetContent = content;
this.$emit('update', this.innerDataForm);
},

async handleProductlineChange(id) {
await this.getWorksectionList(id);
// await this.getWorksectionList(id);
this.innerDataForm.sectionId = null;
this.$emit('update', this.innerDataForm);
},

// getCode
async getCode(url) {
const response = await this.$axios(url);
return response.data;
},

// 获取产线列表
async getProductLineList() {
const response = await this.$axios('/base/production-line/listAll');
@@ -214,16 +230,19 @@ export default {
value: item.id,
}));
},

// 获取检测内容列表
async getInspectionDetList() {
const response = await this.$axios(
'/base/quality-inspection-det/listAll'
);
this.cacheInspectionDetList = response.data;
this.inspectionDetList = response.data.map((item) => ({
label: item.content,
value: item.id,
}));
},

// 获取工段列表
async getWorksectionList(plId) {
const response = await this.$axios(


+ 1
- 1
src/views/quality/monitoring/qualityStatistics/components/graphs/line.vue 파일 보기

@@ -147,7 +147,7 @@ export default {
},
yAxis: {
type: 'value',
name: '单位/片',
name: '检测数量',
nameTextStyle: {
color: '#999',
fontSize: 14,


불러오는 중...
취소
저장