Skip to main content

Class: OrderEditService

Hierarchy

  • Copy to Clipboard

    Copy to Clipboard

Constructors

constructor

new OrderEditService(Copy to Clipboard)

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Overrides

TransactionBaseService.constructor

Defined in

packages/medusa/src/services/order-edit.ts:65

Properties

__configModule__

Copy to Clipboard Copy to Clipboard Copy to Clipboard __configModule__: Copy to Clipboard<Copy to Clipboard, Copy to Clipboard>

Inherited from

TransactionBaseService.__configModule__

Defined in

packages/medusa/src/interfaces/transaction-base-service.ts:10


__container__

Copy to Clipboard Copy to Clipboard __container__: Copy to Clipboard

Inherited from

TransactionBaseService.__container__

Defined in

packages/medusa/src/interfaces/transaction-base-service.ts:9


eventBusService_

Copy to Clipboard Copy to Clipboard eventBusService_: Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:60


lineItemAdjustmentService_

Copy to Clipboard Copy to Clipboard lineItemAdjustmentService_: Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:62


lineItemService_

Copy to Clipboard Copy to Clipboard lineItemService_: Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:59


manager_

Copy to Clipboard Copy to Clipboard manager_: Copy to Clipboard

Overrides

TransactionBaseService.manager_

Defined in

packages/medusa/src/services/order-edit.ts:52


orderEditItemChangeService_

Copy to Clipboard Copy to Clipboard orderEditItemChangeService_: Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:63


orderEditRepository_

Copy to Clipboard Copy to Clipboard orderEditRepository_: typeof Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:55


orderService_

Copy to Clipboard Copy to Clipboard orderService_: Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:57


taxProviderService_

Copy to Clipboard Copy to Clipboard taxProviderService_: Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:61


totalsService_

Copy to Clipboard Copy to Clipboard totalsService_: Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:58


transactionManager_

Copy to Clipboard transactionManager_: Copy to Clipboard | Copy to Clipboard

Overrides

TransactionBaseService.transactionManager_

Defined in

packages/medusa/src/services/order-edit.ts:53


Events

Copy to Clipboard Copy to Clipboard Events: Copy to Clipboard

Type declaration

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:43

Methods

addLineItem

