|
@@ -43,6 +43,7 @@ import org.springframework.web.bind.annotation.*;
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
import java.util.*;
|
|
|
import java.util.concurrent.CompletableFuture;
|
|
|
+import java.util.concurrent.ExecutionException;
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
import static com.sooka.sponest.event.utils.EventConstants.*;
|
|
@@ -209,7 +210,7 @@ public class CentereventTEventcatalogueController extends BaseController {
|
|
|
centereventTEventcatalogue.setEventStatusValue("forest_event_status_2");
|
|
|
centereventTEventcatalogue.setEventStatus("签收");
|
|
|
SysUser user = SecurityUtils.getLoginUser().getSysUser();
|
|
|
- CompletableFuture.runAsync(() -> {
|
|
|
+ CompletableFuture<Void> future = CompletableFuture.runAsync(() -> {
|
|
|
SysUser sysUser = SpringUtils.getBean(RemoteUserService.class).selectById(centereventTEventcatalogue.getUpdateBy()).getData();
|
|
|
if (null != sysUser) {
|
|
|
String message = "您申请办结的事件经县(市/区)指挥中心审核,未达到归档标准,请重新处置!如有疑问请联系县(市/区)指挥中心。审核人:"
|
|
@@ -217,6 +218,13 @@ public class CentereventTEventcatalogueController extends BaseController {
|
|
|
RemoteApiUtil.getInstance().sendMessage(new HashSet<>(Arrays.asList(sysUser.getPhonenumber())), message, centereventTEventcatalogue.getEventCode(), centereventTEventcatalogue.getEventName());
|
|
|
}
|
|
|
});
|
|
|
+ try {
|
|
|
+ future.get();
|
|
|
+ } catch (InterruptedException e) {
|
|
|
+ logger.error(e.getMessage());
|
|
|
+ } catch (ExecutionException e) {
|
|
|
+ logger.error(e.getMessage());
|
|
|
+ }
|
|
|
}
|
|
|
// 审核后变更消息状态为已读
|
|
|
RemoteApiUtil.getInstance().updateMessageByEventCode(centereventTEventcatalogue.getEventCode());
|
|
@@ -275,7 +283,7 @@ public class CentereventTEventcatalogueController extends BaseController {
|
|
|
// 确认时更改附件路径
|
|
|
try {
|
|
|
if ("qr".equals(centereventtDeptEventBO.getEventStatus())) {
|
|
|
- CompletableFuture.runAsync(() -> {
|
|
|
+ CompletableFuture<Void> future = CompletableFuture.runAsync(() -> {
|
|
|
Map<String, String> paramMap = SpringUtils.getBean(RemoteConfigService.class).remotegetConfigMap(Arrays.asList(FILE_PREFIX_LOCAL, FILE_PREFIX_HIK1, FILE_PREFIX_HIK2, FILE_PREFIX_DH1, FILE_PREFIX_DH2)).getData();
|
|
|
paramMap.put("czlx", centereventtDeptEventBO.getCzlx());
|
|
|
CentereventTFireLog log = centereventTFireLogService.selectFirstCentereventTFireLogByEventCode(centereventtDeptEventBO.getEventCode());
|
|
@@ -283,6 +291,7 @@ public class CentereventTEventcatalogueController extends BaseController {
|
|
|
paramMap.put("token", RemoteApiUtil.getInstance().getToken());// 大华token
|
|
|
remoteDataService.updateAttach(paramMap);
|
|
|
});
|
|
|
+ future.get();
|
|
|
}
|
|
|
} catch (Exception e) {
|
|
|
logger.error(e.getMessage());
|
|
@@ -311,9 +320,9 @@ public class CentereventTEventcatalogueController extends BaseController {
|
|
|
Map<String, String> paramMap = SpringUtils.getBean(RemoteConfigService.class).remotegetConfigMap(Arrays.asList(FILE_PREFIX_LOCAL, FILE_PREFIX_HIK1, FILE_PREFIX_HIK2, FILE_PREFIX_DH1, FILE_PREFIX_DH2)).getData();
|
|
|
paramMap.put("token", RemoteApiUtil.getInstance().getToken());// 大华token
|
|
|
List<Map<String, Object>> list = centereventTEventcatalogueService.selectFailUpattah();
|
|
|
- for (Map map:list) {
|
|
|
+ for (Map map : list) {
|
|
|
paramMap.put("czlx", "AI");
|
|
|
- paramMap.put("busId", MapUtils.getString(map,"busId"));
|
|
|
+ paramMap.put("busId", MapUtils.getString(map, "busId"));
|
|
|
remoteDataService.updateAttach(paramMap);
|
|
|
}
|
|
|
return AjaxResult.success();
|