add: member by superrior
This commit is contained in:
@@ -13,7 +13,7 @@ import { ProductSubCategories } from './product-sub-category.entity';
|
||||
import { BaseModel } from '../../config/basemodel.entity';
|
||||
|
||||
@Entity()
|
||||
export class Product extends BaseModel{
|
||||
export class Product extends BaseModel {
|
||||
@PrimaryGeneratedColumn('uuid')
|
||||
id: string;
|
||||
|
||||
@@ -30,13 +30,17 @@ export class Product extends BaseModel{
|
||||
price: number;
|
||||
|
||||
@Column({
|
||||
nullable:true
|
||||
nullable: true,
|
||||
})
|
||||
basePrice: number;
|
||||
|
||||
@ManyToOne(
|
||||
() => ProductSubCategories,
|
||||
(subCategories) => subCategories.category,
|
||||
() => {
|
||||
return ProductSubCategories;
|
||||
},
|
||||
(subCategories) => {
|
||||
return subCategories.product;
|
||||
},
|
||||
)
|
||||
subCategories: ProductSubCategories;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user