diff --git a/kernel-s-sys/sys-business-hr/src/main/java/cn/stylefeng/roses/kernel/sys/modular/org/controller/HomeOrgStatController.java b/kernel-s-sys/sys-business-hr/src/main/java/cn/stylefeng/roses/kernel/sys/modular/org/controller/HomeOrgStatController.java new file mode 100644 index 000000000..b9ceacaa0 --- /dev/null +++ b/kernel-s-sys/sys-business-hr/src/main/java/cn/stylefeng/roses/kernel/sys/modular/org/controller/HomeOrgStatController.java @@ -0,0 +1,39 @@ +package cn.stylefeng.roses.kernel.sys.modular.org.controller; + +import cn.stylefeng.roses.kernel.rule.pojo.response.ResponseData; +import cn.stylefeng.roses.kernel.rule.pojo.response.SuccessResponseData; +import cn.stylefeng.roses.kernel.scanner.api.annotation.ApiResource; +import cn.stylefeng.roses.kernel.scanner.api.annotation.GetResource; +import cn.stylefeng.roses.kernel.sys.modular.org.pojo.response.HomeCompanyInfo; +import cn.stylefeng.roses.kernel.sys.modular.org.service.HrOrganizationService; +import org.springframework.web.bind.annotation.RestController; + +import javax.annotation.Resource; + +/** + * 获取组织机构统计信息 + * + * @author fengshuonan + * @since 2023/6/26 22:51 + */ +@RestController +@ApiResource(name = "获取组织机构统计信息") +public class HomeOrgStatController { + + @Resource + private HrOrganizationService hrOrganizationService; + + /** + * 获取组织机构统计信息,包含系统的统计,包含当前用户公司的统计 + *
+ * 一般用在首页展示组织机构的统计信息界面
+ *
+ * @author fengshuonan
+ * @since 2023/6/26 22:51
+ */
+ @GetResource(name = "获取组织机构统计信息", path = "/org/statInfo")
+ public ResponseData
+ * 一般用在首页展示组织机构的统计信息界面
+ *
+ * @author fengshuonan
+ * @since 2023/6/26 22:53
+ */
+ HomeCompanyInfo orgStatInfo();
+
}
\ No newline at end of file
diff --git a/kernel-s-sys/sys-business-hr/src/main/java/cn/stylefeng/roses/kernel/sys/modular/org/service/impl/HrOrganizationServiceImpl.java b/kernel-s-sys/sys-business-hr/src/main/java/cn/stylefeng/roses/kernel/sys/modular/org/service/impl/HrOrganizationServiceImpl.java
index 4465ba130..2b3d5d1d9 100644
--- a/kernel-s-sys/sys-business-hr/src/main/java/cn/stylefeng/roses/kernel/sys/modular/org/service/impl/HrOrganizationServiceImpl.java
+++ b/kernel-s-sys/sys-business-hr/src/main/java/cn/stylefeng/roses/kernel/sys/modular/org/service/impl/HrOrganizationServiceImpl.java
@@ -20,6 +20,7 @@ import cn.stylefeng.roses.kernel.sys.modular.org.entity.HrOrganization;
import cn.stylefeng.roses.kernel.sys.modular.org.factory.OrganizationFactory;
import cn.stylefeng.roses.kernel.sys.modular.org.mapper.HrOrganizationMapper;
import cn.stylefeng.roses.kernel.sys.modular.org.pojo.request.HrOrganizationRequest;
+import cn.stylefeng.roses.kernel.sys.modular.org.pojo.response.HomeCompanyInfo;
import cn.stylefeng.roses.kernel.sys.modular.org.service.HrOrganizationService;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@@ -198,6 +199,15 @@ public class HrOrganizationServiceImpl extends ServiceImpl