From d55fef9c7205b412cadc99c2bb2dea9329b7a2c9 Mon Sep 17 00:00:00 2001
From: zhaowei <zhaowei>
Date: 星期三, 31 七月 2024 09:39:19 +0800
Subject: [PATCH] 1、公司级与分厂级看板调整OEE图表样式 2、各看板中的饼图图表增加随分辨率变化而改变自身半径功能,从而更清晰的展示内容标题指示箭头 3、OEE综合效率分析页面新增车间字段
---
src/views/eam/modules/equipmentUnseal/EquipmentUnsealForm.vue | 329 +++++++++++++++++++++++++++++++++---------------------
1 files changed, 199 insertions(+), 130 deletions(-)
diff --git a/src/views/eam/modules/equipmentUnseal/EquipmentUnsealForm.vue b/src/views/eam/modules/equipmentUnseal/EquipmentUnsealForm.vue
index fc83ac7..398b08d 100644
--- a/src/views/eam/modules/equipmentUnseal/EquipmentUnsealForm.vue
+++ b/src/views/eam/modules/equipmentUnseal/EquipmentUnsealForm.vue
@@ -2,29 +2,71 @@
<a-spin :spinning="confirmLoading">
<j-form-container :disabled="formDisabled">
<!-- 涓昏〃鍗曞尯鍩� -->
- <a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
+ <a-form-model
+ ref="form"
+ :model="model"
+ :rules="validatorRules"
+ slot="detail"
+ >
<a-row>
<a-col :span="24">
- <a-form-model-item label="鍗曟嵁鍙�" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="num">
- <a-input v-model="model.num" placeholder="璇疯緭鍏ュ崟鎹彿"></a-input>
+ <a-form-model-item
+ label="鍗曟嵁鍙�"
+ :labelCol="labelCol"
+ :wrapperCol="wrapperCol"
+ prop="num"
+ >
+ <a-input
+ v-model="model.num"
+ placeholder="灏嗙敱绯荤粺鑷姩鐢熸垚"
+ disabled
+ ></a-input>
</a-form-model-item>
</a-col>
- <a-col :span="12" :hidden=true>
- <a-form-model-item label="鍙樺姩鏂瑰紡" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="changeMethod">
- <a-input v-model="model.changeMethod" placeholder="璇疯緭鍏ュ彉鍔ㄦ柟寮�" defaultValue="unseal"></a-input>
+ <a-col
+ :span="12"
+ :hidden=true
+ >
+ <a-form-model-item
+ label="鍙樺姩鏂瑰紡"
+ :labelCol="labelCol"
+ :wrapperCol="wrapperCol"
+ prop="changeMethod"
+ >
+ <a-input
+ v-model="model.changeMethod"
+ placeholder="璇疯緭鍏ュ彉鍔ㄦ柟寮�"
+ defaultValue="unseal"
+ ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
- <a-form-model-item label="澶囨敞" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="remark">
- <a-textarea v-model="model.remark" rows="4" placeholder="璇疯緭鍏ュ娉�" />
+ <a-form-model-item
+ label="澶囨敞"
+ :labelCol="labelCol"
+ :wrapperCol="wrapperCol"
+ prop="remark"
+ >
+ <a-textarea
+ v-model="model.remark"
+ rows="4"
+ placeholder="璇疯緭鍏ュ娉�"
+ />
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</j-form-container>
<!-- 瀛愯〃鍗曞尯鍩� -->
- <a-tabs v-model="activeKey" @change="handleChangeTabs">
- <a-tab-pane tab="璁惧鍚皝鏄庣粏" :key="refKeys[0]" :forceRender="true">
+ <a-tabs
+ v-model="activeKey"
+ @change="handleChangeTabs"
+ >
+ <a-tab-pane
+ tab="璁惧鍚皝鏄庣粏"
+ :key="refKeys[0]"
+ :forceRender="true"
+ >
<j-vxe-table
keep-source
:ref="refKeys[0]"
@@ -37,25 +79,43 @@
:rowSelection="true"
:toolbar="true"
:toolbarConfig="toolbarConfig"
+ :alwaysEdit='true'
+ :bordered='true'
>
-
<template slot="toolbarPrefix">
- <a-button type="primary" @click="selectEquipmentList" :disabled="formDisabled">閫夋嫨璁惧
+ <a-button
+ type="primary"
+ @click="selectEquipmentList"
+ :disabled="formDisabled"
+ >閫夋嫨璁惧
</a-button>
</template>
<!-- 璁惧鍥剧墖鎻掓Ы -->
- <template v-slot:equipmentPhoto='props'>
+ <!-- <template v-slot:equipmentPhoto='props'>
<Tooltip
- placement="top"
- title="棰勮鍥剧墖"
- >
- <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span>
- <img v-else :src="getImgView(text)" :preview="props.rowId" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
- </Tooltip>
- </template>
+ placement="top"
+ title="棰勮鍥剧墖"
+ >
+ <span
+ v-if="!text"
+ style="font-size: 12px;font-style: italic;"
+ >鏃犲浘鐗�</span>
+ <img
+ v-else
+ :src="getImgView(text)"
+ :preview="props.rowId"
+ height="25px"
+ alt=""
+ style="max-width:80px;font-size: 12px;font-style: italic;"
+ />
+ </Tooltip>
+ </template> -->
<template v-slot:action="props">
- <a-popconfirm title="纭畾鍒犻櫎鍚楋紵" @confirm="handleDL(props)">
+ <a-popconfirm
+ title="纭畾鍒犻櫎鍚楋紵"
+ @confirm="handleDL(props)"
+ >
<a>鍒犻櫎</a>
</a-popconfirm>
</template>
@@ -145,103 +205,33 @@
title: '璁惧ID',
key: 'equipmentId',
type: JVXETypes.hidden,
-
defaultValue: ''
},
{
- title: '璁惧缂栫爜',
+ title: '缁熶竴缂栫爜',
key: 'equipmentNum',
type: JVXETypes.normal,
-
- width: '120px',
- // placeholder: '璇疯緭鍏�${title}',
-
- fixed: 'left'
+ width: '150px',
+ align: "center",
},
- {
- title: '璧勪骇缂栫爜',
- key: 'assetNumber',
- type: JVXETypes.normal,
-
- width: '120px',
- fixed: 'left',
-
- defaultValue: ''
- },
- {
- title: '灏佸瓨鍘熷洜',
- key: 'sealReason',
- type: JVXETypes.normal,
- disabled: true,
- width: '200px'
-
- },
- {
- title: '灏佸瓨鏃ユ湡',
- key: 'sealDate',
- type: JVXETypes.normal,
- disabled: true,
- width: '120px'
-
- },
- {
- title: '鍚皝鏃ユ湡',
- key: 'unsealDate',
- type: JVXETypes.datetime,
- width: '200px',
- placeholder: '璇疯緭鍏�${title}',
- defaultValue: '',
- validateRules: [
- {
- required: true, // 蹇呭~
- message: '${title}涓嶈兘涓虹┖' // 鎻愮ず鐨勬枃鏈�
- }]
- },
- {
- title: '鍚皝鍘熷洜',
- key: 'unsealReason',
- type: JVXETypes.textarea,
- width: '200px',
- placeholder: '璇疯緭鍏�${title}',
- defaultValue: '',
- validateRules: [
- {
- required: true, // 蹇呭~
- message: '${title}涓嶈兘涓虹┖' // 鎻愮ず鐨勬枃鏈�
- }]
- },
-
- {
- title: '鐗圭璁惧',
- key: 'specificEquipment',
- type: JVXETypes.hidden,
- disabled: true,
-
- defaultValue: ''
- },
- {
- title: '鐗圭璁惧',
- key: 'specificEquipment_dictText',
- type: JVXETypes.normal,
- disabled: true,
- width: '100px',
- defaultValue: ''
- },
+ // fixed: 'left'
{
title: '璁惧鍚嶇О',
key: 'equipmentName',
type: JVXETypes.normal,
disabled: true,
- width: '200px',
-
+ width: '150px',
+ align: "center",
defaultValue: ''
},
+ // fixed: 'left',
{
title: '璁惧鍨嬪彿',
key: 'model',
type: JVXETypes.normal,
disabled: true,
- width: '120px',
+ width: '150px',
+ align: "center",
defaultValue: ''
},
{
@@ -249,17 +239,87 @@
key: 'specification',
type: JVXETypes.normal,
disabled: true,
- width: '120px',
+ width: '150px',
+ align: "center",
placeholder: '璇疯緭鍏�${title}',
defaultValue: ''
},
+ {
+ title: '璧勪骇缂栫爜',
+ key: 'assetNumber',
+ type: JVXETypes.normal,
+ width: '150px',
+ align: "center",
+ defaultValue: ''
+ },
+ {
+ title: '灏佸瓨鍘熷洜',
+ key: 'sealReason',
+ type: JVXETypes.normal,
+ disabled: true,
+ width: '200px',
+ align: "center",
+ },
+ {
+ title: '灏佸瓨鏃ユ湡',
+ key: 'sealDate',
+ type: JVXETypes.normal,
+ disabled: true,
+ width: '150px',
+ align: "center",
+ },
+ {
+ title: '鍚皝鏃ユ湡',
+ key: 'unsealDate',
+ type: JVXETypes.datetime,
+ width: '150px',
+ align: "center",
+ placeholder: '璇疯緭鍏�${title}',
+ defaultValue: '',
+ validateRules: [{
+ required: true, // 蹇呭~
+ message: '${title}涓嶈兘涓虹┖' // 鎻愮ず鐨勬枃鏈�
+ }]
+ },
+ {
+ title: '鍚皝鍘熷洜',
+ key: 'unsealReason',
+ type: JVXETypes.textarea,
+ width: '200px',
+ align: "center",
+ placeholder: '璇疯緭鍏�${title}',
+ defaultValue: '',
+ validateRules: [{
+ required: true, // 蹇呭~
+ message: '${title}涓嶈兘涓虹┖' // 鎻愮ず鐨勬枃鏈�
+ }]
+ },
+ {
+ title: '鐗圭璁惧',
+ key: 'specificEquipment',
+ type: JVXETypes.hidden,
+ disabled: true,
+ width: '150px',
+ align: "center",
+ defaultValue: ''
+ },
+ {
+ title: '鐗圭璁惧',
+ key: 'specificEquipment_dictText',
+ type: JVXETypes.normal,
+ disabled: true,
+ width: '150px',
+ align: "center",
+ defaultValue: ''
+ },
+
{
title: '璁惧鐘舵��',
key: 'equipmentStatus_dictText',
type: JVXETypes.normal,
disabled: true,
- width: '100px',
- // placeholder: '璇疯緭鍏�${title}',
+ width: '150px',
+ align: "center",
defaultValue: ''
},
// {
@@ -278,7 +338,8 @@
key: 'technologyStatus_dictText',
type: JVXETypes.normal,
disabled: true,
- width: '100px',
+ width: '150px',
+ align: "center",
defaultValue: ''
},
{
@@ -286,15 +347,16 @@
key: 'location',
type: JVXETypes.normal,
disabled: true,
- width: '120px'
-
+ width: '150px',
+ align: "center",
},
{
title: '閲嶈搴�',
key: 'equipmentImportanceId_dictText',
type: JVXETypes.normal,
disabled: true,
- width: '100px',
+ width: '150px',
+ align: "center",
// placeholder: '璇疯緭鍏�${title}',
defaultValue: ''
},
@@ -303,29 +365,29 @@
key: 'equipmentImportanceId',
type: JVXETypes.hidden
},
- {
- title: '璁惧鍥剧墖',
- key: 'equipmentPhoto',
- type: JVXETypes.slot,
- disabled: true,
- width: '120px',
- slotName:'equipmentPhoto'
-
- },
- {
- title: '鎿嶄綔',
- key: 'action',
- type: JVXETypes.slot,
- disabled: true,
- width: '100px',
- slotName: 'action',
- },
+ // {
+ // title: '璁惧鍥剧墖',
+ // key: 'equipmentPhoto',
+ // type: JVXETypes.slot,
+ // disabled: true,
+ // width: '120px',
+ // slotName: 'equipmentPhoto'
+ // },
+ // {
+ // title: '鎿嶄綔',
+ // key: 'action',
+ // type: JVXETypes.slot,
+ // disabled: true,
+ // width: '100px',
+ // slotName: 'action',
+ // },
]
},
url: {
add: '/eam/equipmentUnseal/add',
edit: '/eam/equipmentUnseal/edit',
queryById: '/eam/equipmentUnseal/queryById',
+ getNum: '/eam/sysIdentity/getNumNew',
equipmentUnsealDetail: {
list: '/eam/equipmentUnseal/listEquipmentUnsealDetailByMainId'
}
@@ -355,6 +417,7 @@
created() {
},
methods: {
+
//閫夋嫨璁惧
selectEquipmentList() {
let ids = []
@@ -391,8 +454,8 @@
location: data[i].location,
equipmentImportanceId_dictText: data[i].equipmentImportanceId_dictText,
equipmentImportanceId: data[i].equipmentImportanceId,
- sealReason:data[i].sealReason,
- sealDate:data[i].sealDate
+ sealReason: data[i].sealReason,
+ sealDate: data[i].sealDate
}
}
addRows.push(sealDetail)
@@ -400,9 +463,9 @@
this.$refs.equipmentUnsealDetail.pushRows(addRows)
},
handleDL(props) {
- // 璋冪敤鍒犻櫎鏂规硶
- props.target.removeRows(props.row)
- },
+ // 璋冪敤鍒犻櫎鏂规硶
+ props.target.removeRows(props.row)
+ },
addBefore() {
this.equipmentUnsealDetailTable.dataSource = []
},
@@ -416,8 +479,14 @@
})
// 鍔犺浇瀛愯〃鏁版嵁
if (this.model.id) {
- let params = { equipmentChangeId: this.model.id}
+ let params = { equipmentChangeId: this.model.id }
this.requestSubTableData(this.url.equipmentUnsealDetail.list, params, this.equipmentUnsealDetailTable)
+ }else{
+ getAction(this.url.getNum, { type: 'EquipmentUnseal', length: '4' }).then((res) => {
+ if (res.success) {
+ this.model.num = res.message
+ }
+ })
}
},
//鏍¢獙鎵�鏈変竴瀵逛竴瀛愯〃琛ㄥ崟
--
Gitblit v1.9.3