remove user relation
This commit is contained in:
@ -11,7 +11,6 @@ import {
|
||||
} from 'typeorm';
|
||||
|
||||
import { Status } from '../types/status';
|
||||
import { User } from './users';
|
||||
import { Supplier } from './supplier';
|
||||
import { AssetCategory } from './asset_category';
|
||||
|
||||
@ -35,7 +34,7 @@ export class Goods {
|
||||
@Column({
|
||||
nullable: false,
|
||||
length: 64,
|
||||
unique: true,
|
||||
unique: true,
|
||||
})
|
||||
item_code: string;
|
||||
|
||||
@ -63,20 +62,12 @@ export class Goods {
|
||||
})
|
||||
category_id: string;
|
||||
|
||||
@ManyToOne(() => User, (user) => user.id, { nullable: true })
|
||||
@JoinColumn({ name: 'created_by' })
|
||||
createdBy: User;
|
||||
|
||||
@Index()
|
||||
@Column({
|
||||
nullable: true,
|
||||
type: 'uuid',
|
||||
})
|
||||
created_by: string;
|
||||
|
||||
@ManyToOne(() => User, (user) => user.id, { nullable: true })
|
||||
@JoinColumn({ name: 'updated_by' })
|
||||
updatedBy: User;
|
||||
created_by: string;
|
||||
|
||||
@Index()
|
||||
@Column({
|
||||
@ -88,12 +79,11 @@ export class Goods {
|
||||
@ManyToOne(() => Supplier, { nullable: false })
|
||||
@JoinColumn({ name: 'supplier_id' })
|
||||
supplier: Supplier;
|
||||
|
||||
|
||||
@Column({
|
||||
nullable: false,
|
||||
type: 'uuid',
|
||||
})
|
||||
|
||||
supplier_id: string;
|
||||
|
||||
@Column({
|
||||
|
||||
Reference in New Issue
Block a user