|
|
@ -2,6 +2,7 @@ package org.dromara.business.controller; |
|
|
|
|
|
|
|
import cn.dev33.satoken.annotation.SaCheckPermission; |
|
|
|
import cn.hutool.core.convert.Convert; |
|
|
|
import cn.hutool.core.util.ObjectUtil; |
|
|
|
import com.alibaba.fastjson.JSON; |
|
|
|
import com.alibaba.nacos.client.utils.TenantUtil; |
|
|
|
import io.swagger.v3.oas.annotations.Operation; |
|
|
@ -119,10 +120,12 @@ public class BusinessAlertController extends BaseController { |
|
|
|
*/ |
|
|
|
@Operation(summary ="预警推送-实时预警模块专用",description = "预警推送-实时预警模块专用") |
|
|
|
@GetMapping("/pushAlert") |
|
|
|
public R pushAlert(Long alertId,String deptId,String deptName) { |
|
|
|
public R pushAlert(Long alertId,@RequestParam(required = false) String deptId,@RequestParam(required = false)String deptName) { |
|
|
|
BusinessAlert businessAlert= businessAlertService.getBusinessAlert(alertId); |
|
|
|
if(!ObjectUtil.hasEmpty(deptId,deptName)){ |
|
|
|
businessAlert.setDeptName(deptName); |
|
|
|
businessAlert.setDeptId(deptId); |
|
|
|
} |
|
|
|
businessAlert.setCreateTime(new Date()); |
|
|
|
//businessAlert.setJobName(deptName + businessAlert.getLabelCn() + DateUtils.parseDateToStr("yyyy-MM-dd HH:mm:ss",businessAlert.getCreateTime()));
|
|
|
|
businessAlertService.updateBusinessAlert(businessAlert); |
|
|
|