From 240c74ffb2b98faddf76648116ca9eeb61ee2cde Mon Sep 17 00:00:00 2001 From: qushaowei <qushaowei@163.com> Date: 星期四, 11 一月 2024 09:34:49 +0800 Subject: [PATCH] 问题项修改 --- src/views/eam/EquipmentListOfTester.vue | 975 ++- src/views/eam/EquipmentMaintenancePlanList.vue | 646 +- src/views/eam/EquipmentListOfProduct.vue | 975 ++- src/views/eam/EquipmentListOfTruck.vue | 975 ++- src/views/eam/EquipmentListOfEnvProEquipment.vue | 985 ++- src/views/eam/EquipmentListOfCrane.vue | 973 ++- src/views/eam/ABC/StreamList.vue | 579 +- src/views/eam/EquipmentListOfAll.vue | 1013 ++- src/views/eam/modules/malfunctionRepair/FaultDescriptionList.vue | 9 src/views/eam/DeductionItemList.vue | 326 src/views/eam/MalfunctionRepair.vue | 47 src/views/eam/modules/malfunctionRepair/MalfunctionRepaireModal.vue | 147 src/views/eam/EquipmentListOfFilesCarousel.vue | 973 ++- src/views/eam/EquipmentListOfPressureVessel.vue | 973 ++- src/views/eam/OperationCertificateList.vue | 243 src/views/eam/DailyInspectionStandardList.vue | 4 src/views/eam/RepairOrderList.vue | 171 src/views/eam/OperationCertificateApplyList.vue | 477 + src/views/eam/EquipmentOfLine.vue | 553 +- src/views/eam/DailyMaintenanceStandardList.vue | 4 src/views/eam/EquipmentCalibrationOrder.vue | 8 src/views/eam/modules/operationCertificate/OperationCertificateDetailList.vue | 181 src/views/eam/EquipmentListOfRide.vue | 973 ++- src/views/eam/EquipmentListOfWeldingMachine.vue | 975 ++- src/views/eam/modules/malfunctionRepair/AcceptModel.vue | 40 25 files changed, 7,619 insertions(+), 5,606 deletions(-) diff --git a/src/views/eam/ABC/StreamList.vue b/src/views/eam/ABC/StreamList.vue index 8c396d9..cbe2fbf 100644 --- a/src/views/eam/ABC/StreamList.vue +++ b/src/views/eam/ABC/StreamList.vue @@ -1,16 +1,20 @@ <template> - <a-card :bordered="false"> + <a-card + title='ABC璇勫垎' + :bordered="false" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="鍗曟嵁鍙�" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="鍗曟嵁鍙�" > <a-input placeholder="璇疯緭鍏ュ崟鎹彿鏌ヨ" @@ -34,7 +38,12 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-if="nodeSort===1">鏂板</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-if="nodeSort===1" + >鏂板</a-button> <!-- <a-button type="primary" icon="download" @click="handleExportXls('璁惧ABC璇勪环')">瀵煎嚭</a-button> <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> <a-button type="primary" icon="import">瀵煎叆</a-button> @@ -45,9 +54,15 @@ <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -56,300 +71,350 @@ bordered rowKey="id" class="j-table-force-nowrap" - :scroll="{x:true}" :columns="columns" :dataSource="dataSource" :pagination="ipagination" :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'radio'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > + <!-- :scroll="{x:true}" --> - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <span slot="action" slot-scope="text, record"> + <span + slot="action" + slot-scope="text, record" + > <div v-if="nodeValue===record.status"> - <a @click="handleStreamNext(record)" :disabled="nodeSort===1&&nodeValue!==record.status" v-if="button1!={}">{{button1.name}}</a> - <a-divider type="vertical" v-if="button2!={}"/> - <a @click="handleStreamLast(record)" :disabled="nodeSort===1" v-if="button2!={}" >{{button2.name}}</a> - </div> - <div v-if="nodeSort===1&&nodeValue===record.status"> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link">鏇村 <a-icon type="down" /></a> - <a-menu slot="overlay"> - <a-menu-item> - <a-popconfirm title="纭畾鍒犻櫎鍚�?" @confirm="() => handleDelete(record.id)"> - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - <a-menu-item> - <a @click="handleEdit(record)">缂栬緫</a> - </a-menu-item> - </a-menu> - </a-dropdown> - </div> + <a + @click="handleStreamNext(record)" + :disabled="nodeSort===1&&nodeValue!==record.status" + v-if="button1!={}" + >{{button1.name}}</a> + <a-divider + type="vertical" + v-if="button2!={}" + /> + <a + @click="handleStreamLast(record)" + :disabled="nodeSort===1" + v-if="button2!={}" + >{{button2.name}}</a> + </div> + <div v-if="nodeSort===1&&nodeValue===record.status"> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link">鏇村 <a-icon type="down" /></a> + <a-menu slot="overlay"> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + <a-menu-item> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + </a-menu> + </a-dropdown> + </div> </span> </a-table> </div> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="鎿嶄綔璁板綍" key="1" > + <a-tab-pane + tab="鎿嶄綔璁板綍" + key="1" + > <StreamOperationList :mainId="streamOperationMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC璇勫垎" key="2" forceRender> + <a-tab-pane + tab="ABC璇勫垎" + key="2" + forceRender + > <ABCAssessmentList :mainId="aBCAssessmentMainId" /> </a-tab-pane> </a-tabs> - <stream-modal ref="modalForm" @ok="modalFormOk"></stream-modal> - <node-model ref="nodeModel" @ok="modalFormOk"></node-model> + <stream-modal + ref="modalForm" + @ok="modalFormOk" + ></stream-modal> + <node-model + ref="nodeModel" + @ok="modalFormOk" + ></node-model> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import StreamModal from './modules/StreamModal' - import { getAction } from '@/api/manage' - import StreamOperationList from './StreamOperationList' - import ABCAssessmentList from './ABCAssessmentList' - import '@/assets/less/TableExpand.less' - import NodeModel from './modules/NodeModel.vue' +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import StreamModal from './modules/StreamModal' +import { getAction } from '@/api/manage' +import StreamOperationList from './StreamOperationList' +import ABCAssessmentList from './ABCAssessmentList' +import '@/assets/less/TableExpand.less' +import NodeModel from './modules/NodeModel.vue' - export default { - name: "StreamList", - mixins:[JeecgListMixin], - components: { - StreamOperationList, - ABCAssessmentList, - StreamModal, - NodeModel +export default { + name: "StreamList", + mixins: [JeecgListMixin], + components: { + StreamOperationList, + ABCAssessmentList, + StreamModal, + NodeModel + }, + data() { + return { + description: '璁惧ABC璇勪环绠$悊椤甸潰', + // 琛ㄥご + labelCol: { + xs: { span: 24 }, + sm: { span: 5 }, + }, + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + columns: [ + { + title: '#', + dataIndex: '', + key: 'rowIndex', + width: 60, + align: "center", + customRender: function (t, r, index) { + return parseInt(index) + 1; + } + }, + { + title: '鍗曟嵁鍙�', + align: "center", + dataIndex: 'num', + }, + { + title: '褰撳墠鑺傜偣', + align: "center", + dataIndex: 'status_dictText', + }, + { + title: '鍗曟嵁绫诲瀷', + align: "center", + dataIndex: 'type_dictText', + }, + { + title: '鍙戣捣鏃堕棿', + align: "center", + dataIndex: 'createTime', + }, + // width: 300 + { + title: '鍙戣捣浜�', + align: "center", + dataIndex: 'createBy_dictText' + }, + { + title: '鎿嶄綔', + dataIndex: 'action', + align: "center", + scopedSlots: { customRender: 'action' }, + } + // fixed: "right", + ], + url: { + list: "/eam/stream/list", + delete: "/eam/stream/delete", + deleteBatch: "/eam/stream/deleteBatch", + exportXlsUrl: "/eam/stream/exportXls", + importExcelUrl: "eam/stream/importExcel", + getPreInfo: "eam/stream/getPreInfo" + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" + }, + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + streamOperationMainId: '', + aBCAssessmentMainId: '', + button1: {}, + button2: {}, + nodeSort: 0, + nodeValue: '' + } + }, + created() { + this.getSuperFieldList(); + }, + mounted() { + this.getPreInfo(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { }, - data () { + clickThenSelect(record) { return { - description: '璁惧ABC璇勪环绠$悊椤甸潰', - // 琛ㄥご - labelCol: { - xs: { span: 24 }, - sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - columns: [ - { - title: '#', - dataIndex: '', - key:'rowIndex', - width:60, - align:"center", - customRender:function (t,r,index) { - return parseInt(index)+1; - } - }, - { - title:'鍗曟嵁鍙�', - align:"center", - dataIndex: 'num', - width:400 - }, - { - title:'褰撳墠鑺傜偣', - align:"center", - dataIndex: 'status_dictText', - width:300 - }, - { - title:'鍗曟嵁绫诲瀷', - align:"center", - dataIndex: 'type_dictText', - width:300 - }, - { - title:'鍙戣捣鏃堕棿', - align:"center", - dataIndex: 'createTime', - width:300 - }, - { - title:'鍙戣捣浜�', - align:"center", - dataIndex: 'createBy_dictText' - }, - { - title: '鎿嶄綔', - dataIndex: 'action', - align:"center", - fixed:"right", - width:200, - scopedSlots: { customRender: 'action' }, + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } - ], - url: { - list: "/eam/stream/list", - delete: "/eam/stream/delete", - deleteBatch: "/eam/stream/deleteBatch", - exportXlsUrl: "/eam/stream/exportXls", - importExcelUrl: "eam/stream/importExcel", - getPreInfo:"eam/stream/getPreInfo" - }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - streamOperationMainId: '', - aBCAssessmentMainId: '', - button1:{}, - button2:{}, - nodeSort:0, - nodeValue:'' + } } }, - created() { - this.getSuperFieldList(); - }, - mounted(){ - this.getPreInfo(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + handleStreamNext(record) { + var step = { + name: this.button1.name, + value: this.button1.value, + opType: 'next', + nodeSort: this.nodeSort, + node: this.nodeValue, + streamId: record.id } + this.$refs.nodeModel.title = this.button1.name + "鎿嶄綔"; + this.$refs.nodeModel.edit(step); }, - methods: { - initDictConfig(){ - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } - } - } - }, - handleStreamNext(record){ - var step = { - name:this.button1.name, - value:this.button1.value, - opType:'next', - nodeSort:this.nodeSort, - node:this.nodeValue, - streamId:record.id - } - this.$refs.nodeModel.title = this.button1.name+"鎿嶄綔"; - this.$refs.nodeModel.edit(step); - }, - handleStreamLast(record){ - var step = { - name:this.button2.name, - value:this.button2.value, - opType:'last', - nodeSort:this.nodeSort, - node:this.nodeValue, - streamId:record.id - } - this.$refs.nodeModel.title = this.button2.name+"鎿嶄綔"; - this.$refs.nodeModel.edit(step); - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length===1){ - this.selectedMainId=selectedRowKeys[0] - this.streamOperationMainId = selectionRows[0]['id'] - this.aBCAssessmentMainId = selectionRows[0]['id'] - }else{ - this.selectedMainId='' - this.streamOperationMainId = '' - this.aBCAssessmentMainId = '' - } - - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return - } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'num',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'type',text:'鍗曟嵁绫诲瀷',dictCode:''}) - this.superFieldList = fieldList - }, - getPreInfo(){ - getAction(this.url.getPreInfo).then(res=>{ - if(res.result.msg==='ok'){ - this.button1 = res.result.buttons[0]; - if(res.result.buttons.length===2){ - this.button2 = res.result.buttons[1]; - } - this.nodeSort = res.result.nodeSort; - this.nodeValue = res.result.nodeValue; - } - }) + handleStreamLast(record) { + var step = { + name: this.button2.name, + value: this.button2.value, + opType: 'last', + nodeSort: this.nodeSort, + node: this.nodeValue, + streamId: record.id } + this.$refs.nodeModel.title = this.button2.name + "鎿嶄綔"; + this.$refs.nodeModel.edit(step); + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length === 1) { + this.selectedMainId = selectedRowKeys[0] + this.streamOperationMainId = selectionRows[0]['id'] + this.aBCAssessmentMainId = selectionRows[0]['id'] + } else { + this.selectedMainId = '' + this.streamOperationMainId = '' + this.aBCAssessmentMainId = '' + } + + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; + } + if (res.code === 510) { + this.$message.warning(res.message) + } + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: 'num', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'type', text: '鍗曟嵁绫诲瀷', dictCode: '' }) + this.superFieldList = fieldList + }, + getPreInfo() { + getAction(this.url.getPreInfo).then(res => { + if (res.result.msg === 'ok') { + this.button1 = res.result.buttons[0]; + if (res.result.buttons.length === 2) { + this.button2 = res.result.buttons[1]; + } + this.nodeSort = res.result.nodeSort; + this.nodeValue = res.result.nodeValue; + } + }) } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/DailyInspectionStandardList.vue b/src/views/eam/DailyInspectionStandardList.vue index afc6879..6025a98 100644 --- a/src/views/eam/DailyInspectionStandardList.vue +++ b/src/views/eam/DailyInspectionStandardList.vue @@ -409,8 +409,8 @@ /* 鍒嗛〉鍙傛暟 */ ipagination: { current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], showTotal: (total, range) => { return range[0] + '-' + range[1] + ' 鍏�' + total + '鏉�' }, diff --git a/src/views/eam/DailyMaintenanceStandardList.vue b/src/views/eam/DailyMaintenanceStandardList.vue index 38a7ee1..3a50e65 100644 --- a/src/views/eam/DailyMaintenanceStandardList.vue +++ b/src/views/eam/DailyMaintenanceStandardList.vue @@ -458,8 +458,8 @@ /* 鍒嗛〉鍙傛暟 */ ipagination: { current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], showTotal: (total, range) => { return range[0] + '-' + range[1] + ' 鍏�' + total + '鏉�' }, diff --git a/src/views/eam/DeductionItemList.vue b/src/views/eam/DeductionItemList.vue index 47f05d5..2ab0591 100644 --- a/src/views/eam/DeductionItemList.vue +++ b/src/views/eam/DeductionItemList.vue @@ -1,33 +1,83 @@ <template> - <a-card :bordered="false"> + <a-card + title="鎿嶄綔璇佺Н鍒嗚鍒�" + :bordered="false" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="缂栧彿"> - <a-input placeholder="璇疯緭鍏ョ紪鍙�" v-model="queryParam.num"></a-input> + <a-input + placeholder="璇疯緭鍏ョ紪鍙�" + v-model="queryParam.num" + ></a-input> </a-form-item> </a-col> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="鍐呭"> - <a-input placeholder="璇疯緭鍏ュ唴瀹�" v-model="queryParam.content"></a-input> + <a-input + placeholder="璇疯緭鍏ュ唴瀹�" + v-model="queryParam.content" + ></a-input> </a-form-item> </a-col> <template v-if="toggleSearchStatus"> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="鍒嗘暟"> - <a-input placeholder="璇疯緭鍏ュ垎鏁�" v-model="queryParam.deductionScore"></a-input> + <a-input + placeholder="璇疯緭鍏ュ垎鏁�" + v-model="queryParam.deductionScore" + ></a-input> </a-form-item> </a-col> </template> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> - <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> - <a-button type="primary" @click="searchQuery" icon="search">鏌ヨ</a-button> - <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">閲嶇疆</a-button> - <a @click="handleToggleSearch" style="margin-left: 8px"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > + <span + style="float: left;overflow: hidden;" + class="table-page-search-submitButtons" + > + <a-button + type="primary" + @click="searchQuery" + icon="search" + >鏌ヨ</a-button> + <a-button + type="primary" + @click="searchReset" + icon="reload" + style="margin-left: 8px" + >閲嶇疆</a-button> + <a + @click="handleToggleSearch" + style="margin-left: 8px" + > {{ toggleSearchStatus ? '鏀惰捣' : '灞曞紑' }} - <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/> + <a-icon :type="toggleSearchStatus ? 'up' : 'down'" /> </a> </span> </a-col> @@ -38,16 +88,37 @@ <!-- 鎿嶄綔鎸夐挳鍖哄煙 --> <div class="table-operator"> - <a-button @click="handleAdd" type="primary" icon="plus">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('鎿嶄綔璁″垎瑙勫垯')">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('鎿嶄綔璁″垎瑙勫垯')" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + >瀵煎叆</a-button> </a-upload> <!-- 楂樼骇鏌ヨ鍖哄煙 --> -<!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>--> + <!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>--> <a-dropdown v-if="selectedRowKeys.length > 0"> <a-menu slot="overlay"> - <a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>鍒犻櫎</a-menu-item> + <a-menu-item + key="1" + @click="batchDel" + ><a-icon type="delete" />鍒犻櫎</a-menu-item> </a-menu> <a-button style="margin-left: 8px"> 鎵归噺鎿嶄綔 <a-icon type="down" /></a-button> </a-dropdown> @@ -55,9 +126,15 @@ <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -72,29 +149,56 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" class="j-table-force-nowrap" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <span slot="action" slot-scope="text, record"> + <span + slot="action" + slot-scope="text, record" + > <a @click="handleEdit(record)">缂栬緫</a> <a-divider type="vertical" /> @@ -105,7 +209,10 @@ <a @click="handleDetail(record)">璇︽儏</a> </a-menu-item> <a-menu-item> - <a-popconfirm title="纭畾鍒犻櫎鍚�?" @confirm="() => handleDelete(record.id)"> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + > <a>鍒犻櫎</a> </a-popconfirm> </a-menu-item> @@ -116,95 +223,98 @@ </a-table> </div> - <deduction-item-modal ref="modalForm" @ok="modalFormOk"></deduction-item-modal> + <deduction-item-modal + ref="modalForm" + @ok="modalFormOk" + ></deduction-item-modal> </a-card> </template> <script> - import '@/assets/less/TableExpand.less' - import { mixinDevice } from '@/utils/mixin' - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import DeductionItemModal from './modules/deductionItem/DeductionItemModal' +import '@/assets/less/TableExpand.less' +import { mixinDevice } from '@/utils/mixin' +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import DeductionItemModal from './modules/deductionItem/DeductionItemModal' - export default { - name: 'DeductionItemList', - mixins:[JeecgListMixin, mixinDevice], - components: { - DeductionItemModal - }, - data () { - return { - description: '鎿嶄綔璁″垎瑙勫垯绠$悊椤甸潰', - // 琛ㄥご - columns: [ - { - title: '#', - dataIndex: '', - key:'rowIndex', - width:60, - align:"center", - customRender:function (t,r,index) { - return parseInt(index)+1; - } - }, - { - title:'缂栧彿', - align:"center", - dataIndex: 'num' - }, - { - title:'鍐呭', - align:"center", - dataIndex: 'content' - }, - { - title:'鍒嗘暟', - align:"center", - dataIndex: 'deductionScore' - }, - { - title: '鎿嶄綔', - dataIndex: 'action', - align:"center", - fixed:"right", - width:147, - scopedSlots: { customRender: 'action' } +export default { + name: 'DeductionItemList', + mixins: [JeecgListMixin, mixinDevice], + components: { + DeductionItemModal + }, + data() { + return { + description: '鎿嶄綔璁″垎瑙勫垯绠$悊椤甸潰', + // 琛ㄥご + columns: [ + { + title: '#', + dataIndex: '', + key: 'rowIndex', + width: 60, + align: "center", + customRender: function (t, r, index) { + return parseInt(index) + 1; } - ], - url: { - list: "/eam/deductionItem/list", - delete: "/eam/deductionItem/delete", - deleteBatch: "/eam/deductionItem/deleteBatch", - exportXlsUrl: "/eam/deductionItem/exportXls", - importExcelUrl: "eam/deductionItem/importExcel", - }, - dictOptions:{}, - superFieldList:[], - } - }, - created() { + { + title: '缂栧彿', + align: "center", + dataIndex: 'num' + }, + { + title: '鍐呭', + align: "center", + dataIndex: 'content' + }, + { + title: '鍒嗘暟', + align: "center", + dataIndex: 'deductionScore' + }, + { + title: '鎿嶄綔', + dataIndex: 'action', + align: "center", + fixed: "right", + width: 147, + scopedSlots: { customRender: 'action' } + } + ], + url: { + list: "/eam/deductionItem/list", + delete: "/eam/deductionItem/delete", + deleteBatch: "/eam/deductionItem/deleteBatch", + exportXlsUrl: "/eam/deductionItem/exportXls", + importExcelUrl: "eam/deductionItem/importExcel", + + }, + dictOptions: {}, + superFieldList: [], + } + }, + created() { this.getSuperFieldList(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - }, + }, + methods: { + initDictConfig() { }, - methods: { - initDictConfig(){ - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'content',text:'鍐呭',dictCode:''}) - fieldList.push({type:'int',value:'deductionScore',text:'鍒嗘暟',dictCode:''}) - this.superFieldList = fieldList - } + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'content', text: '鍐呭', dictCode: '' }) + fieldList.push({ type: 'int', value: 'deductionScore', text: '鍒嗘暟', dictCode: '' }) + this.superFieldList = fieldList } } +} </script> <style scoped> - @import '~@assets/less/common.less'; +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentCalibrationOrder.vue b/src/views/eam/EquipmentCalibrationOrder.vue index dd553bb..534895d 100644 --- a/src/views/eam/EquipmentCalibrationOrder.vue +++ b/src/views/eam/EquipmentCalibrationOrder.vue @@ -15,10 +15,10 @@ :sm='8' > <a-form-item label='宸ュ崟缂栫爜'> - <a-input + <j-input placeholder='璇疯緭鍏ュ伐鍗曠紪鐮�' v-model='queryParam.num' - ></a-input> + ></j-input> </a-form-item> </a-col> <!-- <a-col @@ -315,8 +315,8 @@ description: '鎶�鏈姸鎬侀壌瀹氱鐞�', ipagination: { current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], showTotal: (total, range) => { return range[0] + '-' + range[1] + ' 鍏�' + total + '鏉�' }, diff --git a/src/views/eam/EquipmentListOfAll.vue b/src/views/eam/EquipmentListOfAll.vue index 6863712..c2a2ca1 100644 --- a/src/views/eam/EquipmentListOfAll.vue +++ b/src/views/eam/EquipmentListOfAll.vue @@ -1,17 +1,24 @@ <template> - <a-card :bordered="false" title="鎵�鏈夎澶�"> + <a-card + :bordered="false" + title="鎵�鏈夎澶�" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> - <a-row :gutter="24" style="margin-bottom: 1%;"> - <a-col - :span="24" - > - <a-form-item - label="缁熶竴缂栧彿缇�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" - > + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > + <a-row + :gutter="24" + style="margin-bottom: 1%;" + > + <a-col :span="24"> + <a-form-item + label="缁熶竴缂栧彿缇�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" + > <a-textarea placeholder="璇疯緭鍏ユ墍鏈夌粺涓�缂栫爜,椤荤敤绌烘牸闅斿紑,鍚﹀垯鍙兘鏌ヨ鍑洪敊璇俊鎭�" v-model="queryParam.nums" @@ -23,9 +30,9 @@ <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag dictCode="mom_eam_equipment_category,name,id" @@ -34,13 +41,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -48,13 +53,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -66,23 +69,23 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> - </a-col> + </a-col> </a-row> <a-row :gutter="24"> <a-col :span="6"> <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -110,9 +113,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -126,9 +129,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -142,7 +145,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -159,7 +162,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -189,7 +192,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -223,7 +226,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -232,7 +240,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -251,20 +264,64 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> - <a-button @click="handleUpdateKeyEquipment" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璁剧疆鍏抽敭璁惧鏍囪瘑</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + @click="handleUpdateKeyEquipment" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璁剧疆鍏抽敭璁惧鏍囪瘑</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -279,162 +336,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -443,107 +530,161 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> - <key-equipment-update-model @ok="modalFormOk" :updateList="selectionRows" ref="keyEquipmentUpdate"></key-equipment-update-model> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> + <key-equipment-update-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="keyEquipmentUpdate" + ></key-equipment-update-model> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' import KeyEquipmentUpdateModel from './modules/equipmentNew/edit/KeyEquipmentUpdateModel.vue' - - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - KeyEquipmentUpdateModel, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'all', - // 琛ㄥご - columns: [ + +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + KeyEquipmentUpdateModel, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'all', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -624,7 +765,7 @@ align: "center", dataIndex: 'technologyStatusVerificationType_dictText', }, - + { title: '鐢熶骇绾跨紪鍙�', align: "center", @@ -650,7 +791,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -773,184 +914,184 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -959,21 +1100,21 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); }, - handleUpdateKeyEquipment(){ + handleUpdateKeyEquipment() { this.$refs.keyEquipmentUpdate.add(); }, - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfCrane.vue b/src/views/eam/EquipmentListOfCrane.vue index 5839b70..7ae791e 100644 --- a/src/views/eam/EquipmentListOfCrane.vue +++ b/src/views/eam/EquipmentListOfCrane.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="璧烽噸璁惧"> + <a-card + :bordered="false" + title="璧烽噸璁惧" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag :dictCode="'mom_eam_equipment_category,name,id,equipment_category_uda1='+'\''+caytegoryParam+'\''" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,12 +51,12 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> </a-col> </a-row> @@ -63,9 +65,9 @@ <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -78,9 +80,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -94,9 +96,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -110,7 +112,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -127,7 +129,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -157,7 +159,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -191,7 +193,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -200,7 +207,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -219,19 +231,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -246,162 +297,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -410,103 +491,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'crane', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'crane', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -617,7 +748,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -740,185 +871,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -927,19 +1058,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfEnvProEquipment.vue b/src/views/eam/EquipmentListOfEnvProEquipment.vue index 7832d39..8123347 100644 --- a/src/views/eam/EquipmentListOfEnvProEquipment.vue +++ b/src/views/eam/EquipmentListOfEnvProEquipment.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="鐜繚璁惧"> + <a-card + :bordered="false" + title="鐜繚璁惧" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag :dictCode="'mom_eam_equipment_category,name,id,equipment_category_uda1='+'\''+caytegoryParam+'\''" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,23 +51,23 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> - </a-col> + </a-col> </a-row> <a-row :gutter="24"> <a-col :span="6"> <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -93,9 +95,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,106 +506,160 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="缁翠繚鏍囧噯" key="7" forceRender> - <standard-of-maintenance :mainId="selectedMainId"/> + <a-tab-pane + tab="缁翠繚鏍囧噯" + key="7" + forceRender + > + <standard-of-maintenance :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'envProEquipment', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'envProEquipment', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -540,7 +675,7 @@ align: "center", dataIndex: 'equipmentCategoryId_dictText', }, - { + { title: '鏄惁鐢熶骇绾胯澶�', align: "center", dataIndex: 'isLineEquip_dictText', @@ -635,7 +770,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -758,185 +893,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -945,19 +1080,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfFilesCarousel.vue b/src/views/eam/EquipmentListOfFilesCarousel.vue index b6cac7d..698a4d8 100644 --- a/src/views/eam/EquipmentListOfFilesCarousel.vue +++ b/src/views/eam/EquipmentListOfFilesCarousel.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="鏁版帶鍥炶浆搴�"> + <a-card + :bordered="false" + title="鏁版帶鍥炶浆搴�" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag dictCode="mom_eam_equipment_category,name,id,equipment_category_uda1='filesCarousel'" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,12 +51,12 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> </a-col> </a-row> @@ -63,9 +65,9 @@ <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -93,9 +95,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,103 +506,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'filesCarousel', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'filesCarousel', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -632,7 +763,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -755,185 +886,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -942,19 +1073,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfPressureVessel.vue b/src/views/eam/EquipmentListOfPressureVessel.vue index b8812cc..dd9729f 100644 --- a/src/views/eam/EquipmentListOfPressureVessel.vue +++ b/src/views/eam/EquipmentListOfPressureVessel.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="鍘嬪姏瀹瑰櫒"> + <a-card + :bordered="false" + title="鍘嬪姏瀹瑰櫒" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag :dictCode="'mom_eam_equipment_category,name,id,equipment_category_uda1='+'\''+caytegoryParam+'\''" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,12 +51,12 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> </a-col> </a-row> @@ -63,9 +65,9 @@ <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -93,9 +95,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,103 +506,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'pressureVessel', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'pressureVessel', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -632,7 +763,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -755,185 +886,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -942,19 +1073,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfProduct.vue b/src/views/eam/EquipmentListOfProduct.vue index a9885a2..b2b21bc 100644 --- a/src/views/eam/EquipmentListOfProduct.vue +++ b/src/views/eam/EquipmentListOfProduct.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="鐢熶骇璁惧"> + <a-card + :bordered="false" + title="鐢熶骇璁惧" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag dictCode="mom_eam_equipment_category,name,id,equipment_category_uda1 = 'producter'" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,23 +51,23 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> - </a-col> + </a-col> </a-row> <a-row :gutter="24"> <a-col :span="6"> <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -93,9 +95,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,103 +506,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'producter', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'producter', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -632,7 +763,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -755,185 +886,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 10, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -942,19 +1073,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfRide.vue b/src/views/eam/EquipmentListOfRide.vue index edede79..d955b25 100644 --- a/src/views/eam/EquipmentListOfRide.vue +++ b/src/views/eam/EquipmentListOfRide.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="杞﹀彴"> + <a-card + :bordered="false" + title="杞﹀彴" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag :dictCode="'mom_eam_equipment_category,name,id,equipment_category_uda1='+'\''+caytegoryParam+'\''" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,12 +51,12 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> </a-col> </a-row> @@ -63,9 +65,9 @@ <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -93,9 +95,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,103 +506,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'ride', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'ride', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -632,7 +763,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -755,185 +886,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 10, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -942,19 +1073,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfTester.vue b/src/views/eam/EquipmentListOfTester.vue index 8b39870..675006b 100644 --- a/src/views/eam/EquipmentListOfTester.vue +++ b/src/views/eam/EquipmentListOfTester.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="璇曢獙鍣�"> + <a-card + :bordered="false" + title="璇曢獙鍣�" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag :dictCode="'mom_eam_equipment_category,name,id,equipment_category_uda1='+'\''+caytegoryParam+'\''" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,23 +51,23 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> - </a-col> + </a-col> </a-row> <a-row :gutter="24"> <a-col :span="6"> <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -93,9 +95,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,103 +506,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'tester', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'tester', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -632,7 +763,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -755,185 +886,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 10, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -942,19 +1073,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfTruck.vue b/src/views/eam/EquipmentListOfTruck.vue index 8ca0d29..63c687c 100644 --- a/src/views/eam/EquipmentListOfTruck.vue +++ b/src/views/eam/EquipmentListOfTruck.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="杩愯緭杞�"> + <a-card + :bordered="false" + title="杩愯緭杞�" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag :dictCode="'mom_eam_equipment_category,name,id,equipment_category_uda1='+'\''+caytegoryParam+'\''" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,12 +51,12 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> </a-col> </a-row> @@ -63,9 +65,9 @@ <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -92,10 +94,10 @@ <a-col :span="6"> <a-form-item label="缁存姢閮ㄩ棬" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,103 +506,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'truck', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'truck', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -632,7 +763,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -755,185 +886,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -942,19 +1073,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentListOfWeldingMachine.vue b/src/views/eam/EquipmentListOfWeldingMachine.vue index d5cae4a..734e51c 100644 --- a/src/views/eam/EquipmentListOfWeldingMachine.vue +++ b/src/views/eam/EquipmentListOfWeldingMachine.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="鐒婃満"> + <a-card + :bordered="false" + title="鐒婃満" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="璁惧鎵�灞炲垎绫�" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="璁惧鎵�灞炲垎绫�" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag dictCode="mom_eam_equipment_category,name,id,equipment_category_uda1 = 'weldingMachine'" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="缁熶竴缂栫爜" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="缁熶竴缂栫爜" > <a-input placeholder="璇疯緭鍏ヨ澶囩粺涓�缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="璁惧鍚嶇О" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="璁惧鍚嶇О" > <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版煡璇�" @@ -49,23 +51,23 @@ <a-form-item label="鍨嬪彿" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-input + <a-input v-model="queryParam.model" placeholder="璇疯緭鍏ュ瀷鍙�" - ></a-input> + ></a-input> </a-form-item> - </a-col> + </a-col> </a-row> <a-row :gutter="24"> <a-col :span="6"> <a-form-item label="宸ュ尯" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <j-dict-select-tag + <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨宸ュ尯" :triggerChange="true" @@ -93,9 +95,9 @@ <a-form-item label="缁存姢閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -109,9 +111,9 @@ <a-form-item label="浣跨敤閮ㄩ棬" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > - <a-tree-select + <a-tree-select style="width: 100%" :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" :tree-data="treeData" @@ -125,7 +127,7 @@ <a-form-item label="鏄惁鐢熶骇绾胯澶�" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -142,7 +144,7 @@ <a-form-item label="ABC鏍囪瘑" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -172,7 +174,7 @@ <a-form-item label="璁惧鐘舵��" :labelCol="labelCol" - :wrapperCol="wrapperCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag allow-clear @@ -206,7 +208,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" class="query-group-cust" v-model="queryParam.warrantyStart"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨寮�濮嬫棩鏈�" + class="query-group-cust" + v-model="queryParam.warrantyStart" + ></j-date> </a-form-model-item> </a-col> <a-col :span="6"> @@ -215,7 +222,12 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <j-date style="width: 100%;" placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" class="query-group-cust" v-model="queryParam.warrantyEnd"></j-date> + <j-date + style="width: 100%;" + placeholder="璇烽�夋嫨缁撴潫鏃ユ湡" + class="query-group-cust" + v-model="queryParam.warrantyEnd" + ></j-date> </a-form-model-item> </a-col> </a-row> @@ -234,19 +246,58 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'equipmentAccount:add&delete&import&Edit'">鏂板</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鏂板</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('璁惧鍙拌处')" + v-has="'equipmentAccount:outport'" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + v-has="'equipmentAccount:add&delete&import&Edit'" + >瀵煎叆</a-button> </a-upload> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateABC" type="primary" icon="font-colors" v-has="'equipmentAccount:add&delete&import&Edit'">ABC鏍囪瘑鍙樻洿</a-button> - <a-button :disabled="selectedRowKeys.length==0" @click="handleUpdateWarranty" type="primary" icon="calendar" v-has="'equipmentAccount:add&delete&import&Edit'">璐ㄤ繚鏈熷彉鏇�</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateABC" + type="primary" + icon="font-colors" + v-has="'equipmentAccount:add&delete&import&Edit'" + >ABC鏍囪瘑鍙樻洿</a-button> + <a-button + :disabled="selectedRowKeys.length==0" + @click="handleUpdateWarranty" + type="primary" + icon="calendar" + v-has="'equipmentAccount:add&delete&import&Edit'" + >璐ㄤ繚鏈熷彉鏇�</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -261,162 +312,192 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <!--宸ヨ壓鍙傛暟涓�у睍绀�--> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + <!--宸ヨ壓鍙傛暟涓�у睍绀�--> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="processParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.processParameters==1" - status="success" - /> + slot="processParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.processParameters==1" + status="success" + /> + <span + v-if="record.processParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.processParameters==0" + status="error" + /> + <span + v-if="record.processParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.processParameters==0" - status="error" - /> + slot="precisionParameters" + slot-scope="text,record" + > + <a-badge + v-if="record.precisionParameters==1" + status="success" + /> + <span + v-if="record.precisionParameters==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.precisionParameters==0" + status="error" + /> + <span + v-if="record.precisionParameters==0" + class="error" + >鍚�</span> + </span> <span - v-if="record.processParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="precisionParameters" - slot-scope="text,record" - > - <a-badge - v-if="record.precisionParameters==1" - status="success" - /> - <span - v-if="record.precisionParameters==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.precisionParameters==0" - status="error" - /> - <span - v-if="record.precisionParameters==0" - class="error" - >鍚�</span> - </span> - <span - slot="verification" - slot-scope="text,record" - > - <a-badge - v-if="record.verification==1" - status="success" - /> - <span - v-if="record.verification==1" - class="success" - >鏄�</span> - <a-badge - v-if="record.verification==0" - status="error" - /> - <span - v-if="record.verification==0" - class="error" - >鍚�</span> - </span> + slot="verification" + slot-scope="text,record" + > + <a-badge + v-if="record.verification==1" + status="success" + /> + <span + v-if="record.verification==1" + class="success" + >鏄�</span> + <a-badge + v-if="record.verification==0" + status="error" + /> + <span + v-if="record.verification==0" + class="error" + >鍚�</span> + </span> - <span - slot="action" - slot-scope="text, record" - > - <!-- class="table-operation" --> - <!-- <a + <span + slot="action" + slot-scope="text, record" + > + <!-- class="table-operation" --> + <!-- <a href="javascript:;" @click="equipmentStructuresShow(record)" >璁惧缁撴瀯</a> <a-divider type="vertical" /> --> - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.processParameters==1"> - <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'accountSons:add&edit&delete&submit'" v-if="record.precisionParameters==1"> - <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEdit(record)" >缂栬緫</a> - </a-menu-item> - <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> - <a @click="handleEditSpareParts(record)" >缂栬緫澶囦欢</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'equipmentAccount:add&delete&import&Edit'" + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="equipmentResumeShow(record)">璁惧灞ュ巻</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.processParameters==1" > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <a @click="editProcess(record)">宸ヨ壓鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item + v-has="'accountSons:add&edit&delete&submit'" + v-if="record.precisionParameters==1" + > + <a @click="editPrecision(record)">绮惧害鍙傛暟缁存姢</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item v-has="'equipmentAccount:add&delete&import&Edit'"> + <a @click="handleEditSpareParts(record)">缂栬緫澶囦欢</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'equipmentAccount:add&delete&import&Edit'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <equipment-resume-drawer @@ -425,103 +506,153 @@ ></equipment-resume-drawer> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="宸ヨ壓鍙傛暟" key="1" > - <EquipmentProcessParametersList - :mainId="selectedMainId" - :isOpen="isOpenProcess" + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="1" + > + <EquipmentProcessParametersList + :mainId="selectedMainId" + :isOpen="isOpenProcess" /> </a-tab-pane> - <a-tab-pane tab="璁惧绮惧害" key="2" forceRender> - <EquipmentPrecisionParametersList - :isOpen="isOpenPrecision" - :mainId="precisionParametersTemplateId" /> + <a-tab-pane + tab="璁惧绮惧害" + key="2" + forceRender + > + <EquipmentPrecisionParametersList + :isOpen="isOpenPrecision" + :mainId="precisionParametersTemplateId" + /> </a-tab-pane> - <a-tab-pane tab="璁惧鏂囨。" key="3" forceRender> + <a-tab-pane + tab="璁惧鏂囨。" + key="3" + forceRender + > <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="澶囦欢" key="4" forceRender> + <a-tab-pane + tab="澶囦欢" + key="4" + forceRender + > <EquipmentSpareParts :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="ABC鏍囪瘑鍙樻洿璁板綍" key="5" forceRender> + <a-tab-pane + tab="ABC鏍囪瘑鍙樻洿璁板綍" + key="5" + forceRender + > <equipment-update-ABC-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="璐ㄤ繚鏈熷彉鏇�" key="6" forceRender> + <a-tab-pane + tab="璐ㄤ繚鏈熷彉鏇�" + key="6" + forceRender + > <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> - <a-tab-pane tab="鏃ヤ繚鏍囧噯" key="7" forceRender> + <a-tab-pane + tab="鏃ヤ繚鏍囧噯" + key="7" + forceRender + > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> - <a-tab-pane tab="浜屼繚鏍囧噯" key="8" forceRender> + <a-tab-pane + tab="浜屼繚鏍囧噯" + key="8" + forceRender + > <second-maintenance-list :mainId="selectedMainId"></second-maintenance-list> </a-tab-pane> - <a-tab-pane tab="涓変繚鏍囧噯" key="9" forceRender> + <a-tab-pane + tab="涓変繚鏍囧噯" + key="9" + forceRender + > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> </a-tab-pane> </a-tabs> - <equipment-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-modal> - <process-edit-model ref ="processEditModel"></process-edit-model> - <precision-edit-model ref ="precisionEditModel"></precision-edit-model> - <aBC-update-edit-model @ok="modalFormOk" :updateList="selectionRows" ref="updateABC"></aBC-update-edit-model> - <warranty-update-model :updateList="selectionRows" ref="updateWarranty"></warranty-update-model> - <EquipmentSparePartsModal ref="modalFormSpareParts" @ok="modalFormOk" /> + <equipment-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-modal> + <process-edit-model ref="processEditModel"></process-edit-model> + <precision-edit-model ref="precisionEditModel"></precision-edit-model> + <aBC-update-edit-model + @ok="modalFormOk" + :updateList="selectionRows" + ref="updateABC" + ></aBC-update-edit-model> + <warranty-update-model + :updateList="selectionRows" + ref="updateWarranty" + ></warranty-update-model> + <EquipmentSparePartsModal + ref="modalFormSpareParts" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import EquipmentModal from './modules/equipmentNew/EquipmentModal' - import { getAction } from '@/api/manage' - import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' - import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' - import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' - import '@/assets/less/TableExpand.less' - import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' - import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' - import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' - import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' - import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' - import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' - import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' - import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' - import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' - import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' - import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' - import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' - import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' - export default { - name: "EquipmentList", - mixins:[JeecgListMixin,mixinDevice], - components: { - EquipmentProcessParametersList, - EquipmentDocumentList, - EquipmentPrecisionParametersList, - EquipmentModal, - EquipmentResumeDrawer, - JSearchSelectTag, - ProcessEditModel, - PrecisionEditModel, - EquipmentUpdateABCList , - EquipmentUpdateWarrantyList, - ABCUpdateEditModel, - WarrantyUpdateModel, - EquipmentSpareParts, - EquipmentSparePartsModal, - StandardOfInspection, - StandardOfMaintenance, - DailyMaintenanceList, - SecondMaintenanceList, - ThirdMaintenanceList, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'weldingMachine', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import EquipmentModal from './modules/equipmentNew/EquipmentModal' +import { getAction } from '@/api/manage' +import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' +import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' +import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' +import '@/assets/less/TableExpand.less' +import EquipmentResumeDrawer from './modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import ProcessEditModel from './modules/equipmentNew/edit/ProcessEditModel.vue' +import PrecisionEditModel from './modules/equipmentNew/edit/PrecisionEditModel' +import EquipmentUpdateABCList from './modules/equipmentNew/EquipmentUpdateABCList.vue' +import EquipmentUpdateWarrantyList from './modules/equipmentNew/EquipmentUpdateWarrantyList.vue' +import ABCUpdateEditModel from './modules/equipmentNew/edit/ABCUpdateEditModel' +import WarrantyUpdateModel from './modules/equipmentNew/edit/WarrantyUpdateModel.vue' +import EquipmentSpareParts from './modules/equipmentNew/EquipmentSpareParts' +import EquipmentSparePartsModal from './modules/equipmentNew/EquipmentSparePartsModal' +import StandardOfInspection from './modules/equipmentNew/StandardOfInspection.vue' +import StandardOfMaintenance from './modules/equipmentNew/StandardOfMaintenance.vue' +import DailyMaintenanceList from './modules/equipmentNew/DailyMaintenanceList.vue' +import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' +import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' +export default { + name: "EquipmentList", + mixins: [JeecgListMixin, mixinDevice], + components: { + EquipmentProcessParametersList, + EquipmentDocumentList, + EquipmentPrecisionParametersList, + EquipmentModal, + EquipmentResumeDrawer, + JSearchSelectTag, + ProcessEditModel, + PrecisionEditModel, + EquipmentUpdateABCList, + EquipmentUpdateWarrantyList, + ABCUpdateEditModel, + WarrantyUpdateModel, + EquipmentSpareParts, + EquipmentSparePartsModal, + StandardOfInspection, + StandardOfMaintenance, + DailyMaintenanceList, + SecondMaintenanceList, + ThirdMaintenanceList, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'weldingMachine', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -632,7 +763,7 @@ // align: "center", // dataIndex: 'fireExtinguisher', // }, - + // { // title: '鐏伀鍣ㄦ湁鏁堟湡', // align: "center", @@ -755,185 +886,185 @@ width: 147, fixed: 'right', }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 10, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; - this.isOpenProcess = selectionRows[0].processParameters==1; - this.isOpenPrecision = selectionRows[0].precisionParameters==1; - }else{ - this.selectedMainId='' - this.precisionParametersTemplateId = '' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; + this.isOpenProcess = selectionRows[0].processParameters == 1; + this.isOpenPrecision = selectionRows[0].precisionParameters == 1; + } else { + this.selectedMainId = '' + this.precisionParametersTemplateId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -942,19 +1073,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentMaintenancePlanList.vue b/src/views/eam/EquipmentMaintenancePlanList.vue index 1e32c5e..3184ec5 100644 --- a/src/views/eam/EquipmentMaintenancePlanList.vue +++ b/src/views/eam/EquipmentMaintenancePlanList.vue @@ -2,22 +2,59 @@ <a-card :bordered="false"> <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="鍗曟嵁鍙�"> - <j-input placeholder="璇疯緭鍏ュ崟鎹彿" v-model="queryParam.num"></j-input> + <j-input + placeholder="璇疯緭鍏ュ崟鎹彿" + v-model="queryParam.num" + ></j-input> </a-form-item> </a-col> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="淇濆吇绫诲瀷"> - <j-dict-select-tag placeholder="璇烽�夋嫨淇濆吇绫诲瀷" v-model="queryParam.type" dictCode="maintenance_type" /> + <j-dict-select-tag + placeholder="璇烽�夋嫨淇濆吇绫诲瀷" + v-model="queryParam.type" + dictCode="maintenance_type" + /> </a-form-item> </a-col> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> - <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> - <a-button type="primary" @click="searchQuery" icon="search">鏌ヨ</a-button> - <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">閲嶇疆</a-button> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > + <span + style="float: left;overflow: hidden;" + class="table-page-search-submitButtons" + > + <a-button + type="primary" + @click="searchQuery" + icon="search" + >鏌ヨ</a-button> + <a-button + type="primary" + @click="searchReset" + icon="reload" + style="margin-left: 8px" + >閲嶇疆</a-button> </span> </a-col> </a-row> @@ -27,14 +64,25 @@ <!-- 鎿嶄綔鎸夐挳鍖哄煙 --> <div class="table-operator"> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'MaintenancePlan:add&edit&submit'">鏂板</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'MaintenancePlan:add&edit&submit'" + >鏂板</a-button> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -43,300 +91,382 @@ bordered rowKey="id" class="j-table-force-nowrap" - :scroll="{x:true}" :columns="columns" :dataSource="dataSource" :pagination="ipagination" :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'radio'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > + <!-- :scroll="{x:true}" --> - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <span slot="action" slot-scope="text, record"> - <a @click="handleEdit(record)" v-if="record.status==='created'||record.status==='rejected'" v-has="'MaintenancePlan:add&edit&submit'">缂栬緫</a> - <a-divider type="vertical" v-if="record.status==='created'||record.status==='rejected'"/> - <a-popconfirm title="纭畾鍒犻櫎鍚�?" @confirm="() => handleDelete(record.id)" v-if="record.status==='created'||record.status==='rejected'" v-has="'MaintenancePlan:add&edit&submit'"> - <a>鍒犻櫎</a> + <span + slot="action" + slot-scope="text, record" + > + <a + @click="handleEdit(record)" + v-if="record.status==='created'||record.status==='rejected'" + v-has="'MaintenancePlan:add&edit&submit'" + >缂栬緫</a> + <a-divider + type="vertical" + v-if="record.status==='created'||record.status==='rejected'" + /> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-if="record.status==='created'||record.status==='rejected'" + v-has="'MaintenancePlan:add&edit&submit'" + > + <a>鍒犻櫎</a> </a-popconfirm> - <a-divider type="vertical" v-if="record.status==='created'||record.status==='rejected'" v-has="'MaintenancePlan:add&edit&submit'"/> - <a-popconfirm title="鎻愪氦鍚庝笉鍙挙鍥烇紝纭畾鎻愪氦鍚�?" @confirm="() => handleSubmit(record)" v-if="record.status==='created'||record.status==='rejected'" v-has="'MaintenancePlan:add&edit&submit'"> - <a>鎻愪氦</a> + <a-divider + type="vertical" + v-if="record.status==='created'||record.status==='rejected'" + v-has="'MaintenancePlan:add&edit&submit'" + /> + <a-popconfirm + title="鎻愪氦鍚庝笉鍙挙鍥烇紝纭畾鎻愪氦鍚�?" + @confirm="() => handleSubmit(record)" + v-if="record.status==='created'||record.status==='rejected'" + v-has="'MaintenancePlan:add&edit&submit'" + > + <a>鎻愪氦</a> </a-popconfirm> - <a-divider type="vertical" v-if="record.status==='created'||record.status==='rejected'" v-has="'MaintenancePlan:add&edit&submit'"/> - <a-popconfirm title="閫氳繃鍚庝笉鍙挙閿�锛岀‘瀹氶�氳繃鍚�?" @confirm="() => handleAudit(record)" v-if="record.status==='submitted'" v-has="'MaintenancePlan:audit&reject'"> - <a>閫氳繃</a> + <a-divider + type="vertical" + v-if="record.status==='created'||record.status==='rejected'" + v-has="'MaintenancePlan:add&edit&submit'" + /> + <a-popconfirm + title="閫氳繃鍚庝笉鍙挙閿�锛岀‘瀹氶�氳繃鍚�?" + @confirm="() => handleAudit(record)" + v-if="record.status==='submitted'" + v-has="'MaintenancePlan:audit&reject'" + > + <a>閫氳繃</a> </a-popconfirm> - <a-divider type="vertical" v-if="record.status==='submitted'" v-has="'MaintenancePlan:audit&reject'"/> - <a-popconfirm title="纭畾椹冲洖鍚�?" @confirm="() => handleReject(record)" v-if="record.status==='submitted'" v-has="'MaintenancePlan:audit&reject'"> - <a>椹冲洖</a> + <a-divider + type="vertical" + v-if="record.status==='submitted'" + v-has="'MaintenancePlan:audit&reject'" + /> + <a-popconfirm + title="纭畾椹冲洖鍚�?" + @confirm="() => handleReject(record)" + v-if="record.status==='submitted'" + v-has="'MaintenancePlan:audit&reject'" + > + <a>椹冲洖</a> </a-popconfirm> - <a-divider type="vertical" v-if="record.status==='submitted'" v-has="'MaintenancePlan:audit&reject'"/> - <a-popconfirm title="涓嬪彂鍚庝笉鍙挙閿�锛岀‘瀹氫笅鍙戝悧?" @confirm="() => handleDistrbute(record)" v-if="record.status==='passed'" v-has="'MaintenancePlan:distribute'"> - <a>涓嬪彂</a> + <a-divider + type="vertical" + v-if="record.status==='submitted'" + v-has="'MaintenancePlan:audit&reject'" + /> + <a-popconfirm + title="涓嬪彂鍚庝笉鍙挙閿�锛岀‘瀹氫笅鍙戝悧?" + @confirm="() => handleDistrbute(record)" + v-if="record.status==='passed'" + v-has="'MaintenancePlan:distribute'" + > + <a>涓嬪彂</a> </a-popconfirm> - <span v-if="record.status==='distributed'" style="font-size: 12px;font-style: italic;">宸茬敓鎴愬伐鍗�</span> + <span + v-if="record.status==='distributed'" + style="font-size: 12px;font-style: italic;" + >宸茬敓鎴愬伐鍗�</span> </span> </a-table> </div> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="淇濆吇璁″垝鏄庣粏" key="1" > - <EquipmentMaintenancePlanDetailList :mainId="equipmentMaintenancePlanDetailMainId" :mainStatus="mainStatus" /> + <a-tab-pane + tab="淇濆吇璁″垝鏄庣粏" + key="1" + > + <EquipmentMaintenancePlanDetailList + :mainId="equipmentMaintenancePlanDetailMainId" + :mainStatus="mainStatus" + /> </a-tab-pane> </a-tabs> - <equipmentMaintenancePlan-modal ref="modalForm" @ok="modalFormOk"></equipmentMaintenancePlan-modal> + <equipmentMaintenancePlan-modal + ref="modalForm" + @ok="modalFormOk" + ></equipmentMaintenancePlan-modal> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import EquipmentMaintenancePlanModal from './modules/maintenancePlan/EquipmentMaintenancePlanModal' - import { getAction } from '@/api/manage' - import EquipmentMaintenancePlanDetailList from './EquipmentMaintenancePlanDetailList' - import '@/assets/less/TableExpand.less' +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import EquipmentMaintenancePlanModal from './modules/maintenancePlan/EquipmentMaintenancePlanModal' +import { getAction } from '@/api/manage' +import EquipmentMaintenancePlanDetailList from './EquipmentMaintenancePlanDetailList' +import '@/assets/less/TableExpand.less' import { putAction } from '../../api/manage' - export default { - name: "EquipmentMaintenancePlanList", - mixins:[JeecgListMixin], - components: { - EquipmentMaintenancePlanDetailList, - EquipmentMaintenancePlanModal +export default { + name: "EquipmentMaintenancePlanList", + mixins: [JeecgListMixin], + components: { + EquipmentMaintenancePlanDetailList, + EquipmentMaintenancePlanModal + }, + data() { + return { + description: '淇濆吇璁″垝绠$悊椤甸潰', + // 琛ㄥご + columns: [ + { + title: '璁″垝鍗曞彿', + align: "center", + dataIndex: 'num', + }, + { + title: '璁″垝鍗曠被鍨�', + align: "center", + dataIndex: 'type_dictText', + }, + { + title: '璁″垝鍗曠姸鎬�', + align: "center", + dataIndex: 'status_dictText', + }, + { + title: '璁惧鏁伴噺', + align: "center", + dataIndex: 'equipNo', + }, + { + title: '鍒涘缓浜�', + align: "center", + dataIndex: 'createBy', + }, + { + title: '鍒涘缓鏃堕棿', + align: "center", + dataIndex: 'createTime', + }, + // { + // title: '淇敼浜�', + // align: "center", + // dataIndex: 'updateBy', + // width: 200, + // }, + // { + // title: '淇敼鏃堕棿', + // align: "center", + // dataIndex: 'updateTime', + // width: 200, + // }, + { + title: '鎿嶄綔', + dataIndex: 'action', + align: "center", + scopedSlots: { customRender: 'action' }, + } + // fixed: "right", + // width: 200, + ], + url: { + list: "/eam/equipmentMaintenancePlan/list", + delete: "/eam/equipmentMaintenancePlan/delete", + deleteBatch: "/eam/equipmentMaintenancePlan/deleteBatch", + exportXlsUrl: "/eam/equipmentMaintenancePlan/exportXls", + importExcelUrl: "eam/equipmentMaintenancePlan/importExcel", + submit: "eam/equipmentMaintenancePlan/submit", + reject: "eam/equipmentMaintenancePlan/reject", + distrbute: "eam/equipmentMaintenancePlan/distrbute", + audit: "eam/equipmentMaintenancePlan/audit" + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" + }, + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentMaintenancePlanDetailMainId: '', + mainStatus: '', + } + }, + created() { + this.getSuperFieldList(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { }, - data () { + clickThenSelect(record) { return { - description: '淇濆吇璁″垝绠$悊椤甸潰', - // 琛ㄥご - columns: [ - { - title:'璁″垝鍗曞彿', - align:"center", - dataIndex: 'num', - }, - { - title:'璁″垝鍗曠被鍨�', - align:"center", - dataIndex: 'type_dictText', - width:200, - }, - { - title:'璁″垝鍗曠姸鎬�', - align:"center", - dataIndex: 'status_dictText', - width:200, - }, - { - title:'璁惧鏁伴噺', - align:"center", - dataIndex: 'equipNo', - width:200, - }, - { - title:'鍒涘缓浜�', - align:"center", - dataIndex: 'createBy', - width:200, - }, - { - title:'鍒涘缓鏃堕棿', - align:"center", - dataIndex: 'createTime', - width:200, - }, - { - title:'淇敼浜�', - align:"center", - dataIndex: 'updateBy', - width:200, - }, - { - title:'淇敼鏃堕棿', - align:"center", - dataIndex: 'updateTime', - width:200, - }, - { - title: '鎿嶄綔', - dataIndex: 'action', - align:"center", - fixed:"right", - width:200, - scopedSlots: { customRender: 'action' }, - } - ], - url: { - list: "/eam/equipmentMaintenancePlan/list", - delete: "/eam/equipmentMaintenancePlan/delete", - deleteBatch: "/eam/equipmentMaintenancePlan/deleteBatch", - exportXlsUrl: "/eam/equipmentMaintenancePlan/exportXls", - importExcelUrl: "eam/equipmentMaintenancePlan/importExcel", - submit:"eam/equipmentMaintenancePlan/submit", - reject:"eam/equipmentMaintenancePlan/reject", - distrbute:"eam/equipmentMaintenancePlan/distrbute", - audit:"eam/equipmentMaintenancePlan/audit" - }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentMaintenancePlanDetailMainId: '', - mainStatus:'', - } - }, - created() { - this.getSuperFieldList(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - this.selectedMainId=selectedRowKeys[0] - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - this.equipmentMaintenancePlanDetailMainId = selectionRows[0]['id'] - this.mainStatus = selectionRows[0]['status'] - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return - } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'璁″垝鍗曞彿',dictCode:''}) - fieldList.push({type:'string',value:'type',text:'璁″垝鍗曠被鍨嬶紙鏁版嵁瀛楀吀锛歮aintenance_plan_type锛�',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'璁″垝鍗曠姸鎬�(鏁版嵁瀛楀吀锛歮aintenance_plan_type)',dictCode:''}) - fieldList.push({type:'int',value:'equipNo',text:'璁惧鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'createBy',text:'createBy',dictCode:''}) - fieldList.push({type:'date',value:'createTime',text:'createTime'}) - fieldList.push({type:'string',value:'updateBy',text:'updateBy',dictCode:''}) - fieldList.push({type:'date',value:'updateTime',text:'updateTime'}) - this.superFieldList = fieldList - }, - handleSubmit(record){ - this.loading = true; - putAction(this.url.submit,record).then(res=>{ - if(res.success){ - this.$message.success("鎿嶄綔鎴愬姛"); - }else{ - this.$message.success("鎿嶄綔澶辫触"); - - } - }).finally(res=>{ - this.loadData(); - }) - }, - handleAudit(record){ - this.loading = true; - putAction(this.url.audit,record).then(res=>{ - if(res.success){ - this.$message.success("鎿嶄綔鎴愬姛"); - }else{ - this.$message.success("鎿嶄綔澶辫触"); - } - }).finally(res=>{ - this.loadData(); - }) - }, - handleDistrbute(record){ - this.loading = true; - putAction(this.url.distrbute,record).then(res=>{ - if(res.success){ - this.$message.success("鎿嶄綔鎴愬姛"); - }else{ - this.$message.success("鎿嶄綔澶辫触"); - } - }).finally(res=>{ - this.loadData(); - }) - }, - handleReject(record){ - this.loading = true; - putAction(this.url.reject,record).then(res=>{ - if(res.success){ - this.$message.success("鎿嶄綔鎴愬姛"); - }else{ - this.$message.success("鎿嶄綔澶辫触"); - } - }).finally(res=>{ - this.loadData(); - }) } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + this.selectedMainId = selectedRowKeys[0] + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + this.equipmentMaintenancePlanDetailMainId = selectionRows[0]['id'] + this.mainStatus = selectionRows[0]['status'] + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; + } + if (res.code === 510) { + this.$message.warning(res.message) + } + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '璁″垝鍗曞彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'type', text: '璁″垝鍗曠被鍨嬶紙鏁版嵁瀛楀吀锛歮aintenance_plan_type锛�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: '璁″垝鍗曠姸鎬�(鏁版嵁瀛楀吀锛歮aintenance_plan_type)', dictCode: '' }) + fieldList.push({ type: 'int', value: 'equipNo', text: '璁惧鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'createBy', text: 'createBy', dictCode: '' }) + fieldList.push({ type: 'date', value: 'createTime', text: 'createTime' }) + fieldList.push({ type: 'string', value: 'updateBy', text: 'updateBy', dictCode: '' }) + fieldList.push({ type: 'date', value: 'updateTime', text: 'updateTime' }) + this.superFieldList = fieldList + }, + handleSubmit(record) { + this.loading = true; + putAction(this.url.submit, record).then(res => { + if (res.success) { + this.$message.success("鎿嶄綔鎴愬姛"); + } else { + this.$message.success("鎿嶄綔澶辫触"); + + } + }).finally(res => { + this.loadData(); + }) + }, + handleAudit(record) { + this.loading = true; + putAction(this.url.audit, record).then(res => { + if (res.success) { + this.$message.success("鎿嶄綔鎴愬姛"); + } else { + this.$message.success("鎿嶄綔澶辫触"); + } + }).finally(res => { + this.loadData(); + }) + }, + handleDistrbute(record) { + this.loading = true; + putAction(this.url.distrbute, record).then(res => { + if (res.success) { + this.$message.success("鎿嶄綔鎴愬姛"); + } else { + this.$message.success("鎿嶄綔澶辫触"); + } + }).finally(res => { + this.loadData(); + }) + }, + handleReject(record) { + this.loading = true; + putAction(this.url.reject, record).then(res => { + if (res.success) { + this.$message.success("鎿嶄綔鎴愬姛"); + } else { + this.$message.success("鎿嶄綔澶辫触"); + } + }).finally(res => { + this.loadData(); + }) } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/EquipmentOfLine.vue b/src/views/eam/EquipmentOfLine.vue index 3335ca5..1c48942 100644 --- a/src/views/eam/EquipmentOfLine.vue +++ b/src/views/eam/EquipmentOfLine.vue @@ -1,14 +1,20 @@ <template> - <a-card :bordered="false" title="杩愯緭杞�"> + <a-card + :bordered="false" + title="鐢熶骇绾�" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> <a-col :span="6"> <a-form-item - label="鍒嗙被" - :labelCol="labelCol" - :wrapperCol="wrapperCol" + label="鍒嗙被" + :labelCol="labelCol" + :wrapperCol="wrapperCol" > <j-dict-select-tag :dictCode="'mom_eam_equipment_category,name,id,equipment_category_uda1='+'\''+caytegoryParam+'\''" @@ -17,13 +23,11 @@ /> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="鐢熶骇绾跨紪鍙�" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="鐢熶骇绾跨紪鍙�" > <a-input placeholder="璇疯緭鍏ョ敓浜х嚎缂栫爜鏌ヨ" @@ -31,13 +35,11 @@ ></a-input> </a-form-item> </a-col> - <a-col - :span="6" - > - <a-form-item - :labelCol="labelCol" - :wrapperCol="wrapperCol" - label="鐢熶骇绾垮悕绉�" + <a-col :span="6"> + <a-form-item + :labelCol="labelCol" + :wrapperCol="wrapperCol" + label="鐢熶骇绾垮悕绉�" > <a-input placeholder="璇疯緭鍏ョ敓浜х嚎鍚嶇О鏌ヨ" @@ -61,7 +63,12 @@ @click="searchReset" icon="reload" >閲嶇疆</a-button> - <a-button @click="handleAdd" type="primary" icon="plus" v-has="'line:add&edit&delete'">鏂板</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + v-has="'line:add&edit&delete'" + >鏂板</a-button> <!-- <a-button type="primary" icon="download" @click="handleExportXls('璁惧鍙拌处')" v-has="'equipmentAccount:outport'">瀵煎嚭</a-button> <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> <a-button type="primary" icon="import" v-has="'equipmentAccount:add&delete&import&Edit'">瀵煎叆</a-button> @@ -71,9 +78,15 @@ </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -88,93 +101,125 @@ :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'checkbox'}" :customRow="clickThenSelect" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <span - slot="action" - slot-scope="text, record" - > - <a - href="javascript:;" - @click='handleDetail(record)' - >璇︽儏</a> - <a-divider type="vertical" /> - <a @click="handleEdit(record)" >缂栬緫</a> - <a-divider type="vertical" /> - <a-dropdown> - <a class="ant-dropdown-link"> - 鏇村 - <a-icon type="down" /> - </a> - <a-menu slot="overlay"> - <a-menu-item v-has="'line:add&edit&delete'"> - - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - v-has="'line:add&edit&delete'" - > - <a>鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> + <span + slot="action" + slot-scope="text, record" + > + <a + href="javascript:;" + @click='handleDetail(record)' + >璇︽儏</a> + <a-divider type="vertical" /> + <a @click="handleEdit(record)">缂栬緫</a> + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link"> + 鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item v-has="'line:add&edit&delete'"> + + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-has="'line:add&edit&delete'" + > + <a>鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> </a-table> </div> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="璁惧" key="1" forceRender> + <a-tab-pane + tab="璁惧" + key="1" + forceRender + > <equipment-list-of-line :mainId="selectedMainId"></equipment-list-of-line> </a-tab-pane> </a-tabs> - <equipment-of-line-modal ref="modalForm" @ok="modalFormOk" :caytegoryParam="caytegoryParam"></equipment-of-line-modal> + <equipment-of-line-modal + ref="modalForm" + @ok="modalFormOk" + :caytegoryParam="caytegoryParam" + ></equipment-of-line-modal> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import { mixinDevice } from '@/utils/mixin' - import { getAction } from '@/api/manage' - import '@/assets/less/TableExpand.less' - import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' - import EquipmentOfLineModal from './modules/line/EquipmentOfLineModal.vue' - import EquipmentListOfLine from './modules/line/EquipmentListOfLine' - export default { - name: "EquipmentOfLine", - mixins:[JeecgListMixin,mixinDevice], - components: { - JSearchSelectTag, - EquipmentOfLineModal, - EquipmentListOfLine, - }, - data () { - return { - description: '璁惧鍙拌处绠$悊椤甸潰', - caytegoryParam:'line', - // 琛ㄥご - columns: [ +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import { mixinDevice } from '@/utils/mixin' +import { getAction } from '@/api/manage' +import '@/assets/less/TableExpand.less' +import JSearchSelectTag from '../../components/dict/JSearchSelectTag.vue' +import EquipmentOfLineModal from './modules/line/EquipmentOfLineModal.vue' +import EquipmentListOfLine from './modules/line/EquipmentListOfLine' +export default { + name: "EquipmentOfLine", + mixins: [JeecgListMixin, mixinDevice], + components: { + JSearchSelectTag, + EquipmentOfLineModal, + EquipmentListOfLine, + }, + data() { + return { + description: '璁惧鍙拌处绠$悊椤甸潰', + caytegoryParam: 'line', + // 琛ㄥご + columns: [ { title: '#', dataIndex: '', @@ -236,181 +281,181 @@ }, width: 150, }, - ], - url: { - list: "/eam/equipment/getEquipmentList", - delete: "/eam/equipment/delete", - deleteBatch: "/eam/equipment/deleteBatch", - active: "/eam/equipment/active", - exportXlsUrl: '/eam/equipment/exportXls', - importExcelUrl: "/eam/equipment/importExcel", - loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + ], + url: { + list: "/eam/equipment/getEquipmentList", + delete: "/eam/equipment/delete", + deleteBatch: "/eam/equipment/deleteBatch", + active: "/eam/equipment/active", + exportXlsUrl: '/eam/equipment/exportXls', + importExcelUrl: "/eam/equipment/importExcel", + loadOptions: '/sys/sysDepart/loadDepartTreeOptions', + }, + dictOptions: { + }, + /* 鍒嗛〉鍙傛暟 */ + ipagination: { + current: 1, + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], + showTotal: (total, range) => { + return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, - dictOptions:{ - }, - /* 鍒嗛〉鍙傛暟 */ - ipagination:{ - current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], - showTotal: (total, range) => { - return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" - }, - showQuickJumper: true, - showSizeChanger: true, - total: 0 - }, - selectedMainId:'', - superFieldList:[], - equipmentProcessParametersMainId: '', - equipmentDocumentMainId: '', - equipmentPrecisionParametersMainId: '', - precisionParametersTemplateId:'', - isOpenPrecision:true, - isOpenProcess:true, - treeData: [], - labelCol: { + showQuickJumper: true, + showSizeChanger: true, + total: 0 + }, + selectedMainId: '', + superFieldList: [], + equipmentProcessParametersMainId: '', + equipmentDocumentMainId: '', + equipmentPrecisionParametersMainId: '', + precisionParametersTemplateId: '', + isOpenPrecision: true, + isOpenProcess: true, + treeData: [], + labelCol: { xs: { span: 24 }, sm: { span: 5 }, - }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, - }, - mainId:'', - } - }, - created() { - this.getSuperFieldList(); - this.initOptions(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ }, - equipmentResumeShow(record) { + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, + }, + mainId: '', + } + }, + created() { + this.getSuperFieldList(); + this.initOptions(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + equipmentResumeShow(record) { this.$refs.EquipmentResumeDrawer.visible = true this.$refs.EquipmentResumeDrawer.title = '璁惧灞ュ巻' this.$refs.EquipmentResumeDrawer.handleShow(record) - }, - clickThenSelect(record) { - return { - on: { - click: () => { - this.onSelectChange(record.id.split(","), [record]); - } + }, + clickThenSelect(record) { + return { + on: { + click: () => { + this.onSelectChange(record.id.split(","), [record]); } } - }, - onClearSelected() { - this.selectedRowKeys = []; - this.selectionRows = []; - this.selectedMainId='' - }, - onSelectChange(selectedRowKeys, selectionRows) { - if(selectedRowKeys.length==1){ - this.selectedMainId=selectedRowKeys[0] - }else{ - this.selectedMainId='' + } + }, + onClearSelected() { + this.selectedRowKeys = []; + this.selectionRows = []; + this.selectedMainId = '' + }, + onSelectChange(selectedRowKeys, selectionRows) { + if (selectedRowKeys.length == 1) { + this.selectedMainId = selectedRowKeys[0] + } else { + this.selectedMainId = '' + } + this.selectedRowKeys = selectedRowKeys; + this.selectionRows = selectionRows; + }, + loadData(arg) { + if (!this.url.list) { + this.$message.error("璇疯缃畊rl.list灞炴��!") + return + } + //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 + if (arg === 1) { + this.ipagination.current = 1; + } + this.onClearSelected() + this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; + var params = this.getQueryParams();//鏌ヨ鏉′欢 + this.loading = true; + getAction(this.url.list, params).then((res) => { + if (res.success) { + this.dataSource = res.result.records; + this.ipagination.total = res.result.total; } - this.selectedRowKeys = selectedRowKeys; - this.selectionRows = selectionRows; - }, - loadData(arg) { - if(!this.url.list){ - this.$message.error("璇疯缃畊rl.list灞炴��!") - return + if (res.code === 510) { + this.$message.warning(res.message) } - //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭 - if (arg === 1) { - this.ipagination.current = 1; - } - this.onClearSelected() - this.queryParam.equipmentCategoryUda1 = this.caytegoryParam; - var params = this.getQueryParams();//鏌ヨ鏉′欢 - this.loading = true; - getAction(this.url.list, params).then((res) => { - if (res.success) { - this.dataSource = res.result.records; - this.ipagination.total = res.result.total; - } - if(res.code===510){ - this.$message.warning(res.message) - } - this.loading = false; - }) - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'缁熶竴缂栫爜',dictCode:''}) - fieldList.push({type:'string',value:'name',text:'璁惧鍚嶇О',dictCode:''}) - fieldList.push({type:'string',value:'model',text:'鍨嬪彿',dictCode:''}) - fieldList.push({type:'string',value:'specification',text:'瑙勬牸',dictCode:''}) - fieldList.push({type:'string',value:'equipmentStatus',text:'璁惧鐘舵��',dictCode:''}) - fieldList.push({type:'string',value:'technologyStatus',text:'technologyStatus',dictCode:''}) - fieldList.push({type:'string',value:'assetNumber',text:'assetNumber',dictCode:''}) - fieldList.push({type:'string',value:'equipmentCategoryId',text:'equipmentCategoryId',dictCode:''}) - fieldList.push({type:'string',value:'specificEquipment',text:'specificEquipment',dictCode:''}) - fieldList.push({type:'string',value:'equipmentPhoto',text:'equipmentPhoto',dictCode:''}) - fieldList.push({type:'string',value:'constructorId',text:'璧勪骇鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'supplierId',text:'supplierId',dictCode:''}) - fieldList.push({type:'string',value:'factoryNumber',text:'factoryNumber',dictCode:''}) - fieldList.push({type:'string',value:'leaveFactoryDate',text:'鍑哄巶鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'acceptanceCheckDate',text:'楠屾敹鏃ユ湡',dictCode:''}) - fieldList.push({type:'string',value:'affiliationId',text:'affiliationId',dictCode:''}) - fieldList.push({type:'string',value:'manageId',text:'缁存姢閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'manager',text:'manager',dictCode:''}) - fieldList.push({type:'string',value:'useId',text:'浣跨敤閮ㄩ棬ID',dictCode:''}) - fieldList.push({type:'string',value:'functionary',text:'functionary',dictCode:''}) - fieldList.push({type:'string',value:'location',text:'location',dictCode:''}) - fieldList.push({type:'string',value:'equipmentImportanceId',text:'ABC鏍囪瘑ID',dictCode:''}) - fieldList.push({type:'string',value:'processParameters',text:'processParameters',dictCode:''}) - fieldList.push({type:'string',value:'processParametersTemplateId',text:'processParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'precisionParameters',text:'precisionParameters',dictCode:''}) - fieldList.push({type:'string',value:'precisionParametersTemplateId',text:'precisionParametersTemplateId',dictCode:''}) - fieldList.push({type:'string',value:'verification',text:'verification',dictCode:''}) - fieldList.push({type:'string',value:'verificationPeriod',text:'verificationPeriod',dictCode:''}) - fieldList.push({type:'string',value:'lastVerificationDate',text:'lastVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'nextVerificationDate',text:'nextVerificationDate',dictCode:''}) - fieldList.push({type:'string',value:'status',text:'status',dictCode:''}) - fieldList.push({type:'string',value:'remark',text:'remark',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda1',text:'宸ュ尯',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda2',text:'瀹夎浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda3',text:'閲嶉噺',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda4',text:'閲嶉噺璁¢噺鍗曚綅ID',dictCode:''}) - fieldList.push({type:'string',value:'equipmentUda5',text:'鍔熻兘浣嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'tenantId',text:'tenantId',dictCode:''}) - fieldList.push({type:'int',value:'delFlag',text:'delFlag',dictCode:''}) - fieldList.push({type:'string',value:'teamId',text:'缁翠慨鐝粍ID',dictCode:''}) - fieldList.push({type:'string',value:'sourceId',text:'sourceId',dictCode:''}) - fieldList.push({type:'string',value:'fundSource',text:'璧勯噾鏉ユ簮',dictCode:''}) - fieldList.push({type:'string',value:'factoryNo',text:'鍑哄巶缂栧彿',dictCode:''}) - fieldList.push({type:'string',value:'mfr',text:'鍒堕�犲晢',dictCode:''}) - fieldList.push({type:'string',value:'sourceCountry',text:'璧勪骇鏉ユ簮鍥藉',dictCode:''}) - fieldList.push({type:'string',value:'gpo',text:'鎬诲姛鐜�',dictCode:''}) - fieldList.push({type:'string',value:'keyEquipmentIdentification',text:'鍏抽敭璁惧鏍囪瘑',dictCode:''}) - fieldList.push({type:'string',value:'securityConfiguration',text:'瀹夊叏閰嶇疆',dictCode:''}) - fieldList.push({type:'string',value:'coolingSystem',text:'鍐峰嵈绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisher',text:'鐏伀鍣�',dictCode:''}) - fieldList.push({type:'string',value:'fireExtinguisherValidityPeriod',text:'鐏伀鍣ㄦ湁鏁堟湡',dictCode:''}) - fieldList.push({type:'string',value:'operatingSystem',text:'鎿嶄綔绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'system',text:'绯荤粺',dictCode:''}) - fieldList.push({type:'string',value:'port',text:'绔彛',dictCode:''}) - fieldList.push({type:'BigDecimal',value:'coordinateNum',text:'鍧愭爣鏁伴噺',dictCode:''}) - fieldList.push({type:'string',value:'projectApprovalNo',text:'绔嬮」鍗″彿',dictCode:''}) - this.superFieldList = fieldList - }, - editProcess(record){ - this.$refs.processEditModel.edit(record); - }, - editPrecision(record){ - this.$refs.precisionEditModel.edit(record); - }, - initOptions() { + this.loading = false; + }) + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '缁熶竴缂栫爜', dictCode: '' }) + fieldList.push({ type: 'string', value: 'name', text: '璁惧鍚嶇О', dictCode: '' }) + fieldList.push({ type: 'string', value: 'model', text: '鍨嬪彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specification', text: '瑙勬牸', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentStatus', text: '璁惧鐘舵��', dictCode: '' }) + fieldList.push({ type: 'string', value: 'technologyStatus', text: 'technologyStatus', dictCode: '' }) + fieldList.push({ type: 'string', value: 'assetNumber', text: 'assetNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentCategoryId', text: 'equipmentCategoryId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'specificEquipment', text: 'specificEquipment', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentPhoto', text: 'equipmentPhoto', dictCode: '' }) + fieldList.push({ type: 'string', value: 'constructorId', text: '璧勪骇鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'supplierId', text: 'supplierId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNumber', text: 'factoryNumber', dictCode: '' }) + fieldList.push({ type: 'string', value: 'leaveFactoryDate', text: '鍑哄巶鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'acceptanceCheckDate', text: '楠屾敹鏃ユ湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'affiliationId', text: 'affiliationId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manageId', text: '缁存姢閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'manager', text: 'manager', dictCode: '' }) + fieldList.push({ type: 'string', value: 'useId', text: '浣跨敤閮ㄩ棬ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'functionary', text: 'functionary', dictCode: '' }) + fieldList.push({ type: 'string', value: 'location', text: 'location', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentImportanceId', text: 'ABC鏍囪瘑ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParameters', text: 'processParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'processParametersTemplateId', text: 'processParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParameters', text: 'precisionParameters', dictCode: '' }) + fieldList.push({ type: 'string', value: 'precisionParametersTemplateId', text: 'precisionParametersTemplateId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verification', text: 'verification', dictCode: '' }) + fieldList.push({ type: 'string', value: 'verificationPeriod', text: 'verificationPeriod', dictCode: '' }) + fieldList.push({ type: 'string', value: 'lastVerificationDate', text: 'lastVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'nextVerificationDate', text: 'nextVerificationDate', dictCode: '' }) + fieldList.push({ type: 'string', value: 'status', text: 'status', dictCode: '' }) + fieldList.push({ type: 'string', value: 'remark', text: 'remark', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda1', text: '宸ュ尯', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda2', text: '瀹夎浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda3', text: '閲嶉噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda4', text: '閲嶉噺璁¢噺鍗曚綅ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'equipmentUda5', text: '鍔熻兘浣嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'tenantId', text: 'tenantId', dictCode: '' }) + fieldList.push({ type: 'int', value: 'delFlag', text: 'delFlag', dictCode: '' }) + fieldList.push({ type: 'string', value: 'teamId', text: '缁翠慨鐝粍ID', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceId', text: 'sourceId', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fundSource', text: '璧勯噾鏉ユ簮', dictCode: '' }) + fieldList.push({ type: 'string', value: 'factoryNo', text: '鍑哄巶缂栧彿', dictCode: '' }) + fieldList.push({ type: 'string', value: 'mfr', text: '鍒堕�犲晢', dictCode: '' }) + fieldList.push({ type: 'string', value: 'sourceCountry', text: '璧勪骇鏉ユ簮鍥藉', dictCode: '' }) + fieldList.push({ type: 'string', value: 'gpo', text: '鎬诲姛鐜�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'keyEquipmentIdentification', text: '鍏抽敭璁惧鏍囪瘑', dictCode: '' }) + fieldList.push({ type: 'string', value: 'securityConfiguration', text: '瀹夊叏閰嶇疆', dictCode: '' }) + fieldList.push({ type: 'string', value: 'coolingSystem', text: '鍐峰嵈绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisher', text: '鐏伀鍣�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'fireExtinguisherValidityPeriod', text: '鐏伀鍣ㄦ湁鏁堟湡', dictCode: '' }) + fieldList.push({ type: 'string', value: 'operatingSystem', text: '鎿嶄綔绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'system', text: '绯荤粺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'port', text: '绔彛', dictCode: '' }) + fieldList.push({ type: 'BigDecimal', value: 'coordinateNum', text: '鍧愭爣鏁伴噺', dictCode: '' }) + fieldList.push({ type: 'string', value: 'projectApprovalNo', text: '绔嬮」鍗″彿', dictCode: '' }) + this.superFieldList = fieldList + }, + editProcess(record) { + this.$refs.processEditModel.edit(record); + }, + editPrecision(record) { + this.$refs.precisionEditModel.edit(record); + }, + initOptions() { getAction(this.url.loadOptions).then(res => { if (res.success) { this.treeData = res.result @@ -419,19 +464,19 @@ } }) }, - handleUpdateABC(){ + handleUpdateABC() { this.$refs.updateABC.add(); }, - handleUpdateWarranty(){ + handleUpdateWarranty() { this.$refs.updateWarranty.add(); }, - handleEditSpareParts(record){ + handleEditSpareParts(record) { this.$refs.modalFormSpareParts.edit(record); } - } } +} </script> <style scoped> - @import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/MalfunctionRepair.vue b/src/views/eam/MalfunctionRepair.vue index 8bab567..d2077f6 100644 --- a/src/views/eam/MalfunctionRepair.vue +++ b/src/views/eam/MalfunctionRepair.vue @@ -178,12 +178,10 @@ </a-form-item> </a-col> <a-col - :md="6" + :md="6" :sm="6" > - <a-form-item - label="鏄惁鍏抽敭璁惧" - > + <a-form-item label="鏄惁鍏抽敭璁惧"> <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨鏄惁鍏抽敭璁惧" @@ -225,7 +223,7 @@ <a-table ref="table" size="middle" - :scroll="{ x: 'calc(1900px + 50%)', y: 900 }" + :scroll="{ x: 'calc(1500px + 50%)', y: 900 }" bordered rowKey="id" :columns="columns" @@ -236,13 +234,21 @@ @change="handleTableChange" :customRow="clickThenSelect" > - <span + <span slot="specificEquipment" slot-scope="text" > - <a-icon type="check" style="color: chartreuse;" v-if="text==='0'" /> - <a-icon type="close" v-else style="color:red;"/> - </span> + <a-icon + type="check" + style="color: chartreuse;" + v-if="text==='0'" + /> + <a-icon + type="close" + v-else + style="color:red;" + /> + </span> <span slot="action" slot-scope="text, record" @@ -413,7 +419,7 @@ dataIndex: 'statusName', }, { - title: '绫诲瀷', + title: '鎶ヤ慨绫诲瀷', align: "center", dataIndex: 'type', customRender: (text) => { @@ -421,6 +427,8 @@ return "琚姩鎶ヤ慨"; } else if (text == '2') { return "涓诲姩鎶ヤ慨"; + } else if (text == '3') { + return "涓诲姩缁翠慨"; } }, }, @@ -457,11 +465,11 @@ align: "center", dataIndex: 'equipmentModel', }, - { - title: '瑙勬牸', - align: "center", - dataIndex: 'equipmentSpecification', - }, + // { + // title: '瑙勬牸', + // align: "center", + // dataIndex: 'equipmentSpecification', + // }, { title: '浣跨敤閮ㄩ棬', align: "center", @@ -495,7 +503,8 @@ { title: '鏁呴殰鏃堕棿', align: "center", - dataIndex: 'faultTime' + dataIndex: 'faultTime', + width: 200 }, { title: '鏄惁鍋滄満寰呬慨', @@ -530,7 +539,7 @@ dataIndex: 'action', align: "center", fixed: "right", - width: 200, + width: 100, scopedSlots: { customRender: 'action' } } ], @@ -546,8 +555,8 @@ /* 鍒嗛〉鍙傛暟 */ ipagination: { current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], showTotal: (total, range) => { return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, diff --git a/src/views/eam/OperationCertificateApplyList.vue b/src/views/eam/OperationCertificateApplyList.vue index ca8f095..19720e2 100644 --- a/src/views/eam/OperationCertificateApplyList.vue +++ b/src/views/eam/OperationCertificateApplyList.vue @@ -1,33 +1,85 @@ <template> - <a-card :bordered="false"> + <a-card + title="鎿嶄綔璇佺敵璇�" + :bordered="false" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="鐢宠鍗曠紪鍙�"> - <a-input placeholder="璇疯緭鍏ョ敵璇峰崟缂栧彿" v-model="queryParam.num"></a-input> + <a-input + placeholder="璇疯緭鍏ョ敵璇峰崟缂栧彿" + v-model="queryParam.num" + ></a-input> </a-form-item> </a-col> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="绫诲瀷"> - <j-dict-select-tag placeholder="璇烽�夋嫨绫诲瀷" v-model="queryParam.type" dictCode="apply_type"/> + <j-dict-select-tag + placeholder="璇烽�夋嫨绫诲瀷" + v-model="queryParam.type" + dictCode="apply_type" + /> </a-form-item> </a-col> <template v-if="toggleSearchStatus"> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > <a-form-item label="瀹℃牳鐘舵��"> - <j-dict-select-tag placeholder="璇烽�夋嫨瀹℃牳鐘舵��" v-model="queryParam.auditStatus" dictCode="certificate_apply_status"/> + <j-dict-select-tag + placeholder="璇烽�夋嫨瀹℃牳鐘舵��" + v-model="queryParam.auditStatus" + dictCode="certificate_apply_status" + /> </a-form-item> </a-col> </template> - <a-col :xl="6" :lg="7" :md="8" :sm="24"> - <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> - <a-button type="primary" @click="searchQuery" icon="search">鏌ヨ</a-button> - <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">閲嶇疆</a-button> - <a @click="handleToggleSearch" style="margin-left: 8px"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > + <span + style="float: left;overflow: hidden;" + class="table-page-search-submitButtons" + > + <a-button + type="primary" + @click="searchQuery" + icon="search" + >鏌ヨ</a-button> + <a-button + type="primary" + @click="searchReset" + icon="reload" + style="margin-left: 8px" + >閲嶇疆</a-button> + <a + @click="handleToggleSearch" + style="margin-left: 8px" + > {{ toggleSearchStatus ? '鏀惰捣' : '灞曞紑' }} - <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/> + <a-icon :type="toggleSearchStatus ? 'up' : 'down'" /> </a> </span> </a-col> @@ -38,17 +90,43 @@ <!-- 鎿嶄綔鎸夐挳鍖哄煙 --> <div class="table-operator"> - <a-button @click="handleAdd" type="primary" icon="plus">鐢宠</a-button> - <a-button type="primary" icon="download" @click="handleExportXls('鎿嶄綔璇佺敵璇疯〃')">瀵煎嚭</a-button> - <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> - <a-button type="primary" icon="import">瀵煎叆</a-button> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + >鐢宠</a-button> + <a-button + type="primary" + icon="download" + @click="handleExportXls('鎿嶄綔璇佺敵璇疯〃')" + >瀵煎嚭</a-button> + <a-upload + name="file" + :showUploadList="false" + :multiple="false" + :headers="tokenHeader" + :action="importExcelUrl" + @change="handleImportExcel" + > + <a-button + type="primary" + icon="import" + >瀵煎叆</a-button> </a-upload> - <a-button @click="handleAchievement" type="primary" icon="plus" v-if="selectedRowKeys.length == 1 && selectionRows[0].auditStatus == 'audited'">鎴愮哗褰曞叆</a-button> + <a-button + @click="handleAchievement" + type="primary" + icon="plus" + v-if="selectedRowKeys.length == 1 && selectionRows[0].auditStatus == 'audited'" + >鎴愮哗褰曞叆</a-button> <!-- 楂樼骇鏌ヨ鍖哄煙 --> -<!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>--> + <!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>--> <a-dropdown v-if="selectedRowKeys.length > 0"> <a-menu slot="overlay"> - <a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>鍒犻櫎</a-menu-item> + <a-menu-item + key="1" + @click="batchDel" + ><a-icon type="delete" />鍒犻櫎</a-menu-item> </a-menu> <a-button style="margin-left: 8px"> 鎵归噺鎿嶄綔 <a-icon type="down" /></a-button> </a-dropdown> @@ -56,9 +134,15 @@ <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� - <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> </div> <a-table @@ -73,29 +157,56 @@ :pagination="ipagination" :loading="loading" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" - @change="handleTableChange"> + @change="handleTableChange" + > - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <span slot="action" slot-scope="text, record"> + <span + slot="action" + slot-scope="text, record" + > <a-popconfirm v-if="record.auditStatus == 'created'" @@ -122,7 +233,10 @@ v-if="record.auditStatus == 'created' || record.auditStatus == 'submitted'" type="vertical" /> - <a @click="handleEdit(record)" v-if="record.auditStatus == 'created'">缂栬緫</a> + <a + @click="handleEdit(record)" + v-if="record.auditStatus == 'created'" + >缂栬緫</a> <a-divider v-if="record.auditStatus == 'created'" type="vertical" @@ -151,7 +265,10 @@ > <a>瀹℃牳</a> </a-popconfirm> --> - <a-divider type="vertical" v-if="record.auditStatus == 'created' || record.auditStatus == 'submitted' || record.auditStatus == 'approved'"/> + <a-divider + type="vertical" + v-if="record.auditStatus == 'created' || record.auditStatus == 'submitted' || record.auditStatus == 'approved'" + /> <a-dropdown> <a class="ant-dropdown-link">鏇村 <a-icon type="down" /></a> <a-menu slot="overlay"> @@ -159,7 +276,11 @@ <a @click="handleDetail(record)">璇︽儏</a> </a-menu-item> <a-menu-item> - <a-popconfirm title="纭畾鍒犻櫎鍚�?" @confirm="() => handleDelete(record.id)" v-if="record.auditStatus == 'created'"> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + v-if="record.auditStatus == 'created'" + > <a>鍒犻櫎</a> </a-popconfirm> </a-menu-item> @@ -170,150 +291,160 @@ </a-table> </div> <a-tabs defaultActiveKey='1'> - <a-tab-pane tab='鎿嶄綔璇佺敵璇锋槑缁�' key='1'> + <a-tab-pane + tab='鎿嶄綔璇佺敵璇锋槑缁�' + key='1' + > <div class='table-operator' - style='margin:-20px'> + style='margin:-20px' + > <operation-certificate-apply-detail-list :mainId='operationCretificateApplyId' /> </div> </a-tab-pane> </a-tabs> - <operation-certificate-apply-modal ref="modalForm" @ok="modalFormOk" /> - <operation-certificate-apply-audit ref="modalFormAudit" @ok="modalFormOk" /> + <operation-certificate-apply-modal + ref="modalForm" + @ok="modalFormOk" + /> + <operation-certificate-apply-audit + ref="modalFormAudit" + @ok="modalFormOk" + /> </a-card> </template> <script> - import { JeecgListMixin } from '@/mixins/JeecgListMixin' - import OperationCertificateApplyModal from './modules/operationCertificateApply/OperationCertificateApplyModal' - import OperationCertificateApplyAudit from './modules/operationCertificateApply/OperationCertificateApplyAudit' - import {filterMultiDictText} from '@/components/dict/JDictSelectUtil' - import { getAction, postAction } from '@/api/manage' - import OperationCertificateApplyDetailList from './modules/operationCertificateApply/OperationCertificateApplyDetailList' - import '@/assets/less/TableExpand.less' +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import OperationCertificateApplyModal from './modules/operationCertificateApply/OperationCertificateApplyModal' +import OperationCertificateApplyAudit from './modules/operationCertificateApply/OperationCertificateApplyAudit' +import { filterMultiDictText } from '@/components/dict/JDictSelectUtil' +import { getAction, postAction } from '@/api/manage' +import OperationCertificateApplyDetailList from './modules/operationCertificateApply/OperationCertificateApplyDetailList' +import '@/assets/less/TableExpand.less' - export default { - name: "OperationCertificateApplyList", - mixins:[JeecgListMixin], - components: { - OperationCertificateApplyModal, - OperationCertificateApplyDetailList, - OperationCertificateApplyAudit - }, - data () { - return { - description: '鎿嶄綔璇佺敵璇疯〃绠$悊椤甸潰', - operationCretificateApplyId:'', - selectedMainId: '', - // 琛ㄥご - columns: [ - { - title: '#', - dataIndex: '', - key:'rowIndex', - width:60, - align:"center", - customRender:function (t,r,index) { - return parseInt(index)+1; - } - }, - { - title:'鐢宠鍗曠紪鍙�', - align:"center", - dataIndex: 'num' - }, - { - title:'绫诲瀷', - align:"center", - dataIndex: 'type_dictText' - }, - { - title:'鎵�鍦ㄥ崟浣�', - align:"center", - dataIndex: 'departId_dictText' - }, - { - title:'鐢宠鍗曚綅鑱旂郴鐢佃瘽', - align:"center", - dataIndex: 'contactNumber' - }, - { - title:'鐢宠浜�', - align:"center", - dataIndex: 'applicant_dictText' - }, - { - title:'瀹℃牳鐘舵��', - align:"center", - dataIndex: 'auditStatus_dictText' - }, - { - title:'鍔炵悊浜�', - align:"center", - dataIndex: 'handlePerson_dictText' - }, - { - title:'澶囨敞', - align:"center", - dataIndex: 'remark' - }, - { - title: '鎿嶄綔', - dataIndex: 'action', - align:"center", - fixed:"right", - width:147, - scopedSlots: { customRender: 'action' }, +export default { + name: "OperationCertificateApplyList", + mixins: [JeecgListMixin], + components: { + OperationCertificateApplyModal, + OperationCertificateApplyDetailList, + OperationCertificateApplyAudit + }, + data() { + return { + description: '鎿嶄綔璇佺敵璇疯〃绠$悊椤甸潰', + operationCretificateApplyId: '', + selectedMainId: '', + // 琛ㄥご + columns: [ + { + title: '#', + dataIndex: '', + key: 'rowIndex', + width: 60, + align: "center", + customRender: function (t, r, index) { + return parseInt(index) + 1; } - ], - url: { - list: "/eam/operationCertificateApply/list", - delete: "/eam/operationCertificateApply/delete", - deleteBatch: "/eam/operationCertificateApply/deleteBatch", - exportXlsUrl: "/eam/operationCertificateApply/exportXls", - importExcelUrl: "eam/operationCertificateApply/importExcel", - approve:"/eam/operationCertificateApply/approve" }, - dictOptions:{}, - superFieldList:[], - } - }, - created() { - this.getSuperFieldList(); - }, - computed: { - importExcelUrl: function(){ - return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; - } - }, - methods: { - initDictConfig(){ - }, - getSuperFieldList(){ - let fieldList=[]; - fieldList.push({type:'string',value:'num',text:'鐢宠鍗曠紪鍙�',dictCode:''}) - fieldList.push({type:'string',value:'type',text:'绫诲瀷',dictCode:'apply_type'}) - fieldList.push({type:'sel_depart',value:'departId',text:'鎵�鍦ㄥ崟浣�'}) - fieldList.push({type:'string',value:'contactNumber',text:'鐢宠鍗曚綅鑱旂郴鐢佃瘽',dictCode:''}) - fieldList.push({type:'string',value:'applicant',text:'鐢宠浜�',dictCode:"sys_user,realname,id"}) - fieldList.push({type:'string',value:'auditStatus',text:'瀹℃牳鐘舵��',dictCode:'certificate_apply_status'}) - fieldList.push({type:'string',value:'remark',text:'澶囨敞',dictCode:''}) - this.superFieldList = fieldList - }, - handleCommit(record, type) { - if(type == 'commit'){ - record.auditStatus = 'submitted' - }else if(type == 'back'){ - record.auditStatus = 'created' - }else if(type == 'approved'){ - record.auditStatus = 'approved' - }else if(type == 'audited'){ - record.auditStatus = 'audited' + { + title: '鐢宠鍗曠紪鍙�', + align: "center", + dataIndex: 'num' + }, + { + title: '绫诲瀷', + align: "center", + dataIndex: 'type_dictText' + }, + { + title: '鎵�鍦ㄥ崟浣�', + align: "center", + dataIndex: 'departId_dictText' + }, + { + title: '鐢宠鍗曚綅鑱旂郴鐢佃瘽', + align: "center", + dataIndex: 'contactNumber' + }, + { + title: '鐢宠浜�', + align: "center", + dataIndex: 'applicant_dictText' + }, + { + title: '瀹℃牳鐘舵��', + align: "center", + dataIndex: 'auditStatus_dictText' + }, + { + title: '鍔炵悊浜�', + align: "center", + dataIndex: 'handlePerson_dictText' + }, + { + title: '澶囨敞', + align: "center", + dataIndex: 'remark' + }, + { + title: '鎿嶄綔', + dataIndex: 'action', + align: "center", + fixed: "right", + width: 147, + scopedSlots: { customRender: 'action' }, } - + ], + url: { + list: "/eam/operationCertificateApply/list", + delete: "/eam/operationCertificateApply/delete", + deleteBatch: "/eam/operationCertificateApply/deleteBatch", + exportXlsUrl: "/eam/operationCertificateApply/exportXls", + importExcelUrl: "eam/operationCertificateApply/importExcel", + approve: "/eam/operationCertificateApply/approve" + }, + dictOptions: {}, + superFieldList: [], + } + }, + created() { + this.getSuperFieldList(); + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + } + }, + methods: { + initDictConfig() { + }, + getSuperFieldList() { + let fieldList = []; + fieldList.push({ type: 'string', value: 'num', text: '鐢宠鍗曠紪鍙�', dictCode: '' }) + fieldList.push({ type: 'string', value: 'type', text: '绫诲瀷', dictCode: 'apply_type' }) + fieldList.push({ type: 'sel_depart', value: 'departId', text: '鎵�鍦ㄥ崟浣�' }) + fieldList.push({ type: 'string', value: 'contactNumber', text: '鐢宠鍗曚綅鑱旂郴鐢佃瘽', dictCode: '' }) + fieldList.push({ type: 'string', value: 'applicant', text: '鐢宠浜�', dictCode: "sys_user,realname,id" }) + fieldList.push({ type: 'string', value: 'auditStatus', text: '瀹℃牳鐘舵��', dictCode: 'certificate_apply_status' }) + fieldList.push({ type: 'string', value: 'remark', text: '澶囨敞', dictCode: '' }) + this.superFieldList = fieldList + }, + handleCommit(record, type) { + if (type == 'commit') { + record.auditStatus = 'submitted' + } else if (type == 'back') { + record.auditStatus = 'created' + } else if (type == 'approved') { + record.auditStatus = 'approved' + } else if (type == 'audited') { + record.auditStatus = 'audited' + } + postAction(this.url.approve, record).then(res => { if (res.success) { this.$message.success("鎿嶄綔鎴愬姛锛�"); @@ -323,7 +454,7 @@ } }) }, - handleEdit: function (record) { + handleEdit: function (record) { this.$refs.modalForm.edit(record); this.$refs.modalForm.title = "缂栬緫"; this.$refs.modalForm.disableSubmit = false; @@ -333,18 +464,18 @@ this.$refs.modalForm.title = "鏂板"; this.$refs.modalForm.disableSubmit = false; }, - handleAchievement(){ - this.$refs.modalForm.edit(this.selectionRows[0]); - this.$refs.modalForm.title = "鎴愮哗褰曞叆"; - this.$refs.modalForm.disableSubmit = false; - this.$refs.modalForm.isAchievement = true; - }, - handleFinish: function (record) { + handleAchievement() { + this.$refs.modalForm.edit(this.selectionRows[0]); + this.$refs.modalForm.title = "鎴愮哗褰曞叆"; + this.$refs.modalForm.disableSubmit = false; + this.$refs.modalForm.isAchievement = true; + }, + handleFinish: function (record) { this.$refs.modalFormAudit.edit(record); this.$refs.modalFormAudit.title = "鎿嶄綔璇佺敵璇峰鏍�"; this.$refs.modalFormAudit.disableSubmit = true; }, - onSelectChange(selectedRowKeys, selectionRows) { + onSelectChange(selectedRowKeys, selectionRows) { if (selectedRowKeys.length == 1) { this.operationCretificateApplyId = selectionRows[0]['id'] @@ -367,9 +498,9 @@ this.selectedMainId = '' this.operationCretificateApplyId = '' } - } } +} </script> <style scoped> - @import '~@assets/less/common.less'; +@import '~@assets/less/common.less'; </style> \ No newline at end of file diff --git a/src/views/eam/OperationCertificateList.vue b/src/views/eam/OperationCertificateList.vue index 53b4262..9cb2195 100644 --- a/src/views/eam/OperationCertificateList.vue +++ b/src/views/eam/OperationCertificateList.vue @@ -1,37 +1,95 @@ <template> - <a-card :bordered='false'> + <a-card + title="鎿嶄綔璇佷功绠$悊" + :bordered='false' + > <!-- 鏌ヨ鍖哄煙 --> <div class='table-page-search-wrapper'> - <a-form layout='inline' @keyup.enter.native='searchQuery'> + <a-form + layout='inline' + @keyup.enter.native='searchQuery' + > <a-row :gutter='24'> - <a-col :xl='6' :lg='7' :md='8' :sm='24'> + <a-col + :xl='6' + :lg='7' + :md='8' + :sm='24' + > <a-form-item label='鎿嶄綔璇佺紪鍙�'> - <a-input placeholder='璇疯緭鍏ユ搷浣滆瘉缂栧彿' v-model='queryParam.num'></a-input> + <a-input + placeholder='璇疯緭鍏ユ搷浣滆瘉缂栧彿' + v-model='queryParam.num' + ></a-input> </a-form-item> </a-col> - <a-col :xl='6' :lg='7' :md='8' :sm='24'> + <a-col + :xl='6' + :lg='7' + :md='8' + :sm='24' + > <a-form-item label='濮撳悕'> - <j-select-user-by-dep placeholder='璇烽�夋嫨濮撳悕' v-model='queryParam.userId' /> + <j-select-user-by-dep + placeholder='璇烽�夋嫨濮撳悕' + v-model='queryParam.userId' + /> </a-form-item> </a-col> <template v-if='toggleSearchStatus'> - <a-col :xl='6' :lg='7' :md='8' :sm='24'> + <a-col + :xl='6' + :lg='7' + :md='8' + :sm='24' + > <a-form-item label='鍙戣瘉鏃ユ湡'> - <j-date placeholder='璇烽�夋嫨鍙戣瘉鏃ユ湡' v-model='queryParam.issueDate'></j-date> + <j-date + placeholder='璇烽�夋嫨鍙戣瘉鏃ユ湡' + v-model='queryParam.issueDate' + ></j-date> </a-form-item> </a-col> - <a-col :xl='6' :lg='7' :md='8' :sm='24'> + <a-col + :xl='6' + :lg='7' + :md='8' + :sm='24' + > <a-form-item label='璁惧缁熶竴缂栫爜'> - <j-multi-select-tag placeholder='璇烽�夋嫨璁惧缁熶竴缂栫爜' dictCode='mom_eam_equipment,num,id' - v-model='queryParam.equipmentIds' /> + <j-multi-select-tag + placeholder='璇烽�夋嫨璁惧缁熶竴缂栫爜' + dictCode='mom_eam_equipment,num,id' + v-model='queryParam.equipmentIds' + /> </a-form-item> </a-col> </template> - <a-col :xl='6' :lg='7' :md='8' :sm='24'> - <span style='float: left;overflow: hidden;' class='table-page-search-submitButtons'> - <a-button type='primary' @click='searchQuery' icon='search'>鏌ヨ</a-button> - <a-button type='primary' @click='searchReset' icon='reload' style='margin-left: 8px'>閲嶇疆</a-button> - <a @click='handleToggleSearch' style='margin-left: 8px'> + <a-col + :xl='6' + :lg='7' + :md='8' + :sm='24' + > + <span + style='float: left;overflow: hidden;' + class='table-page-search-submitButtons' + > + <a-button + type='primary' + @click='searchQuery' + icon='search' + >鏌ヨ</a-button> + <a-button + type='primary' + @click='searchReset' + icon='reload' + style='margin-left: 8px' + >閲嶇疆</a-button> + <a + @click='handleToggleSearch' + style='margin-left: 8px' + > {{ toggleSearchStatus ? '鏀惰捣' : '灞曞紑' }} <a-icon :type="toggleSearchStatus ? 'up' : 'down'" /> </a> @@ -44,12 +102,29 @@ <!-- 鎿嶄綔鎸夐挳鍖哄煙 --> <div class='table-operator'> -<!-- <a-button @click='handleAdd' type='primary' icon='plus'>鏂板</a-button>--> - <a-button @click='handleChangeCertificate' type='primary' icon='plus'>鍙樻洿鎿嶄綔璇�</a-button> - <a-button type='primary' icon='download' @click="handleExportXls('鎿嶄綔璇佷功绠$悊')">瀵煎嚭</a-button> - <a-upload name='file' :showUploadList='false' :multiple='false' :headers='tokenHeader' :action='importExcelUrl' - @change='handleImportExcel'> - <a-button type='primary' icon='import'>瀵煎叆</a-button> + <!-- <a-button @click='handleAdd' type='primary' icon='plus'>鏂板</a-button>--> + <a-button + @click='handleChangeCertificate' + type='primary' + icon='plus' + >鍙樻洿鎿嶄綔璇�</a-button> + <a-button + type='primary' + icon='download' + @click="handleExportXls('鎿嶄綔璇佷功绠$悊')" + >瀵煎嚭</a-button> + <a-upload + name='file' + :showUploadList='false' + :multiple='false' + :headers='tokenHeader' + :action='importExcelUrl' + @change='handleImportExcel' + > + <a-button + type='primary' + icon='import' + >瀵煎叆</a-button> </a-upload> <!-- 楂樼骇鏌ヨ鍖哄煙 --> <!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>--> @@ -63,10 +138,15 @@ <!-- table鍖哄煙-begin --> <div> - <div class='ant-alert ant-alert-info' style='margin-bottom: 16px;'> - <i class='anticon anticon-info-circle ant-alert-icon'></i> 宸查�夋嫨 <a - style='font-weight: 600'>{{ selectedRowKeys.length }}</a>椤� - <a style='margin-left: 24px' @click='onClearSelected'>娓呯┖</a> + <div + class='ant-alert ant-alert-info' + style='margin-bottom: 16px;' + > + <i class='anticon anticon-info-circle ant-alert-icon'></i> 宸查�夋嫨 <a style='font-weight: 600'>{{ selectedRowKeys.length }}</a>椤� + <a + style='margin-left: 24px' + @click='onClearSelected' + >娓呯┖</a> </div> <a-table @@ -82,59 +162,67 @@ :loading='loading' :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange ,type:'radio'}" :customRow='clickThenSelect' - @change='handleTableChange'> + @change='handleTableChange' + :rowClassName="tableRowClass" + > - - - <template slot='htmlSlot' slot-scope='text'> + <template + slot='htmlSlot' + slot-scope='text' + > <div v-html='text'></div> </template> - <template slot='imgSlot' slot-scope='text,record'> - <span v-if='!text' style='font-size: 12px;font-style: italic;'>鏃犲浘鐗�</span> - <img v-else :src='getImgView(text)' :preview='record.id' height='25px' alt='' - style='max-width:80px;font-size: 12px;font-style: italic;' /> + <template + slot='imgSlot' + slot-scope='text,record' + > + <span + v-if='!text' + style='font-size: 12px;font-style: italic;' + >鏃犲浘鐗�</span> + <img + v-else + :src='getImgView(text)' + :preview='record.id' + height='25px' + alt='' + style='max-width:80px;font-size: 12px;font-style: italic;' + /> </template> - <template slot='fileSlot' slot-scope='text'> - <span v-if='!text' style='font-size: 12px;font-style: italic;'>鏃犳枃浠�</span> + <template + slot='fileSlot' + slot-scope='text' + > + <span + v-if='!text' + style='font-size: 12px;font-style: italic;' + >鏃犳枃浠�</span> <a-button v-else :ghost='true' type='primary' icon='download' size='small' - @click='downloadFile(text)'> + @click='downloadFile(text)' + > 涓嬭浇 </a-button> </template> - <span slot='action' slot-scope='text, record'> -<!-- <a @click='handleEdit(record)'>缂栬緫</a>--> - <!-- <a-divider type='vertical' />--> -<!-- <a @click='handleDetail(record)'>璇︽儏</a>--> - <!-- <a-divider type="vertical" />--> - <!-- <a-dropdown>--> - <!-- <a class="ant-dropdown-link">鏇村 <a-icon type="down" /></a>--> - <!-- <a-menu slot="overlay">--> - <!-- <a-menu-item>--> - <!-- <a @click="handleDetail(record)">璇︽儏</a>--> - <!-- </a-menu-item>--> - <!-- <a-menu-item>--> - <!-- <a-popconfirm title="纭畾鍒犻櫎鍚�?" @confirm="() => handleDelete(record.id)">--> - <!-- <a>鍒犻櫎</a>--> - <!-- </a-popconfirm>--> - <!-- </a-menu-item>--> - <!-- </a-menu>--> - <!-- </a-dropdown>--> - </span> - </a-table> </div> <a-tabs defaultActiveKey="1"> - <a-tab-pane tab="鎿嶄綔璇佺鐞嗘槑缁�" key="1" > + <a-tab-pane + tab="鎿嶄綔璇佺鐞嗘槑缁�" + key="1" + > <OperationCertificateDetailList :mainId="operationCertificateDetailMainId" /> </a-tab-pane> </a-tabs> - <operation-certificate-modal ref='modalForm' @ok='modalFormOk' /> + <operation-certificate-modal + ref='modalForm' + @ok='modalFormOk' + /> </a-card> </template> @@ -164,7 +252,7 @@ key: 'rowIndex', width: 60, align: 'center', - customRender: function(t, r, index) { + customRender: function (t, r, index) { return parseInt(index) + 1 } }, @@ -182,7 +270,7 @@ title: '鍙戣瘉鏃ユ湡', align: 'center', dataIndex: 'issueDate', - customRender: function(text) { + customRender: function (text) { return !text ? '' : (text.length > 10 ? text.substr(0, 10) : text) } }, @@ -190,7 +278,7 @@ title: '寮�濮嬫椂闂�', align: 'center', dataIndex: 'startTime', - customRender: function(text) { + customRender: function (text) { return !text ? '' : (text.length > 10 ? text.substr(0, 10) : text) } }, @@ -198,7 +286,7 @@ title: '缁撴潫鏃堕棿', align: 'center', dataIndex: 'endTime', - customRender: function(text) { + customRender: function (text) { return !text ? '' : (text.length > 10 ? text.substr(0, 10) : text) } }, @@ -242,7 +330,7 @@ dictOptions: {}, superFieldList: [], /* 鍒嗛〉鍙傛暟 */ - ipagination:{ + ipagination: { current: 1, pageSize: 5, pageSizeOptions: ['5', '10', '50'], @@ -253,7 +341,7 @@ showSizeChanger: true, total: 0 }, - selectedMainId:'', + selectedMainId: '', operationCertificateDetailMainId: '', } @@ -262,7 +350,7 @@ this.getSuperFieldList() }, computed: { - importExcelUrl: function() { + importExcelUrl: function () { return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` } }, @@ -278,7 +366,7 @@ } } }, - handleChangeCertificate: function() { + handleChangeCertificate: function () { if (this.selectionRows.length <= 0) { this.$message.warning('璇烽�夋嫨涓�鏉¤褰�') return @@ -293,16 +381,16 @@ onClearSelected() { this.selectedRowKeys = []; this.selectionRows = []; - this.selectedMainId='' + this.selectedMainId = '' }, onSelectChange(selectedRowKeys, selectionRows) { - this.selectedMainId=selectedRowKeys[0] + this.selectedMainId = selectedRowKeys[0] this.selectedRowKeys = selectedRowKeys; this.selectionRows = selectionRows; this.operationCertificateDetailMainId = selectionRows[0]['id'] }, loadData(arg) { - if(!this.url.list){ + if (!this.url.list) { this.$message.error("璇疯缃畊rl.list灞炴��!") return } @@ -318,11 +406,18 @@ this.dataSource = res.result.records; this.ipagination.total = res.result.total; } - if(res.code===510){ + if (res.code === 510) { this.$message.warning(res.message) } this.loading = false; }) + }, + //棰勮棰滆壊 + tableRowClass(record, index) { + debugger + if ('0' === record.status) { + return 'error' + } }, getSuperFieldList() { let fieldList = [] @@ -347,6 +442,10 @@ } } </script> -<style scoped> +<style> @import '~@assets/less/common.less'; +.error { + color: red; + font-weight: bold; +} </style> \ No newline at end of file diff --git a/src/views/eam/RepairOrderList.vue b/src/views/eam/RepairOrderList.vue index c2c0583..fdf05fe 100644 --- a/src/views/eam/RepairOrderList.vue +++ b/src/views/eam/RepairOrderList.vue @@ -8,14 +8,17 @@ layout="inline" @keyup.enter.native="searchQuery" > - <a-row :gutter="24" style="margin-bottom: 1%;"> + <a-row + :gutter="24" + style="margin-bottom: 1%;" + > <a-col :xl="24" :lg="7" :md="8" :sm="24" > - <a-form-item label="缁熶竴缂栧彿缇�"> + <a-form-item label="缁熶竴缂栧彿缇�"> <a-textarea placeholder="璇疯緭鍏ユ墍鏈夌粺涓�缂栫爜,椤荤敤绌烘牸闅斿紑,鍚﹀垯鍙兘鏌ヨ鍑洪敊璇俊鎭�" v-model="queryParam.nums" @@ -82,28 +85,27 @@ </span> </a-col> --> <a-col - :xl="6" - :lg="7" - :md="8" - :sm="24" - > - <a-form-item label="璁惧鍚嶇О"> - <a-input - placeholder="璇疯緭鍏ヨ澶囧悕绉�" - v-model="queryParam.equipmentName" - ></a-input> - </a-form-item> - </a-col> - </a-row> - <a-row :gutter="24"> - <a-col :xl="6" - :lg="7" - :md="8" - :sm="24"> - <a-form-item - label="璁惧鎵�灞炲垎绫�" - > + :lg="7" + :md="8" + :sm="24" + > + <a-form-item label="璁惧鍚嶇О"> + <a-input + placeholder="璇疯緭鍏ヨ澶囧悕绉�" + v-model="queryParam.equipmentName" + ></a-input> + </a-form-item> + </a-col> + </a-row> + <a-row :gutter="24"> + <a-col + :xl="6" + :lg="7" + :md="8" + :sm="24" + > + <a-form-item label="璁惧鎵�灞炲垎绫�"> <j-dict-select-tag dictCode="mom_eam_equipment_category,name,id" placeholder="璇疯緭鍏ユ悳绱㈡潯浠跺苟閫夋嫨" @@ -111,15 +113,13 @@ /> </a-form-item> </a-col> - <a-col - :xl="6" + <a-col + :xl="6" :lg="7" - :md="8" - :sm="24" + :md="8" + :sm="24" > - <a-form-item - label="宸ュ尯" - > + <a-form-item label="宸ュ尯"> <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨璧勫伐鍖�" @@ -130,14 +130,12 @@ </a-form-item> </a-col> <a-col - :xl="6" + :xl="6" :lg="7" - :md="8" - :sm="24" + :md="8" + :sm="24" > - <a-form-item - label="鏄惁鍏抽敭璁惧" - > + <a-form-item label="鏄惁鍏抽敭璁惧"> <j-dict-select-tag allow-clear placeholder="璇烽�夋嫨鏄惁鍏抽敭璁惧" @@ -163,8 +161,8 @@ /> </a-form-item> </a-col> - </a-row> - <!-- <a-row :gutter="24"> + </a-row> + <!-- <a-row :gutter="24"> <a-col :xl="6" :lg="7" @@ -187,16 +185,16 @@ </div> <!-- 鎿嶄綔鎸夐挳鍖哄煙 --> <div class="table-operator"> - <a-dropdown> + <!-- <a-dropdown> <a-menu slot="overlay"> - <!-- <a-menu-item + <a-menu-item key="1" @click="handleAddPre(1)" - ><a-icon type="smile" />鑷缓</a-menu-item> --> - <!-- <a-menu-item + ><a-icon type="smile" />鑷缓</a-menu-item> + <a-menu-item key="2" @click="handleAddPre(2)" - ><a-icon type="copy" />鍙傜収鏁呴殰鎶ヤ慨鍗�</a-menu-item> --> + ><a-icon type="copy" />鍙傜収鏁呴殰鎶ヤ慨鍗�</a-menu-item> <a-menu-item key="2" @click="handleAddPre(3)" @@ -206,7 +204,7 @@ type="primary" icon="plus" >鏂板</a-button> - </a-dropdown> + </a-dropdown> --> <a-button type="primary" @@ -226,10 +224,10 @@ :disabled="selectionRows.length==0" >娲惧伐</a-button> <a-button - type="primary" - icon="plus" - @click="getReports" - v-has="'repair:accept'" + type="primary" + icon="plus" + @click="getReports" + v-has="'repair:accept'" >棰嗗彇</a-button> <!-- <a-button type="primary" icon="download" @click="handleExportXls('缁翠慨宸ュ崟')">瀵煎嚭</a-button> <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel"> @@ -258,7 +256,6 @@ bordered rowKey="id" class="j-table-force-nowrap" - :scroll="{ x: 'calc(2700px + 50%)', y: 900 }" :columns="columns" :dataSource="dataSource" :pagination="ipagination" @@ -266,17 +263,32 @@ @change="handleTableChange" :customRow="clickThenSelect" :rowClassName="tableRowClass" + :scroll="{ x: 'calc(1700px + 50%)', y: 900 }" > - <span slot="jell" slot-scope="text"> - <j-ellipsis :value="text" :length="8" /> + <span + slot="jell" + slot-scope="text" + > + <j-ellipsis + :value="text" + :length="8" + /> </span> <span slot="specificEquipment" slot-scope="text" > - <a-icon type="check" style="color: chartreuse;" v-if="text==='0'" /> - <a-icon type="close" v-else style="color:red;"/> - </span> + <a-icon + type="check" + style="color: chartreuse;" + v-if="text==='0'" + /> + <a-icon + type="close" + v-else + style="color:red;" + /> + </span> <span slot="num" slot-scope="text, record" @@ -285,8 +297,14 @@ v-if="record.status === '3' || record.status === '4' ||record.status === '5' ||record.status === '7' " class="lot" @click="handleOrderExe(record)" - ><j-ellipsis :value="text" :length="15"/></a> - <span v-else> <j-ellipsis :value="text" :length="15"/></span> + ><j-ellipsis + :value="text" + :length="15" + /></a> + <span v-else> <j-ellipsis + :value="text" + :length="15" + /></span> </span> <span slot="action" @@ -425,10 +443,9 @@ tab="瀹為檯鐢ㄦ枡" key="6" forceRender - v-if="false" > - <!-- v-if="!sonsAddStatus&&selectedRowKeys.length!=0" --> + <!-- v-if="!sonsAddStatus&&selectedRowKeys.length!=0" --> <RepairOrderActualMaterialList :mainId="repairOrderActualMaterialMainId" /> </a-tab-pane> <a-tab-pane @@ -510,10 +527,10 @@ FaultReportRepair, store }, - mounted(){ + mounted() { let intervalId = setInterval(() => { - this.loadData(); - }, 600*1000); // 1000姣锛屽嵆1绉� + this.loadData(); + }, 600 * 1000); // 1000姣锛屽嵆1绉� }, data() { return { @@ -534,6 +551,7 @@ title: '鍏抽敭璁惧', align: "center", dataIndex: 'specificEquipment', + width: 90, scopedSlots: { customRender: 'specificEquipment' } }, { @@ -545,8 +563,8 @@ title: '缁翠慨鐘舵��', align: "center", dataIndex: 'repairOrderUda1_dictText', - customRender:function (t,r,index) { - return t===null||r.repairOrderUda1===null?'/':t; + customRender: function (t, r, index) { + return t === null || r.repairOrderUda1 === null ? '/' : t; } }, { @@ -599,8 +617,8 @@ title: '缁翠慨鐝粍', align: "center", dataIndex: 'teamId_dictText', - scopedSlots: { - customRender: 'jell' + scopedSlots: { + customRender: 'jell' } }, { @@ -632,8 +650,8 @@ title: '鏁呴殰鎻忚堪', align: "center", dataIndex: 'faultDescription', - scopedSlots: { - customRender: 'jell' + scopedSlots: { + customRender: 'jell' } }, // { @@ -712,9 +730,10 @@ dataIndex: 'action', align: "center", fixed: "right", - width: 230, + width: 130, scopedSlots: { customRender: 'action' }, } + ], url: { list: "/eam/repairOrder/list", @@ -731,8 +750,8 @@ /* 鍒嗛〉鍙傛暟 */ ipagination: { current: 1, - pageSize: 5, - pageSizeOptions: ['5', '10', '50'], + pageSize: 20, + pageSizeOptions: ['5', '10', '20', '50'], showTotal: (total, range) => { return range[0] + "-" + range[1] + " 鍏�" + total + "鏉�" }, @@ -948,16 +967,16 @@ this.onClearSelected() this.$refs.FaultDescriptionList.faultId = '-1' }, - getReports(){ - this.$refs.FaultReportRepair.title = '鏁呴殰鎶ヤ慨鍗�'; - this.$refs.FaultReportRepair.loadData(); - this.$refs.FaultReportRepair.visible = true; + getReports() { + this.$refs.FaultReportRepair.title = '鏁呴殰鎶ヤ慨鍗�'; + this.$refs.FaultReportRepair.loadData(); + this.$refs.FaultReportRepair.visible = true; }, tableRowClass(record, index) { if ("2" === record.status) { - if (record.specificEquipment==='0'&&dayjs(record.faultTime).add(12,'hour')<dayjs()) { + if (record.specificEquipment === '0' && dayjs(record.faultTime).add(12, 'hour') < dayjs()) { return 'error' - } else if(dayjs(record.faultTime).add(7,'day')<dayjs()){ + } else if (dayjs(record.faultTime).add(7, 'day') < dayjs()) { return 'primary' } } diff --git a/src/views/eam/modules/malfunctionRepair/AcceptModel.vue b/src/views/eam/modules/malfunctionRepair/AcceptModel.vue index 03735f5..e9674f0 100644 --- a/src/views/eam/modules/malfunctionRepair/AcceptModel.vue +++ b/src/views/eam/modules/malfunctionRepair/AcceptModel.vue @@ -17,14 +17,14 @@ > <a-row :gutter="24"> <a-col :span='24'> - <a-form-model-item - label='楠屾敹浜�' - prop='errUda3' + <a-form-model-item + label='楠屾敹浜�' + prop='errUda3' :labelCol="labelCol" - :wrapperCol="wrapperCol"> - <a-input v-model='model.errUda3' - > - </a-input> + :wrapperCol="wrapperCol" + > + <a-input v-model='model.errUda3'> + </a-input> </a-form-model-item> </a-col> <a-col :span="24"> @@ -34,7 +34,11 @@ :wrapperCol="wrapperCol" prop="errUda5" > - <a-textarea v-model="model.errUda5" rows="4" placeholder="楠屾敹鎰忚" /> + <a-textarea + v-model="model.errUda5" + rows="4" + placeholder="楠屾敹鎰忚" + /> </a-form-model-item> </a-col> </a-row> @@ -72,28 +76,28 @@ data() { return { title: "鎿嶄綔", - width: 1500, + width: 650, visible: false, model: { }, labelCol: { - xs: { span: 24 }, - sm: { span: 5 }, + xs: { span: 24 }, + sm: { span: 5 }, }, - wrapperCol: { - xs: { span: 24 }, - sm: { span: 16 }, + wrapperCol: { + xs: { span: 24 }, + sm: { span: 16 }, }, confirmLoading: false, validatorRules: { errUda5: [ - {required:true,message:"璇疯緭鍏ラ獙鏀舵剰瑙�"}, + { required: true, message: "璇疯緭鍏ラ獙鏀舵剰瑙�" }, { min: 0, max: 100, message: '闀垮害涓嶈秴杩� 100 涓瓧绗�' }, ], - errUda3 :[ - {required:true,message:"璇疯緭鍏ュ悕绉�"}, - { min: 0, max: 10, message: '鍚嶇О涓嶈秴杩� 10 涓瓧绗�'}, + errUda3: [ + { required: true, message: "璇疯緭鍏ュ悕绉�" }, + { min: 0, max: 10, message: '鍚嶇О涓嶈秴杩� 10 涓瓧绗�' }, ], }, url: { diff --git a/src/views/eam/modules/malfunctionRepair/FaultDescriptionList.vue b/src/views/eam/modules/malfunctionRepair/FaultDescriptionList.vue index acacf9a..e4a8c99 100644 --- a/src/views/eam/modules/malfunctionRepair/FaultDescriptionList.vue +++ b/src/views/eam/modules/malfunctionRepair/FaultDescriptionList.vue @@ -72,7 +72,7 @@ url: { list: "/eam/faultDescription/list", }, - faultId: '', + faultId: '-1', faultDetails: '', photo: '' } @@ -82,7 +82,8 @@ computed: { }, methods: { - loadData(arg) { + loadData() { }, + loadData1(arg) { if (!this.url.list) { this.$message.error('璇疯缃畊rl.list灞炴��!') return @@ -95,7 +96,7 @@ this.loading = true getAction(this.url.list, params) .then(res => { - if (res.success&&res.result!==null) { + if (res.success && res.result !== null) { //update-begin---author:zhangyafei Date:20201118 for锛氶�傞厤涓嶅垎椤电殑鏁版嵁鍒楄〃------------ this.dataSource = res.result.records if (this.dataSource != null && this.dataSource != "") { @@ -125,7 +126,7 @@ faultId() { this.queryParam = {}; this.queryParam.faultId = this.faultId; - this.loadData(1); + this.loadData1(1); }, } } diff --git a/src/views/eam/modules/malfunctionRepair/MalfunctionRepaireModal.vue b/src/views/eam/modules/malfunctionRepair/MalfunctionRepaireModal.vue index 99252ff..d5b36ae 100644 --- a/src/views/eam/modules/malfunctionRepair/MalfunctionRepaireModal.vue +++ b/src/views/eam/modules/malfunctionRepair/MalfunctionRepaireModal.vue @@ -49,7 +49,7 @@ :labelCol="labelCol" :wrapperCol="wrapperCol" > - <a-input + <a-input v-decorator="['errUda2', validatorRules.errUda2]" placeholder="璇疯緭鍏ユ姤淇汉" ></a-input> @@ -134,36 +134,36 @@ </a-form-item> </a-col> </a-row> - <a-row - hidden - :gutter="24" - > - <a-col :span="12"> - <a-form-item - label="璁惧Id" - :labelCol="labelCol" - :wrapperCol="wrapperCol" - > - <a-input - :disabled="true" - :placeholder="disableSubmit?'':'璇疯緭鍏ョ粺涓�缂栧彿/鍚嶇О/鍨嬪彿'" - v-decorator="['equipmentId', validatorRules.equipmentId ]" - /> - </a-form-item> - </a-col> - <a-col :span="12"> - <a-form-item - label="浣跨敤閮ㄩ棬Id" - :labelCol="labelCol" - :wrapperCol="wrapperCol" - > - <a-input - :disabled="true" - :placeholder="disableSubmit?'':'璇疯緭鍏ヤ娇鐢ㄩ儴闂╥d'" - v-decorator="['useDepartId', validatorRules.useDepartId ]" - /> - </a-form-item> - </a-col> + <a-row + hidden + :gutter="24" + > + <a-col :span="12"> + <a-form-item + label="璁惧Id" + :labelCol="labelCol" + :wrapperCol="wrapperCol" + > + <a-input + :disabled="true" + :placeholder="disableSubmit?'':'璇疯緭鍏ョ粺涓�缂栧彿/鍚嶇О/鍨嬪彿'" + v-decorator="['equipmentId', validatorRules.equipmentId ]" + /> + </a-form-item> + </a-col> + <a-col :span="12"> + <a-form-item + label="浣跨敤閮ㄩ棬Id" + :labelCol="labelCol" + :wrapperCol="wrapperCol" + > + <a-input + :disabled="true" + :placeholder="disableSubmit?'':'璇疯緭鍏ヤ娇鐢ㄩ儴闂╥d'" + v-decorator="['useDepartId', validatorRules.useDepartId ]" + /> + </a-form-item> + </a-col> </a-row> <a-row :gutter="24"> <a-col :span="24/2"> @@ -184,6 +184,21 @@ :disabled="true" :placeholder="disableSubmit?'':'璇疯緭鍏ヤ娇鐢ㄩ儴闂�'" v-decorator="['departName', validatorRules.departName ]" + /> + </a-form-item> + </a-col> + <a-col :span="24/2"> + <a-form-item + label="鎶ヤ慨绫诲瀷" + :labelCol="labelCol" + :wrapperCol="wrapperCol" + > + <j-dict-select-tag + allow-clear + :placeholder="disableSubmit?'':'璇烽�夋嫨鎶ヤ慨绫诲瀷'" + :triggerChange="true" + dictCode="report_repair_type" + v-decorator="['type', validatorRules.type]" /> </a-form-item> </a-col> @@ -221,7 +236,7 @@ </a-col> </a-row> <a-row :gutter="24"> - <a-col :span="24/2"> + <a-col :span="24/2"> <a-form-item label="鏄惁鍦ㄥ姞宸ラ浂浠�" :labelCol="labelCol" @@ -237,7 +252,10 @@ /> </a-form-item> </a-col> - <a-col :span="24/2" v-if="workingStatus"> + <a-col + :span="24/2" + v-if="workingStatus" + > <a-form-item label="鍔犲伐闆朵欢鍙�" :labelCol="labelCol" @@ -252,7 +270,10 @@ </a-col> </a-row> <a-row :gutter="24"> - <a-col :span="24/2" v-if="workingStatus"> + <a-col + :span="24/2" + v-if="workingStatus" + > <a-form-item label="鎵规鍙�" :labelCol="labelCol" @@ -265,7 +286,10 @@ /> </a-form-item> </a-col> - <a-col :span="24/2" v-if="workingStatus"> + <a-col + :span="24/2" + v-if="workingStatus" + > <a-form-item label="浠舵暟" :labelCol="labelCol" @@ -368,13 +392,13 @@ { required: true, message: '璇烽�夋嫨鏁呴殰鏃堕棿!' }, ] }, - faultDescription:{ + faultDescription: { rules: [ { required: true, message: '璇锋弿杩版晠闅�!' }, - { max: 1000, min:1,message: '鏈�澶氬彲鎻忚堪1000瀛�!' }, + { max: 1000, min: 1, message: '鏈�澶氬彲鎻忚堪1000瀛�!' }, ] }, - errUda1:{ + errUda1: { rules: [ { required: true, message: '璇烽�夋嫨鏄惁鍦ㄥ姞宸ラ浂浠�!' }, ] @@ -382,33 +406,38 @@ errUda2: { rules: [ { required: true, message: '璇疯緭鍏ユ姤淇汉!' }, - { min:1,max:10, message: '闀垮害涓嶈兘澶т簬10涓瓧绗�!' }, + { min: 1, max: 10, message: '闀垮害涓嶈兘澶т簬10涓瓧绗�!' }, ] }, - partNumber:{ + partNumber: { rules: [ { required: true, message: '璇疯緭鍏ラ浂浠跺浘鍙�!' }, ] }, - batchNo:{ + batchNo: { rules: [ { required: true, message: '璇疯緭鍏ユ壒娆″彿!' }, ] }, - quantity:{ + quantity: { rules: [ { required: true, message: '璇疯緭鍏ヤ欢鏁�!' }, ] - } + }, + type: { + rules: [ + { required: true, message: '璇烽�夋嫨鎶ヤ慨绫诲瀷!' }, + ] + }, }, url: { add: "/eam/equipmentReportRepair/add", edit: "/eam/equipmentReportRepair/edit", getSysDeparts: "/eam/equipment/getSysDeparts", - getNum:'/eam/sysIdentity/getNumNew' + getNum: '/eam/sysIdentity/getNumNew' }, dataSource: [], - workingStatus:false + workingStatus: false } }, @@ -419,19 +448,22 @@ methods: { add() { let that = this; + let param = { - type: 'EquipmentReportRepair', - length: 4 + type: 'EquipmentReportRepair', + length: 4 }; let modelDefault = {}; - getAction(this.url.getNum,param).then(res=>{ - if(res.success){ - modelDefault.num = res.result; - this.workingStatus = false; - modelDefault.faultTime = dayjs(new Date()).format('YYYY-MM-DD HH:mm:ss'); - that.edit(modelDefault); - } + getAction(this.url.getNum, param).then(res => { + if (res.success) { + modelDefault.num = res.result; + this.workingStatus = false; + modelDefault.faultTime = dayjs(new Date()).format('YYYY-MM-DD HH:mm:ss'); + that.edit(modelDefault); + } }) + + }, edit(record) { let that = this; @@ -440,7 +472,8 @@ that.model = Object.assign({}, record); that.visible = true; that.$nextTick(() => { - that.form.setFieldsValue(pick(that.model,'errUda1' ,'num', 'isStop', 'equipmentId', 'equipmentNum', 'equipmentName', 'equipmentModel', 'equipmentSpecification', 'urgency', 'useDepartId', 'departName', 'faultDescription', 'faultTime', 'remark', "photo")); + that.form.setFieldsValue(pick(that.model, 'errUda1', 'num', 'isStop', 'equipmentId', 'equipmentNum', 'equipmentName', 'equipmentModel', 'equipmentSpecification', 'urgency', 'useDepartId', 'departName', 'faultDescription', 'faultTime', 'remark', "photo")); + that.form.setFieldsValue({ type: "1" }); }); if (record.id) { this.codeDisable = true; @@ -501,8 +534,8 @@ let record = data.record; this.form.setFieldsValue({ equipmentName: record.name, equipmentId: record.id, equipmentNum: record.num, equipmentModel: record.model, equipmentSpecification: record.specification, useDepartId: record.useId, departName: record.useId_dictText }); }, - statusChange(val){ - this.workingStatus=val==='no'?false:true; + statusChange(val) { + this.workingStatus = val === 'no' ? false : true; } }, } diff --git a/src/views/eam/modules/operationCertificate/OperationCertificateDetailList.vue b/src/views/eam/modules/operationCertificate/OperationCertificateDetailList.vue index 31ecb2b..a68b504 100644 --- a/src/views/eam/modules/operationCertificate/OperationCertificateDetailList.vue +++ b/src/views/eam/modules/operationCertificate/OperationCertificateDetailList.vue @@ -1,8 +1,14 @@ <template> - <a-card :bordered="false" :class="'cust-erp-sub-tab'"> + <a-card + :bordered="false" + :class="'cust-erp-sub-tab'" + > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> - <a-form layout="inline" @keyup.enter.native="searchQuery"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > <a-row :gutter="24"> </a-row> </a-form> @@ -10,32 +16,35 @@ <!-- 鏌ヨ鍖哄煙-END --> <!-- 鎿嶄綔鎸夐挳鍖哄煙 --> - <div class="table-operator" v-if="mainId"> -<!-- <a-button @click="handleAdd" type="primary" icon="plus">鏂板</a-button>--> -<!-- <a-button type="primary" icon="download" @click="handleExportXls('鎿嶄綔璇佺鐞嗘槑缁�')">瀵煎嚭</a-button>--> -<!-- <a-upload--> -<!-- name="file"--> -<!-- :showUploadList="false"--> -<!-- :multiple="false"--> -<!-- :headers="tokenHeader"--> -<!-- :action="importExcelUrl"--> -<!-- @change="handleImportExcel">--> -<!-- <a-button type="primary" icon="import">瀵煎叆</a-button>--> -<!-- </a-upload>--> -<!-- <a-dropdown v-if="selectedRowKeys.length > 0">--> -<!-- <a-menu slot="overlay">--> -<!-- <a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>鍒犻櫎</a-menu-item>--> -<!-- </a-menu>--> -<!-- <a-button style="margin-left: 8px"> 鎵归噺鎿嶄綔 <a-icon type="down" /></a-button>--> -<!-- </a-dropdown>--> + <div + class="table-operator" + v-if="mainId" + > + <!-- <a-button @click="handleAdd" type="primary" icon="plus">鏂板</a-button>--> + <!-- <a-button type="primary" icon="download" @click="handleExportXls('鎿嶄綔璇佺鐞嗘槑缁�')">瀵煎嚭</a-button>--> + <!-- <a-upload--> + <!-- name="file"--> + <!-- :showUploadList="false"--> + <!-- :multiple="false"--> + <!-- :headers="tokenHeader"--> + <!-- :action="importExcelUrl"--> + <!-- @change="handleImportExcel">--> + <!-- <a-button type="primary" icon="import">瀵煎叆</a-button>--> + <!-- </a-upload>--> + <!-- <a-dropdown v-if="selectedRowKeys.length > 0">--> + <!-- <a-menu slot="overlay">--> + <!-- <a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>鍒犻櫎</a-menu-item>--> + <!-- </a-menu>--> + <!-- <a-button style="margin-left: 8px"> 鎵归噺鎿嶄綔 <a-icon type="down" /></a-button>--> + <!-- </a-dropdown>--> </div> <!-- table鍖哄煙-begin --> <div> - <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> + <!-- <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� <a style="margin-left: 24px" @click="onClearSelected">娓呯┖</a> - </div> + </div> --> <a-table ref="table" @@ -47,33 +56,63 @@ :dataSource="dataSource" :pagination="ipagination" :loading="loading" - :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" - @change="handleTableChange"> + @change="handleTableChange" + > + <!-- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" --> - <template slot="htmlSlot" slot-scope="text"> + <template + slot="htmlSlot" + slot-scope="text" + > <div v-html="text"></div> </template> - <template slot="imgSlot" slot-scope="text,record"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犲浘鐗�</span> - <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> + <template + slot="imgSlot" + slot-scope="text,record" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犲浘鐗�</span> + <img + v-else + :src="getImgView(text)" + :preview="record.id" + height="25px" + alt="" + style="max-width:80px;font-size: 12px;font-style: italic;" + /> </template> - <template slot="fileSlot" slot-scope="text"> - <span v-if="!text" style="font-size: 12px;font-style: italic;">鏃犳枃浠�</span> + <template + slot="fileSlot" + slot-scope="text" + > + <span + v-if="!text" + style="font-size: 12px;font-style: italic;" + >鏃犳枃浠�</span> <a-button v-else :ghost="true" type="primary" icon="download" size="small" - @click="downloadFile(text)"> + @click="downloadFile(text)" + > 涓嬭浇 </a-button> </template> - <span slot="action" slot-scope="text, record"> + <span + slot="action" + slot-scope="text, record" + > <a @click="handleEdit(record)">缂栬緫</a> <a-divider type="vertical" /> - <a-popconfirm title="纭畾鍒犻櫎鍚�?" @confirm="() => handleDelete(record.id)"> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + > <a>鍒犻櫎</a> </a-popconfirm> </span> @@ -81,7 +120,11 @@ </a-table> </div> - <operationCertificateDetail-modal ref="modalForm" @ok="modalFormOk" :mainId="mainId"></operationCertificateDetail-modal> + <operationCertificateDetail-modal + ref="modalForm" + @ok="modalFormOk" + :mainId="mainId" + ></operationCertificateDetail-modal> </a-card> </template> @@ -92,42 +135,42 @@ export default { name: "OperationCertificateDetailList", - mixins:[JeecgListMixin], + mixins: [JeecgListMixin], components: { OperationCertificateDetailModal }, - props:{ - mainId:{ - type:String, - default:'', - required:false + props: { + mainId: { + type: String, + default: '', + required: false } }, - watch:{ - mainId:{ + watch: { + mainId: { immediate: true, handler(val) { - if(!this.mainId){ + if (!this.mainId) { this.clearList() - }else{ + } else { this.queryParam['operationCertificateId'] = val this.loadData(1); } } } }, - data () { + data() { return { description: '鎿嶄綔璇佷功绠$悊绠$悊椤甸潰', - disableMixinCreated:true, + disableMixinCreated: true, // 琛ㄥご columns: [ { title: '#', dataIndex: '', - key:'rowIndex', - width:60, - align:"center", - customRender:function (t,r,index) { - return parseInt(index)+1; + key: 'rowIndex', + width: 60, + align: "center", + customRender: function (t, r, index) { + return parseInt(index) + 1; } }, // { @@ -136,26 +179,26 @@ // dataIndex: 'operationCertificateId' // }, { - title:'鍙戠敓鏃堕棿', - align:"center", + title: '鍙戠敓鏃堕棿', + align: "center", dataIndex: 'happenDate', - customRender:function (text) { - return !text?"":(text.length>10?text.substr(0,10):text) + customRender: function (text) { + return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text) } }, { - title:'绫诲瀷', - align:"center", + title: '绫诲瀷', + align: "center", dataIndex: 'type_dictText' }, { - title:'璁惧缁熶竴缂栫爜', - align:"center", + title: '璁惧缁熶竴缂栫爜', + align: "center", dataIndex: 'equipmentId_dictText' }, { - title:'鎵e垎椤�', - align:"center", + title: '鎵e垎椤�', + align: "center", dataIndex: 'deductionItem_dictText' }, // { @@ -179,23 +222,23 @@ exportXlsUrl: "/eam/operationCertificate/exportOperationCertificateDetail", importUrl: "/eam/operationCertificate/importOperationCertificateDetail", }, - dictOptions:{ - equipmentIds:[], - status:[], + dictOptions: { + equipmentIds: [], + status: [], } } }, created() { }, computed: { - importExcelUrl(){ + importExcelUrl() { return `${window._CONFIG['domianURL']}/${this.url.importUrl}/${this.mainId}`; } }, methods: { - clearList(){ - this.dataSource=[] - this.selectedRowKeys=[] + clearList() { + this.dataSource = [] + this.selectedRowKeys = [] this.ipagination.current = 1 } @@ -203,5 +246,5 @@ } </script> <style scoped> -@import '~@assets/less/common.less' +@import '~@assets/less/common.less'; </style> -- Gitblit v1.9.3