ProductOption
ProductOption
A ProductOption is used to differentiate ProductVariants from one another.
Signature
class ProductOption extends VendureEntity implements Translatable, HasCustomFields, SoftDeletable {
constructor(input?: DeepPartial<ProductOption>)
@Column({ type: Date, nullable: true })
deletedAt: Date | null;
name: LocaleString;
@Column() code: string;
@OneToMany(type => ProductOptionTranslation, translation => translation.base, { eager: true })
translations: Array<Translation<ProductOption>>;
@Index()
@ManyToOne(type => ProductOptionGroup, group => group.options)
group: ProductOptionGroup;
@EntityId()
groupId: ID;
@ManyToMany(type => ProductVariant, variant => variant.options)
productVariants: ProductVariant[];
@Column(type => CustomProductOptionFields)
customFields: CustomProductOptionFields;
}
-
Extends:
VendureEntity
-
Implements:
Translatable
,HasCustomFields
,SoftDeletable