ProductOptionService

ProductOptionService

Contains methods relating to ProductOption entities.

Signature

class ProductOptionService {
  constructor(connection: TransactionalConnection, translatableSaver: TranslatableSaver, customFieldRelationService: CustomFieldRelationService)
  findAll(ctx: RequestContext) => Promise<Array<Translated<ProductOption>>>;
  findOne(ctx: RequestContext, id: ID) => Promise<Translated<ProductOption> | undefined>;
  async create(ctx: RequestContext, group: ProductOptionGroup | ID, input: CreateGroupOptionInput | CreateProductOptionInput) => Promise<Translated<ProductOption>>;
  async update(ctx: RequestContext, input: UpdateProductOptionInput) => Promise<Translated<ProductOption>>;
}

Members

constructor

method
type:
(connection: TransactionalConnection, translatableSaver: TranslatableSaver, customFieldRelationService: CustomFieldRelationService) => ProductOptionService

findAll

method
type:
(ctx: RequestContext) => Promise<Array<Translated<ProductOption>>>

findOne

method
type:
(ctx: RequestContext, id: ID) => Promise<Translated<ProductOption> | undefined>

create

async method
type:
(ctx: RequestContext, group: ProductOptionGroup | ID, input: CreateGroupOptionInput | CreateProductOptionInput) => Promise<Translated<ProductOption>>

update

async method
type:
(ctx: RequestContext, input: UpdateProductOptionInput) => Promise<Translated<ProductOption>>