reorganizing

This commit is contained in:
rubikscraft
2022-03-03 22:48:03 +01:00
parent 59c50d9236
commit 0ac46696c8
29 changed files with 42 additions and 32 deletions

View File

@@ -0,0 +1,20 @@
import { EUser } from 'picsur-shared/dist/entities/user.entity';
import { Column, Entity, Index, PrimaryGeneratedColumn } from 'typeorm';
// Different data for public and private
@Entity()
export class EUserBackend extends EUser {
@PrimaryGeneratedColumn()
override id?: number;
@Index()
@Column({ unique: true })
override username: string;
@Column({ default: false })
override isAdmin: boolean;
@Column({ select: false })
override password?: string;
}