fix admn controller
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Column, CreateDateColumn, Entity, ManyToOne, PrimaryGeneratedColumn, UpdateDateColumn } from 'typeorm';
|
||||
import type { Relation } from 'typeorm';
|
||||
import { User } from './User.js';
|
||||
import { dateTimeColumnType } from '../utils/db-column-types.js';
|
||||
|
||||
@Entity('merchants')
|
||||
export class Merchant {
|
||||
@@ -19,12 +19,12 @@ export class Merchant {
|
||||
@Column({ type: 'boolean', default: true })
|
||||
isActive!: boolean;
|
||||
|
||||
@CreateDateColumn({ type: 'datetime' })
|
||||
@CreateDateColumn({ type: dateTimeColumnType })
|
||||
createdAt!: Date;
|
||||
|
||||
@UpdateDateColumn({ type: 'datetime' })
|
||||
@UpdateDateColumn({ type: dateTimeColumnType })
|
||||
updatedAt!: Date;
|
||||
|
||||
@ManyToOne(() => User, { onDelete: 'CASCADE' })
|
||||
user!: Relation<User>;
|
||||
user!: User;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user