mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-22 12:45:46 +08:00
更改:webhook更新返回结构体
This commit is contained in:
@@ -27,7 +27,7 @@ class Api::V1::Issues::JournalsController < Api::V1::BaseController
|
||||
end
|
||||
|
||||
def destroy
|
||||
TouchWebhookJob.perform_later('IssueComment', @issue&.id, current_user.id, @journal.id, 'deleted', JSON.parse(@journal.to_builder.target!))
|
||||
TouchWebhookJob.set(wait: 5.seconds).perform_later('IssueComment', @issue&.id, current_user.id, @journal.id, 'deleted', JSON.parse(@journal.to_builder.target!))
|
||||
if @journal.destroy!
|
||||
render_ok
|
||||
else
|
||||
|
||||
@@ -62,7 +62,7 @@ class JournalsController < ApplicationController
|
||||
|
||||
def destroy
|
||||
if @journal.destroy #如果有子评论,子评论删除吗?
|
||||
TouchWebhookJob.perform_later('PullRequestComment', @issue&.id, current_user.id, @journal.id, 'deleted', JSON.parse(@journal.to_builder.target!))
|
||||
TouchWebhookJob.set(wait: 5.seconds).perform_later('PullRequestComment', @issue&.id, current_user.id, @journal.id, 'deleted', JSON.parse(@journal.to_builder.target!))
|
||||
Journal.children_journals(@journal.id).destroy_all
|
||||
normal_status(0, "评论删除成功")
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user