From 94148c9028829b5576a5dcbfba2c7fb9cf6443d3 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Mon, 27 Jul 2020 11:40:30 +0200 Subject: Add abuse messages management in my account --- .../shared-abuse-list/processed-abuse.model.ts | 25 ++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 client/src/app/shared/shared-abuse-list/processed-abuse.model.ts (limited to 'client/src/app/shared/shared-abuse-list/processed-abuse.model.ts') diff --git a/client/src/app/shared/shared-abuse-list/processed-abuse.model.ts b/client/src/app/shared/shared-abuse-list/processed-abuse.model.ts new file mode 100644 index 000000000..fce1a8db3 --- /dev/null +++ b/client/src/app/shared/shared-abuse-list/processed-abuse.model.ts @@ -0,0 +1,25 @@ +import { SafeHtml } from '@angular/platform-browser' +import { AdminAbuse } from '@shared/models' +import { Account } from '@app/shared/shared-main' + +// Don't use an abuse model because we need external services to compute some properties +// And this model is only used in this component +export type ProcessedAbuse = AdminAbuse & { + moderationCommentHtml?: string, + reasonHtml?: string + embedHtml?: SafeHtml + updatedAt?: Date + + // override bare server-side definitions with rich client-side definitions + reporterAccount?: Account + flaggedAccount?: Account + + truncatedCommentHtml?: string + commentHtml?: string + + video: AdminAbuse['video'] & { + channel: AdminAbuse['video']['channel'] & { + ownerAccount: Account + } + } +} -- cgit v1.2.3