Commit 4a276ca4 authored by 黎博's avatar 黎博

update

parent 867570df
...@@ -15,6 +15,7 @@ import java.util.HashMap; ...@@ -15,6 +15,7 @@ import java.util.HashMap;
import java.util.Map; import java.util.Map;
@Slf4j @Slf4j
@CrossOrigin
@RestController @RestController
@RequestMapping("/jira") @RequestMapping("/jira")
public class JiraWebhookController { public class JiraWebhookController {
...@@ -90,7 +91,7 @@ public class JiraWebhookController { ...@@ -90,7 +91,7 @@ public class JiraWebhookController {
if (dingRobot.getDingUrl() == null) { if (dingRobot.getDingUrl() == null) {
return JsonResult.buildErrorStateResult("钉钉url不能为空!", false); return JsonResult.buildErrorStateResult("钉钉url不能为空!", false);
} }
return JsonResult.buildSuccessResult(dingRobotService.save(dingRobot)); return JsonResult.buildSuccessResult(dingRobotService.updateById(dingRobot));
} }
/** /**
...@@ -98,7 +99,7 @@ public class JiraWebhookController { ...@@ -98,7 +99,7 @@ public class JiraWebhookController {
* @param projectRobotId 项目机器人实体id * @param projectRobotId 项目机器人实体id
* @return * @return
*/ */
@PostMapping("/delete/robot") @GetMapping("/delete/robot")
public JsonResult deleteProjectRobot(Integer projectRobotId) { public JsonResult deleteProjectRobot(Integer projectRobotId) {
if (dingRobotService.getById(projectRobotId) == null) { if (dingRobotService.getById(projectRobotId) == null) {
return JsonResult.buildErrorStateResult("项目机器人不存在!", false); return JsonResult.buildErrorStateResult("项目机器人不存在!", false);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment