lyh
2025-02-17 1dcf43467f34eb70002be3c2f3cd7605ceb5dcdd
lxzn-module-dnc/src/main/java/org/jeecg/modules/dnc/service/impl/DeviceInfoServiceImpl.java
@@ -22,6 +22,7 @@
import org.jeecg.modules.system.entity.MdcProductionEquipment;
import org.jeecg.modules.system.entity.SysUser;
import org.jeecg.modules.system.service.IMdcProductionService;
import org.jeecg.modules.system.service.IMdcUserProductionService;
import org.jeecg.modules.system.service.ISysUserService;
import org.jeecg.modules.dnc.response.DeviceCode;
import org.jeecg.modules.dnc.response.DeviceGroupCode;
@@ -68,7 +69,8 @@
    private IMdcEquipmentService mdcEquipmentService;
    @Autowired
    private IMdcProductionEquipmentService mdcProductionEquipmentService;
    @Autowired
    private IMdcUserProductionService mdcUserProductionService;
    @Override
    @Transactional(rollbackFor = {Exception.class})
    public boolean addDeviceInfo(DeviceInfo deviceInfo) {
@@ -243,13 +245,13 @@
    }
    @Override
    public List<UserDepartExt> getUserPermsList(Integer nodeType, String paramId) {
    public List<SysUser> getUserPermsList(Integer nodeType, String paramId) {
        if(!ValidateUtil.validateInteger(nodeType) || !ValidateUtil.validateString(paramId))
            return null;
        if(nodeType == 1) {
            return deviceGroupPermissionService.getUserPermsByGroupId(paramId);
            return mdcUserProductionService.getUserPermsByGroupId(paramId);
        }else if(nodeType == 2) {
            return devicePermissionService.getUserPermsByDeviceId(paramId);
            return mdcUserProductionService.getUserPermsByDeviceId(paramId);
        }else {
            return null;
        }
@@ -260,9 +262,9 @@
        if(!ValidateUtil.validateInteger(nodeType) || !ValidateUtil.validateString(paramId))
            return null;
        if(nodeType == 1) {
            return deviceGroupPermissionService.getUserNonPermsByGroupId(paramId);
            return mdcUserProductionService.getUserNonPermsByGroupId(paramId);
        }else if(nodeType == 2) {
            return devicePermissionService.getUserNonPermsByDeviceId(paramId);
            return mdcUserProductionService.getUserNonPermsByDeviceId(paramId);
        }else {
            return null;
        }