gongchunyi
22 小时以前 579f5ecc15a375651956485f6086c4b8e1eef088
src/main/java/com/ruoyi/home/service/impl/HomeServiceImpl.java
@@ -627,9 +627,9 @@
        for (SysDept dept : depts) {
            if ("0".equals(dept.getStatus()) && "0".equals(dept.getDelFlag())) {
                Long count = sysUserDeptMapper.selectCount(new LambdaQueryWrapper<SysUserDept>()
                        .eq(SysUserDept::getDeptId, dept.getDeptId()));
                if (count > 0) {
                Long count = staffOnJobMapper.selectCount(new QueryWrapper<StaffOnJob>()
                        .eq("sys_dept_id", dept.getDeptId()).eq("staff_state", 1));
                if (count != null && count > 0) {
                    Map<String, Object> map = new HashMap<>();
                    map.put("name", dept.getDeptName());
                    map.put("count", count);
@@ -689,12 +689,11 @@
    }
    private Long countStaff(LocalDateTime dateTime) {
        Long sysUserCount = sysUserMapper.selectCount(new LambdaQueryWrapper<SysUser>()
                .eq(SysUser::getDelFlag, "0")
                .le(SysUser::getCreateTime, dateTime));
        Long staffCountItem = staffOnJobMapper.selectCount(new LambdaQueryWrapper<StaffOnJob>()
                .isNotNull(StaffOnJob::getStaffState)
                .eq(StaffOnJob::getStaffState, 1)
                .le(StaffOnJob::getCreateTime, dateTime));
        return sysUserCount + staffCountItem;
        return staffCountItem;
    }
    private Long countCustomers(LocalDateTime dateTime) {