diff options
Diffstat (limited to 'models')
-rw-r--r-- | models/migrations/v161.go | 20 | ||||
-rw-r--r-- | models/migrations/v162.go | 20 | ||||
-rw-r--r-- | models/webhook.go | 19 |
3 files changed, 32 insertions, 27 deletions
diff --git a/models/migrations/v161.go b/models/migrations/v161.go index 4ca9f01218..7ef06b4c26 100644 --- a/models/migrations/v161.go +++ b/models/migrations/v161.go @@ -19,18 +19,20 @@ func convertTaskTypeToString(x *xorm.Engine) error { MSTEAMS FEISHU MATRIX + WECHATWORK ) hookTaskTypes := map[int]string{ - GITEA: "gitea", - GOGS: "gogs", - SLACK: "slack", - DISCORD: "discord", - DINGTALK: "dingtalk", - TELEGRAM: "telegram", - MSTEAMS: "msteams", - FEISHU: "feishu", - MATRIX: "matrix", + GITEA: "gitea", + GOGS: "gogs", + SLACK: "slack", + DISCORD: "discord", + DINGTALK: "dingtalk", + TELEGRAM: "telegram", + MSTEAMS: "msteams", + FEISHU: "feishu", + MATRIX: "matrix", + WECHATWORK: "wechatwork", } type HookTask struct { diff --git a/models/migrations/v162.go b/models/migrations/v162.go index 9dd175cd38..cf2baadbca 100644 --- a/models/migrations/v162.go +++ b/models/migrations/v162.go @@ -19,18 +19,20 @@ func convertWebhookTaskTypeToString(x *xorm.Engine) error { MSTEAMS FEISHU MATRIX + WECHATWORK ) hookTaskTypes := map[int]string{ - GITEA: "gitea", - GOGS: "gogs", - SLACK: "slack", - DISCORD: "discord", - DINGTALK: "dingtalk", - TELEGRAM: "telegram", - MSTEAMS: "msteams", - FEISHU: "feishu", - MATRIX: "matrix", + GITEA: "gitea", + GOGS: "gogs", + SLACK: "slack", + DISCORD: "discord", + DINGTALK: "dingtalk", + TELEGRAM: "telegram", + MSTEAMS: "msteams", + FEISHU: "feishu", + MATRIX: "matrix", + WECHATWORK: "wechatwork", } type Webhook struct { diff --git a/models/webhook.go b/models/webhook.go index 29cfcf6ed4..9c8c0a568b 100644 --- a/models/webhook.go +++ b/models/webhook.go @@ -114,15 +114,16 @@ type HookType = string // Types of webhooks const ( - GITEA HookType = "gitea" - GOGS HookType = "gogs" - SLACK HookType = "slack" - DISCORD HookType = "discord" - DINGTALK HookType = "dingtalk" - TELEGRAM HookType = "telegram" - MSTEAMS HookType = "msteams" - FEISHU HookType = "feishu" - MATRIX HookType = "matrix" + GITEA HookType = "gitea" + GOGS HookType = "gogs" + SLACK HookType = "slack" + DISCORD HookType = "discord" + DINGTALK HookType = "dingtalk" + TELEGRAM HookType = "telegram" + MSTEAMS HookType = "msteams" + FEISHU HookType = "feishu" + MATRIX HookType = "matrix" + WECHATWORK HookType = "wechatwork" ) // HookStatus is the status of a web hook |