mirror of
https://github.com/outline/outline.git
synced 2026-12-01 09:22:14 +03:00
chore: Soft delete webhooks (#3722)
This commit is contained in:
1 parent
8ebf6e884f
commit
f744d488f6
2 files changed
+15
-2
No files matched your search
@@ -0,0 +1,13 @@
|
||||
'use strict';
|
||||
|
||||
module.exports = {
|
||||
up: async (queryInterface, Sequelize) => {
|
||||
await queryInterface.addColumn("webhook_subscriptions", "deletedAt", {
|
||||
type: Sequelize.DATE,
|
||||
allowNull: true
|
||||
});
|
||||
},
|
||||
down: async () => {
|
||||
await queryInterface.removeColumn("webhook_subscriptions", "deletedAt");
|
||||
},
|
||||
};
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
import { Event } from "@server/types";
|
||||
import Team from "./Team";
|
||||
import User from "./User";
|
||||
import IdModel from "./base/IdModel";
|
||||
import ParanoidModel from "./base/ParanoidModel";
|
||||
import Fix from "./decorators/Fix";
|
||||
|
||||
@Table({
|
||||
@@ -19,7 +19,7 @@ import Fix from "./decorators/Fix";
|
||||
modelName: "webhook_subscription",
|
||||
})
|
||||
@Fix
|
||||
class WebhookSubscription extends IdModel {
|
||||
class WebhookSubscription extends ParanoidModel {
|
||||
@NotEmpty
|
||||
@Column
|
||||
name: string;
|
||||
|
||||
Reference in new issue
Block a user