addLineItem(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:547


atomicPhase_

Copy to Clipboard atomicPhase_<Copy to Clipboard, Copy to Clipboard>(Copy to Clipboard, Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Wraps some work within a transactional block. If the service already has a transaction manager attached this will be reused, otherwise a new transaction manager is created.

Type parameters

Name
Copy to Clipboard
Copy to Clipboard

Parameters

NameTypeDescription
Copy to Clipboard(Copy to Clipboard: Copy to Clipboard) => Copy to Clipboard<Copy to Clipboard>the transactional work to be done
Copy to ClipboardCopy to Clipboard | (Copy to Clipboard: Copy to Clipboard) => Copy to Clipboard<Copy to Clipboard | Copy to Clipboard>the isolation level to be used for the work.
Copy to Clipboard(Copy to Clipboard: Copy to Clipboard) => Copy to Clipboard<Copy to Clipboard | Copy to Clipboard>Potential error handler

Returns

Copy to Clipboard<Copy to Clipboard>

the result of the transactional work

Inherited from

TransactionBaseService.atomicPhase_

Defined in

packages/medusa/src/interfaces/transaction-base-service.ts:48


cancel

cancel(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:691


confirm

confirm(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:730


create

create(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:207


decline

decline(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:309


decorateTotals

decorateTotals(Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:533


delete

delete(Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:285


deleteClonedItems

Copy to Clipboard deleteClonedItems(Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:803


deleteItemChange

deleteItemChange(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:619


getTotals

getTotals(Copy to Clipboard): Copy to Clipboard<{ Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard | Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard }>

Compute and return the different totals from the order edit id

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<{ Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard | Copy to Clipboard ; Copy to Clipboard: Copy to Clipboard }>

Defined in

packages/medusa/src/services/order-edit.ts:148


list

list(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard[]>

Parameters

NameType
Copy to ClipboardCopy to Clipboard<Copy to Clipboard>
Copy to ClipboardCopy to Clipboard<Copy to Clipboard>

Returns

Copy to Clipboard<Copy to Clipboard[]>

Defined in

packages/medusa/src/services/order-edit.ts:136


listAndCount

listAndCount(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<[Copy to Clipboard[], Copy to Clipboard]>

Parameters

NameType
Copy to ClipboardCopy to Clipboard<Copy to Clipboard> & { Copy to Clipboard: Copy to Clipboard }
Copy to ClipboardCopy to Clipboard<Copy to Clipboard>

Returns

Copy to Clipboard<[Copy to Clipboard[], Copy to Clipboard]>

Defined in

packages/medusa/src/services/order-edit.ts:112


refreshAdjustments

refreshAdjustments(Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:490


removeLineItem

removeLineItem(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:433


requestConfirmation

requestConfirmation(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:651


retrieve

retrieve(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard<Copy to Clipboard>

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:90


retrieveActive

Copy to Clipboard retrieveActive(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard | Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard<Copy to Clipboard>

Returns

Copy to Clipboard<Copy to Clipboard | Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:782


shouldRetryTransaction_

Copy to Clipboard shouldRetryTransaction_(Copy to Clipboard): Copy to Clipboard

Parameters

NameType
Copy to ClipboardCopy to Clipboard<Copy to Clipboard, Copy to Clipboard> | { Copy to Clipboard: Copy to Clipboard }

Returns

Copy to Clipboard

Inherited from

TransactionBaseService.shouldRetryTransaction_

Defined in

packages/medusa/src/interfaces/transaction-base-service.ts:29


update

update(Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to Clipboard{ toString?: {} | undefined; toDateString?: {} | undefined; toTimeString?: {} | undefined; toLocaleString?: {} | undefined; toLocaleDateString?: {} | undefined; toLocaleTimeString?: {} | undefined; ... 37 more ...; [Symbol.toPrimitive]?: {} | undefined; }
Copy to ClipboardCopy to Clipboard
Copy to Clipboard(Copy to Clipboard | { type?: OrderEditItemChangeType | undefined; order_edit_id?: string | undefined; order_edit?: { order_id?: string | undefined; order?: { readonly object?: "order" | undefined; ... 51 more ...; updated_at?: { ...; } | undefined; } | undefined; ... 27 more ...; updated_at?: { ...; } | undefined; } | undefined; ... 7 ...)[]
Copy to Clipboard{ toString?: {} | undefined; toDateString?: {} | undefined; toTimeString?: {} | undefined; toLocaleString?: {} | undefined; toLocaleDateString?: {} | undefined; toLocaleTimeString?: {} | undefined; ... 37 more ...; [Symbol.toPrimitive]?: {} | undefined; }
Copy to ClipboardCopy to Clipboard
Copy to Clipboard{ toString?: {} | undefined; toDateString?: {} | undefined; toTimeString?: {} | undefined; toLocaleString?: {} | undefined; toLocaleDateString?: {} | undefined; toLocaleTimeString?: {} | undefined; ... 37 more ...; [Symbol.toPrimitive]?: {} | undefined; }
Copy to ClipboardCopy to Clipboard
Copy to Clipboard{ toString?: {} | undefined; toDateString?: {} | undefined; toTimeString?: {} | undefined; toLocaleString?: {} | undefined; toLocaleDateString?: {} | undefined; toLocaleTimeString?: {} | undefined; ... 37 more ...; [Symbol.toPrimitive]?: {} | undefined; }
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to Clipboard(Copy to Clipboard | { cart_id?: string | undefined; cart?: { readonly object?: "cart" | undefined; email?: string | undefined; billing_address_id?: string | undefined; billing_address?: { customer_id?: string | ... 1 more ... | undefined; ... 16 more ...; updated_at?: { ...; } | undefined; } | undefined; ... 36 more ...; updated_at?: {...)[]
Copy to Clipboard{ readonly object?: "order" | undefined; status?: OrderStatus | undefined; fulfillment_status?: FulfillmentStatus | undefined; payment_status?: PaymentStatus | undefined; ... 48 more ...; updated_at?: { ...; } | undefined; }
Copy to ClipboardCopy to Clipboard
Copy to Clipboard{ type?: PaymentCollectionType | undefined; status?: PaymentCollectionStatus | undefined; description?: string | null | undefined; ... 13 more ...; updated_at?: { ...; } | undefined; }
Copy to ClipboardCopy to Clipboard
Copy to Clipboard{ toString?: {} | undefined; toDateString?: {} | undefined; toTimeString?: {} | undefined; toLocaleString?: {} | undefined; toLocaleDateString?: {} | undefined; toLocaleTimeString?: {} | undefined; ... 37 more ...; [Symbol.toPrimitive]?: {} | undefined; }
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard | Copy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to Clipboard{ toString?: {} | undefined; toDateString?: {} | undefined; toTimeString?: {} | undefined; toLocaleString?: {} | undefined; toLocaleDateString?: {} | undefined; toLocaleTimeString?: {} | undefined; ... 37 more ...; [Symbol.toPrimitive]?: {} | undefined; }
Copy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:256


updateLineItem

updateLineItem(Copy to Clipboard, Copy to Clipboard, Copy to Clipboard): Copy to Clipboard<Copy to Clipboard>

Create or update order edit item change line item and apply the quantity

  • If the item change already exists then update the quantity of the line item as well as the line adjustments
  • If the item change does not exist then create the item change of type update and apply the quantity as well as update the line adjustments

Parameters

NameType
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard<Copy to Clipboard>

Defined in

packages/medusa/src/services/order-edit.ts:360


withTransaction

withTransaction(Copy to Clipboard): Copy to Clipboard

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard

Inherited from

TransactionBaseService.withTransaction

Defined in

packages/medusa/src/interfaces/transaction-base-service.ts:13


isOrderEditActive

Copy to Clipboard Copy to Clipboard isOrderEditActive(Copy to Clipboard): Copy to Clipboard

Parameters

NameType
Copy to ClipboardCopy to Clipboard

Returns

Copy to Clipboard

Defined in

packages/medusa/src/services/order-edit.ts:849