|
@@ -61,7 +61,7 @@
|
|
|
</a-dropdown>
|
|
</a-dropdown>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
- <!-- table区域-begin -->
|
|
|
|
|
|
|
+ <!-- table区域 begin -->
|
|
|
<div>
|
|
<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>项
|
|
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
|
|
@@ -105,12 +105,24 @@
|
|
|
<span slot="action" slot-scope="text, record">
|
|
<span slot="action" slot-scope="text, record">
|
|
|
<a @click="handleEdit(record)">编辑</a>
|
|
<a @click="handleEdit(record)">编辑</a>
|
|
|
|
|
|
|
|
|
|
+ <a-divider type="vertical" />
|
|
|
|
|
+ <a @click="handleDetail(record)">详情</a>
|
|
|
|
|
+ <a-divider type="vertical" />
|
|
|
|
|
+ <a @click="showCheckList(record)">稽核详情</a>
|
|
|
<a-divider type="vertical" />
|
|
<a-divider type="vertical" />
|
|
|
<a-dropdown>
|
|
<a-dropdown>
|
|
|
<a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
|
|
<a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
|
|
|
<a-menu slot="overlay">
|
|
<a-menu slot="overlay">
|
|
|
- <a-menu-item>
|
|
|
|
|
- <a @click="handleDetail(record)">详情</a>
|
|
|
|
|
|
|
+
|
|
|
|
|
+ <a-menu-item v-if="record.taskState == 0">
|
|
|
|
|
+ <a-popconfirm title="确定开始稽核吗?" @confirm="() => checkStart(record)">
|
|
|
|
|
+ <a>开始稽核</a>
|
|
|
|
|
+ </a-popconfirm>
|
|
|
|
|
+ </a-menu-item>
|
|
|
|
|
+ <a-menu-item v-if="record.taskState == 1">
|
|
|
|
|
+ <a-popconfirm title="确定结束稽核吗?" @confirm="() => checkEnd(record)">
|
|
|
|
|
+ <a>结束稽核</a>
|
|
|
|
|
+ </a-popconfirm>
|
|
|
</a-menu-item>
|
|
</a-menu-item>
|
|
|
<a-menu-item>
|
|
<a-menu-item>
|
|
|
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
|
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
|
@@ -123,8 +135,11 @@
|
|
|
|
|
|
|
|
</a-table>
|
|
</a-table>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <!-- table区域 end -->
|
|
|
|
|
+
|
|
|
<!-- 任务添加 -->
|
|
<!-- 任务添加 -->
|
|
|
<task-add ref="modalForm" @ok="modalFormOk"></task-add>
|
|
<task-add ref="modalForm" @ok="modalFormOk"></task-add>
|
|
|
|
|
+ <task-detail ref="modalDetail" @ok="modalFormOk"></task-detail>
|
|
|
</a-card>
|
|
</a-card>
|
|
|
|
|
|
|
|
|
|
|
|
@@ -132,23 +147,23 @@
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
|
|
|
|
|
|
|
+ import { httpAction } from '@api/manage'
|
|
|
import '@/assets/less/TableExpand.less'
|
|
import '@/assets/less/TableExpand.less'
|
|
|
- import { mixinDevice } from '@/utils/mixin'
|
|
|
|
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
|
- import SmsCheckTaskModal from './SmsCheckTaskModal'
|
|
|
|
|
import TaskAdd from './TaskAdd'
|
|
import TaskAdd from './TaskAdd'
|
|
|
|
|
+ import TaskDetail from './TaskDetail'
|
|
|
|
|
|
|
|
export default {
|
|
export default {
|
|
|
name: 'TaskList',
|
|
name: 'TaskList',
|
|
|
- mixins:[JeecgListMixin, mixinDevice],
|
|
|
|
|
|
|
+ mixins:[JeecgListMixin],
|
|
|
components: {
|
|
components: {
|
|
|
- SmsCheckTaskModal,
|
|
|
|
|
- TaskAdd
|
|
|
|
|
|
|
+ TaskAdd,
|
|
|
|
|
+ TaskDetail,
|
|
|
},
|
|
},
|
|
|
data () {
|
|
data () {
|
|
|
return {
|
|
return {
|
|
|
description: '稽核任务管理页面',
|
|
description: '稽核任务管理页面',
|
|
|
- // 表头
|
|
|
|
|
|
|
+ disableSubmit: false,
|
|
|
columns: [
|
|
columns: [
|
|
|
{
|
|
{
|
|
|
title: '#',
|
|
title: '#',
|
|
@@ -207,13 +222,15 @@
|
|
|
url: {
|
|
url: {
|
|
|
list: "/smsCheck/task/list",
|
|
list: "/smsCheck/task/list",
|
|
|
delete: "/smsCheck/task/delete",
|
|
delete: "/smsCheck/task/delete",
|
|
|
|
|
+ edit: "/smsCheck/task/edit",
|
|
|
deleteBatch: "/smsCheck/task/deleteBatch",
|
|
deleteBatch: "/smsCheck/task/deleteBatch",
|
|
|
exportXlsUrl: "/smsCheck/task/exportXls",
|
|
exportXlsUrl: "/smsCheck/task/exportXls",
|
|
|
importExcelUrl: "smsCheck/task/importExcel",
|
|
importExcelUrl: "smsCheck/task/importExcel",
|
|
|
|
|
|
|
|
},
|
|
},
|
|
|
- dictOptions:{},
|
|
|
|
|
- superFieldList:[],
|
|
|
|
|
|
|
+ dictOptions: {},
|
|
|
|
|
+ superFieldList: [],
|
|
|
|
|
+ currentTaskState: 0,
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
created() {
|
|
created() {
|
|
@@ -231,7 +248,39 @@
|
|
|
},
|
|
},
|
|
|
// 显示导入页面
|
|
// 显示导入页面
|
|
|
showImport() {
|
|
showImport() {
|
|
|
- this.$emit('goImport', true);
|
|
|
|
|
|
|
+ // 选择一条
|
|
|
|
|
+ if (this.selectedRowKeys.length !== 1) {
|
|
|
|
|
+ this.$message.warning('请选择一条记录!');
|
|
|
|
|
+ return;
|
|
|
|
|
+ }
|
|
|
|
|
+ let row = this.selectionRows[0]
|
|
|
|
|
+ let task = {
|
|
|
|
|
+ id: row.id,
|
|
|
|
|
+ name: row.taskName,
|
|
|
|
|
+ startTime: row.taskStartTime,
|
|
|
|
|
+ endTime: row.taskEndTime,
|
|
|
|
|
+ state: row.taskState,
|
|
|
|
|
+ stateText: row.taskState_dictText,
|
|
|
|
|
+ description: row.description,
|
|
|
|
|
+ customerCount: row.customerCount,
|
|
|
|
|
+ checkCount: row.checkCount,
|
|
|
|
|
+ }
|
|
|
|
|
+ this.$emit('goImport', task);
|
|
|
|
|
+ },
|
|
|
|
|
+ // 显示导入页面
|
|
|
|
|
+ showCheckList(record) {
|
|
|
|
|
+ let task = {
|
|
|
|
|
+ id: record.id,
|
|
|
|
|
+ name: record.taskName,
|
|
|
|
|
+ startTime: record.taskStartTime,
|
|
|
|
|
+ endTime: record.taskEndTime,
|
|
|
|
|
+ state: record.taskState,
|
|
|
|
|
+ stateText: record.taskState_dictText,
|
|
|
|
|
+ description: record.description,
|
|
|
|
|
+ customerCount: record.customerCount,
|
|
|
|
|
+ checkCount: record.checkCount,
|
|
|
|
|
+ }
|
|
|
|
|
+ this.$emit('goCheckList', task);
|
|
|
},
|
|
},
|
|
|
initDictConfig(){
|
|
initDictConfig(){
|
|
|
},
|
|
},
|
|
@@ -253,6 +302,53 @@
|
|
|
// this.$refs.modalForm.title = "编辑";
|
|
// this.$refs.modalForm.title = "编辑";
|
|
|
// this.$refs.modalForm.disableSubmit = false;
|
|
// this.$refs.modalForm.disableSubmit = false;
|
|
|
// },
|
|
// },
|
|
|
|
|
+ // handleDetail:function(record){
|
|
|
|
|
+ // this.$refs.modalForm.edit(record);
|
|
|
|
|
+ // this.$refs.modalForm.title="详情";
|
|
|
|
|
+ // this.$refs.modalForm.disableSubmit = true;
|
|
|
|
|
+ // },
|
|
|
|
|
+ handleDetail(record){
|
|
|
|
|
+ this.$refs.modalDetail.detail(record);
|
|
|
|
|
+ this.$refs.modalDetail.title="详情";
|
|
|
|
|
+ },
|
|
|
|
|
+ checkStart(record){
|
|
|
|
|
+ record.taskState = 1;
|
|
|
|
|
+ let that = this;
|
|
|
|
|
+ let httpUrl = this.url.edit;
|
|
|
|
|
+ let param = record;
|
|
|
|
|
+ let method = 'put';
|
|
|
|
|
+
|
|
|
|
|
+ // 发送请求
|
|
|
|
|
+ httpAction(httpUrl, param, method)
|
|
|
|
|
+ .then((res) => {
|
|
|
|
|
+ if(res.success){
|
|
|
|
|
+ that.$message.success("稽核任务已开始!");
|
|
|
|
|
+ }else{
|
|
|
|
|
+ that.$message.warning(res.message);
|
|
|
|
|
+ }
|
|
|
|
|
+ }).finally(() => {
|
|
|
|
|
+ that.loadData();
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
|
|
+ checkEnd(record){
|
|
|
|
|
+ record.taskState = 2;
|
|
|
|
|
+ let that = this;
|
|
|
|
|
+ let httpUrl = this.url.edit;
|
|
|
|
|
+ let param = record;
|
|
|
|
|
+ let method = 'put';
|
|
|
|
|
+
|
|
|
|
|
+ // 发送请求
|
|
|
|
|
+ httpAction(httpUrl, param, method)
|
|
|
|
|
+ .then((res) => {
|
|
|
|
|
+ if(res.success){
|
|
|
|
|
+ that.$message.success("稽核任务已结束!");
|
|
|
|
|
+ }else{
|
|
|
|
|
+ that.$message.warning(res.message);
|
|
|
|
|
+ }
|
|
|
|
|
+ }).finally(() => {
|
|
|
|
|
+ that.loadData();
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
</script>
|
|
</script>
|