order
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
import { Entity, Index, ManyToOne, Property } from '@mikro-orm/core';
|
||||
import { Entity, Enum, Index, ManyToOne, Property } from '@mikro-orm/core';
|
||||
import { BaseEntity } from '../../../common/entities/base.entity';
|
||||
import { Order } from './order.entity';
|
||||
import { product } from 'src/modules/product/entities/product.entity';
|
||||
import { OrderItemStatus } from '../interface/order.interface';
|
||||
|
||||
@Entity({ tableName: 'order_items' })
|
||||
@Index({ properties: ['order'] })
|
||||
@@ -27,4 +28,7 @@ export class OrderItem extends BaseEntity {
|
||||
|
||||
@Property({ nullable: true })
|
||||
description?: string;
|
||||
|
||||
@Enum(() => OrderItemStatus)
|
||||
status!: OrderItemStatus;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user