新火炬后端单体项目初始化代码
Lius
8 天以前 9af27ed8da6b5710025fb080f96a7dd9e80467a4
src/main/java/org/jeecg/modules/system/controller/SysUserController.java
@@ -12,6 +12,7 @@
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import liquibase.pro.packaged.I;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang.StringUtils;
import org.apache.shiro.SecurityUtils;
@@ -30,6 +31,8 @@
import org.jeecg.modules.base.service.BaseCommonService;
import org.jeecg.modules.base.service.IUserFactoryService;
import org.jeecg.modules.base.service.IUserGroupService;
import org.jeecg.modules.mdc.model.ProductionIdModel;
import org.jeecg.modules.mdc.service.IMdcUserProductionService;
import org.jeecg.modules.system.entity.*;
import org.jeecg.modules.system.model.DepartIdModel;
import org.jeecg.modules.base.model.FactoryIdModel;
@@ -104,6 +107,9 @@
    @Resource
    private IUserFactoryService userFactoryService;
    @Resource
    private IMdcUserProductionService userProductionService;
    @Resource
    private IUserGroupService userGroupService;
@@ -473,10 +479,10 @@
    @AutoLog(value = "用户表-查询指定用户和产线关联的数据")
    @ApiOperation(value = "用户表-查询指定用户和产线关联的数据", notes = "用户表-查询指定用户和产线关联的数据")
    @GetMapping(value = "/userProductionList")
    public Result<List<FactoryIdModel>> getUserProductionsList(@RequestParam(name = "userId", required = true) String userId) {
        Result<List<FactoryIdModel>> result = new Result<>();
    public Result<List<ProductionIdModel>> getUserProductionsList(@RequestParam(name = "userId", required = true) String userId) {
        Result<List<ProductionIdModel>> result = new Result<>();
        try {
            List<FactoryIdModel> proIdModelList = this.userFactoryService.queryFactoryIdsOfUser(userId);
            List<ProductionIdModel> proIdModelList = this.userProductionService.queryProductionIdsOfUser(userId);
            if (proIdModelList != null && !proIdModelList.isEmpty()) {
                result.setSuccess(true);
                result.setMessage("查找成功");