|
|
@ -4,8 +4,8 @@ |
|
|
|
<BasicTable @register="registerTable" :rowSelection="rowSelection"> |
|
|
|
<BasicTable @register="registerTable" :rowSelection="rowSelection"> |
|
|
|
<!--插槽:table标题--> |
|
|
|
<!--插槽:table标题--> |
|
|
|
<template #tableTitle> |
|
|
|
<template #tableTitle> |
|
|
|
<a-button type="primary" @click="handleAdd" preIcon="ant-design:plus-outlined"> 新增</a-button> |
|
|
|
<!-- <a-button type="primary" @click="handleAdd" preIcon="ant-design:plus-outlined"> 新增</a-button>--> |
|
|
|
<!-- <a-button type="primary" @click="go_xinjianshenbao" preIcon="ant-design:plus-outlined"> 新建审报书</a-button>--> |
|
|
|
<!-- <a-button type="primary" @click="go_xinjianshenbao" preIcon="ant-design:plus-outlined"> 新建申报书</a-button>--> |
|
|
|
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls"> 导出</a-button> |
|
|
|
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls"> 导出</a-button> |
|
|
|
<!-- <j-upload-button type="primary" v-auth="'project:project:importExcel'" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>--> |
|
|
|
<!-- <j-upload-button type="primary" v-auth="'project:project:importExcel'" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>--> |
|
|
|
<a-dropdown> |
|
|
|
<a-dropdown> |
|
|
@ -15,13 +15,16 @@ |
|
|
|
<Icon icon="ant-design:plus-outlined"></Icon> |
|
|
|
<Icon icon="ant-design:plus-outlined"></Icon> |
|
|
|
科技攻关 |
|
|
|
科技攻关 |
|
|
|
</a-menu-item> |
|
|
|
</a-menu-item> |
|
|
|
|
|
|
|
<!-- <a-menu-item v-for="opt of RANGE_OPTIONS" :key="opt.key"> |
|
|
|
|
|
|
|
{{ opt.label }} |
|
|
|
|
|
|
|
</a-menu-item>--> |
|
|
|
<!--<a-menu-item key="1" @click="go_xinjianshenbao"> |
|
|
|
<!--<a-menu-item key="1" @click="go_xinjianshenbao"> |
|
|
|
<Icon icon="ant-design:plus-outlined"></Icon> |
|
|
|
<Icon icon="ant-design:plus-outlined"></Icon> |
|
|
|
xxx |
|
|
|
xxx |
|
|
|
</a-menu-item>--> |
|
|
|
</a-menu-item>--> |
|
|
|
</a-menu> |
|
|
|
</a-menu> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
<a-button type="primary">新建审报 |
|
|
|
<a-button type="primary">新建申报 |
|
|
|
<Icon icon="mdi:chevron-down"></Icon> |
|
|
|
<Icon icon="mdi:chevron-down"></Icon> |
|
|
|
</a-button> |
|
|
|
</a-button> |
|
|
|
</a-dropdown> |
|
|
|
</a-dropdown> |
|
|
@ -48,12 +51,22 @@ import {useModal} from '/@/components/Modal'; |
|
|
|
import { useListPage } from '/@/hooks/system/useListPage' |
|
|
|
import { useListPage } from '/@/hooks/system/useListPage' |
|
|
|
import ProjectModal from './components/ProjectModal.vue' |
|
|
|
import ProjectModal from './components/ProjectModal.vue' |
|
|
|
import {columns, searchFormSchema, superQuerySchema} from './Project.data'; |
|
|
|
import {columns, searchFormSchema, superQuerySchema} from './Project.data'; |
|
|
|
import {list, deleteOne, batchDelete, getImportUrl,getExportUrl} from './Project.api'; |
|
|
|
import { |
|
|
|
|
|
|
|
list, |
|
|
|
|
|
|
|
deleteOne, |
|
|
|
|
|
|
|
rollbackOne, |
|
|
|
|
|
|
|
submitOne, |
|
|
|
|
|
|
|
batchDelete, |
|
|
|
|
|
|
|
getImportUrl, |
|
|
|
|
|
|
|
getExportUrl, |
|
|
|
|
|
|
|
getProjectTypeList |
|
|
|
|
|
|
|
} from './Project.api'; |
|
|
|
import { downloadFile } from '/@/utils/common/renderUtils'; |
|
|
|
import { downloadFile } from '/@/utils/common/renderUtils'; |
|
|
|
import { useGo } from '/@/hooks/web/usePage'; |
|
|
|
import { useGo } from '/@/hooks/web/usePage'; |
|
|
|
|
|
|
|
|
|
|
|
import { useUserStore } from '/@/store/modules/user'; |
|
|
|
import { useUserStore } from '/@/store/modules/user'; |
|
|
|
import {getUserData} from "@/views/system/usersetting/UserSetting.api"; |
|
|
|
import {getUserData} from "@/views/system/usersetting/UserSetting.api"; |
|
|
|
|
|
|
|
import {useTimeoutFn} from "@/hooks/core/useTimeout"; |
|
|
|
const go = useGo(); |
|
|
|
const go = useGo(); |
|
|
|
|
|
|
|
|
|
|
|
const queryParam = reactive<any>({}); |
|
|
|
const queryParam = reactive<any>({}); |
|
|
@ -61,7 +74,6 @@ const checkedKeys = ref<Array<string | number>>([]); |
|
|
|
const userStore = useUserStore(); |
|
|
|
const userStore = useUserStore(); |
|
|
|
//注册model |
|
|
|
//注册model |
|
|
|
const [registerModal, {openModal}] = useModal(); |
|
|
|
const [registerModal, {openModal}] = useModal(); |
|
|
|
//注册table数据 |
|
|
|
|
|
|
|
const { prefixCls,tableContext,onExportXls,onImportXls } = useListPage({ |
|
|
|
const { prefixCls,tableContext,onExportXls,onImportXls } = useListPage({ |
|
|
|
tableProps:{ |
|
|
|
tableProps:{ |
|
|
|
title: '项目表', |
|
|
|
title: '项目表', |
|
|
@ -79,7 +91,7 @@ const { prefixCls,tableContext,onExportXls,onImportXls } = useListPage({ |
|
|
|
], |
|
|
|
], |
|
|
|
}, |
|
|
|
}, |
|
|
|
actionColumn: { |
|
|
|
actionColumn: { |
|
|
|
width: 280, |
|
|
|
width: 380, |
|
|
|
fixed:'right' |
|
|
|
fixed:'right' |
|
|
|
}, |
|
|
|
}, |
|
|
|
beforeFetch: (params) => { |
|
|
|
beforeFetch: (params) => { |
|
|
@ -97,6 +109,21 @@ const { prefixCls,tableContext,onExportXls,onImportXls } = useListPage({ |
|
|
|
}, |
|
|
|
}, |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 日期范围选项 |
|
|
|
|
|
|
|
// 日期范围选项 |
|
|
|
|
|
|
|
const RANGE_OPTIONS = [ |
|
|
|
|
|
|
|
{key: 'TODAY', label: '今天'}, |
|
|
|
|
|
|
|
{key: 'YESTERDAY', label: '昨天'}, |
|
|
|
|
|
|
|
{key: 'TOMORROW', label: '明天'}, |
|
|
|
|
|
|
|
{key: 'THIS_WEEK', label: '本周'}, |
|
|
|
|
|
|
|
{key: 'LAST_WEEK', label: '上周'}, |
|
|
|
|
|
|
|
{key: 'NEXT_WEEK', label: '下周'}, |
|
|
|
|
|
|
|
{key: 'LAST_7_DAYS', label: '过去七天'}, |
|
|
|
|
|
|
|
{key: 'THIS_MONTH', label: '本月'}, |
|
|
|
|
|
|
|
{key: 'LAST_MONTH', label: '上月'}, |
|
|
|
|
|
|
|
{key: 'NEXT_MONTH', label: '下月'}, |
|
|
|
|
|
|
|
]; |
|
|
|
|
|
|
|
|
|
|
|
const [registerTable, {reload},{ rowSelection, selectedRowKeys }] = tableContext |
|
|
|
const [registerTable, {reload},{ rowSelection, selectedRowKeys }] = tableContext |
|
|
|
|
|
|
|
|
|
|
|
// 高级查询配置 |
|
|
|
// 高级查询配置 |
|
|
@ -124,7 +151,7 @@ function handleAdd() { |
|
|
|
//跳转到新建申报页面 |
|
|
|
//跳转到新建申报页面 |
|
|
|
function go_xinjianshenbao() { |
|
|
|
function go_xinjianshenbao() { |
|
|
|
// go('/comp/jeecg/basic'); |
|
|
|
// go('/comp/jeecg/basic'); |
|
|
|
go('/projectApplication/index'); |
|
|
|
go('/projectApplication/index?projectTypeId='+'1846744340708184065'); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
//跳转到项目书页面 |
|
|
|
//跳转到项目书页面 |
|
|
@ -136,10 +163,16 @@ function go_xiangmushu(record) { |
|
|
|
//跳转到预算书页面 |
|
|
|
//跳转到预算书页面 |
|
|
|
function go_yusuanshu(record) { |
|
|
|
function go_yusuanshu(record) { |
|
|
|
// go('/comp/jeecg/basic?id=' +'666'); |
|
|
|
// go('/comp/jeecg/basic?id=' +'666'); |
|
|
|
go('/projectApplication/kejigongguan/xiangmushu?id='+record.id); |
|
|
|
go('/projectApplication/kejigongguan/yusuanshu?id='+record.id); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function go_projectLog(record) { |
|
|
|
|
|
|
|
// go('/comp/jeecg/basic?id=' +'666'); |
|
|
|
|
|
|
|
go('/projectLog/projectLogList?id='+record.id); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 编辑事件 |
|
|
|
* 编辑事件 |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -166,6 +199,16 @@ function handleDetail(record: Recordable) { |
|
|
|
async function handleDelete(record) { |
|
|
|
async function handleDelete(record) { |
|
|
|
await deleteOne({id: record.id}, handleSuccess); |
|
|
|
await deleteOne({id: record.id}, handleSuccess); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//取回项目 |
|
|
|
|
|
|
|
async function handleSubmitOne(record) { |
|
|
|
|
|
|
|
await submitOne({id: record.id}, handleSuccess); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//取回项目 |
|
|
|
|
|
|
|
async function handleRollbackOne(record) { |
|
|
|
|
|
|
|
await rollbackOne({id: record.id}, handleSuccess); |
|
|
|
|
|
|
|
} |
|
|
|
/** |
|
|
|
/** |
|
|
|
* 批量删除事件 |
|
|
|
* 批量删除事件 |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -198,19 +241,40 @@ function getTableAction(record){ |
|
|
|
onClick: handleDetail.bind(null, record), |
|
|
|
onClick: handleDetail.bind(null, record), |
|
|
|
}, |
|
|
|
}, |
|
|
|
{ |
|
|
|
{ |
|
|
|
|
|
|
|
label: '日志查询', |
|
|
|
|
|
|
|
onClick: go_projectLog.bind(null, record), |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
]; |
|
|
|
|
|
|
|
//申请人待提交时可以删除(只有自己能删除) |
|
|
|
|
|
|
|
if (record.projectStatus == 5) { |
|
|
|
|
|
|
|
actions.unshift({ |
|
|
|
label: '删除', |
|
|
|
label: '删除', |
|
|
|
popConfirm: { |
|
|
|
popConfirm: { |
|
|
|
title: '是否确认删除', |
|
|
|
title: '是否确认删除', |
|
|
|
confirm: handleDelete.bind(null, record), |
|
|
|
confirm: handleDelete.bind(null, record), |
|
|
|
placement: 'topLeft', |
|
|
|
placement: 'topLeft', |
|
|
|
}, |
|
|
|
}, |
|
|
|
// auth: 'projecttype:project_type:delete' |
|
|
|
}); |
|
|
|
}]; |
|
|
|
} |
|
|
|
//申请人待提交时,可以修改 |
|
|
|
|
|
|
|
if (record.projectStatus == 5) { |
|
|
|
if (record.projectStatus == 5) { |
|
|
|
actions.unshift({ |
|
|
|
actions.unshift({ |
|
|
|
label: '编辑', |
|
|
|
label: '提交项目', |
|
|
|
onClick: handleEdit.bind(null, record), |
|
|
|
onClick: handleSubmitOne.bind(null, record), |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
//projectStatus 项目书状态 |
|
|
|
|
|
|
|
//('科技主管部门待提交', '1'); |
|
|
|
|
|
|
|
//('科技主管部门已提交', '2'); |
|
|
|
|
|
|
|
//('不受理', '3'); |
|
|
|
|
|
|
|
//('已受理', '4'); |
|
|
|
|
|
|
|
//('申请人待提交', '5'); |
|
|
|
|
|
|
|
//('申请单位待提交', '6'); |
|
|
|
|
|
|
|
//('市科技局待提交', '7'); |
|
|
|
|
|
|
|
//('市科技局已提交', '8'); |
|
|
|
|
|
|
|
if (record.projectStatus ==6) { |
|
|
|
|
|
|
|
actions.unshift({ |
|
|
|
|
|
|
|
label: '取回项目', |
|
|
|
|
|
|
|
onClick: handleRollbackOne.bind(null, record), |
|
|
|
}); |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|
return actions; |
|
|
|
return actions; |
|
|
|