¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <a-card :bordered="false"> |
| | | |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | | <a-row :gutter="24"> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="12"> |
| | | <a-form-item label="ç»ä¸ç¼ç "> |
| | | <lx-search-equipment-select placeholder="请è¾å
¥ç»ä¸ç¼ç æåç§°æç´¢" v-model="queryParam.equipmentId"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="12"> |
| | | <a-form-item label="ç»è®°ç¶æ"> |
| | | <j-dict-select-tag placeholder="è¯·éæ©ç»è®°ç¶æ" v-model="queryParam.registerStatus" |
| | | dict-code="eam_report_accidents_register_status"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="12"> |
| | | <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> |
| | | <a-button type="primary" @click="searchQuery" icon="search">æ¥è¯¢</a-button> |
| | | <a-button type="info" @click="searchReset" icon="reload" style="margin-left: 8px">éç½®</a-button> |
| | | </span> |
| | | </a-col> |
| | | </a-row> |
| | | </a-form> |
| | | </div> |
| | | |
| | | <!-- tableåºå-begin --> |
| | | <a-table ref="table" size="middle" bordered rowKey="id" :columns="columns" :dataSource="dataSource" |
| | | :pagination="ipagination" :loading="loading" :scroll="{x:'max-content'}" @change="handleTableChange"> |
| | | |
| | | <!--æ¯å¦æè®¾å¤æä½è¯--> |
| | | <template slot="operationCertificate" slot-scope="text"> |
| | | <a-switch checked-children="æ¯" un-checked-children="å¦" :checked="Boolean(+text)" disabled/> |
| | | </template> |
| | | |
| | | <!--æ¯å¦æçµéå¯--> |
| | | <template slot="powerOffRestart" slot-scope="text"> |
| | | <a-switch checked-children="æ¯" un-checked-children="å¦" :checked="Boolean(+text)" disabled/> |
| | | </template> |
| | | |
| | | <!--æ¯å¦ä¸ºæ¹æ¬¡é¦ä»¶--> |
| | | <template slot="batchFirstPiece" slot-scope="text"> |
| | | <a-switch checked-children="æ¯" un-checked-children="å¦" :checked="Boolean(+text)" disabled/> |
| | | </template> |
| | | |
| | | <!--åå¨å ç´ --> |
| | | <template slot="variableFactors" slot-scope="text"> |
| | | <a-switch checked-children="æ¯" un-checked-children="å¦" :checked="Boolean(+text)" disabled/> |
| | | </template> |
| | | |
| | | <!--åå åææ ¸å¯¹--> |
| | | <template slot="checkAgree" slot-scope="text"> |
| | | <a-switch v-if="text" checked-children="åæ" un-checked-children="ä¸åæ" :checked="Boolean(text)" disabled/> |
| | | </template> |
| | | |
| | | <span slot="action" slot-scope="text, record"> |
| | | <template v-if="record.registerStatus==='PENDING_SUBMIT'"> |
| | | <a @click="handleEdit(record)">ç¼è¾</a> |
| | | <a-divider type="vertical"/> |
| | | <a-popconfirm title="ç¡®å®æäº¤å?" @confirm="() => handleSubmit(record.id)"> |
| | | <a>æäº¤</a> |
| | | </a-popconfirm> |
| | | </template> |
| | | |
| | | <a v-else @click="handleDetail(record)">详æ
</a> |
| | | </span> |
| | | |
| | | </a-table> |
| | | <!-- tableåºå-end --> |
| | | |
| | | <!-- 表ååºå --> |
| | | <eamReportAccidentsRegister-modal ref="modalForm" @ok="modalFormOk"/> |
| | | |
| | | <!--审æ¹çªå£--> |
| | | <report-accidents-register-approval-modal ref="reportAccidentsRegisterApprovalModal" |
| | | :selectShenpiData="selectedRowData"/> |
| | | </a-card> |
| | | </template> |
| | | |
| | | <script> |
| | | import EamReportAccidentsRegisterModal from './modules/EamReportAccidentsRegisterModal' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import LxSearchEquipmentSelect from '../equipment/modules/LxSearchEquipmentSelect' |
| | | import { getAction } from '@/api/manage' |
| | | import ReportAccidentsRegisterApprovalModal |
| | | from '../../flowable/workflow/repairOrder/ReportAccidentsRegisterApprovalModal' |
| | | |
| | | export default { |
| | | name: 'EamReportAccidentsRegisterList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | ReportAccidentsRegisterApprovalModal, |
| | | LxSearchEquipmentSelect, |
| | | EamReportAccidentsRegisterModal |
| | | }, |
| | | data() { |
| | | return { |
| | | description: '设å¤äºæ
ç»è®°è¡¨ç®¡ç页é¢', |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 60, |
| | | align: 'center', |
| | | customRender: function(t, r, index) { |
| | | return parseInt(index) + 1 |
| | | }, |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: 'ç»ä¸ç¼ç ', |
| | | align: 'center', |
| | | dataIndex: 'equipmentCode', |
| | | fixed: 'left', |
| | | scopedSlots: { customRender: 'equipmentCode' } |
| | | }, |
| | | { |
| | | title: '设å¤åç§°', |
| | | align: 'center', |
| | | dataIndex: 'equipmentName', |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: '设å¤åå·', |
| | | align: 'center', |
| | | dataIndex: 'equipmentModel', |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: 'ç»è®°ç¶æ', |
| | | align: 'center', |
| | | dataIndex: 'registerStatus_dictText', |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: 'åºåä»¶å·', |
| | | align: 'center', |
| | | dataIndex: 'scrapPartNumber' |
| | | }, |
| | | { |
| | | title: 'åºåä»¶æ°', |
| | | align: 'center', |
| | | dataIndex: 'scrapPartQuantity' |
| | | }, |
| | | { |
| | | title: 'åºåä»·å¼', |
| | | align: 'center', |
| | | dataIndex: 'scrapPartValue' |
| | | }, |
| | | { |
| | | title: 'æ¯å¦æè®¾å¤æä½è¯', |
| | | align: 'center', |
| | | dataIndex: 'operationCertificate', |
| | | scopedSlots: { customRender: 'operationCertificate' } |
| | | }, |
| | | { |
| | | title: 'æ¯å¦æçµéå¯', |
| | | align: 'center', |
| | | dataIndex: 'powerOffRestart', |
| | | scopedSlots: { customRender: 'powerOffRestart' } |
| | | }, |
| | | { |
| | | title: 'æ¯å¦ä¸ºæ¹æ¬¡é¦ä»¶', |
| | | align: 'center', |
| | | dataIndex: 'batchFirstPiece', |
| | | scopedSlots: { customRender: 'batchFirstPiece' } |
| | | }, |
| | | { |
| | | title: 'åå¨å ç´ ', |
| | | align: 'center', |
| | | dataIndex: 'variableFactors', |
| | | scopedSlots: { customRender: 'variableFactors' } |
| | | }, |
| | | { |
| | | title: 'åå¨å ç´ å
容', |
| | | align: 'center', |
| | | dataIndex: 'variableFactorsValue_dictText' |
| | | }, |
| | | { |
| | | title: 'æ§è¡ç¨åº', |
| | | align: 'center', |
| | | dataIndex: 'executeNc' |
| | | }, |
| | | { |
| | | title: 'äºæ
ç°è±¡', |
| | | align: 'center', |
| | | dataIndex: 'accidentPhenomenon' |
| | | }, |
| | | { |
| | | title: 'éåæªæ½', |
| | | align: 'center', |
| | | dataIndex: 'measure' |
| | | }, |
| | | { |
| | | title: 'é æç»æ', |
| | | align: 'center', |
| | | dataIndex: 'causingResults' |
| | | }, |
| | | { |
| | | title: 'æä½å·¥', |
| | | align: 'center', |
| | | dataIndex: 'confirmer_dictText' |
| | | }, |
| | | { |
| | | title: 'æä½å·¥ç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'confirmTime' |
| | | }, |
| | | { |
| | | title: 'åºé¿', |
| | | align: 'center', |
| | | dataIndex: 'district_dictText' |
| | | }, |
| | | { |
| | | title: 'åºé¿ç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'districtTime' |
| | | }, |
| | | { |
| | | title: 'ä¸å¿ä¸»ä»»', |
| | | align: 'center', |
| | | dataIndex: 'centerDirector_dictText' |
| | | }, |
| | | { |
| | | title: 'ä¸å¿ä¸»ä»»ç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'centerDirectorTime' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®å¼å§æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'reportStartTime' |
| | | }, |
| | | { |
| | | title: '设å¤ç¶æ', |
| | | align: 'center', |
| | | dataIndex: 'equipmentStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'åå åæ', |
| | | align: 'center', |
| | | dataIndex: 'causeAnalysis' |
| | | }, |
| | | { |
| | | title: 'æ£æ¥ç»æ', |
| | | align: 'center', |
| | | dataIndex: 'inspectionResults_dictText' |
| | | }, |
| | | { |
| | | title: 'éåæªæ½', |
| | | align: 'center', |
| | | dataIndex: 'takeSteps' |
| | | }, |
| | | { |
| | | title: '建议éåæªæ½', |
| | | align: 'center', |
| | | dataIndex: 'suggestionTakeSteps' |
| | | }, |
| | | { |
| | | title: '建议éåæªæ½æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'suggestionTakeStepsTime' |
| | | }, |
| | | { |
| | | title: '维修确认', |
| | | align: 'center', |
| | | dataIndex: 'repairConfirm_dictText' |
| | | }, |
| | | { |
| | | title: '维修确认æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'repairConfirmTime' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»é¿ç¡®è®¤', |
| | | align: 'center', |
| | | dataIndex: 'repairGroupLeader_dictText' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»é¿ç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'repairGroupLeaderTime' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»é¿ç¡®è®¤', |
| | | align: 'center', |
| | | dataIndex: 'repairDistrict_dictText' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»é¿ç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'repairDistrictTime' |
| | | }, |
| | | { |
| | | title: 'åå åææ ¸å¯¹', |
| | | align: 'center', |
| | | dataIndex: 'checkAgree', |
| | | scopedSlots: { customRender: 'checkAgree' } |
| | | }, |
| | | { |
| | | title: 'ä¸åæåå åæ', |
| | | align: 'center', |
| | | dataIndex: 'disagreeReason' |
| | | }, |
| | | { |
| | | title: 'æ´æ¹æªæ½', |
| | | align: 'center', |
| | | dataIndex: 'rectificationMeasures' |
| | | }, |
| | | { |
| | | title: 'äºæ
ç»è®º', |
| | | align: 'center', |
| | | dataIndex: 'accidentConclusion' |
| | | }, |
| | | { |
| | | title: 'ææ¯è´è´£äºº', |
| | | align: 'center', |
| | | dataIndex: 'technicalDirector_dictText' |
| | | }, |
| | | { |
| | | title: 'ææ¯è´è´£äººç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'technicalDirectorTime' |
| | | }, |
| | | { |
| | | title: 'ææ¯ä¸»ç®¡å®¤çº§é¢å¯¼', |
| | | align: 'center', |
| | | dataIndex: 'technicalDirectorLeader_dictText' |
| | | }, |
| | | { |
| | | title: 'ææ¯ä¸»ç®¡å®¤çº§é¢å¯¼ç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'technicalDirectorLeaderTime' |
| | | }, |
| | | { |
| | | title: '主管é¨çº§é¢å¯¼', |
| | | align: 'center', |
| | | dataIndex: 'technicalDirectorPart_dictText' |
| | | }, |
| | | { |
| | | title: '主管é¨çº§é¢å¯¼ç¡®è®¤æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'technicalDirectorPartTime' |
| | | }, |
| | | { |
| | | title: 'æä½', |
| | | dataIndex: 'action', |
| | | align: 'center', |
| | | scopedSlots: { customRender: 'action' }, |
| | | width: 200, |
| | | fixed: 'right' |
| | | } |
| | | ], |
| | | selectedRowData: {}, |
| | | url: { |
| | | list: '/eam/eamReportAccidentsRegister/list', |
| | | submit: '/eam/eamReportAccidentsRegister/submit', |
| | | delete: '/eam/eamReportAccidentsRegister/delete' |
| | | } |
| | | } |
| | | }, |
| | | methods: { |
| | | /** |
| | | * ç¹å»æäº¤æ¶è§¦å |
| | | * @param id |
| | | */ |
| | | handleSubmit(id) { |
| | | this.loading = true |
| | | getAction(this.url.submit, { id }) |
| | | .then(res => { |
| | | if (res.success) { |
| | | this.$notification.success({ |
| | | message: 'æ¶æ¯', |
| | | description: res.message |
| | | }) |
| | | this.loadData() |
| | | } else { |
| | | this.$notification.warning({ |
| | | message: 'æ¶æ¯', |
| | | description: res.message |
| | | }) |
| | | this.loading = false |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | /** |
| | | * ç¹å»è¯¦æ
æ¶è§¦åæ¶è§¦å |
| | | * @param record |
| | | */ |
| | | handleDetail(record) { |
| | | this.selectedRowData = Object.assign({}, record) |
| | | this.$refs.reportAccidentsRegisterApprovalModal.title = '详æ
' |
| | | this.$refs.reportAccidentsRegisterApprovalModal.disableSubmit = true |
| | | this.$refs.reportAccidentsRegisterApprovalModal.visible = true |
| | | this.$refs.reportAccidentsRegisterApprovalModal.handleDetail(record) |
| | | } |
| | | } |
| | | } |
| | | </script> |