Merge branch 'master' into docker_package

This commit is contained in:
wangliwen 2022-07-27 17:10:21 +08:00
commit 7bacc9b245
5 changed files with 16 additions and 13 deletions

View File

@ -158,7 +158,7 @@ public class AbilityCenterControllerV2 {
tAbilityApplicationDTO.setApproveStatus("审核中"); tAbilityApplicationDTO.setApproveStatus("审核中");
tAbilityApplicationDTO.setDelFlag(0); tAbilityApplicationDTO.setDelFlag(0);
// v2 新增字段 // v2 新增字段
tAbilityApplicationDTO.setCameraList(index.get("cameraId") == null ? null : JSON.toJSONString(index.get("cameraId"))); tAbilityApplicationDTO.setCameraList(index.get("channelId") == null ? null : JSON.toJSONString(index));
tAbilityApplicationDTO.setTitle(abilityBatchApplicationDTO.getTitle()); tAbilityApplicationDTO.setTitle(abilityBatchApplicationDTO.getTitle());
tAbilityApplicationDTO.setApplicationBackground(abilityBatchApplicationDTO.getApplicationBackground()); tAbilityApplicationDTO.setApplicationBackground(abilityBatchApplicationDTO.getApplicationBackground());
tAbilityApplicationDTO.setApplicationScene(abilityBatchApplicationDTO.getApplicationScene()); tAbilityApplicationDTO.setApplicationScene(abilityBatchApplicationDTO.getApplicationScene());
@ -262,4 +262,5 @@ public class AbilityCenterControllerV2 {
}); });
} }
} }
} }

View File

@ -277,12 +277,12 @@ public class ActHistoryService {
for (ProcessInstanceDTO dto : list) { for (ProcessInstanceDTO dto : list) {
List<TAbilityApplicationDTO> abilityApplicationDTO = tAbilityApplicationService.getByInstanceId(dto.getProcessInstanceId()); // 获取申请表单 List<TAbilityApplicationDTO> abilityApplicationDTO = tAbilityApplicationService.getByInstanceId(dto.getProcessInstanceId()); // 获取申请表单
if (abilityApplicationDTO != null && !abilityApplicationDTO.isEmpty()) { if (abilityApplicationDTO != null && !abilityApplicationDTO.isEmpty()) {
if (abilityApplicationDTO.stream().filter(index -> StringUtils.isNotEmpty(index.getCameraList())).findAny().isPresent()) { // 存在摄像头 if (abilityApplicationDTO.stream().anyMatch(index -> StringUtils.isNotEmpty(index.getCameraList()))) { // 存在摄像头
dto.setName("申请摄像头列表"); dto.setName("申请摄像头列表");
dto.setResourceId(null); dto.setResourceId(null);
} else { } else {
StringBuffer stringBuffer = new StringBuffer(); StringBuffer stringBuffer = new StringBuffer();
abilityApplicationDTO.stream().map(TAbilityApplicationDTO::getSystem).filter(index -> StringUtils.isNotEmpty(index)).forEach(index -> { abilityApplicationDTO.stream().map(TAbilityApplicationDTO::getSystem).filter(StringUtils::isNotEmpty).forEach(index -> {
stringBuffer.append(index); stringBuffer.append(index);
stringBuffer.append(","); stringBuffer.append(",");
}); });

View File

@ -225,10 +225,12 @@ public class TAbilityApplicationController {
if (StringUtils.isEmpty(index_.getCameraList())) { if (StringUtils.isEmpty(index_.getCameraList())) {
return; return;
} }
List<CameraChannelDto1> channelDto1s = cameraChannelMapper.selectByChannelCode(index_.getCameraList().replaceAll("\"", "")); cameraList.add(JSON.parseObject(index_.getCameraList()));
if (!channelDto1s.isEmpty()) { //
cameraList.add(channelDto1s.get(0)); //List<CameraChannelDto1> channelDto1s = cameraChannelMapper.selectByChannelCode(index_.getCameraList().replaceAll("\"", ""));
} //if (!channelDto1s.isEmpty()) {
// cameraList.add(channelDto1s.get(0));
//}
}); });
camera = cameraList; camera = cameraList;

View File

@ -24,6 +24,7 @@ import org.activiti.engine.TaskService;
import org.activiti.engine.delegate.*; import org.activiti.engine.delegate.*;
import org.activiti.engine.delegate.event.ActivitiEvent; import org.activiti.engine.delegate.event.ActivitiEvent;
import org.activiti.engine.delegate.event.ActivitiEventListener; import org.activiti.engine.delegate.event.ActivitiEventListener;
import org.apache.commons.lang3.ObjectUtils;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
@ -266,10 +267,11 @@ public class CorrectionListener implements TaskListener, ExecutionListener, Acti
logger.info("-------能力申请code-------"); logger.info("-------能力申请code-------");
ResourceEntity resourceEntity = resourceService.selectById(abilityApplicationDTO.getResourceId()); ResourceEntity resourceEntity = resourceService.selectById(abilityApplicationDTO.getResourceId());
if (ObjectUtils.allNotNull(resourceEntity)) {
//没有groupid当做没有接口直接跳过 //没有groupid当做没有接口直接跳过
if (resourceEntity.getGroupId() == null) if (resourceEntity.getGroupId() == null)
return; return;
}
String code = UUID.randomUUID().toString(); String code = UUID.randomUUID().toString();
apiGatewayService.subscribeCode(String.valueOf(abilityApplicationDTO.getId()), code); apiGatewayService.subscribeCode(String.valueOf(abilityApplicationDTO.getId()), code);

View File

@ -1,7 +1,5 @@
package io.renren.modules.security.oauth2; package io.renren.modules.security.oauth2;
import javax.servlet.http.HttpServletRequest;
public interface SSOValidator { public interface SSOValidator {
String validatePrincipal(String requestURL); String validatePrincipal(String requestURL);