From 267adf748e9af2c71ea826c7210dad1f355cc723 Mon Sep 17 00:00:00 2001 From: zhc077 <565291854@qq.com> Date: Thu, 7 Nov 2024 15:17:13 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AB=8B=E9=A1=B9=E3=80=81=E9=AA=8C=E6=94=B6?= =?UTF-8?q?=E3=80=81=E7=BB=93=E9=A1=B9=E5=8A=9F=E8=83=BD=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=2011.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../project/controller/ProjectController.java | 84 ++++++++++++------- .../controller/ProjectLogController.java | 1 + jeecgboot-vue3/.env.development | 4 +- .../jiexiang/jixiang4CaiZhengList.vue | 2 +- .../lixiang/lixiang4CaiZhengList.vue | 2 +- .../yanshao/yanshou4CaiZhengList.vue | 2 +- jeecgboot-vue3/vite.config.ts | 2 +- 7 files changed, 61 insertions(+), 36 deletions(-) diff --git a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/project/controller/ProjectController.java b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/project/controller/ProjectController.java index 95101e9..09782af 100644 --- a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/project/controller/ProjectController.java +++ b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/project/controller/ProjectController.java @@ -122,20 +122,11 @@ public class ProjectController extends JeecgController } /** - * @description: //('科技主管部门待提交', '1'); - * //('科技主管部门已提交', '2'); - * //('不受理', '3'); - * //('已受理', '4'); - * //('申请人待提交', '5'); - * //('申请单位待提交', '6'); - * //('市科技局待提交', '7'); - * //('市科技局已提交', '8'); - * //('财政主管理部门待审核', '9'); - * //('财政主管理部门审核通过', '10'); + * @description: 申报列表,不同角色可见数据 * @param: [project, pageNo, pageSize, req] - * @return: org.jeecg.common.api.vo.Result> + * @return: org.jeecg.common.api.vo.Result> * @author: z.h.c - * @date: 24/11/5 16:25 + * @date: 24/11/7 14:56 */ @ApiOperation(value = "项目表-分页列表查询", notes = "项目表-分页列表查询") @GetMapping(value = "/list4Audit") @@ -165,6 +156,9 @@ public class ProjectController extends JeecgController //('市科技局已提交', '8'); //('财政主管理部门待审核', '9'); //('财政主管理部门审核通过', '10'); + // 11 已立项 + // 12 已验收 + //13 已结项 //申请人数据 if ("shenbaoren_role".equals(loginUser.getRoleCode())) { @@ -197,9 +191,9 @@ public class ProjectController extends JeecgController @GetMapping(value = "/list4LiXiang") // @PermissionData(pageComponent = "projectApplication/productAudit/project4AuditList") public Result> list4LiXiang(Project project, - @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, - @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, - HttpServletRequest req) { + @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, + HttpServletRequest req) { // 自定义查询规则 Map customeRuleMap = new HashMap<>(); // 自定义多选的查询规则为:LIKE_WITH_OR @@ -227,9 +221,9 @@ public class ProjectController extends JeecgController //13 已结项 //财政管理员看到要立项的数据 - if ("caizheng_admin".equals(loginUser.getRoleCode())) { - queryWrapper.in("budget_status", 10,11); - }else { + if ("kejiju_admin".equals(loginUser.getRoleCode())) { + queryWrapper.in("budget_status", 10, 11); + } else { queryWrapper.in("project_status", 11); } IPage pageList = projectService.page(page, queryWrapper); @@ -241,9 +235,9 @@ public class ProjectController extends JeecgController @GetMapping(value = "/list4YanShou") // @PermissionData(pageComponent = "projectApplication/productAudit/project4AuditList") public Result> list4YanShou(Project project, - @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, - @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, - HttpServletRequest req) { + @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, + HttpServletRequest req) { // 自定义查询规则 Map customeRuleMap = new HashMap<>(); // 自定义多选的查询规则为:LIKE_WITH_OR @@ -271,9 +265,9 @@ public class ProjectController extends JeecgController //13 已结项 //财政管理可以看到要验收的数据 - if ("caizheng_admin".equals(loginUser.getRoleCode())) { - queryWrapper.in("project_status", 11,12); - }else { + if ("kejiju_admin".equals(loginUser.getRoleCode())) { + queryWrapper.in("project_status", 11, 12); + } else { queryWrapper.in("project_status", 12); } IPage pageList = projectService.page(page, queryWrapper); @@ -284,9 +278,9 @@ public class ProjectController extends JeecgController @GetMapping(value = "/list4JieXiang") // @PermissionData(pageComponent = "projectApplication/productAudit/project4AuditList") public Result> list4JieXiang(Project project, - @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, - @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, - HttpServletRequest req) { + @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, + HttpServletRequest req) { // 自定义查询规则 Map customeRuleMap = new HashMap<>(); // 自定义多选的查询规则为:LIKE_WITH_OR @@ -303,19 +297,49 @@ public class ProjectController extends JeecgController //13 已结项 //财政管理可以看到要验收的数据 - if ("caizheng_admin".equals(loginUser.getRoleCode())) { - queryWrapper.in("project_status", 12,13); - }else { + if ("kejiju_admin".equals(loginUser.getRoleCode())) { + queryWrapper.in("project_status", 12, 13); + } else { queryWrapper.in("project_status", 13); } IPage pageList = projectService.page(page, queryWrapper); return Result.OK(pageList); } + /** + * @description: 市科技局立项、验收、结项审核流程 + * @param: [param, req] + * @return: org.jeecg.common.api.vo.Result + * @author: z.h.c + * @date: 24/11/7 14:44 + */ @ApiOperation(value = "项目表-更新状态", notes = "项目表-更新状态") @PostMapping(value = "/updateStatus") public Result updateStatus(@RequestBody Project param, HttpServletRequest req) { + Project project = projectService.getById(param.getId()); projectService.updateById(param); + LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); + ProjectLog log = new ProjectLog(); + log.setOperatorName(loginUser.getRealname()); + log.setOperatorId(loginUser.getId()); + log.setProjectId(project.getId()); + log.setProjectName(project.getProjectName()); + log.setOperationTime(new Date()); + log.setProjectStatus(param.getProjectStatus()); + log.setBudgetStatus(param.getBudgetStatus()); + // 11 已立项 + // 12 已验收 + //13 已结项 + if ("11".equals(param.getProjectStatus())) { + log.setOperationMark("市科技局立项"); + } + if ("12".equals(param.getProjectStatus())) { + log.setOperationMark("市科技局验收"); + } + if ("13".equals(param.getProjectStatus())) { + log.setOperationMark("市科技局结项"); + } + iProjectLogService.save(log); return Result.OK("操作成功"); } diff --git a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/projectLog/controller/ProjectLogController.java b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/projectLog/controller/ProjectLogController.java index 4b86efa..c804657 100644 --- a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/projectLog/controller/ProjectLogController.java +++ b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/projectLog/controller/ProjectLogController.java @@ -53,6 +53,7 @@ public class ProjectLogController extends JeecgController queryWrapper = QueryGenerator.initQueryWrapper(projectLog, req.getParameterMap()); Page page = new Page(pageNo, pageSize); + queryWrapper.orderByDesc("operation_time"); IPage pageList = projectLogService.page(page, queryWrapper); return Result.OK(pageList); } diff --git a/jeecgboot-vue3/.env.development b/jeecgboot-vue3/.env.development index e37bfea..e090825 100644 --- a/jeecgboot-vue3/.env.development +++ b/jeecgboot-vue3/.env.development @@ -6,10 +6,10 @@ VITE_PUBLIC_PATH = / # 跨域代理,您可以配置多个 ,请注意,没有换行符 -VITE_PROXY = [["/jeecgboot","http://10.121.2.107:18086/jeecg-boot"],["/upload","http://localhost:3300/upload"]] +VITE_PROXY = [["/jeecgboot","http://localhost:18086/jeecg-boot"],["/upload","http://localhost:3300/upload"]] #后台接口全路径地址(必填) -VITE_GLOB_DOMAIN_URL=http://10.121.2.107:18086/jeecg-boot +VITE_GLOB_DOMAIN_URL=http://localhost:18086/jeecg-boot #后台接口父地址(必填) VITE_GLOB_API_URL=/jeecgboot diff --git a/jeecgboot-vue3/src/views/projectApplication/jiexiang/jixiang4CaiZhengList.vue b/jeecgboot-vue3/src/views/projectApplication/jiexiang/jixiang4CaiZhengList.vue index ede7fa6..ba4b149 100644 --- a/jeecgboot-vue3/src/views/projectApplication/jiexiang/jixiang4CaiZhengList.vue +++ b/jeecgboot-vue3/src/views/projectApplication/jiexiang/jixiang4CaiZhengList.vue @@ -64,7 +64,7 @@ const {prefixCls, tableContext, onExportXls, onImportXls} = useListPage({ fieldMapToTime: [], }, actionColumn: { - width: 320, + width: 350, fixed: 'right' }, beforeFetch: (params) => { diff --git a/jeecgboot-vue3/src/views/projectApplication/lixiang/lixiang4CaiZhengList.vue b/jeecgboot-vue3/src/views/projectApplication/lixiang/lixiang4CaiZhengList.vue index c3afdc4..a71f459 100644 --- a/jeecgboot-vue3/src/views/projectApplication/lixiang/lixiang4CaiZhengList.vue +++ b/jeecgboot-vue3/src/views/projectApplication/lixiang/lixiang4CaiZhengList.vue @@ -64,7 +64,7 @@ const {prefixCls, tableContext, onExportXls, onImportXls} = useListPage({ fieldMapToTime: [], }, actionColumn: { - width: 320, + width: 350, fixed: 'right' }, beforeFetch: (params) => { diff --git a/jeecgboot-vue3/src/views/projectApplication/yanshao/yanshou4CaiZhengList.vue b/jeecgboot-vue3/src/views/projectApplication/yanshao/yanshou4CaiZhengList.vue index 0fa6e8d..f79b7db 100644 --- a/jeecgboot-vue3/src/views/projectApplication/yanshao/yanshou4CaiZhengList.vue +++ b/jeecgboot-vue3/src/views/projectApplication/yanshao/yanshou4CaiZhengList.vue @@ -64,7 +64,7 @@ const {prefixCls, tableContext, onExportXls, onImportXls} = useListPage({ fieldMapToTime: [], }, actionColumn: { - width: 320, + width: 350, fixed: 'right' }, beforeFetch: (params) => { diff --git a/jeecgboot-vue3/vite.config.ts b/jeecgboot-vue3/vite.config.ts index 49cb7eb..63ed8f3 100644 --- a/jeecgboot-vue3/vite.config.ts +++ b/jeecgboot-vue3/vite.config.ts @@ -67,7 +67,7 @@ export default ({ command, mode }: ConfigEnv): UserConfig => { https: false, port: VITE_PORT, // Load proxy configuration from .env - // proxy: createProxy(VITE_PROXY), + proxy: createProxy(VITE_PROXY), }, build: { minify: 'esbuild',