From ac499486cf06e9e06834ed5c182f26267d871b9b Mon Sep 17 00:00:00 2001 From: xuhy <3313886187@qq.com> Date: 星期二, 08 七月 2025 15:08:21 +0800 Subject: [PATCH] bug修改 --- ruoyi-admin/src/main/java/com/ruoyi/web/controller/task/TaskUtil.java | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/task/TaskUtil.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/task/TaskUtil.java index 8af7cba..d1ff21f 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/task/TaskUtil.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/task/TaskUtil.java @@ -117,9 +117,12 @@ // 获取点位类型的占比 String num4 = detail.getNum4(); + // 未绑定员工 if(CollectionUtils.isEmpty(sysUsers)){ continue; } + + SysUser sysUser = sysUsers.get(0); List<TProjectDept> projectDeptLists = new ArrayList<>(); @@ -193,7 +196,7 @@ } int dayCleanerCount = cleanerSums / cycle; - if((cycle - detail.getCurrentValue()) == 1 && cleanerSums % cycle != 0){ + if((cycle == detail.getCurrentValue()) && cleanerSums % cycle != 0){ dayCleanerCount++; } @@ -275,6 +278,10 @@ detail.setCurrentValue(0); // 将重复点位置空 redisCache.deleteObject(detail.getId() + REPEAT_LOCATION); + // 将项目部权重置空 + redisCache.deleteObject(detail.getId() + PROJECT_DEPT_WEIGHT); + // 将保洁员权重置空 + redisCache.deleteObject(detail.getId() + CLEANER_WEIGHT); } // 创建任务 -- Gitblit v1.7.1