|
@@ -3,17 +3,17 @@
|
|
<div class="table-page-search-wrapper">
|
|
<div class="table-page-search-wrapper">
|
|
<a-form layout="inline">
|
|
<a-form layout="inline">
|
|
<a-row :gutter="48">
|
|
<a-row :gutter="48">
|
|
- <a-col :md="8" :sm="24">
|
|
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
<a-form-item label="计划名称">
|
|
<a-form-item label="计划名称">
|
|
<a-input v-model="queryParam.planName" placeholder="请输入计划名称" />
|
|
<a-input v-model="queryParam.planName" placeholder="请输入计划名称" />
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
- <a-col :md="8" :sm="24">
|
|
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
<a-form-item label="负责人">
|
|
<a-form-item label="负责人">
|
|
<a-input v-model.trim="queryParam.keyword" placeholder="请输入负责人" />
|
|
<a-input v-model.trim="queryParam.keyword" placeholder="请输入负责人" />
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
- <a-col :md="8" :sm="24">
|
|
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
<a-form-item label="任务状态">
|
|
<a-form-item label="任务状态">
|
|
<a-select v-model="queryParam.status" placeholder="请选择">
|
|
<a-select v-model="queryParam.status" placeholder="请选择">
|
|
<a-select-option v-for="(label,value) in statusMap" :key="value" :label="label" :value="parseInt(value)">{{ label }}
|
|
<a-select-option v-for="(label,value) in statusMap" :key="value" :label="label" :value="parseInt(value)">{{ label }}
|
|
@@ -21,7 +21,7 @@
|
|
</a-select>
|
|
</a-select>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
- <a-col :md="8 || 24" :sm="24">
|
|
|
|
|
|
+ <a-col :md="6 || 24" :sm="24">
|
|
<span class="table-page-search-submitButtons">
|
|
<span class="table-page-search-submitButtons">
|
|
<a-button type="primary" @click="$refs.table.refresh(true)">查询</a-button>
|
|
<a-button type="primary" @click="$refs.table.refresh(true)">查询</a-button>
|
|
<a-button style="margin-left: 8px" @click="resetSearchForm">重置</a-button>
|
|
<a-button style="margin-left: 8px" @click="resetSearchForm">重置</a-button>
|
|
@@ -46,7 +46,15 @@
|
|
</a-dropdown>
|
|
</a-dropdown>
|
|
</div>-->
|
|
</div>-->
|
|
|
|
|
|
- <s-table ref="table" size="default" rowKey="id" :columns="columns" :data="loadData" :alert="options.alert" :rowSelection="options.rowSelection" showPagination="auto">
|
|
|
|
|
|
+ <s-table
|
|
|
|
+ ref="table"
|
|
|
|
+ size="default"
|
|
|
|
+ rowKey="id"
|
|
|
|
+ :columns="columns"
|
|
|
|
+ :data="loadData"
|
|
|
|
+ :alert="options.alert"
|
|
|
|
+ :rowSelection="options.rowSelection"
|
|
|
|
+ showPagination="auto">
|
|
<span slot="action" slot-scope="record">
|
|
<span slot="action" slot-scope="record">
|
|
<template>
|
|
<template>
|
|
<a @click="handleView(record)">查看</a>
|
|
<a @click="handleView(record)">查看</a>
|
|
@@ -82,7 +90,7 @@ export default {
|
|
STable,
|
|
STable,
|
|
Ellipsis,
|
|
Ellipsis,
|
|
BaseForm,
|
|
BaseForm,
|
|
- Detail,
|
|
|
|
|
|
+ Detail
|
|
},
|
|
},
|
|
props: {
|
|
props: {
|
|
/**
|
|
/**
|
|
@@ -90,20 +98,20 @@ export default {
|
|
*/
|
|
*/
|
|
checkType: {
|
|
checkType: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: 1,
|
|
|
|
|
|
+ default: 1
|
|
},
|
|
},
|
|
filter: {
|
|
filter: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: -1,
|
|
|
|
- },
|
|
|
|
|
|
+ default: -1
|
|
|
|
+ }
|
|
},
|
|
},
|
|
- data() {
|
|
|
|
|
|
+ data () {
|
|
this.names = ['负责', '巡检']
|
|
this.names = ['负责', '巡检']
|
|
return {
|
|
return {
|
|
// 查询参数
|
|
// 查询参数
|
|
queryParam: {
|
|
queryParam: {
|
|
type: this.checkType,
|
|
type: this.checkType,
|
|
- filter: this.filter,
|
|
|
|
|
|
+ filter: this.filter
|
|
},
|
|
},
|
|
// 表头
|
|
// 表头
|
|
columns: [
|
|
columns: [
|
|
@@ -114,27 +122,27 @@ export default {
|
|
return `${
|
|
return `${
|
|
(this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1
|
|
(this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1
|
|
}`
|
|
}`
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '计划名称',
|
|
title: '计划名称',
|
|
- dataIndex: 'planName',
|
|
|
|
|
|
+ dataIndex: 'planName'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '仓库名称',
|
|
title: '仓库名称',
|
|
- dataIndex: 'storeName',
|
|
|
|
|
|
+ dataIndex: 'storeName'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '备件名称',
|
|
title: '备件名称',
|
|
- dataIndex: 'spareName',
|
|
|
|
|
|
+ dataIndex: 'spareName'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '待盘数量',
|
|
title: '待盘数量',
|
|
- dataIndex: 'checkNum',
|
|
|
|
|
|
+ dataIndex: 'checkNum'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '实际数量',
|
|
title: '实际数量',
|
|
- dataIndex: 'realNum',
|
|
|
|
|
|
+ dataIndex: 'realNum'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '盘盈盘亏',
|
|
title: '盘盈盘亏',
|
|
@@ -149,36 +157,36 @@ export default {
|
|
if (text === 2) {
|
|
if (text === 2) {
|
|
return '盘盈'
|
|
return '盘盈'
|
|
}
|
|
}
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '说明',
|
|
title: '说明',
|
|
- dataIndex: 'remark',
|
|
|
|
|
|
+ dataIndex: 'remark'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '处理结果',
|
|
title: '处理结果',
|
|
- dataIndex: 'feedback',
|
|
|
|
|
|
+ dataIndex: 'feedback'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '开始时间',
|
|
title: '开始时间',
|
|
- dataIndex: 'startTime',
|
|
|
|
|
|
+ dataIndex: 'startTime'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '结束时间',
|
|
title: '结束时间',
|
|
- dataIndex: 'endTime',
|
|
|
|
|
|
+ dataIndex: 'endTime'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '任务状态',
|
|
title: '任务状态',
|
|
dataIndex: 'status',
|
|
dataIndex: 'status',
|
|
- scopedSlots: { customRender: 'status' },
|
|
|
|
|
|
+ scopedSlots: { customRender: 'status' }
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '操作',
|
|
title: '操作',
|
|
key: 'action',
|
|
key: 'action',
|
|
width: '200px',
|
|
width: '200px',
|
|
align: 'center',
|
|
align: 'center',
|
|
- scopedSlots: { customRender: 'action' },
|
|
|
|
- },
|
|
|
|
|
|
+ scopedSlots: { customRender: 'action' }
|
|
|
|
+ }
|
|
],
|
|
],
|
|
// 下拉框map
|
|
// 下拉框map
|
|
statusMap: {},
|
|
statusMap: {},
|
|
@@ -188,7 +196,7 @@ export default {
|
|
parameter = {
|
|
parameter = {
|
|
...parameter,
|
|
...parameter,
|
|
...this.queryParam,
|
|
...this.queryParam,
|
|
- dataScope: {},
|
|
|
|
|
|
+ dataScope: {}
|
|
}
|
|
}
|
|
return getCheckJobPage(Object.assign(parameter, this.queryParam)).then((res) => {
|
|
return getCheckJobPage(Object.assign(parameter, this.queryParam)).then((res) => {
|
|
return res.data
|
|
return res.data
|
|
@@ -202,31 +210,31 @@ export default {
|
|
show: true,
|
|
show: true,
|
|
clear: () => {
|
|
clear: () => {
|
|
this.selectedRowKeys = []
|
|
this.selectedRowKeys = []
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
rowSelection: {
|
|
rowSelection: {
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
- onChange: this.onSelectChange,
|
|
|
|
- },
|
|
|
|
|
|
+ onChange: this.onSelectChange
|
|
|
|
+ }
|
|
},
|
|
},
|
|
- optionAlertShow: false,
|
|
|
|
|
|
+ optionAlertShow: false
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- created() {
|
|
|
|
|
|
+ created () {
|
|
// 下拉框map
|
|
// 下拉框map
|
|
this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.STORE_CHECK_JOB_STATUS)
|
|
this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.STORE_CHECK_JOB_STATUS)
|
|
this.sbStatusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.YES_NO)
|
|
this.sbStatusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.YES_NO)
|
|
this.tableOption()
|
|
this.tableOption()
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- tableOption() {
|
|
|
|
|
|
+ tableOption () {
|
|
if (!this.optionAlertShow) {
|
|
if (!this.optionAlertShow) {
|
|
this.options = {
|
|
this.options = {
|
|
alert: {
|
|
alert: {
|
|
show: true,
|
|
show: true,
|
|
clear: () => {
|
|
clear: () => {
|
|
this.selectedRowKeys = []
|
|
this.selectedRowKeys = []
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
rowSelection: {
|
|
rowSelection: {
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
@@ -234,21 +242,21 @@ export default {
|
|
getCheckboxProps: (record) => ({
|
|
getCheckboxProps: (record) => ({
|
|
props: {
|
|
props: {
|
|
disabled: false,
|
|
disabled: false,
|
|
- name: record.id,
|
|
|
|
- },
|
|
|
|
- }),
|
|
|
|
- },
|
|
|
|
|
|
+ name: record.id
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ }
|
|
}
|
|
}
|
|
this.optionAlertShow = true
|
|
this.optionAlertShow = true
|
|
} else {
|
|
} else {
|
|
this.options = {
|
|
this.options = {
|
|
alert: false,
|
|
alert: false,
|
|
- rowSelection: null,
|
|
|
|
|
|
+ rowSelection: null
|
|
}
|
|
}
|
|
this.optionAlertShow = false
|
|
this.optionAlertShow = false
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- batchDelete(id) {
|
|
|
|
|
|
+ batchDelete (id) {
|
|
let ids = []
|
|
let ids = []
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
const length = this.selectedRows.length
|
|
const length = this.selectedRows.length
|
|
@@ -266,46 +274,46 @@ export default {
|
|
this.$refs.table.clearSelected()
|
|
this.$refs.table.clearSelected()
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleEdit(record) {
|
|
|
|
|
|
+ handleEdit (record) {
|
|
const modal = this.$refs.baseModal
|
|
const modal = this.$refs.baseModal
|
|
modal.base(record)
|
|
modal.base(record)
|
|
},
|
|
},
|
|
- handleFinish(record) {
|
|
|
|
|
|
+ handleFinish (record) {
|
|
fetchCheckJob({ id: record.id }).then((res) => {
|
|
fetchCheckJob({ id: record.id }).then((res) => {
|
|
const modal = this.$refs.baseModal
|
|
const modal = this.$refs.baseModal
|
|
modal.base(res.data)
|
|
modal.base(res.data)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleExecute(record) {
|
|
|
|
|
|
+ handleExecute (record) {
|
|
executeJob({ id: record.id }).then((res) => {
|
|
executeJob({ id: record.id }).then((res) => {
|
|
this.handleOk()
|
|
this.handleOk()
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleView(record) {
|
|
|
|
|
|
+ handleView (record) {
|
|
fetchCheckJob({ id: record.id }).then((res) => {
|
|
fetchCheckJob({ id: record.id }).then((res) => {
|
|
const modal = this.$refs.detailModal
|
|
const modal = this.$refs.detailModal
|
|
modal.base(res.data)
|
|
modal.base(res.data)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleOk() {
|
|
|
|
|
|
+ handleOk () {
|
|
this.$refs.table.refresh()
|
|
this.$refs.table.refresh()
|
|
},
|
|
},
|
|
- onSelectChange(selectedRowKeys, selectedRows) {
|
|
|
|
|
|
+ onSelectChange (selectedRowKeys, selectedRows) {
|
|
this.selectedRowKeys = selectedRowKeys
|
|
this.selectedRowKeys = selectedRowKeys
|
|
this.selectedRows = selectedRows
|
|
this.selectedRows = selectedRows
|
|
},
|
|
},
|
|
- resetSearchForm() {
|
|
|
|
|
|
+ resetSearchForm () {
|
|
this.queryParam = {}
|
|
this.queryParam = {}
|
|
this.$refs.table.refresh(true)
|
|
this.$refs.table.refresh(true)
|
|
},
|
|
},
|
|
- doExport() {
|
|
|
|
|
|
+ doExport () {
|
|
const parameter = {
|
|
const parameter = {
|
|
- ...this.queryParam,
|
|
|
|
|
|
+ ...this.queryParam
|
|
}
|
|
}
|
|
exportCheckJob(parameter).then((file) => {
|
|
exportCheckJob(parameter).then((file) => {
|
|
this.BaseTool.UPLOAD.downLoadExportExcel(file)
|
|
this.BaseTool.UPLOAD.downLoadExportExcel(file)
|
|
})
|
|
})
|
|
- },
|
|
|
|
- },
|
|
|
|
|
|
+ }
|
|
|
|
+ }
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|