chore: add business logic
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { Column, Entity, ManyToOne } from "typeorm";
|
||||
import { Column, Entity, JoinTable, ManyToMany, ManyToOne } from "typeorm";
|
||||
|
||||
import { SubscriptionPlan } from "./subscription.entity";
|
||||
import { BaseEntity } from "../../../common/entities/base.entity";
|
||||
@@ -28,6 +28,13 @@ export class UserSubscription extends BaseEntity {
|
||||
@Column({ type: "text", nullable: false })
|
||||
description: string;
|
||||
|
||||
@Column({ type: "varchar", length: 250, unique: true, nullable: true })
|
||||
slug: string;
|
||||
|
||||
@Column({ type: "enum", enum: SubscriptionStatus, default: SubscriptionStatus.INACTIVE })
|
||||
status: SubscriptionStatus;
|
||||
|
||||
@ManyToMany(() => User)
|
||||
@JoinTable()
|
||||
staff: User[];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user