| | |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24" v-if="isDisplayOperation"> |
| | | <a-form-item label="单据状态"> |
| | | <a-select placeholder="请选择单据状态" v-model="queryParam.reportStatus" allow-clear> |
| | | <a-form-item label="报修状态"> |
| | | <a-select placeholder="请选择报修状态" v-model="queryParam.reportStatus" allow-clear> |
| | | <a-select-option v-for="item in report_repair_status_list" :key="item.value">{{ item.label }} |
| | | </a-select-option> |
| | | </a-select> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="故障简称"> |
| | | <!-- <a-select placeholder="请选择故障简称" v-model="queryParam.faultName" allow-clear>--> |
| | | <!-- <a-select-option v-for="item in faultReasonList" :key="item.faultName">--> |
| | | <!-- {{ item.faultName }}--> |
| | | <!-- </a-select-option>--> |
| | | <!-- </a-select>--> |
| | | <a-input placeholder="请输入故障简称" v-model="queryParam.faultName" allow-clear/> |
| | | <a-form-item label="故障描述"> |
| | | <a-input placeholder="请输入故障描述" v-model="queryParam.faultDescription" allow-clear/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <!-- <a-col :xl="6" :lg="7" :md="8" :sm="24">--> |
| | | <!-- <a-form-item label="故障分类">--> |
| | | <!-- <a-input placeholder="请输入故障分类" v-model="queryParam.faultType"></a-input>--> |
| | | <!-- </a-form-item>--> |
| | | <!-- </a-col>--> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="故障时间"> |
| | | <a-range-picker showTime v-model="faultTimeRange" value-format="YYYY-MM-DD HH:mm:ss" |
| | |
| | | <!-- 操作按钮区域 --> |
| | | <div class="table-operator" v-if="isDisplayOperation"> |
| | | <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 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"> |
| | |
| | | :pagination="ipagination" |
| | | :loading="loading" |
| | | class="j-table-force-nowrap" |
| | | :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange,type:isDisplayOperation?'checkbox':'radio'}" |
| | | :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange,type:isDisplayOperation?'checkbox':'radio',getCheckboxProps:getCheckboxProps}" |
| | | @change="handleTableChange"> |
| | | |
| | | <template slot="imageFiles" slot-scope="text, record" v-if="text"> |
| | |
| | | |
| | | <span slot="action" slot-scope="text, record" v-if="record.reportStatus=='WAIT_REPAIR'"> |
| | | <a @click="handleEdit(record)">编辑</a> |
| | | |
| | | <a-divider type="vertical"/> |
| | | |
| | | <a @click="handleAssign(record)">指派</a> |
| | | |
| | | <a-divider type="vertical"/> |
| | | |
| | |
| | | @ok="modalFormOk"/> |
| | | <!-- 图片预览弹窗 --> |
| | | <images-preview-modal ref="imagesPreviewModalRef" :imageListUrl="currentImageListUrl"/> |
| | | <!--指派报修弹窗--> |
| | | <assign-repair-report-modal ref="assignRepairReportModalRef" @ok="modalFormOk"/> |
| | | </a-card> |
| | | </template> |
| | | |
| | |
| | | import { ajaxGetDictItems, getDictItemsFromCache } from '@/api/api' |
| | | import ImagesPreviewModal from '@views/eam/repair/modules/ImagesPreviewModal.vue' |
| | | import { getAction } from '@/api/manage' |
| | | import AssignRepairReportModal from './modules/EamReportRepairList/AssignRepairReportModal' |
| | | |
| | | |
| | | export default { |
| | | name: 'EamReportRepairList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | AssignRepairReportModal, |
| | | ImagesPreviewModal, |
| | | LxSearchEquipmentSelect, |
| | | EamReportRepairModal |
| | |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: '状态', |
| | | title: '报修状态', |
| | | align: 'center', |
| | | dataIndex: 'reportStatus_dictText', |
| | | width: 100 |
| | |
| | | created() { |
| | | this.initDictData('breakdown_flag') |
| | | this.initDictData('report_repair_status') |
| | | this.getFaultReasonListByApi() |
| | | if (!this.isDisplayOperation) this.queryParam = Object.assign({} ,this.propsQueryParam) |
| | | if (!this.isDisplayOperation) this.queryParam = Object.assign({}, this.propsQueryParam) |
| | | else { |
| | | const operationColumn = { |
| | | title: '操作', |
| | | dataIndex: 'action', |
| | | align: 'center', |
| | | scopedSlots: { customRender: 'action' }, |
| | | width: 150 |
| | | width: 200 |
| | | } |
| | | this.columns = [...this.columns, operationColumn] |
| | | this.getFaultReasonListByApi() |
| | | } |
| | | this.loadData(1) |
| | | }, |
| | |
| | | this.$refs.imagesPreviewModalRef.visible = true |
| | | }, |
| | | |
| | | /** |
| | | * 指派报修单 |
| | | * @param record 表格行信息 |
| | | */ |
| | | handleAssign(record) { |
| | | this.$refs.assignRepairReportModalRef.visible = true |
| | | this.$refs.assignRepairReportModalRef.model = Object.assign({}, { id: record.id }) |
| | | }, |
| | | |
| | | getCheckboxProps(record) { |
| | | return { |
| | | props: { |
| | | disabled: record.reportStatus !== 'WAIT_REPAIR' |
| | | } |
| | | } |
| | | }, |
| | | |
| | | searchReset() { |
| | | if (this.isDisplayOperation) this.queryParam = {} |
| | | else this.queryParam = Object.assign({}, this.propsQueryParam) |