| | |
| | | :md='8' |
| | | :sm='6' |
| | | > |
| | | <a-form-item label='点检项目名称'> |
| | | <a-input |
| | | placeholder='请输入点检项目名称' |
| | | v-model='queryParam.num' |
| | | <a-form-item label='点检项目'> |
| | | <j-input |
| | | placeholder='请输入点检项目' |
| | | v-model='queryParam.name' |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | |
| | | :columns='columns' |
| | | :dataSource='dataSource' |
| | | :pagination='ipagination' |
| | | :rowSelection='rowSelection' |
| | | :loading='loading' |
| | | @change='handleTableChange' |
| | | :rowSelection='rowSelection' |
| | | > |
| | | |
| | | </a-table> |
| | |
| | | align: 'center', |
| | | dataIndex: 'detectionStandard' |
| | | }, |
| | | { |
| | | title: '合格范围', |
| | | align: 'center', |
| | | dataIndex: 'acceptabilityLimit' |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: 'center', |
| | | dataIndex: 'inspectionMethod_dictText' |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: 'center', |
| | | dataIndex: 'inspectionTool' |
| | | }, |
| | | // { |
| | | // title: '合格范围', |
| | | // align: 'center', |
| | | // dataIndex: 'acceptabilityLimit' |
| | | // }, |
| | | // { |
| | | // title: '方法', |
| | | // align: 'center', |
| | | // dataIndex: 'inspectionMethod_dictText' |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: 'center', |
| | | // dataIndex: 'inspectionTool' |
| | | // }, |
| | | // { |
| | | // title: '周期', |
| | | // align: 'center', |
| | |
| | | |
| | | ], |
| | | selectedRowKeys: [], |
| | | selectedRows: [], |
| | | selectionRowsNotClear: [], |
| | | oldSelectRows: [], |
| | | scrollTrigger: {}, |
| | | dataSource: [], |
| | |
| | | this.selectedRowKeys = selectedRowKeys |
| | | this.onSelectChange(selectedRows) |
| | | }, |
| | | onSelect: (record, selected, selectedRows) => { |
| | | if (selected) { |
| | | this.selectionRowsNotClear.push(record); |
| | | } |
| | | if (!selected) { |
| | | let delIndex = this.selectionRowsNotClear.findIndex(val => { |
| | | return val.id === record.id |
| | | }) |
| | | this.selectionRowsNotClear.splice(delIndex, 1); |
| | | } |
| | | }, |
| | | getCheckboxProps: record => ({ |
| | | props: { |
| | | disabled: record.distable |
| | | } |
| | | }), |
| | | selectedRowKeys: this.selectedRowKeys |
| | | selectedRowKeys: this.selectedRowKeys, |
| | | } |
| | | } |
| | | }, |
| | | |
| | | methods: { |
| | | |
| | | async loadData(arg) { |
| | | if (arg === 1) { |
| | | this.ipagination.current = 1 |
| | |
| | | |
| | | showModals(oldSelectRows) { |
| | | this.selectionRows = [] |
| | | this.selectedRowKeys = [] |
| | | this.selectionRowsNotClear = [] |
| | | this.oldSelectRows = oldSelectRows |
| | | this.visible = true |
| | | this.loadData(1) |
| | |
| | | if (num !== 0) { |
| | | that.loadData(1) |
| | | } |
| | | that.selectborrowIds = [] |
| | | }, |
| | | close() { |
| | | this.searchReset(0) |
| | |
| | | }, |
| | | handleTableChange(pagination, filters, sorter) { |
| | | //TODO 筛选 |
| | | |
| | | if (Object.keys(sorter).length > 0) { |
| | | this.isorter.column = sorter.field |
| | | this.isorter.order = 'ascend' === sorter.order ? 'asc' : 'desc' |
| | | } |
| | | this.ipagination = pagination |
| | | |
| | | this.loadData() |
| | | }, |
| | | handleSubmit() { |
| | | // this.$bus.$emit('selectionRows', this.selectionRowsNotClear) |
| | | this.$bus.$emit('selectionRows', this.selectionRows) |
| | | this.searchReset(0) |
| | | this.close() |
| | |
| | | onSelectChange(selectionRows) { |
| | | this.selectionRows = selectionRows |
| | | }, |
| | | // onSelectionChange(selectedRowKeys, selectedRows) { |
| | | // this.selectedRowKeys = selectedRowKeys; |
| | | // this.selectedRows = selectedRows; |
| | | // }, |
| | | |
| | | searchQuery() { |
| | | this.loadData(1) |
| | | } |