Skip to main content

ProvinceService

ProvinceService

Contains methods relating to Province entities.

Signature
class ProvinceService {
constructor(connection: TransactionalConnection, listQueryBuilder: ListQueryBuilder, translatableSaver: TranslatableSaver, eventBus: EventBus, translator: TranslatorService)
findAll(ctx: RequestContext, options?: ListQueryOptions<Province>, relations: RelationPaths<Province> = []) => Promise<PaginatedList<Translated<Province>>>;
findOne(ctx: RequestContext, provinceId: ID, relations: RelationPaths<Province> = []) => Promise<Translated<Province> | undefined>;
create(ctx: RequestContext, input: CreateProvinceInput) => Promise<Translated<Province>>;
update(ctx: RequestContext, input: UpdateProvinceInput) => Promise<Translated<Province>>;
delete(ctx: RequestContext, id: ID) => Promise<DeletionResponse>;
}

constructor

method
(connection: TransactionalConnection, listQueryBuilder: ListQueryBuilder, translatableSaver: TranslatableSaver, eventBus: EventBus, translator: TranslatorService) => ProvinceService

findAll

method
(ctx: RequestContext, options?: ListQueryOptions<Province>, relations: RelationPaths<Province> = []) => Promise<PaginatedList<Translated<Province>>>

findOne

method
(ctx: RequestContext, provinceId: ID, relations: RelationPaths<Province> = []) => Promise<Translated<Province> | undefined>

create

method
(ctx: RequestContext, input: CreateProvinceInput) => Promise<Translated<Province>>

update

method
(ctx: RequestContext, input: UpdateProvinceInput) => Promise<Translated<Province>>

delete

method
(ctx: RequestContext, id: ID) => Promise<DeletionResponse>