Plentymarkets interface documentation

Code

Contracts

CouponCampaignCodeRepositoryContract

This interface allows you to get and create coupon codes.

Namespace

Plenty\Modules\Order\Coupon\Campaign\Code\Contracts

Methods
public getByCode($code, $with = []):Plenty\Modules\Order\Coupon\Campaign\Code\Models\CouponCampaignCode
Return type: CouponCampaignCode

Gets a coupon code. The code string must be specified.

Parameters

Name

Type

Description

$code

string

$with

array

public deleteCode($code, $withoutUsed = false):bool

Delete a coupon code.

Parameters

Name

Type

Description

$code

string

$withoutUsed

bool

public create($data):Plenty\Modules\Order\Coupon\Campaign\Code\Models\CouponCampaignCode
Return type: CouponCampaignCode

Creates a coupon code.

Parameters

Name

Type

Description

$data

array

public setDisabledByCode($code, $disabled):int

Disable or enable coupon

Parameters

Name

Type

Description

$code

string

$disabled

int

CouponCodeRepositoryContract

The CouponCodeRepositoryContract is the interface for the coupon code repository. This interface allows you to redeem coupons.

Namespace

Plenty\Modules\Order\Coupon\Code\Contracts

Methods
public redeem($orderId, $coupon):bool

Redeem coupon codes

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$coupon

string

The coupon code to be redeemed

Models

CouponCampaignCode

The CouponCampaignCode model contains information about coupon codes. Each code belongs to one campaign only.

Namespace

Plenty\Modules\Order\Coupon\Campaign\Code\Models

Properties
Name Type Description

code

string

The coupon code

campaignId

int

The ID of the campaign that the code belongs to

disable

int

Flag that indicates if a code is active or deactivated. <ul><li>True = the code is deactivated</li> <li>False = the code is active</li></ul>

consumed

int

Flag that indicates if a code was redeemed or not. <ul><li>True = the code was redeemed</li> <li>False = the code is not redeemed</li></ul>

usedCount

int

How many times a code has been redeemed

usedAmount

float

The amount that is already redeemed. The total amount that can be redeemed is defined in the campaign as coupon value, because the value applies to all codes of a campaign.

generatedAt

Carbon

The date and time that the code was generated

lastUsedAt

Carbon

The date and time that the code was redeemed last. This date will be set if the coupon amount has not been fully used.

consumedAt

Carbon

The date and time that the coupon amount of this code was fully consumed

expiresAt

Carbon

The date and time that the code will expire or has expired

value

float

The value of the coupon if it differs from the campaign value. The value is null if the campaign value is used.

campaign

CouponCampaign

The coupon campaign and all information about the campaign that this code belongs to

Methods
public toArray()

Returns this model as an array.

Order

Models

GiftCardCode

Model that holds gift card codes.

Namespace

Plenty\Modules\Order\Coupon\Campaign\Code\Order\Models

Properties
Name Type Description

id

int

The ID of the gift card code

orderItemId

int

The order item ID

campaignId

int

The campaign ID

code

string

The coupon code

sender

string

The name of the sender

receiver

string

The name of the receiver

message

string

The message

Methods
public toArray()

Returns this model as an array.

CouponCodeOrder

The CouponCodeOrder model.

Namespace

Plenty\Modules\Order\Coupon\Code\Order\Models

Properties
Name Type Description

corderItemId

int

The ID of the order item that the coupon was redeemed for

campaignId

int

The ID of the campaign that the coupon belongs to

code

string

The coupon code

type

string

The display type of the redeemed coupon The following display types are available:<ul> <li>disposable</li> <li>fixed_vat</li> <li>fixed</li> <li>percental</li> <li>undefined</li> </ul>

amount

float

The redeemed amount of the coupon

vatRate

string

The redeemed vat rate of the coupon

Methods
public toArray()

Returns this model as an array.

Order

The model of the order.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the order

typeId

int

The ID of the order type It is possible to define individual order types. However, the following types are available by default:

  • 1 = Sales order

  • 2 = Delivery

  • 3 = Returns

  • 4 = Credit note

  • 5 = Warranty

  • 6 = Repair

  • 7 = Offer

  • 8 = Advance order

  • 9 = Multi-order

  • 10 = Multi credit note

  • 11 = Multi delivery

  • 12 = Reorder

  • 13 = Partial delivery

  • 14 = Subscription

  • 15 = Redistribution

methodOfPaymentId

int

The ID of the order’s payment method (read only)

shippingProfileId

int

The ID of the order’s shipping profile (read only)

paymentStatus

string

The payment status of the order (read only)

statusId

float

The ID of the order status

statusName

string

The name for the status ID (read only)

ownerId

int

The user ID of the order’s owner

referrerId

float

The referrer ID of the order

createdAt

The date that the order was created

updatedAt

The date that the order was updated last

plentyId

int

The plenty ID of the client that the order belongs to

locationId

int

The ID of the location that the order belongs to

roundTotalsOnly

bool

True means only the order’s total amounts are rounded, false the order item price is rounded too. (read-only)

numberOfDecimals

int

The number of decimals this order was rounded with. (read-only)

lockStatus

string

The lock status of the order. The following statuses are available:

  • unlocked

  • permanentlyLocked

  • reversibleLocked

isLocked

bool

True, if the order has the lock status "unlocked". False otherwise.

hasTaxRelevantDocuments

bool

billingAddress

Address

The invoice address of the order

deliveryAddress

Address

The delivery address of the order

owner

User

The owner of the order

hasDeliveryOrders

bool

Has the order delivery orders?

legacyOrderType

string

The legacy order type as string

client

Webstore

The client data

addresses

The address objects that are associated with the order.

addressRelations

The address relations for this order.

orderItems

The order items that are associated with the order.

sortedOrderItems

The order items that are associated with the order sorted by relations.

properties

The order properties that are associated with the order.

relations

The order relation reference instances that are associated with the order.

amounts

The order amounts that are associated with the order.

comments

The order comments.

location

AccountingLocation

The accounting location of the order.

payments

The payments that are associated with the order.

orderReferences

The order references.

reverseOrderReferences

The sub order references showing on the current order .

originOrderReferences

The references of other orders, e.g. returns or credit notes, associated with the order.

shippingPallets

The shipping pallets that are associated with the order.

shippingPackages

The shipping packages that are associated with the order.

documents

The documents that are associated with the order.

returnLabels

The order returns documents that are associated with the order.

dates

The dates of the order. Can contain many different dates with their types like:

  • 1 = Delete date

  • 2 = Entry date

  • 3 = Payment date

  • 4 = Last update

  • 5 = Completed date

  • 6 = Return date

  • 7 = Payment due date

  • 8 = Estimated shipping date

  • 9 = Start date

  • 10 = End date

  • 11 = Estimated delivery date

  • 12 = Market transfer date

  • 13 = Subscription cancelled on

  • 14 = Subscription last run

  • 15 = Subscription next run

  • 16 = Purchase date

  • 17 = Finish date

originOrder

Order

The origin order of this order. If this order is the origin, this attribute is null. (deprecated)

parentOrder

Order

The parent order of this order. If this order has no parent, this attribute is null. (deprecated)

originOrders

The origin orders of this order.

parentOrders

The parent orders of this order.

childOrders

All orders referencing the current order as parent.

systemAmount

OrderAmount

The order amount in the system currency.

amount

OrderAmount

The order amount in foreign currency if exists. Otherwise the amount in system currency.

contactSenderId

int

contactSender

Contact

The associated contact for the contact-sender relation.

contactReceiverId

int

contactReceiver

Contact

The associated contact for the contact-receiver relation.

warehouseSenderId

int

warehouseSender

Warehouse

The associated warehouse for the warehouse-sender relation.

warehouseReceiverId

int

warehouseReceiver

Warehouse

The associated warehouse for the warehouse-receiver relation.

transactionSums

OrderTransactionSums

The sums of all order item transactions.

orderItemSummary

OrderItemSummary

The order item summary

paymentTerms

OrderPaymentTerms

The payment terms of this order.

shippingInformation

ShippingInformation

The shipping information for this order.

tags

The order tags.

Methods
public toArray()

Returns this model as an array.

OrderAmount

The order amount model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the order amount.

orderId

int

The ID of the order that the amount belongs to.

isSystemCurrency

bool

Flag that states if the current currency is the same as system currency or not.

isNet

bool

Flag that states if the invoice is net or not. If the invoice is not net, it is gross.

currency

string

The currency of the amounts.

exchangeRate

float

The exchange rate for converting the current currency into the system currency.

netTotal

float

The total net amount of the order.

grossTotal

float

The total gross amount of the order.

vatTotal

float

The total vat amount of the order.

invoiceTotal

float

The total invoice amount.

paidAmount

float

The order amount that is already paid.

prepaidAmount

float

This is deprecated and will be removed in the next version. Please use <code>$giftCardAmount</code> instead.

giftCardAmount

float

The amount that comes from gift cards that were redeemed when placing the order The gift cards amount does not reduce the invoice total, but reduces the amount that still needs to be paid. The amount that still needs to paid is not an own parameter because the amount can be calculated by subtracting the gift cards amount from the invoice total.

shippingCostsGross

float

The gross shipping costs.

shippingCostsNet

float

The net shipping costs.

taxlessAmount

float

The taxless amount of the order. Portion of the total invoice amount without taxes.

createdAt

The date that the amount was created.

updatedAt

The date that the amount was updated last.

order

Order

The order that this amount belongs to.

vats

The vat amounts

Methods
public toArray()

Returns this model as an array.

OrderAmountVat

The order amount vat model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the VAT information of an order amount

orderAmountId

int

The ID of the order amount that the VAT information belong to

countryVatId

int

The ID of the VAT configuration

vatField

int

The ID of the VAT rate’s field [0,1,2,3,4,5].

vatRate

float

The actual VAT rate that was used, e.g. 19%.

value

float

The VAT amount of money given in the same currency as the order amount.

netTotal

float

The net amount for the current vat rate.

grossTotal

float

The gross amount for the current vat rate.

createdAt

The date that the VAT was created.

updatedAt

The date that the VAT was updated last.

orderAmount

OrderAmount

The OrderAmount model that the OrderAmountVat belongs to.

countryVat

Vat

The country vat instance.

Methods
public toArray()

Returns this model as an array.

OrderItem

The order item model. Items, shipping costs, coupons, surcharges etc. are all displayed as order items.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the order item

orderId

int

The ID of the order that the order item belongs to

typeId

int

The ID of the order item type

  • VARIATION = 1

  • ITEM_BUNDLE = 2

  • BUNDLE_COMPONENT = 3

  • PROMOTIONAL_COUPON = 4

  • GIFT_CARD = 5

  • SHIPPING_COSTS = 6

  • PAYMENT_SURCHARGE = 7

  • GIFT_WRAP = 8

  • UNASSIGEND_VARIATION = 9

  • DEPOSIT = 10

  • ORDER = 11

  • DUNNING_CHARGE = 12

  • ITEM_SET = 13

  • SET_COMPONENT = 14

  • ORDER_PROPERTY = 15

referrerId

float

The ID of order item referrer

itemVariationId

int

The ID of the item variation

quantity

float

The quantity.

orderItemName

string

The name of the order item

attributeValues

string

The attribute value names

shippingProfileId

int

The ID of the order item’s shipping profile

countryVatId

int

The ID of the country vat

vatField

int

The vat id (0-5).

vatRate

float

The vat amount, e.g. 19.0 for 19% VAT.

position

int

The order items position in the order.

warehouseId

int

The ID of the warehouse.

createdAt

The date at which the order item was created.

updatedAt

The date that the order item was last updated.

systemAmount

OrderItemAmount

The order item’s amount in the system currency.

amount

OrderItemAmount

The order item’s amount in the order currency. If the order currency is the same as the system currency this amount is the same.

order

Order

The order that the property belongs to.

type

OrderItemType

The order item type

countryVat

Vat

The country vat instance.

variation

Variation

The item variation in the position.

amounts

The order item amounts that belong to the order item.

properties

The order item properties that belong to the order item.

orderProperties

The order item order properties that belong to the order item.

orderDates

The dates of the associated order.

dates

The dates of the order item. Can contain many different dates with their types. The following types are currently available:

  • Deleted on = 1

  • Created on = 2

  • Paid date = 3

  • Last update = 4

  • Completed on = 5

  • Return date = 6

  • Payment due date = 7

  • Estimated shipping date = 8

  • Start date = 9

  • End date = 10

  • Possible delivery date = 11

  • Market transfer date = 12

orderPropertyItems

A collection with order items referencing the current order item with type 'order_property'.

referencedOrderPropertyItem

OrderItem

The referenced order item with type 'order_property'.

references

The order item references.

referencedBy

The order item references which reference this order item.

giftCardCodes

The gift card codes that belong to the order item.

transactions

array

The transactions that belong to the order item

serialNumbers

array

The serial numbers that belong to the order item

variationBarcodes

array

The barcodes that belong to the variation of the order item

comments

The order item comments.

warehouselocations

<b>DEPRECATED</b> The order items warehouse locations.

transactionSums

OrderItemTransactionSums

The sums of all order item transactions.

couponReferences

The coupon references.

Methods
public toArray()

Returns this model as an array.

OrderItemAmount

The order item amount model. Order item amount refers to amounts of money.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the order item amount.

orderItemId

int

The ID of the order item that the amount belongs to.

isSystemCurrency

bool

Flag that indicates if the current currency is the same as the system currency or not.

currency

string

The currency of the amounts.

exchangeRate

float

The exchange rate for converting the current currency into the system currency.

purchasePrice

float

The purchase price of the variation.

priceOriginalGross

float

The original gross price without any surcharges or discounts.

priceOriginalNet

float

The original net price without any surcharges or discounts.

priceGross

float

The total gross price including surcharges and discounts [READONLY].

priceNet

float

The total net price including surcharges and discounts [READONLY].

surcharge

float

The surcharge as gross amount.

discount

float

The discount can be a percentage or a fixed value.

isPercentage

bool

Flag that indicates if a discount is given as a percentage or as a fixed value.

createdAt

The date that the amount was created.

updatedAt

The date that the amount was last updated.

orderItem

OrderItem

The order item that the amount belongs to.

Methods
public toArray()

Returns this model as an array.

OrderItemOrderProperty

This model contains the order properties that are assigned to order items.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

propertyId

int

The ID of the order property

orderItemId

int

The ID of the order item of the current order item order property

value

string

The value for the order property

fileUrl

string

The URL of the order property

name

string

The name of the order property

type

string

The type of the order property

Methods
public toArray()

Returns this model as an array.

OrderItemReference

The order item reference model. Each OrderItemReference has a referenced OrderItem and a referenced type ('parent','bundle','campaign','reorder','set','order_property').

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the reference

orderItemId

int

The ID of the order item that the reference belongs to

referenceOrderItemId

int

The ID of the order item that is referred to

referenceType

string

The type of the reference

createdAt

The date that the reference was created

updatedAt

The date that the reference was updated last

orderItem

OrderItem

The order item the reference belongs to

referencedOrderItem

OrderItem

The referenced order item

Methods
public toArray()

Returns this model as an array.

OrderItemSummary

The order item summary model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

orderId

int

The ID of the order

quantity

float

The summed up quantity of all order items visible in the UI

count

array

The count of all order items visible in the UI.

weight

float

The summed up weight (property type ID 11) of all order items

warehouses

array

A list of all order items warehouses

profitMarginSystemCurrency

float

The summed up profit margin of all order items in system currency

profitMarginOrderCurrency

float

The summed up profit margin of all order items in order currency

orderCommentCount

int

The number of order comments

Methods
public toArray()

Returns this model as an array.

OrderItemTransactionSums

The order item transaction sums model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

orderItemId

int

The ID of the order item

quantityTransactionsInRegular

float

The summed up quantity of all transactions with direction 'in' and status 'regular'

quantityTransactionsOutRegular

float

The summed up quantity of all transactions with direction 'out' and status 'regular'

quantityTransactionsInCancelled

float

The summed up quantity of all transactions with direction 'in' and status 'cancelled'

quantityTransactionsOutCancelled

float

The summed up quantity of all transactions with direction 'out' and status 'cancelled'

priceTotalTransactionsInRegular

float

The summed up price (in the currency of the order) of all transactions with direction 'in' and status 'regular'

priceTotalTransactionsOutRegular

float

The summed up price (in the currency of the order) of all transactions with direction 'in' and status 'regular'

priceTotalTransactionsInCancelled

float

The summed up price (in the currency of the order) of all transactions with direction 'out' and status 'cancelled'

priceTotalTransactionsOutCancelled

float

The summed up price (in the currency of the order) of all transactions with direction 'out' and status 'cancelled'

areTransactionsInComplete

bool

Flag that indicates if the item has transactions with direction 'in' of the full item quantity

areTransactionsOutComplete

bool

Flag that indicates if the item has transactions with direction 'out' of the full item quantity

Methods
public toArray()

Returns this model as an array.

OrderItemType

The order item type model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the order item type. The following types are currently available: <br />

  • VARIATION = 1

  • ITEM_BUNDLE = 2

  • BUNDLE_COMPONENT = 3

  • PROMOTIONAL_COUPON = 4

  • GIFT_CARD = 5

  • SHIPPING_COSTS = 6

  • PAYMENT_SURCHARGE = 7

  • GIFT_WRAP = 8

  • UNASSIGEND_VARIATION = 9

  • DEPOSIT = 10

  • ORDER = 11

isErasable

bool

Flag that indicates if this type can be deleted or not

position

int

The position for sorting

names

The names of the order item types

Methods
public toArray()

Returns this model as an array.

OrderItemTypeName

The order item type name model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the type name

typeId

int

The related type id.

name

string

The type name.

lang

string

The ISO 639-1 language code for the name, e.g. "en" for English

type

OrderItemType

The order item type instance.

Methods
public toArray()

Returns this model as an array.

OrderItemWarehouseLocation

<b>DEPRECATED</b> The order item warehouse location model. Order item warehouse locations * refer to the location of an order item, in a specific warehouse.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

orderItemId

int

The Id of the order item, that the warehouse location is associated with.

warehouseLocationId

int

The Id of the warehouse location, this order item is associated with.

quantity

float

The quantity stored at the warehouse location

bestBeforeDate

string

The best before date

batch

string

The batch

warehouseLocation

WarehouseLocation

The warehouse location of the item

Methods
public toArray()

Returns this model as an array.

OrderPaymentTerms

The order payment terms model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the early payment discount.

orderId

int

The ID of the order.

earlyPaymentDiscount

float

The early payment discount in percent.

earlyPaymentDiscountDays

int

The allowed number of days for the discount.

valutaDays

int

The valuta given in days.

paymentAllowedDays

int

The allowed number of days for the payment.

createdAt

The date the model was created.

updatedAt

The date the model was last updated.

order

Order

The order of this early payment discount.

Methods
public toArray()

Returns this model as an array.

OrderReference

The order reference model. Each OrderReference has an origin order (the most top order) and a referenced order.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The id of the order reference entry.

orderId

int

The order id.

originOrderId

int

The id of the origin order.

referenceOrderId

int

The id of the referenced order.

referenceType

string

The reference type ("parent", "reorder", "grouped", "split", "multi_order") of the referenced order.

order

Order

originOrder

Order

The origin order of the order.

referenceOrder

Order

The referenced order of the order.

Methods
public toArray()

Returns this model as an array.

OrderTransactionSums

The order transaction sums model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

orderId

int

The ID of the order

quantityAllItems

float

The summed up quantity of all items

quantityTransactionsInRegular

float

The summed up quantity of all transactions with direction 'in' and status 'regular'

quantityTransactionsOutRegular

float

The summed up quantity of all transactions with direction 'out' and status 'regular'

quantityTransactionsInCancelled

float

The summed up quantity of all transactions with direction 'in' and status 'cancelled'

quantityTransactionsOutCancelled

float

The summed up quantity of all transactions with direction 'out' and status 'cancelled'

quantityTransactionsInBooked

float

The summed up quantity of all transactions with direction 'in' and status 'regular' and is booked

quantityTransactionsOutBooked

float

The summed up quantity of all transactions with direction 'out' and status 'regular' and is booked

priceTotalTransactionsInRegular

float

The summed up price (in the currency of the order) of all transactions with direction 'in' and status 'regular'

priceTotalTransactionsOutRegular

float

The summed up price (in the currency of the order) of all transactions with direction 'in' and status 'regular'

priceTotalTransactionsInCancelled

float

The summed up price (in the currency of the order) of all transactions with direction 'out' and status 'cancelled'

priceTotalTransactionsOutCancelled

float

The summed up price (in the currency of the order) of all transactions with direction 'out' and status 'cancelled'

areTransactionsInComplete

bool

Flag that indicates if all items have transactions with direction 'in' of the full item quantity

areTransactionsOutComplete

bool

Flag that indicates if all items have transactions with direction 'out' of the full item quantity

Methods
public toArray()

Returns this model as an array.

OrderType

The order type model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the order type

isErasable

bool

Flag that states if this type can be deleted or not.

position

int

The position for sorting

names

The names of the order item types.

Methods
public toArray()

Returns this model as an array.

OrderTypeName

The order type name model.

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

id

int

The ID of the type name

typeId

int

The ID of the type

name

string

The type name.

lang

string

The ISO 639-1 language code for the name, e.g. "en" for English

type

OrderType

The order type instance.

Methods
public toArray()

Returns this model as an array.

PriceCalculationResultItem

price calculation result item

Namespace

Plenty\Modules\Order\Models

Properties
Name Type Description

total

float

totalNet

float

totalGross

float

totalVat

float

highestVatId

int

netAmountsMap

array

vatAmountsMap

array

Methods
public toArray()

Returns this model as an array.

Template

OrderFilterBuilderFactory

This factory provides methods to retrieve all available catalog order filter builders.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template

Methods
public orderWarehouseFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderWarehouseFilterBuilder
Return type: OrderWarehouseFilterBuilder
public orderStatusFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderStatusFilterBuilder
Return type: OrderStatusFilterBuilder
public orderTypeFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderTypeFilterBuilder
Return type: OrderTypeFilterBuilder
public orderReferrerFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderReferrerFilterBuilder
Return type: OrderReferrerFilterBuilder
public orderPaymentMethodFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderPaymentMethodFilterBuilder
Return type: OrderPaymentMethodFilterBuilder
public orderOwnerFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderOwnerFilterBuilder
Return type: OrderOwnerFilterBuilder
public orderItemVariationIdFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderOwnerFilterBuilder
Return type: OrderOwnerFilterBuilder
public orderClientFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderClientFilterBuilder
Return type: OrderClientFilterBuilder
public orderItemTypeFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderItemTypeFilterBuilder
Return type: OrderItemTypeFilterBuilder
public orderIdFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderIdFilterBuilder
Return type: OrderIdFilterBuilder
public orderCreatedAtFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderCreatedAtFilterBuilder
Return type: OrderCreatedAtFilterBuilder
public orderUpdatedAtFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderUpdatedAtFilterBuilder
Return type: OrderUpdatedAtFilterBuilder
public orderPaidAtFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderPaidAtFilterBuilder
Return type: OrderPaidAtFilterBuilder
public orderCompletedAtFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderCompletedAtFilterBuilder
Return type: OrderCompletedAtFilterBuilder
public orderReceivedDateFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderReceivedDateFilterBuilder
Return type: OrderReceivedDateFilterBuilder
public orderShippingProfileFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderShippingProfileFilterBuilder
Return type: OrderShippingProfileFilterBuilder
public orderExcludeMainOrdersFilterBuilder():Plenty\Modules\Order\Catalogues\Order\Template\Filters\OrderShippingProfileFilterBuilder

Contracts

OrderAmountRepositoryContract

This interface allows you to get and list order amounts and their vats.

Namespace

Plenty\Modules\Order\Contracts

Methods
public getByOrderId($orderId, $currency = null):Plenty\Modules\Order\Models\OrderAmount
Return type: OrderAmount

Get an order amount for an order in a currency. The ID of the order must be specified. The currency is optional. If no currency is specified, the order amount entry will be returned in the default system currency.

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$currency

string

The currency of the order amount

public getById($id):Plenty\Modules\Order\Models\OrderAmount
Return type: OrderAmount

Get an order amount. The ID of the order amount must be specified.

Parameters

Name

Type

Description

$id

int

The ID of the order amount

public listByOrderId($orderId):array

List all order amounts of an order. The ID of the order must be specified.

Parameters

Name

Type

Description

$orderId

int

The ID of the order

OrderItemRepositoryContract

The OrderItemRepositoryContract is the interface for the order item repository. This interface allows you to find, create and update order items. An order item can be e.g. items, surcharges and coupons. Each order item is given a unique id, which links it to a specific order.

Namespace

Plenty\Modules\Order\Contracts

Methods
public getOrderItem($orderItemId, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\OrderItem
Return type: OrderItem

Get an order item

Parameters

Name

Type

Description

$orderItemId

int

The ID of the order item

$with

array

The relations to load

$lazyLoaded

bool

Load order item instance without default relations

public deleteOrderItem($orderId, $orderItemId):bool

Delete an order item

Parameters

Name

Type

Description

$orderId

int

The ID of the order that the item belongs to.

$orderItemId

int

The ID of the order item to be deleted.

Return type: PaginatedResult

Search order items

Parameters

Name

Type

Description

$orderId

int

$page

int

$itemsPerPage

int

$with

array

$sortBy

string

$sortOrder

string

public setFilters($filters = []):void

Sets the filter array.

Parameters

Name

Type

Description

$filters

array

public getFilters():void

Returns the filter array.

public getConditions():void

Returns a collection of parsed filters as Condition object

public clearFilters():void

Clears the filter array.

public clearCriteria():void

Resets all Criteria filters by creating a new instance of the builder object.

public applyCriteriaFromFilters():void

Applies criteria classes to the current repository.

OrderRepositoryContract

The OrderRepositoryContract is the interface for the order repository. This interface allows you to find, create and update orders. There are many different order types and the data returned depends on the order type.

Namespace

Plenty\Modules\Order\Contracts

Methods
public findOrderById($orderId, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Deprecated! (since 2021-04)

Please use OrderRepositoryContract::findById instead

Return type: Order

Get an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$with

array

The relations to load in the order instance, one of "addresses", "events", "dates", "relation", "reference", "location", "payments", "documents" and "comments".

$lazyLoaded

bool

Load order instance without default relations

public findById($orderId, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Get an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$with

array

The relations to load in the order instance

$lazyLoaded

bool

Load order instance without default relations

public getByIds($orderIds, $with = [], $lazyLoaded = false):Illuminate\Support\Collection
Return type: Collection

Get orders

Parameters

Name

Type

Description

$orderIds

array

$with

array

$lazyLoaded

bool

public findOrderByExternalOrderId($externalOrderId, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Deprecated! (since 2021-04)

Please use OrderRepositoryContract::getByExternalOrderId instead

Return type: Order

Get an order by external order ID

Parameters

Name

Type

Description

$externalOrderId

string

$with

array

$lazyLoaded

bool

Load order instance without default relations

public getByExternalOrderId($externalOrderId, $with = [], $lazyLoaded = false):Illuminate\Support\Collection
Return type: Collection

List orders by external order ID

Parameters

Name

Type

Description

$externalOrderId

string

$with

array

$lazyLoaded

bool

Load order instance without default relations

public createOrder($data, $coupon = null, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Deprecated! (since 2021-04)

Please use OrderRepositoryContract::create instead

Return type: Order

Create an order

Parameters

Name

Type

Description

$data

array

The order data. The properties that are required to create an order can be found in the order model.

$coupon

string

A coupon code or a list of coupon codes to be redeemed in the order.

$with

array

$lazyLoaded

bool

public create($data, $coupons = [], $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Create an order

Parameters

Name

Type

Description

$data

array

The order data

$coupons

array

Coupon codes to be redeemed in the order

$with

array

$lazyLoaded

bool

public updateOrder($data, $orderId, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Deprecated! (since 2021-04)

Please use OrderRepositoryContract::update instead

Return type: Order

Update an order

Parameters

Name

Type

Description

$data

array

The order data. The properties that are required to update an order can be found in the order model.

$orderId

int

The ID of the order

$with

array

$lazyLoaded

bool

public update($orderId, $data, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Update an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$data

array

The order data

$with

array

$lazyLoaded

bool

public deleteOrder($orderId):bool
Deprecated! (since 2021-04)

Please use OrderRepositoryContract::delete instead

Delete an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public delete($orderId):void

Delete an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public undeleteOrder($orderId, $status):Plenty\Modules\Order\Models\Order
Deprecated! (since 2021-03)

Method won't be supported in the future

Return type: Order

Restore an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$status

float

The status of the order

public isDeleted($orderId):bool

Checks whether an order has been deleted or not.

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public findSchedulerById($schedulerId):Plenty\Modules\Order\Scheduler\Models\OrderScheduler
Deprecated! (since 2021-03)

Method won't be supported in the future

Return type: OrderScheduler

Get a scheduler order

Parameters

Name

Type

Description

$schedulerId

int

The ID of the scheduler order

public allOrdersByContact($contactId, $page = 1, $itemsPerPage = 50, $with = []):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

List orders of a contact

Parameters

Name

Type

Description

$contactId

int

The ID of the contact

$page

int

The page to get. The default page that will be returned is page 1.

$itemsPerPage

int

The number of orders to be displayed per page. The default number of orders per page is 50.

$with

array

The relations to load in the Order instance. Valid are "addresses", "events", "dates", "relation", "reference", "location", "payments", "documents" and "comments".

public allOrdersBySupplier($contactId, $page = 1, $itemsPerPage = 50, $with = []):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

List orders that include one or more variations from a supplier

Parameters

Name

Type

Description

$contactId

int

The ID of the contact (supplier id)

$page

int

The page to get. The default page that will be returned is page 1.

$itemsPerPage

int

The number of orders to be displayed per page. The default number of orders per page is 50.

$with

array

The relations to load in the Order instance. Valid are "addresses", "events", "dates", "relation", "reference", "location", "payments", "documents" and "comments".

public allOrdersByContactSender($contactId, $page = 1, $itemsPerPage = 50, $with = []):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

List orders sent by a contact

Parameters

Name

Type

Description

$contactId

int

The ID of the contact

$page

int

The page to get. The default page that will be returned is page 1.

$itemsPerPage

int

The number of orders to be displayed per page. The default number of orders per page is 50.

$with

array

The relations to load in the Order instance. Valid are "addresses", "events", "dates", "relation", "reference", "location", "payments", "documents" and "comments".

public getLatestOrderByContactId($contactId, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Get latest order of a contact

Parameters

Name

Type

Description

$contactId

int

The ID of the contact

$with

array

The relations to load in the Order instance. The relations available are: "addresses", "events", "dates", "relation", "reference", "location", "payments", "documents" and "comments". If you want to load relations, you need to include at least one, but you can also include several or all.

$lazyLoaded

bool

public searchOrders($page = 1, $itemsPerPage = 50, $with = [], $lazyLoaded = false):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

Lists orders

Parameters

Name

Type

Description

$page

int

The page to get. The default page that will be returned is page 1.

$itemsPerPage

int

The number of orders to be displayed per page. The default number of orders per page is 50.

$with

array

The relations to load in the Order instance. Valid are "addresses", "events", "dates", "relation", "reference", "location", "payments", "documents" and "comments".

$lazyLoaded

bool

Load order instance without default relations

public getPackageNumbers($orderId):array

List package numbers of an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public cancelOrder($orderId, $data):void
Deprecated! (since 2021-04)

Please use OrderRepositoryContract::cancel instead

Cancel an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$data

array

The request data

public cancel($orderId, $data = []):void

Cancel an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$data

array

The request data

public findOrderByAccessKey($orderId, $accessKey):Plenty\Modules\Order\Models\Order
Return type: Order

Find the order for the given order ID and access key.

Parameters

Name

Type

Description

$orderId

int

The ID of the order to be checked.

$accessKey

string

The access key, that belongs to the order.

public generateAccessKey($orderId, $regenerate = false):string

Generate an access key for the given order ID.

Parameters

Name

Type

Description

$orderId

int

$regenerate

bool

public completeOrder($orderId, $data = []):Plenty\Modules\Order\Models\Order
Deprecated! (since 2021-04)

Please use OrderRepositoryContract::complete instead

Return type: Order

Complete an incomplete order.

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$data

array

Additional data. Currently only the statusId can be specified.

public complete($orderId, $data = []):Plenty\Modules\Order\Models\Order
Return type: Order

Complete an incomplete order.

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$data

array

Additional data. Currently only the statusId can be specified.

public createMultiOrderByContact($contactId):Plenty\Modules\Order\Models\Order
Return type: Order

Creates a multi order for a specific contact

Parameters

Name

Type

Description

$contactId

int

public setOrderStatus45($orderId):Plenty\Modules\Order\Models\Order
Deprecated! (since 2021-03)

Method won't be supported in the future

Return type: Order

Set order status to 4 or 5

Parameters

Name

Type

Description

$orderId

int

public getMyAccountUrl($orderId):string

Get My Account url of the order

Parameters

Name

Type

Description

$orderId

int

public setFilters($filters = []):void

Sets the filter array.

Parameters

Name

Type

Description

$filters

array

public getFilters():void

Returns the filter array.

public getConditions():void

Returns a collection of parsed filters as Condition object

public clearFilters():void

Clears the filter array.

Events

OrderCreated

An event class fired after a new order is created. The order type is not relevant. * At the same time also type depended events will be fired, like ReturnsCreated or CreditNoteCreated.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

OrderEvent

A base event class for all order events. Each order event expects an order instance.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

OrderFullyPaid

An Event class fired after a payment assignment when the order is fully paid.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

OrderOverpaid

An event class will be fired after a payment is assigned and if the order is overpaid.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

OrderPaidEvent

A base Event class for all order paid events.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

OrderPartlyPaid

An Event class fired after a payment is assigned and if the order is only partly paid.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

OrderPaymentAssigned

An Event class fired after a payment was assigned to an order. * After this event one of the following events will be fired, depending the payment status of the order: * OrderPrepaid, OrderPartlyPaid, OrderFullyPaid, OrderOverpaid.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order, $payment):void

OrderPaymentAssigned constructor.

Parameters

Name

Type

Description

$order

Order

$payment

Payment

public getPayment():Plenty\Modules\Payment\Models\Payment
Return type: Payment

Get the payment.

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

OrderPrepaid

An Event class fired after a payment is assigned and if the order is paid in advance.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

SubscriptionChildOrderCreated

An event class fired after a new order for a subscription is created. The order type is not relevant. * At the same time also type depended events will be fired, like ReturnsCreated or CreditNoteCreated.

Namespace

Plenty\Modules\Order\Events

Methods
public __construct($order):void

OrderEvent constructor.

Parameters

Name

Type

Description

$order

Order

public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the order instance.

public broadcastAs():void
public broadcastPayload():void
public getWebstoreId():void
public broadcastWhen():void
public broadcastConnections():void
public broadcastOn():void
public broadcastWith():void

Exceptions

OrderDuplicateException

Exception when duplicate order is created.

Namespace

Plenty\Modules\Order\Exceptions

Methods
public getMessage():void
public getCode():void
public getFile():void
public getLine():void
public getTrace():void
public getPrevious():void
public getTraceAsString():void

Services

OrderCreatedTypeService

This class is used as an event listener as well as a service for registering events. The class allows to register event classes to extend the OrderCreated event for custom order types.

Namespace

Plenty\Modules\Order\Services

Methods
public handle($created):void

Reacts upon the OrderCreated event

Parameters

Name

Type

Description

$created

OrderCreated

The event instance.

public static addEventForType($typeId, $className):void

Create event class for a custom order type

Parameters

Name

Type

Description

$typeId

int

The ID of the custom order type.

$className

string

The name of the event class.

public static removeEventForType($typeId, $className):void

Delete event class from a custom order type

Parameters

Name

Type

Description

$typeId

int

The ID of the custom order type.

$className

string

The name of the event class.

Campaign

Contracts

CouponCampaignRepositoryContract

This is the contract for the coupon campaign repository. It allows you to get coupon campaigns.

Namespace

Plenty\Modules\Order\Coupon\Campaign\Contracts

Methods
public findById($id):Plenty\Modules\Order\Coupon\Campaign\Models\CouponCampaign
Return type: CouponCampaign

Get a coupon campaign

Parameters

Name

Type

Description

$id

The ID of the coupon campaign

public findByEmailPlaceholder($placeholder):Plenty\Modules\Order\Coupon\Campaign\Models\CouponCampaign
Return type: CouponCampaign

Get the CouponCampaign model from the database by emailPlaceholder.

Parameters

Name

Type

Description

$placeholder

string

The email placeholder to search the database by

public findByCouponCode($couponCode):Plenty\Modules\Order\Coupon\Campaign\Models\CouponCampaign
Return type: CouponCampaign

Get the coupon campaign of a coupon code

Parameters

Name

Type

Description

$couponCode

string

The coupon code to search the database by

public getCouponDisplayType($couponCodeValidation):string

Get the display type of a coupon

Parameters

Name

Type

Description

$couponCodeValidation

CouponCodeValidation

public create($data):Plenty\Modules\Order\Coupon\Campaign\Models\CouponCampaign
Return type: CouponCampaign

Create a coupon campaign

Parameters

Name

Type

Description

$data

array

public modifyCampaignUsage($couponCampaignId, $operator, $field):void

Modifies the two counter 'used' and 'unused'

Parameters

Name

Type

Description

$couponCampaignId

int

ID of the Coupon Campaign

$operator

string

How should the usage been modified ( '+' or '-' )

$field

string

Usage type to modify ( 'used' or 'unused' )

public delete($couponCampaignId):bool

Delete a coupon campaign

Parameters

Name

Type

Description

$couponCampaignId

int

The ID of the coupon campaign

public update($data):Plenty\Modules\Order\Coupon\Campaign\Models\CouponCampaign
Return type: CouponCampaign

update a coupon campaign

Parameters

Name

Type

Description

$data

array

Models

CouponCampaign

The CouponCampaign model contains all information of a campaign.

Namespace

Plenty\Modules\Order\Coupon\Campaign\Models

Properties
Name Type Description

id

int

The ID of a coupon campaign

externalId

string

DEPRECATED! The external ID of a coupon campaign

name

string

The name of the coupon campaign

variable

int

The variable to display coupon codes in emails. There are only 10 variables available. A variable may only be used for one campaign. The variable names follow this pattern: CouponCode + Number e.g. CouponCode1.

isPermittedForExternalReferrers

bool

Flag that indicates whether or not coupons can be redeemed if a customer enters the online store from an external referrer. <ul><li>TRUE = The coupon can be redeemed if the customer enters the online store from an external referrer
</li> <li>FALSE = The coupon can not be redeemed</li></ul>

includeShipping

bool

The discount also applies to shipping costs. The property will be only be set if the discount type fixed is set.

unusedCodesCount

int

The number of codes that have been redeemed

usedCodesCount

int

The number of codes that have not been redeemed

endsAt

string

The date that the campaign ends

startsAt

string

The date that the campaign starts

minOrderValue

float

The minimum order value that needs to be reached for the coupon to be redeemed. If the value is not reached the coupon will not be redeemed.

codeDurationWeeks

int

The number of weeks that codes of this campaign can be redeemed after they have been generated.

codeAssignment

string

The code assignment is only relevant for vouchers. Codes can either be generated every time a voucher is bought or a code from a previously created list of codes can be used. The three options available are generate, use_existing and only_use_existing. <ul><li>generate = a new code is generated on demand</li> <li>use_existing = the code already exists and is taken from a previously entered list of codes, in case of vouchers a new code will be generated for each item purchased that has associated a campaign ID</li> <li>only_use_existing = the code already exists and is taken from a previously entered list of codes, for vouchers no additional code will be generated for items purchased, only existing codes will be used</li></ul>

codeLength

string

There are 3 different length available. The code can be 6, 16, 24 or 32 characters long.

usage

string

The usage defines what the coupon codes from this campaign can be used for. There are three options available: <ul><li>single_and_subscription = The codes can be used for single orders and subscription orders</li> <li>single_order = The codes can be used for single orders only</li> <li>subscription = The codes can be used for subscriptions only</li></ul>

concept

string

The campaign concept defines how many codes belong to a campaign. The concept interacts with the redeem type that is explained next. There are two concept options available: <ul><li>single_code = The campaign has only one code</li> <li>multi_code = The campaign has several codes</li></ul>

redeemType

string

The redeem type defines how many times a code of a campaign can be redeemed. There are 4 redeem types available: <ul><li>multi_redeem_per_user = Each customer is allowed to redeem the same code several times</li> <li>single_redeem_per_user = Each customer can only redeem the same code once</li> <li>redeem_until_value_reached = A code can be entered several times by the same customer or by different customers, but only until the coupon value is depleted</li> <li>unique_redeem = The code can be redeemed once. If several customers get the same code, only the first customer to enter the code can use it.</li></ul> The redeem type interacts with the concept. Pay attention to the combination these two options form.

discountType

string

There are 4 discount types available: <ul><li>fixed = The coupon value is a fixed amount of money. This discount type is the only one that makes sense for coupons that are sold in the online store. The actual amount of money needs to be set with the value property.</li> <li>percent = The discount is given as percentage and the actual value depends on the purchase. The actual number of percent need to be set with the value property.</li> <li>item = The discount applies to entire items. A typical example would be - Buy 1 get 1 free - or in other words - Get 2 for the price of 1. The number of items the customer gets and the number of items the customer has to pay for need to be set with itemDiscountToPay and itemDiscountToBuy.</li> <li>shipping = The shipping does not cost anything. The cost will be set to zero no matter what the actual shipping costs are.</li></ul>

itemDiscountToPay

int

The number of items that the customer has to pay for. This number needs to be compared to the number of items the customer receives, itemDiscountToBuy

itemDiscountToBuy

int

The number of items that the customer receives, but he or she only has to pay for the number of items set with itemDiscountToPay.

campaignType

string

The two campaign types available are coupon or voucher.

couponType

string

The coupon type is only for campaigns that have the campaign type coupon. The two coupon types available are promotion and sales.

description

string

The description of the campaign

value

float

The actual discount value of a coupon. The value needs to be set for the two discount types fixed and percent.

codes

Collection

The codes and information about the codes that belong to this CouponCampaign

references

Collection

These references are available <ul> <li>category =</li> <li>item =</li> <li>webstore =</li> <li>customer_group =</li> <li>customer_type =</li> </ul>

Methods
public toArray()

Returns this model as an array.

Reference

Contracts

CouponCampaignReferenceRepositoryContract

This is the contract for the coupon campaign reference repository. It allows you to get and create coupon campaigns references.

Namespace

Plenty\Modules\Order\Coupon\Campaign\Reference\Contracts

Methods
public findByCouponCampaignId($couponCampaignId):Illuminate\Support\Collection
Return type: Collection

Get a coupon campaign

Parameters

Name

Type

Description

$couponCampaignId

int

The ID of the coupon campaign

public create($data):Illuminate\Support\Collection
Return type: Collection

Create a Coupon Campaign reference

Parameters

Name

Type

Description

$data

array

Models

CouponCampaignReference

The CouponCampaignReference model contains all information of a campaign reference.

Namespace

Plenty\Modules\Order\Coupon\Campaign\Reference\Models

Properties
Name Type Description

campaignId

int

The ID of a coupon campaign

referenceType

string

The reference type defines the type of the reference. There are five reference types available: <ul> <li>category =</li> <li>item =</li> <li>webstore =</li> <li>customer_group =</li> <li>customer_type =</li> </ul>

value

int

The name of the coupon campaign

Methods
public toArray()

Returns this model as an array.

Contact

Contracts

CouponCodeContactRepositoryContract

This is the contract for the coupon codes by contacts repository. It allows you to list coupon codes redeemed by a contact as well as to create, update and delete redeemed coupon codes.

Namespace

Plenty\Modules\Order\Coupon\Code\Contact\Contracts

Methods
public create($data):Plenty\Modules\Order\Coupon\Code\Contact\Models\CouponCodeContact
Return type: CouponCodeContact

Create redeemed coupons for a contact.

Parameters

Name

Type

Description

$data

array

The redeemed coupon data. The properties that are required to create an entry can be found in the CouponCodeContact model.

public update($contactId, $campaignId, $coupon, $data):Plenty\Modules\Order\Coupon\Code\Contact\Models\CouponCodeContact
Return type: CouponCodeContact

Update a redeemed coupon of a contact.

Parameters

Name

Type

Description

$contactId

int

The ID of the contact that redeemed the coupon code

$campaignId

int

The ID of the coupon campaign

$coupon

string

The coupon code

$data

array

The redeemed coupon data. The properties that are required to update an entry can be found in the CouponCodeContact model

public find($contactId, $campaignId, $coupon):Plenty\Modules\Order\Coupon\Code\Contact\Models\CouponCodeContact
Return type: CouponCodeContact

Get a redeemed coupon for a contact

Parameters

Name

Type

Description

$contactId

int

The ID of the contact which redeemed the coupon code

$campaignId

int

The ID of the coupon campaign

$coupon

string

The coupon code

public findByContact($contactId, $page = 1, $itemsPerPage = 50):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

List redeemed coupons for a contact

Parameters

Name

Type

Description

$contactId

int

The contact ID as filter for redeemed coupons.

$page

int

The page to get. The default page that will be returned is page 1.

$itemsPerPage

int

The number of coupons to be displayed per page. The default number of coupons per page is 50.

public findByCampaign($campaignId, $page = 1, $itemsPerPage = 50):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

List redeemed coupons of a campaign.

Parameters

Name

Type

Description

$campaignId

int

The campaign ID as filter for redeemed coupons.

$page

int

The page to get. The default page that will be returned is page 1.

$itemsPerPage

int

The number of coupons to be displayed per page. The default number of coupons per page is 50.

public findByCoupon($coupon, $page = 1, $itemsPerPage = 50):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

List redeemed coupons of a coupon code

Parameters

Name

Type

Description

$coupon

string

The coupon code

$page

int

The page to get. The default page that will be returned is page 1.

$itemsPerPage

int

The number of coupons to be displayed per page. The default number of coupons per page is 50.

Models

CouponCodeContact

The CouponCodeContact model.

Namespace

Plenty\Modules\Order\Coupon\Code\Contact\Models

Properties
Name Type Description

code

string

The coupon code

contactId

int

The ID of the contact that redeemed the coupon

openAmount

float

The coupon amount that can still be redeemed

redeemCount

int

How many times a coupon code has already been redeemed

updatedAt

The date that the coupon code was updated last.

campaignId

int

The ID of the campaign that the coupon belongs to

externalTransactionId

int

The ID that is assigned to a coupon by the external coupon service provider, when the coupon is redeemed.

Methods
public toArray()

Returns this model as an array.

Validation

Contracts

CouponCodeValidatorContract

CouponCodeValidatorContract is the interface for the coupon code validation repository. This interface provides the functionality to validate coupon data.

Namespace

Plenty\Modules\Order\Coupon\Code\Validation\Contracts

Methods
public validate($validationData):Plenty\Modules\Order\Coupon\Code\Validation\Models\CouponCodeValidation
Return type: CouponCodeValidation

Validate a coupon code

Parameters

Name

Type

Description

$validationData

CouponCodeValidation

The data to validate a coupon

Models

CouponCodeValidation

The CouponCodeValidation data model contains all data necessary for validating a coupon.

Namespace

Plenty\Modules\Order\Coupon\Code\Validation\Models

Properties
Name Type Description

campaignId

int

The ID of the campaign

validationType

string

The type of the campaign. Currently the only type available is plentymarkets.

items

The list of items or variations to be validated

contactId

int

The ID of the contact that wants to redeem the coupon

couponCode

string

The coupon code

currency

string

The currency of the purchase

exchangeRate

float

The exchange rate of the purchase (optional, is loaded from settings if not given)

referrer

float

The order referrer

salesDiscount

float

The total discount from a coupon applied to an order. The discount is given as gross amount.

salesDiscountNet

float

The net discount from a coupon applied to an order. The net discount is the total discount minus the vat amount.

itemDiscount

float

The discount amount applied to items.

itemDiscountNet

float

The net discount applied to items.

shippingDiscount

float

The discount applied to shipping costs.

shippingDiscountNet

float

The net discount applied to shipping costs.

usedVatFields

array

The vat fields used for the validation

restCouponAmount

float

The remaining coupon amount

checkedItems

array

The list of variations that passed the validation

validateParams

array

Validation parameters

couponCampaignType

string

The campaign type

Methods
public toArray()

Returns this model as an array.

CouponCodeValidationItem

The CouponCodeValidationItem model contains all item data needed for validating whether the coupon can be redeemed for these items or not.

Namespace

Plenty\Modules\Order\Coupon\Code\Validation\Models

Properties
Name Type Description

amount

float

The price of a variation multiplied by the quantity

noCoupon

int

Flag that indicates whether a variation can be bought with a coupon, can exclusively be bought with a coupon or can not be bought with a coupon.

quantity

int

The quantity of the variation

singlePrice

float

The price of a single variation

itemId

int

The ID of the item

vatField

int

The field of the VAT rate

itemHash

string

The hash for items with new order properties

hashReference

string

The reference to itemHash in new order property items

itemVariationId

int

The ID of the variation

Methods
public toArray()

Returns this model as an array.

Currency

Contracts

CurrencyConversionSettingsRepositoryContract

Provides methods for currency conversion data.

Namespace

Plenty\Modules\Order\Currency\Contracts

Methods
public getCurrencyConversionList():array

Gets the currency conversion setting.

CurrencyRepositoryContract

Provides methods for currency data.

Namespace

Plenty\Modules\Order\Currency\Contracts

Methods
public getCurrency($currencyIso, $columns = [], $with = []):Plenty\Modules\Order\Currency\Models\Currency
Return type: Currency

Get a currency

Parameters

Name

Type

Description

$currencyIso

string

The currency ISO 4217 code, e.g. "EUR".

$columns

array

The attributes to be loaded in the currency instance.

$with

array

The relations to be loaded in the currency instance. Valid relations are "names" or "countries").

public getCurrencyList($columns = [], $with = []):void

Get all currencies supported in the system.

Parameters

Name

Type

Description

$columns

array

The attributes to be loaded in the currency instances.

$with

array

The relations to be loaded in the currency instance. Valid relations are "names" or "countries".

public getCurrencyCountries($currencyIso, $columns = []):void

List countries for a currency

Parameters

Name

Type

Description

$currencyIso

string

The currency ISO 4217 code, e.g. "EUR".

$columns

array

The attributes to be loaded in the country instances.

public getCountryCurrency($countryId, $columns = [], $with = []):Plenty\Modules\Order\Currency\Models\Currency
Return type: Currency

Get a currency for a country

Parameters

Name

Type

Description

$countryId

int

The country id.

$columns

array

The attributes to be loaded in the currency instance.

$with

array

The relations to be loaded in the currency instance ("names" or "countries").

public getExchangeRate($currencyIso):Plenty\Modules\Order\Currency\Models\CurrencyExchangeRate
Return type: CurrencyExchangeRate

Get the exchange rate for a currency

Parameters

Name

Type

Description

$currencyIso

string

public getExchangeRatesFrom($currencyIso):array

List exchange rates from a currency

Parameters

Name

Type

Description

$currencyIso

string

The currency ISO 4217 code, e.g. "EUR".

public getExchangeRatesTo($currencyIso):array

List exchange rates to a currency

Parameters

Name

Type

Description

$currencyIso

string

The currency ISO 4217 code, e.g. "EUR".

Models

Currency

The currency model. The model includes information like the ISO 4217 code and the related currency symbols as well as the countries that a currency is used in.

Namespace

Plenty\Modules\Order\Currency\Models

Properties
Name Type Description

currency

string

The ISO 4217 code and id of the currency.

htmlCode

string

The html code (entity) for the currency.

unicodeSign

string

The unicode symbol for the currency. If no unicode symbol exists, the html code will be used.

isActive

bool

Flag that indicates if the currency is active in the system or not. Currencies are activated per sales price.

isErasable

bool

Flag that indicates if this currency can be deleted or not. <ul><li>False = Currency cannot be deleted</li><li>True = Currency can be deleted</li></ul>

exchangeRate

float

The current exchange rate for this currency.

countries

A list of countries that use the currency.

names

A list of names in different languages for the currency.

Methods
public toArray()

Returns this model as an array.

CurrencyCountryRelation

The CurrencyCountryRelation model indicates which currency is related to which country.

Namespace

Plenty\Modules\Order\Currency\Models

Properties
Name Type Description

id

int

The ID of the relation

currency

string

The currency

countryId

int

The ID of the country

country

Country

The related country information

currencyInstance

Currency

The related currency information

Methods
public toArray()

Returns this model as an array.

CurrencyExchangeRate

The currency exchange rate model.

Namespace

Plenty\Modules\Order\Currency\Models

Properties
Name Type Description

exchangeRate

float

The exchange rate

Methods
public toArray()

Returns this model as an array.

CurrencyName

The currency name model.

Namespace

Plenty\Modules\Order\Currency\Models

Properties
Name Type Description

id

int

The ID of the currency name

currency

string

The currency

lang

string

The language of the currency name

name

string

The name in the language

currencyInstance

Currency

The currency instance.

Methods
public toArray()

Returns this model as an array.

Idea

Models

Export

The export model for IDEA exports.

Namespace

Plenty\Modules\Order\Export\Pos\Idea\Models

Properties
Name Type Description

id

int

The id of the export entry.

token

string

The token generated for the export entry.

progress

float

The progress of the export process.

currentModule

string

The currently exporting module of the export process.

state

string

The current state of the export process.

filename

string

The filename of the export content.

createdAt

Carbon

Specifies the creation date of the export entry.

updatedAt

Carbon

Specifies the last update date of the export entry.

modules

Collection

The modules to be used by the export process.

options

Collection

The options for the export process. Currently only "year" is supported as option key.

Methods
public toArray()

Returns this model as an array.

Method

Contracts

PaymentMethodRepositoryContract

Repository Contract for PaymentMethod

Namespace

Plenty\Modules\Order\Payment\Method\Contracts

Methods
public getPaymentMethods($countryId, $plentyId = null, $lang = &quot;de&quot;):array

Gets a list of payment methods

Parameters

Name

Type

Description

$countryId

int

$plentyId

int

$lang

string

public activatePaymentMethod($id):Plenty\Modules\Order\Payment\Method\Models\PaymentMethod
Return type: PaymentMethod

Activate a legacy payment method.

Parameters

Name

Type

Description

$id

int

Models

PaymentMethod

The payment method model

Namespace

Plenty\Modules\Order\Payment\Method\Models

Properties
Name Type Description

id

int

name

string

minimumGross

float

priority

int

active

bool

showBankDetails

int

infoPageType

int

infoPageExternalUrl

int

feeDomesticFlatRateWebstore

float

feeDomesticFlatRateInternal

float

feeDomesticPercentageWebstore

float

feeDomesticPercentageInternal

float

feeForeignFlatRateWebstore

float

feeForeignFlatRateInternal

float

feeForeignPercentageWebstore

float

feeForeignPercentageInternal

float

informations

array

webstores

array

coutries

array

information

PaymentMethodInformation

Methods
public toArray()

Returns this model as an array.

PaymentMethodInformation

The payment method information model

Namespace

Plenty\Modules\Order\Payment\Method\Models

Properties
Name Type Description

id

int

lang

string

name

string

infoPageType

int

infoPageInternalContent

int

infoPageExternalUrl

string

logo

string

showLogo

int

Methods
public toArray()

Returns this model as an array.

Pdf

Events

OrderPdfGenerationEvent

The OrderPdfGenerationEvent triggered before a pdf is generated for an order.

Namespace

Plenty\Modules\Order\Pdf\Events

Methods
public getOrder():Plenty\Modules\Order\Models\Order
Return type: Order

Get the

public getDocType():string

Get the

public addOrderPdfGeneration($orderPdfGeneration):Plenty\Modules\Order\Pdf\Events\OrderPdfGenerationEvent
Return type: OrderPdfGenerationEvent
Parameters

Name

Type

Description

$orderPdfGeneration

OrderPdfGeneration

Models

OrderPdfGeneration

The OrderPdfGeneration Model

Namespace

Plenty\Modules\Order\Pdf\Models

Properties
Name Type Description

language

string

advice

string

sums

array

link

string

image

string

imageHeight

int

imageWidth

int

Methods
public toArray()

Returns this model as an array.

Referrer

Contracts

OrderReferrerRepositoryContract

Provides methods for processing order referrers. An order referrer indicates where a purchase was made originally.

Namespace

Plenty\Modules\Order\Referrer\Contracts

Methods
public getList($columns = [], $filterable = false):void

List order referrers

Parameters

Name

Type

Description

$columns

array

The columns (attributes) to load in the instances.

$filterable

bool

Return type: PaginatedResult

Search for referrers

Parameters

Name

Type

Description

$page

int

$itemsPerPage

int

$sortBy

string

$sortOrder

string

public create($data, $parentReferrerId = null):Plenty\Modules\Order\Referrer\Models\OrderReferrer
Return type: OrderReferrer

Create an order referrer

Parameters

Name

Type

Description

$data

array

The order referrer data. The properties that are required to create an order referrer can be found in the order referrer model.

$parentReferrerId

float

If a parent referrer ID is specified, the new referrer will be created as a sub referrer to this one and will be assigned a sub referrer ID. Sub referrer IDs are build of an integer part and a fractional part. The integer part is the parent ID followed by a 2 character long fractional part. This way the relation between a sub referrer and the parent referrer can be seen easily.

public update($data, $referrerId):Plenty\Modules\Order\Referrer\Models\OrderReferrer
Return type: OrderReferrer

Update an order referrer

Parameters

Name

Type

Description

$data

array

The order referrer data. The properties that are required to update an order referrer can be found in the order referrer model.

$referrerId

float

The ID of the order referrer

public getReferrerById($referrerId, $columns = []):Plenty\Modules\Order\Referrer\Models\OrderReferrer
Return type: OrderReferrer

Get an order referrer

Parameters

Name

Type

Description

$referrerId

float

The ID of the order referrer

$columns

array

The columns (attributes) to load in the instances.

public delete($referrerId):bool

Delete an order referrer.

Parameters

Name

Type

Description

$referrerId

float

The ID of the order referrer

public getNextFreeMainReferrerId():float

Get next free main referrer ID

public clearCriteria():void

Resets all Criteria filters by creating a new instance of the builder object.

public applyCriteriaFromFilters():void

Applies criteria classes to the current repository.

public setFilters($filters = []):void

Sets the filter array.

Parameters

Name

Type

Description

$filters

array

public getFilters():void

Returns the filter array.

public getConditions():void

Returns a collection of parsed filters as Condition object

public clearFilters():void

Clears the filter array.

Models

OrderReferrer

The order referrer model. An order referrer shows where a purchase was originally made.

Namespace

Plenty\Modules\Order\Referrer\Models

Properties
Name Type Description

id

float

The ID of the order referrer

isEditable

bool

Flag that indicates if this referrer can be updated as well as deleted or not <ul><li>True = the referrer can be edited and deleted</li> <li>False = the referrer can neither be edited nor deleted</li></ul>

backendName

string

The backend name of the referrer

name

string

The public name of the referrer as it is displayed e.g. on documents

orderOwnerId

int

The user ID of whoever owns new orders from this referrer

isFilterable

bool

Flag that indicates if this referrer can be used as a filter or not <ul><li>True = Can be used as a filter</li> <li>False = Cannot be used as a filter</li></ul>

origin

string

The origin of this referrer

showInLeads

bool

Referrer is showed in list when creating a new lead

Methods
public toArray()

Returns this model as an array.

Scheduler

Models

OrderScheduler

The legacy order model

Namespace

Plenty\Modules\Order\Scheduler\Models

Properties
Name Type Description

id

int

The order id.

contactId

int

The contact id.

methodOfPayment

int

start

last

end

deliveryAddress

Address

billingAddress

Address

addresses

Collection

addressRelations

Collection

Methods
public toArray()

Returns this model as an array.

SerialNumber

Contracts

OrderSerialNumberRepositoryContract

List serial numbers for orders

Namespace

Plenty\Modules\Order\SerialNumber\Contracts

Methods
public listSerialNumbersByOrder($orderId):void

List serial numbers of an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public listSerialNumbersByOrderItem($orderItemId):void

List serial numbers if an order item

Parameters

Name

Type

Description

$orderItemId

int

The ID of the order item

public addSerialNumberToOrderItem($orderSerialNumber):Plenty\Modules\Order\SerialNumber\Models\OrderSerialNumber
Return type: OrderSerialNumber

Create item serial number and bind it to order item

Parameters

Name

Type

Description

$orderSerialNumber

array

Order serial number data

Models

OrderSerialNumber

The order serial number model

Namespace

Plenty\Modules\Order\SerialNumber\Models

Properties
Name Type Description

serialNumberId

int

The ID of the serial number

orderId

int

The ID of the order

orderItemId

int

The ID of the order item

serialNumber

string

The serial number

itemSerialNumber

ItemSerialNumber

Methods
public toArray()

Returns this model as an array.

Shipping

Contracts

EUCountryCodesServiceContract

The EUCountryCodesServiceContract model

Namespace

Plenty\Modules\Order\Shipping\Contracts

Methods
public isEUCountry($countryId, $date = null):bool
Parameters

Name

Type

Description

$countryId

int

$date

string

public hasCommunityTax($countryId, $date = null):bool
Parameters

Name

Type

Description

$countryId

int

$date

string

public getTaxTerritory($countryId, $date = null):int
Parameters

Name

Type

Description

$countryId

int

$date

string

public hasCommunityToll($countryId, $date = null):bool
Parameters

Name

Type

Description

$countryId

int

$date

string

public getTollTerritory($countryId, $date = null):int
Parameters

Name

Type

Description

$countryId

int

$date

string

public isExportDelivery($countryId, $merchandCountryId = null, $date = null):bool
Parameters

Name

Type

Description

$countryId

int

$merchandCountryId

int

$date

string

ParcelServicePresetRepositoryContract

The ParcelServicePresetRepositoryContract is the interface for the shipping profile repository. This interface allows to get a shipping profile by the ID or list all shipping profiles.

Namespace

Plenty\Modules\Order\Shipping\Contracts

Methods
public getPresetList($columns = [], $with = null, $parcelServiceName = null, $filters = []):void

Lists shipping profiles.

Parameters

Name

Type

Description

$columns

array

The columns (attributes) to retrieve

$with

string

The parameter contains the name of an relation

$parcelServiceName

string

Filter that restricts the search result to parcel service presets with a specified service name (e.g. 'DHL' for DHL)

$filters

array

Possible attributes are updatedAtBefore and updatedAtAfter (yyyy-mm-dd or yyyy-mm-dd hh:mm:ss)

public getPresetById($presetId, $columns = []):Plenty\Modules\Order\Shipping\ParcelService\Models\ParcelServicePreset
Return type: ParcelServicePreset

Gets a shipping profile. The ID of the shipping profile must be specified.

Parameters

Name

Type

Description

$presetId

int

The ID of the shipping profile

$columns

array

The columns (attributes) to retrieve

public getPresetNamesById($presetId):array

Gets a shipping profile names in all langauges. The ID of the shipping profile must be specified.

Parameters

Name

Type

Description

$presetId

int

The ID of the shipping profile

public getLastWeightedPresetCombinations($basket, $contactClass, $customParams = []):array

Calculate shipping costs and list last weighted preset combinations.

Parameters

Name

Type

Description

$basket

Basket

The basket

$contactClass

int

The ID of the contact class

$customParams

array

User-defined parameters

public getPreviewList($language = null, $useBackendName = false):array

Get an array with all parcel service preset with the ID as key and the name as value.

Parameters

Name

Type

Description

$language

string

The names will be returned in this language.

$useBackendName

bool

Use the backend name instead of the external name?

public create($data):Plenty\Modules\Order\Shipping\ParcelService\Models\ParcelServicePreset
Return type: ParcelServicePreset

Creates an parcel service preset

Parameters

Name

Type

Description

$data

array

The data as an associative array

public update($data, $id):Plenty\Modules\Order\Shipping\ParcelService\Models\ParcelServicePreset
Return type: ParcelServicePreset

Update an parcel service preset

Parameters

Name

Type

Description

$data

array

The data as an associative array

$id

int

The ID of the shipping profile

public delete($id):Plenty\Modules\Order\Shipping\ParcelService\Models\ParcelServicePreset
Return type: ParcelServicePreset

Delete a parcel service preset

Parameters

Name

Type

Description

$id

int

The ID of parcel service preset

public clearCriteria():void

Resets all Criteria filters by creating a new instance of the builder object.

public applyCriteriaFromFilters():void

Applies criteria classes to the current repository.

public setFilters($filters = []):void

Sets the filter array.

Parameters

Name

Type

Description

$filters

array

public getFilters():void

Returns the filter array.

public getConditions():void

Returns a collection of parsed filters as Condition object

public clearFilters():void

Clears the filter array.

Events

AfterShippingCostCalculated

An event class fired after the shipping calculation is done. Listeners can add fees to the shipping costs. * The shipping provider type name is mandatory. The ID of the order is optional.

Namespace

Plenty\Modules\Order\Shipping\Events

Methods
public getShippingServiceProvider():int

Get the shipping service provider

public __construct($shippingServiceProvider, $orderId, $shippingProfileId):void

AfterShippingCostCalculated constructor.

Parameters

Name

Type

Description

$shippingServiceProvider

string

The name of the shipping service provider

$orderId

int

The ID of the order

$shippingProfileId

int

The ID of the shipping profile

public getOrderId():int

Get the ID of the order.

public getAdditonalFee():float

Get the additional fee.

public addAdditionalFee($additionalFee):Plenty\Modules\Order\Shipping\Events\AfterShippingCostCalculated
Return type: AfterShippingCostCalculated

Set the additional fee.

Parameters

Name

Type

Description

$additionalFee

float

The additional fee

public getShippingProfileId():int

Get the ID of the shipping profile.

public setShippingProfileId($shippingProfileId):void

Set the ID of the shipping profile.

Parameters

Name

Type

Description

$shippingProfileId

int

The ID of the shipping profile

Models

DefaultShipping

The Default Shipping model is used to define the standard referrer, the standard shipping region and the payment methods.

Namespace

Plenty\Modules\Order\Shipping\Models

Properties
Name Type Description

id

int

The ID of the entry

referrerId

float

The ID of the referrer

shippingDestinationId

int

The ID of the shipping region

position

int

The position

paymentMethod1

int

The first payment method

paymentMethod2

int

The second payment method

paymentMethod3

int

The third payment method

Methods
public toArray()

Returns this model as an array.

Countries

Contracts

CountryRepositoryContract

Repository for Country

Namespace

Plenty\Modules\Order\Shipping\Countries\Contracts

Methods
public findIsoCode($countryId, $isoCodeType):string

Finds the ISO-Code

Parameters

Name

Type

Description

$countryId

int

$isoCodeType

string

public getCountryById($countryId):Plenty\Modules\Order\Shipping\Countries\Models\Country
Return type: Country

Gets a country

Parameters

Name

Type

Description

$countryId

int

public getCountriesList($active, $with, $onlyEUCountries = null):Illuminate\Support\Collection
Return type: Collection

Get countries

Parameters

Name

Type

Description

$active

int

$with

array

$onlyEUCountries

int

public getActiveCountriesList():Illuminate\Support\Collection
Return type: Collection

Get active countries

public getActiveCountryNameMap($language):array

Get names of countries

Parameters

Name

Type

Description

$language

string

public getCountryByIso($isoCode, $isoType):void

Gets a country.

Parameters

Name

Type

Description

$isoCode

string

$isoType

string

('isoCode2', 'isoCode3')

public getCountryStateByIso($countryId, $isoCode):Plenty\Modules\Order\Shipping\Countries\Models\CountryState
Return type: CountryState

Gets a country state

Parameters

Name

Type

Description

$countryId

int

$isoCode

string

public activateCountry($countryId):Plenty\Modules\Order\Shipping\Countries\Models\Country
Return type: Country

Activates a country

Parameters

Name

Type

Description

$countryId

int

public deactivateCountry($countryId):Plenty\Modules\Order\Shipping\Countries\Models\Country
Return type: Country

Deactivates a country

Parameters

Name

Type

Description

$countryId

int

public shouldKeepEUCountry($country):void
Parameters

Name

Type

Description

$country

Models

Country

The country model representing a country with allocated states and a list of names in different languages.

Namespace

Plenty\Modules\Order\Shipping\Countries\Models

Properties
Name Type Description

id

int

The country id.

name

string

The system country name.

shippingDestinationId

int

The shipping destination (region) id.

active

int

The active flag (1: active, 2: backend active, 3: supplier active

storehouseId

int

The id of the main warehouse in this country.

isoCode2

string

The ISO 3166 ALPHA-2 code of the country.

isoCode3

string

The ISO 3166 ALPHA-3 code of the country.

lang

string

The main language spoken in the country.

isCountryStateMandatory

bool

Flag that states if a country state is mandatory for the country.

states

array

An array with country states.

names

array

An array with country names in different languages.

vatCodes

array

An array with country vat codes.

region

ParcelServiceRegionName

The region of the country.

currencies

Methods
public toArray()

Returns this model as an array.

CountryName

The CountryName model containing a name of a country in a specified language.

Namespace

Plenty\Modules\Order\Shipping\Countries\Models

Properties
Name Type Description

id

int

language

string

name

string

Methods
public toArray()

Returns this model as an array.

CountryState

The CountryState model representing a state which belongs to a country specified by the countryId.

Namespace

Plenty\Modules\Order\Shipping\Countries\Models

Properties
Name Type Description

id

int

countryId

int

isoCode

string

name

string

isoCode3166

string

Methods
public toArray()

Returns this model as an array.

ExportDocuments

Contracts

ExportDocumentsContract

Repository for Export Documents

Namespace

Plenty\Modules\Order\Shipping\ExportDocuments\Contracts

Methods
public listExportDocumentsByOrderId($orderId):Plenty\Modules\Order\Shipping\ExportDocuments\Models\ExportDocument
Return type: ExportDocument

List export documents by order ID

Parameters

Name

Type

Description

$orderId

int

Models

ExportDocument

The Export Document model

Namespace

Plenty\Modules\Order\Shipping\ExportDocuments\Models

Properties
Name Type Description

id

int

orderId

int

packageNumber

int

base64Content

int

Methods
public toArray()

Returns this model as an array.

Information

Contracts

ShippingInformationRepositoryContract

The ShippingInformationRepositoryContract is the interface for the shipping information repository. This interface allows to get shipping information by order ID, create new shipping information or update shipping information.

Namespace

Plenty\Modules\Order\Shipping\Information\Contracts

Methods
public getShippingInformationByOrderId($orderId):Plenty\Modules\Order\Shipping\Information\Models\ShippingInformation
Return type: ShippingInformation

Get Shipping Information by an order ID.

Parameters

Name

Type

Description

$orderId

int

The ID of the Order

public getShippingExportLabelByOrderId($orderId):void

Get export label for an order ID.

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public getOrdersShippingInformation($searchParams):array

Get all the orders with their shipping information

Parameters

Name

Type

Description

$searchParams

array

public listOrdersShippingInformation($searchParams, $itemsPerPage = null, $page = null):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

Get all the orders with their shipping information in a paginated form

Parameters

Name

Type

Description

$searchParams

array

$itemsPerPage

int

$page

int

public resetShippingInformation($orderId):void

Delete Shipping Information by an order ID

Parameters

Name

Type

Description

$orderId

int

The ID of the Order

public saveShippingInformation($data):Plenty\Modules\Order\Shipping\Information\Models\ShippingInformation
Return type: ShippingInformation

Create Shipping Information

Parameters

Name

Type

Description

$data

array

The shipping information data as associative array.

public updateAdditionalData($data, $orderId):Plenty\Modules\Order\Shipping\Information\Models\ShippingInformation
Return type: ShippingInformation

Update Additional Data of Shipping Information by Order ID

Parameters

Name

Type

Description

$data

array

The additional data as associative array.

$orderId

int

The ID of the order.

public updateShippingStatus($data, $orderId):Plenty\Modules\Order\Shipping\Information\Models\ShippingInformation
Return type: ShippingInformation

Update Shipping Status of Shipping Information by Order ID

Parameters

Name

Type

Description

$data

array

The status data as associative array.

$orderId

int

The ID of the order.

Models

ShippingInformation

The ShippingInformationModel represents additional shipping information for an order.

Namespace

Plenty\Modules\Order\Shipping\Information\Models

Properties
Name Type Description

orderId

int

The ID of the order

shippingServiceProvider

string

The name of the shipping service provider

transactionId

string

The ID of the transaction

shippingStatus

string

The shipping status. Possible values are 'open', 'prepared' and 'registered'.

shippingCosts

float

The shipping costs

additionalData

string

The additional data. Depending on the shipping service provider selected, this data may contain different information, e.g. shipping service, email address and order ID.

registrationAt

int

The date and time the shipment was registered

shipmentAt

int

The date the items will be shipped

Methods
public toArray()

Returns this model as an array.

Package

Contracts

OrderShippingPackageItemsRepositoryContract

Create and get items in packages from order

Namespace

Plenty\Modules\Order\Shipping\Package\Contracts

Methods
public getItemsForPackage($packageId, $page = 1, $perPage = 1000, $sortBy = &quot;id&quot;, $sortOrder = &quot;desc&quot;):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackageItems
Return type: OrderShippingPackageItems

Get items for a package

Parameters

Name

Type

Description

$packageId

int

The ID of the package

$page

int

$perPage

int

$sortBy

string

$sortOrder

string

public getItemsInPackagesPalletsPaginated($orderId, $page = 1, $perPage = 1000, $sortBy = &quot;id&quot;, $sortOrder = &quot;asc&quot;):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackageItems
Return type: OrderShippingPackageItems

Get all the packed items in the packages in the pallets in the order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$page

int

$perPage

int

$sortBy

string

$sortOrder

string

public getItemsFromPackagesForOrder($orderId):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackageItems
Return type: OrderShippingPackageItems

Get items for an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public getPackedItemsPerPackageForOrder($orderId):array

Get packed items in an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public getPackedItemsFromPackage($packageId, $with = [], $page = 1, $perPage = 25, $sortBy = &quot;variationId&quot;, $sortOrder = &quot;asc&quot;):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackageItems
Return type: OrderShippingPackageItems

Get packed items in a package

Parameters

Name

Type

Description

$packageId

int

The ID of the package for which you want to get the items for

$with

array

Possible value is 'images' to get also the images for the items

$page

int

The page to get. By default, we take the first page

$perPage

int

The number of variations to get per each page. By default, we take 25 variations per page

$sortBy

string

The column for which to sort the values with. Default value is 'variationId'

$sortOrder

string

The order in which to sort the values. Possible values are 'asc' and 'desc'. Default value is ascending

public getUnpackedItemsFromPackagesForOrder($orderId):array

Get unpacked items for an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public getUnpackedItemsForOrderPaginated($orderId, $page = 1, $perPage = 25, $sortBy = &quot;itemVariationId&quot;, $sortOrder = &quot;asc&quot;):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackageItems
Return type: OrderShippingPackageItems

Get all the unpacked items in the order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$page

int

The page to get. By default, we take the first page

$perPage

int

The number of variations to get per each page. By default, we take 25 variations per page

$sortBy

string

The column for which to sort the values with. Default value is 'itemVariationId'

$sortOrder

string

The order in which to sort the values. Possible values are 'asc' and 'desc'. Default value is ascending

public createItemsForPackageOrder($data, $packageId, $isCallFromLegacyCode = false):array

Create items for a package

Parameters

Name

Type

Description

$data

array

Array with data including item id, variation id and the quantity of the item in package

$packageId

int

The ID of the package. This ID is optional. If the ID is not provided, it must be present in the $data array

$isCallFromLegacyCode

bool

Optional. Flag to see if the call of this method is from legacy code or new code

public updateItemsInOrderShippingPackage($id, $data):int

Update package, variation or quantity for an order

Parameters

Name

Type

Description

$id

int

The ID of the order package item variation

$data

array

Array with data including package id, item id, variation id and/or the quantity of the item in package

public deleteItemsInOrderShippingPackage($id):int

Delete a variation of an item from package in an order

Parameters

Name

Type

Description

$id

int

The ID of the order package item variation

public updateItemsFromPackage($packageId, $itemId, $variationId, $data):int
Deprecated!

This method will not be supported in the future. Please refrain from using it as soon as possible.

Update items in a package

Parameters

Name

Type

Description

$packageId

int

The ID of the package

$itemId

int

The ID of the item

$variationId

int

The ID of the variation

$data

array

Array with data including item id, variation id and the quantity of the item in package

public deleteItemsFromPackage($packageId, $itemId, $variationId):Plenty\Repositories\Models\DeleteResponse
Deprecated!

This method will not be supported in the future. Please refrain from using it as soon as possible.

Return type: DeleteResponse

Delete a variation of an item from package in order

Parameters

Name

Type

Description

$packageId

int

The ID of the package

$itemId

int

The ID of the item

$variationId

int

The ID of the variation

OrderShippingPackageRepositoryContract

Create, get, update and delete order shipping packages.

Namespace

Plenty\Modules\Order\Shipping\Package\Contracts

Methods
public getOrderShippingPackage($orderShippingPackageId, $columns = [], $orderId = null):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackage
Return type: OrderShippingPackage

Get an order shipping package

Parameters

Name

Type

Description

$orderShippingPackageId

int

The ID of the order shipping package

$columns

array

The properties to be loaded

$orderId

int

The ID of an order

public listOrderShippingPackages($orderId, $columns = [], $with = [], $packageInputData = []):array

List order shipping packages

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$columns

array

The properties to be loaded

$with

array

(optional) Possible value is 'labelBase64' to get the label with the response

$packageInputData

array

(optional) The package data which is being added by the user in the UI

public getOrderShippingPackagesPaginated($orderId, $with = [], $page = 1, $perPage = 1000, $sortBy = &quot;id&quot;, $sortOrder = &quot;desc&quot;):array

Get all the packages for the given order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$with

array

(Optional) Possible values are 'labelBase64', 'items' to get the label and/or the items with the response

$page

int

$perPage

int

$sortBy

string

$sortOrder

string

public getPackagesFromPallet($palletId, $with = [], $page = 1, $perPage = 1000, $sortBy = &quot;id&quot;, $sortOrder = &quot;desc&quot;):array
Parameters

Name

Type

Description

$palletId

int

$with

array

$page

int

$perPage

int

$sortBy

string

$sortOrder

string

public createOrderShippingPackage($orderId, $data):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackage
Return type: OrderShippingPackage

Create an order shipping package

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$data

array

The request data

public updateOrderShippingPackage($orderShippingPackageId, $data):Plenty\Modules\Order\Shipping\Package\Models\OrderShippingPackage
Return type: OrderShippingPackage

Update an order shipping package

Parameters

Name

Type

Description

$orderShippingPackageId

int

The ID of the order shipping package

$data

array

The request data

public deleteOrderShippingPackage($orderShippingPackageId):void

Delete an order shipping package

Parameters

Name

Type

Description

$orderShippingPackageId

int

The ID of the order shipping package

public deleteAllPackagesInPallet($orderId, $palletId):void

Delete all order shipping packages in a pallet

Parameters

Name

Type

Description

$orderId

int

The ID of the order shipping package

$palletId

int

The ID of the pallet

public updateAllPackagesInPallet($orderId, $palletId, $data):void

Update all the packages in a pallet.

Parameters

Name

Type

Description

$orderId

int

$palletId

int

$data

array

Models

OrderShippingPackage

The order shipping package model

Namespace

Plenty\Modules\Order\Shipping\Package\Models

Properties
Name Type Description

id

int

The ID of the order shipping package

orderId

int

The ID of the order

packageId

int

The ID of the package

weight

int

The weight of the package in grams

packageNumber

string

The package number

labelPath

string

The path to the label

labelBase64

string

The base64 encoded label

exportLabelBase64

string

The base64 encoded export label

returnPackageNumber

string

The return package number

packageType

int

The type of the package. The following types are valid: <ul> <li>0: unpacked</li> <li>1: Bale</li> <li>2: Dispenser</li> <li>3: Coil</li> <li>4: Roll pallet</li> <li>5: Colli</li> <li>6: Container</li> <li>7: Bucket</li> <li>8: Cask</li> <li>9: Bottles</li> <li>10: European flat pallet</li> <li>11: Structural frame</li> <li>12: Gas cylinder</li> <li>13: Pallet cage</li> <li>14: Hobbock</li> <li>15: Half pallet</li> <li>16: Pallet of food items</li> <li>17: Wooden coaster</li> <li>18: IBC container</li> <li>19: Pitcher</li> <li>20: Wicker bottle</li> <li>21: Case</li> <li>22: Canister</li> <li>23: Customer pallet</li> <li>24: Cardboard box</li> <li>25: Composite packaging</li> <li>26: Package</li> <li>27: Ring</li> <li>28: Role</li> <li>29: Sack</li> <li>30: units</li> <li>31: Tank</li> <li>32: Drum</li> <li>34: Crate</li> <li>35: Quarter pallet</li> <li>36: Other pallets</li> <li>37: Bin</li> <li>38: One-way pallet</li> <li>39: Foil bag</li> </ul>

volume

float

The volume of the package

palletId

int

The id of the pallet of which the package belong to

isClosed

bool

Flag to say if the package is editable or not

createdAt

string

updatedAt

string

packageSscc

string

Amazon Vendor PackageSscc

mrn

string

Movement Reference Number (MRN)

atlasRegistration

int

ATLAS export declaration

order

Order

The order the package belongs to

items

OrderShippingPackageItems

The items inside the package.

Methods
public toArray()

Returns this model as an array.

OrderShippingPackageItems

The relation between package, item and variation model

Namespace

Plenty\Modules\Order\Shipping\Package\Models

Properties
Name Type Description

id

int

The ID of the order shipping package item. Primary key auto-increment

packageId

int

The ID of the package (id column from plenty_package_type2order)

itemId

int

The ID of the item (plenty_item_variation_base_item_id column from plenty_item_variation_base)

variationId

int

The ID of the variation (plenty_item_variation_base_id column from plenty_item_variation_base)

itemQuantity

float

The quantity of the item in the package

Methods
public toArray()

Returns this model as an array.

PackageType

Contracts

ShippingPackageTypeRepositoryContract

The ShippingPackageTypeRepositoryContract is the interface for the shipping package type repository. This interface allows to list all shipping package types or to get a shipping package type by the ID.

Namespace

Plenty\Modules\Order\Shipping\PackageType\Contracts

Methods
public findShippingPackageTypeById($shippingPackageTypeId):Plenty\Modules\Order\Shipping\PackageType\Models\ShippingPackageType
Return type: ShippingPackageType

Gets a shipping package type. The ID of the shipping package type must be specified.

Parameters

Name

Type

Description

$shippingPackageTypeId

int

The ID of the shipping package type

public listShippingPackageTypes():array

Lists shipping packages types.

Models

ShippingPackageType

The shipping package type model.

Namespace

Plenty\Modules\Order\Shipping\PackageType\Models

Properties
Name Type Description

id

int

The ID of the shipping package type

name

string

The name of the shipping package type

width

int

The width of the shipping package type

height

int

The height of the shipping package type

length

int

The length of the shipping package type

unit

string

The unit of the shipping package type dimension

maxWeight

int

The maximum weight of the shipping package type

maxVolume

int

The maximum volume of the shipping package type

volumeType

int

The volume type of the shipping package type

Methods
public toArray()

Returns this model as an array.

Pallet

Contracts

OrderShippingPalletRepositoryContract

Create, get, update and delete order shipping pallet.

Namespace

Plenty\Modules\Order\Shipping\Pallet\Contracts

Methods
public getOrderShippingPallet($orderShippingPalletId):Plenty\Modules\Order\Shipping\Pallet\Models\OrderShippingPallet
Return type: OrderShippingPallet

Get an order shipping pallet

Parameters

Name

Type

Description

$orderShippingPalletId

int

The ID of the order shipping pallet

public listOrderShippingPallets($filters, $with):array

List order shipping pallets

Parameters

Name

Type

Description

$filters

array

$with

array

public listPalletPackages($orderShippingPalletId, $orderId):array

Get all the packages in a pallet

Parameters

Name

Type

Description

$orderShippingPalletId

int

$orderId

int

public getPalletsFromOrders($orderIds):array

Get all pallets from given order IDs

Parameters

Name

Type

Description

$orderIds

array

public createOrderShippingPallet($data):Plenty\Modules\Order\Shipping\Pallet\Models\OrderShippingPallet
Return type: OrderShippingPallet

Create an order shipping pallet

Parameters

Name

Type

Description

$data

array

The request data

public updateOrderShippingPallet($orderShippingPalletId, $data):Plenty\Modules\Order\Shipping\Pallet\Models\OrderShippingPallet
Return type: OrderShippingPallet

Update an order shipping pallet

Parameters

Name

Type

Description

$orderShippingPalletId

int

The ID of the order shipping pallet

$data

array

The request data

public deleteOrderShippingPallet($orderShippingPalletId):Plenty\Modules\Order\Shipping\Pallet\Models\OrderShippingPallet
Return type: OrderShippingPallet

Delete an order shipping pallet

Parameters

Name

Type

Description

$orderShippingPalletId

int

The ID of the order shipping pallet

public clearCriteria():void

Resets all Criteria filters by creating a new instance of the builder object.

public applyCriteriaFromFilters():void

Applies criteria classes to the current repository.

public setFilters($filters = []):void

Sets the filter array.

Parameters

Name

Type

Description

$filters

array

public getFilters():void

Returns the filter array.

public getConditions():void

Returns a collection of parsed filters as Condition object

public clearFilters():void

Clears the filter array.

Models

OrderShippingPallet

The order shipping pallet model.

Namespace

Plenty\Modules\Order\Shipping\Pallet\Models

Properties
Name Type Description

id

int

The ID of the order shipping pallet

weight

float

The weight of the order shipping pallet, including it’s contents

individualWeight

float

The weight of the order shipping pallet

width

float

The width of the order shipping pallet

height

float

The height of the order shipping pallet

length

float

The length of the order shipping pallet

isStackable

bool

Flag to tell if the pallet is stackable or not. If true, another pallet can be placed over the current one

additionalInfo

int

Additional info

barcode

string

The barcode

isClosed

bool

Flag to tell if the pallet is closed or not. If true, the information within the pallet should not be changed anymore

palletSscc

string

Amazon Vendor PalletSscc

orderId

int

The id of the order

Methods
public toArray()

Returns this model as an array.

ParcelService

Contracts

ParcelServiceConstraintRepositoryContract

The ParcelServiceConstraintRepositoryContract is the interface for the parcel service constraint type repository.

Namespace

Plenty\Modules\Order\Shipping\ParcelService\Contracts

Methods
public create($data):void

Create a new parcel service constraint entry

Parameters

Name

Type

Description

$data

array

public getById($id):void

Fetch parcel service constraint by ID

Parameters

Name

Type

Description

$id

int

public delete($id):void

Delete a parcel service constant by ID

Parameters

Name

Type

Description

$id

int

Models

ParcelService

The Parcel Service Model

Namespace

Plenty\Modules\Order\Shipping\ParcelService\Models

Properties
Name Type Description

id

int

backendName

string

trackingUrl

string

shippingServiceProviderId

int

shippingServiceProviderAddress

string

splitTrackingUrl

int

splitDelimiter

string

shippingServiceProvider

ShippingServiceProvider

parcelServiceNames

Methods
public toArray()

Returns this model as an array.

ParcelServiceConstraint

The Parcel Service Constraint Model

Namespace

Plenty\Modules\Order\Shipping\ParcelService\Models

Properties
Name Type Description

parcelServiceRegionId

int

constraintType

int

subConstraintType

int

constraintLimit

int

cost

int

startValue

int

Methods
public toArray()

Returns this model as an array.

ParcelServiceName

The Parcel Service Name Model

Namespace

Plenty\Modules\Order\Shipping\ParcelService\Models

Properties
Name Type Description

parcelServiceId

int

name

string

lang

string

Methods
public toArray()

Returns this model as an array.

ParcelServicePreset

The Parcel Service Preset Model

Namespace

Plenty\Modules\Order\Shipping\ParcelService\Models

Properties
Name Type Description

id

int

The ID of the shipping profile (autoincrement value)

parcelServiceId

int

The ID of the shipping service provider

backendName

string

The back end name of the shipping profile

flag

int

The icon of the shipping profile

priority

int

The priority of the shipping profile

category

int

The category of the shipping profile

useArticlePorto

int

Flag that indicates if the extra shipping charge saved in the item data record is used

isInsured

int

Flag that indicates if the shipping profile is insured

isExpress

int

Flag that indicates if the shipping profile is used for express delivery

isPostident

int

Flag that indicates if the shipping profile includes an authority verification

isDefaultEnabled

int

Flag that indicates if the shipping profile is automatically assigned to new items

islandFee

float

The extra charge for islands saved in the shipping profile

isCod

int

Flag that indicates Cash on Delivery

supportedMultishop

array

The clients (stores) that are activated for the shipping profile

supportedReferrer

array

The order referrers that are activated for the shipping profile

subreferrerSupport

array

This field is currently without any function.

excludedPaymentMethods

array

The blocked payment methods that are not offered for the shipping profile

excludedCustomerGroups

array

The blocked customer groups for the shipping profile. Blocked customer groups cannot select the shipping profile during checkout.

shippingGroup

string

The group of the shipping profile

dispatchIdentifier

string

This field is currently without any function.

auctionType

int

The eBay listing type for the shipping profile

supportedLoyaltyPrograms

array

The loyalty programs that are supported by the shipping profile

updatedAt

string

The date the shipping profile was last updated

parcelServicePresetNames

array

parcelServiceNames

array

showDataPrivacyAgreementHint

int

transmitPrivacyRule

string

alternativeEmail

string

alternativePhone

string

isParcelBox

int

Indicates whether the e.g. paketshop is supported

isPostOffice

int

Indicates whether the e.g. postfiliale is supported

parcelService

ParcelService

The parcel service.

parcelServiceRegionConstraint

ParcelServiceRegion

The parcel service region constraint

Methods
public toArray()

Returns this model as an array.

ParcelServicePresetName

The Parcel Service Preset Name Model

Namespace

Plenty\Modules\Order\Shipping\ParcelService\Models

Properties
Name Type Description

presetId

int

name

string

lang

string

Methods
public toArray()

Returns this model as an array.

ParcelServiceRegion

Contracts

ParcelServiceRegionNameRepositoryContract

Get parcel service region name

Namespace

Plenty\Modules\Order\Shipping\ParcelServiceRegion\Contracts

Methods
public create($data):Plenty\Modules\Order\Shipping\ParcelServiceRegion\Models\ParcelServiceRegionName
Return type: ParcelServiceRegionName

Creates a Region

Parameters

Name

Type

Description

$data

array

public getAllRegions():array

Return all the regions

ParcelServiceRegionRepositoryContract

Get parcel service region

Namespace

Plenty\Modules\Order\Shipping\ParcelServiceRegion\Contracts

Methods
public create($data):Plenty\Modules\Order\Shipping\ParcelServiceRegion\Models\ParcelServiceRegion
Return type: ParcelServiceRegion

Creates a ParcelServiceRegion

Parameters

Name

Type

Description

$data

array

public delete($id):void

Deletes a ParcelServiceRegion

Parameters

Name

Type

Description

$id

int

public getParcelServiceRegion($parcelServiceRegionId, $columns = []):Plenty\Modules\Order\Shipping\ParcelServiceRegion\Models\ParcelServiceRegion
Return type: ParcelServiceRegion

Get a parcel service region

Parameters

Name

Type

Description

$parcelServiceRegionId

int

The ID of the parcel service region.

$columns

array

public listParcelServiceRegions($parcelServicePresetId, $columns = []):array

Lists parcel service regions by parcel service preset id.

Parameters

Name

Type

Description

$parcelServicePresetId

int

The ID of the parcel service preset.

$columns

array

Models

ParcelServiceRegion

The parcel service region model.

Namespace

Plenty\Modules\Order\Shipping\ParcelServiceRegion\Models

Properties
Name Type Description

id

int

The ID of the parcel service region

shippingRegionId

int

The ID of the shipping region

parcelServicePresetId

int

The ID of the parcel service preset

shippingRegionName

string

The name of the shipping region

serviceType

int

Type of the parcel service

Methods
public toArray()

Returns this model as an array.

ParcelServiceRegionName

The parcel service region name model.

Namespace

Plenty\Modules\Order\Shipping\ParcelServiceRegion\Models

Properties
Name Type Description

id

int

The ID of the parcel service region name

name

int

The name of the shipping region

Methods
public toArray()

Returns this model as an array.

Returns

Contracts

ReturnsRepositoryContract

The ReturnsRepositoryContract is the interface for the order returns repository. This interface allows to register, assign to order and list order returns.

Namespace

Plenty\Modules\Order\Shipping\Returns\Contracts

Methods
public registerReturns($pluginName, $orderIds):Plenty\Modules\Order\Shipping\Returns\Models\RegisterReturnsResult
Return type: RegisterReturnsResult

Register a new return

Parameters

Name

Type

Description

$pluginName

string

$orderIds

array

public getReturnsLabelById($labelId, $with):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

Get return label by ID

Parameters

Name

Type

Description

$labelId

int

$with

array

public assignLabel2Return($orderId, $returnsId):Plenty\Modules\Order\Shipping\Returns\Models\OrderReturns
Return type: OrderReturns

Assign return label to order

Parameters

Name

Type

Description

$orderId

int

$returnsId

int

public getOrderReturns($orderId, $with = [], $page = 1, $itemsPerPage = 50, $sortBy = &quot;id&quot;, $sortOrder = &quot;desc&quot;):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

Get a paginated list of all order returns

Parameters

Name

Type

Description

$orderId

int

$with

array

$page

int

$itemsPerPage

int

$sortBy

string

$sortOrder

string

public getOrderReturnsByReturnsOrderId($returnsOrderId, $with = [], $page = 1, $itemsPerPage = 50, $sortBy = &quot;id&quot;, $sortOrder = &quot;desc&quot;):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

Get a paginated list of all order returns

Parameters

Name

Type

Description

$returnsOrderId

int

$with

array

$page

int

$itemsPerPage

int

$sortBy

string

$sortOrder

string

public createReturnsOrder($orderId, $data):void

Create a return

Parameters

Name

Type

Description

$orderId

int

$data

array

public updateReturnsOrder($returnsOrderId, $data):void

Update existing return

Parameters

Name

Type

Description

$returnsOrderId

int

$data

array

public deleteReturnsByReturnsOrderId($returnsOrderId):void
Parameters

Name

Type

Description

$returnsOrderId

int

ReturnsServiceProviderRepositoryContract

The ReturnsServiceProviderRepositoryContract is the interface for the returns service provider repository. This interface allows to list returns service providers.

Namespace

Plenty\Modules\Order\Shipping\Returns\Contracts

Methods
public getReturnsServiceProviderList($columns = [], $page = 1, $itemsPerPage = 50, $filters = [], $with = []):Plenty\Repositories\Models\PaginatedResult
Return type: PaginatedResult

Get a paginated list of returns services providers

Parameters

Name

Type

Description

$columns

array

$page

int

$itemsPerPage

int

$filters

array

$with

array

public findById($returnsServiceProviderId):Plenty\Modules\Order\Shipping\Returns\Models\ReturnsServiceProvider
Return type: ReturnsServiceProvider

Find a returns service provider by ID

Parameters

Name

Type

Description

$returnsServiceProviderId

int

public findByName($returnsServiceProviderName):array

Find a returns service provider by name

Parameters

Name

Type

Description

$returnsServiceProviderName

string

public saveReturnsServiceProvider($pluginName, $returnProviderAlias = null):Plenty\Modules\Order\Shipping\Returns\Models\ReturnsServiceProvider
Return type: ReturnsServiceProvider

Save a returns service provider

Parameters

Name

Type

Description

$pluginName

string

$returnProviderAlias

string

public getReturnsServiceProvider($orderId):Plenty\Modules\Order\Shipping\Returns\Models\ReturnsServiceProvider
Return type: ReturnsServiceProvider

Get the returns service provider for an order

Parameters

Name

Type

Description

$orderId

int

public pluginList():void

Models

FailedRegisterOrderReturns

The FailedRegisterOrderReturns model.

Namespace

Plenty\Modules\Order\Shipping\Returns\Models

Methods
public addErrorMessage($errorMessage):void

Add a new error message

Parameters

Name

Type

Description

$errorMessage

string

public setOrderId($orderId):void

Set the order ID variable

Parameters

Name

Type

Description

$orderId

int

public addException($exception):void

Add a new exception object

Parameters

Name

Type

Description

$exception

public get($key):void
Parameters

Name

Type

Description

$key

string

public hasGetMutator($key):bool

Determine if a get mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public setAttributes($attributes):void
Parameters

Name

Type

Description

$attributes

public setAttribute($key, $value):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set a given attribute on the model.

Parameters

Name

Type

Description

$key

string

$value

public hasSetMutator($key):bool

Determine if a set mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public changeValue($key, $callback):void
Parameters

Name

Type

Description

$key

string

$callback

callable

public offsetExists($offset):bool
Parameters

Name

Type

Description

$offset

public offsetGet($offset):void
Parameters

Name

Type

Description

$offset

public offsetSet($offset, $value):void
Parameters

Name

Type

Description

$offset

$value

public offsetUnset($offset):void
Parameters

Name

Type

Description

$offset

public toArray($translate = false):array
Parameters

Name

Type

Description

$translate

bool

Flag indicating if values should be translated.

public toJson($options):string
Parameters

Name

Type

Description

$options

int

public jsonSerialize():void
public fill($attributes):Plenty\Repositories\Models\DataModel
Return type: DataModel

Fill the model with an array of attributes.

Parameters

Name

Type

Description

$attributes

array

public isFillable($key):bool

Determine if the given attribute may be mass assigned.

Parameters

Name

Type

Description

$key

string

public getFillable():array

Get the fillable attributes for the model.

public fillable($fillable):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set the fillable attributes for the model.

Parameters

Name

Type

Description

$fillable

array

public hasCast($key, $types = null):bool

Determine whether an attribute should be cast to a native type.

Parameters

Name

Type

Description

$key

string

$types

public fromJson($value, $asObject = false):void

Decode the given JSON back into an array or object.

Parameters

Name

Type

Description

$value

string

$asObject

bool

OrderReturns

The model for OrderReturns

Namespace

Plenty\Modules\Order\Shipping\Returns\Models

Properties
Name Type Description

id

int

orderId

int

returnsOrderId

int

providerId

int

createdAt

Carbon

fileName

string

externalNumber

string

externalData

string

availableUntil

Carbon

Methods
public toArray()

Returns this model as an array.

RegisterOrderReturnsResponse

The RegisterOrderReturnsResponse model.

Namespace

Plenty\Modules\Order\Shipping\Returns\Models

Methods
public addSuccessfullyRegisteredReturns($successfullyRegisteredReturn):void

Add successfully registered order returns

Parameters

Name

Type

Description

$successfullyRegisteredReturn

SuccessfullyRegisteredOrderReturns

public addFailedRegisterOrderReturns($failedRegisterOrderReturn):void

Add failed registered order returns

Parameters

Name

Type

Description

$failedRegisterOrderReturn

FailedRegisterOrderReturns

public get($key):void
Parameters

Name

Type

Description

$key

string

public hasGetMutator($key):bool

Determine if a get mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public setAttributes($attributes):void
Parameters

Name

Type

Description

$attributes

public setAttribute($key, $value):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set a given attribute on the model.

Parameters

Name

Type

Description

$key

string

$value

public hasSetMutator($key):bool

Determine if a set mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public changeValue($key, $callback):void
Parameters

Name

Type

Description

$key

string

$callback

callable

public offsetExists($offset):bool
Parameters

Name

Type

Description

$offset

public offsetGet($offset):void
Parameters

Name

Type

Description

$offset

public offsetSet($offset, $value):void
Parameters

Name

Type

Description

$offset

$value

public offsetUnset($offset):void
Parameters

Name

Type

Description

$offset

public toArray($translate = false):array
Parameters

Name

Type

Description

$translate

bool

Flag indicating if values should be translated.

public toJson($options):string
Parameters

Name

Type

Description

$options

int

public jsonSerialize():void
public fill($attributes):Plenty\Repositories\Models\DataModel
Return type: DataModel

Fill the model with an array of attributes.

Parameters

Name

Type

Description

$attributes

array

public isFillable($key):bool

Determine if the given attribute may be mass assigned.

Parameters

Name

Type

Description

$key

string

public getFillable():array

Get the fillable attributes for the model.

public fillable($fillable):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set the fillable attributes for the model.

Parameters

Name

Type

Description

$fillable

array

public hasCast($key, $types = null):bool

Determine whether an attribute should be cast to a native type.

Parameters

Name

Type

Description

$key

string

$types

public fromJson($value, $asObject = false):void

Decode the given JSON back into an array or object.

Parameters

Name

Type

Description

$value

string

$asObject

bool

RegisterReturnsResult

The model for RegisterReturnsResult

Namespace

Plenty\Modules\Order\Shipping\Returns\Models

Properties
Name Type Description

orderReturnsList

array

failedRegisterOrderReturnsList

array

Methods
public toArray()

Returns this model as an array.

ReturnsServiceProvider

The ReturnsServiceProvider model.

Namespace

Plenty\Modules\Order\Shipping\Returns\Models

Properties
Name Type Description

id

int

The ID of the returns service provider

name

string

The name of the returns service provider

pluginId

int

The optional ID of the plugin when the returns service provider is registered as a plugin

createdAt

The time the returns service provider was created

updatedAt

The time the returns service provider was updated

Methods
public toArray()

Returns this model as an array.

SuccessfullyRegisteredOrderReturns

The model for SuccessfullyRegisteredOrderReturns

Namespace

Plenty\Modules\Order\Shipping\Returns\Models

Methods
public setOrderId($orderId):void

Set orderId variable

Parameters

Name

Type

Description

$orderId

int

public setFileName($fileName):void

Set fileName variable

Parameters

Name

Type

Description

$fileName

string

public setExternalNumber($externalNumber):void

Set externalNumber variable

Parameters

Name

Type

Description

$externalNumber

string

public setExternalData($externalData):void

Set externalData variable

Parameters

Name

Type

Description

$externalData

array

public setAvailableUntil($availiableUntil):void

Set availableUntil variable

Parameters

Name

Type

Description

$availiableUntil

string

public setLabelBase64($labelBase64):void

Set labelBase64 variable

Parameters

Name

Type

Description

$labelBase64

string

public setReturnsOrderId($returnsOrderId):void

Set returnsOrderId variable

Parameters

Name

Type

Description

$returnsOrderId

int

public get($key):void
Parameters

Name

Type

Description

$key

string

public hasGetMutator($key):bool

Determine if a get mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public setAttributes($attributes):void
Parameters

Name

Type

Description

$attributes

public setAttribute($key, $value):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set a given attribute on the model.

Parameters

Name

Type

Description

$key

string

$value

public hasSetMutator($key):bool

Determine if a set mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public changeValue($key, $callback):void
Parameters

Name

Type

Description

$key

string

$callback

callable

public offsetExists($offset):bool
Parameters

Name

Type

Description

$offset

public offsetGet($offset):void
Parameters

Name

Type

Description

$offset

public offsetSet($offset, $value):void
Parameters

Name

Type

Description

$offset

$value

public offsetUnset($offset):void
Parameters

Name

Type

Description

$offset

public toArray($translate = false):array
Parameters

Name

Type

Description

$translate

bool

Flag indicating if values should be translated.

public toJson($options):string
Parameters

Name

Type

Description

$options

int

public jsonSerialize():void
public fill($attributes):Plenty\Repositories\Models\DataModel
Return type: DataModel

Fill the model with an array of attributes.

Parameters

Name

Type

Description

$attributes

array

public isFillable($key):bool

Determine if the given attribute may be mass assigned.

Parameters

Name

Type

Description

$key

string

public getFillable():array

Get the fillable attributes for the model.

public fillable($fillable):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set the fillable attributes for the model.

Parameters

Name

Type

Description

$fillable

array

public hasCast($key, $types = null):bool

Determine whether an attribute should be cast to a native type.

Parameters

Name

Type

Description

$key

string

$types

public fromJson($value, $asObject = false):void

Decode the given JSON back into an array or object.

Parameters

Name

Type

Description

$value

string

$asObject

bool

Services

RegisterReturnsService

The RegisterReturnsService class offers the possibility to register returns, get returns label and persist returns label.

Namespace

Plenty\Modules\Order\Shipping\Returns\Services

Methods
public registerReturns($pluginName, $orderIds):Plenty\Modules\Order\Shipping\Returns\Models\RegisterReturnsResult
Return type: RegisterReturnsResult

Register returns for each order ID

Parameters

Name

Type

Description

$pluginName

string

$orderIds

array

public persistLabel($labelBase64, $returns):Plenty\Modules\Document\Models\Document
Return type: Document

Save the return label in base64

Parameters

Name

Type

Description

$labelBase64

string

$returns

OrderReturns

public getLabel($orderReturns):string

Get the return label

Parameters

Name

Type

Description

$orderReturns

OrderReturns

ReturnsServiceProviderService

The ReturnsServiceProviderService class offers the possibility to register a returns service provider class and method that can be called by plentymarkets returns controllers.

Namespace

Plenty\Modules\Order\Shipping\Returns\Services

Methods
public registerReturnsProvider($returnsServiceProviderCode, $returnsServiceProviderLabel, $returnsServiceProviderClass, $useParentOrderId = true):bool

Register returns service provider

Parameters

Name

Type

Description

$returnsServiceProviderCode

string

$returnsServiceProviderLabel

string

$returnsServiceProviderClass

string

$useParentOrderId

bool

public getReturnsServiceProviderEntryById($providerId):Plenty\Modules\Order\Shipping\Returns\Services\Entries\ReturnsServiceProviderEntry
Return type: ReturnsServiceProviderEntry

Get returns service provider by id

Parameters

Name

Type

Description

$providerId

int

public hasReturnsServiceProviderMethod($returnsServiceProviderCode, $methodName):bool

Returns boolean whether the returns service provider has or has not the given method

Parameters

Name

Type

Description

$returnsServiceProviderCode

string

$methodName

string

Services

Entries

ReturnsServiceProviderEntry

The returns provider entry contains all information needed to use module returns in plentymarkets returns .

Namespace

Plenty\Modules\Order\Shipping\Returns\Services\Entries

Methods
public getReturnsServiceProviderLabel():string

Get the returns service provider label

public setReturnsServiceProviderLabel($returnsServiceProviderLabel):Plenty\Modules\Order\Shipping\Returns\Services\Entries\ReturnsServiceProviderEntry
Return type: ReturnsServiceProviderEntry

Set the returns service provider label

Parameters

Name

Type

Description

$returnsServiceProviderLabel

string

public getReturnsServiceProviderCode():string

Get the return service provider code

public setReturnsServiceProviderCode($returnsServiceProviderCode):Plenty\Modules\Order\Shipping\Returns\Services\Entries\ReturnsServiceProviderEntry
Return type: ReturnsServiceProviderEntry

Set the returns service provider code

Parameters

Name

Type

Description

$returnsServiceProviderCode

string

public getReturnsServiceProviderClass($methodName):string

Get the returns service provider class

Parameters

Name

Type

Description

$methodName

string

public methodExists($methodName):bool

Check if method exists in returnsServiceProviderClass

Parameters

Name

Type

Description

$methodName

string

public getProviderId():int

Get the provider ID

public getUseParentOrderId():bool

Get setting for using parent order ID

ShippingServiceProviderEntry

The shipping provider entry contains all information needed to use module shipping in plentymarkets shipping .

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Services\Entries

Methods
public getShippingServiceProviderClasses():array

Get the shipping service provider classes

public getShippingServiceProviderNames():void

Get the shipping service provider names

public setShippingServiceProviderNames($shippingServiceProviderNames):Plenty\Modules\Order\Shipping\ServiceProvider\Services\Entries\ShippingServiceProviderEntry
Return type: ShippingServiceProviderEntry

Set the shipping service provider names

Parameters

Name

Type

Description

$shippingServiceProviderNames

array

public getShippingServiceProviderCode():string

Get the shipping service provider code

public setShippingServiceProviderCode($shippingServiceProviderCode):Plenty\Modules\Order\Shipping\ServiceProvider\Services\Entries\ShippingServiceProviderEntry
Return type: ShippingServiceProviderEntry

Set the shipping service provider entry

Parameters

Name

Type

Description

$shippingServiceProviderCode

string

public getShippingServiceProviderClass($methodName):string

Get the shipping service provider class

Parameters

Name

Type

Description

$methodName

string

public methodExists($methodName):bool

Check if method exists in shipping service provider classes

Parameters

Name

Type

Description

$methodName

string

Tax

TaxInformation

This model holds all information about the data used to detect the order taxes.

Namespace

Plenty\Modules\Order\Legacy\Services\Tax

Methods
public getLocationId():int

Get the location ID.

public getBillingCountryId():int

Get the billing country ID.

public getDeliveryCountryId():int

Get the delivery country ID.

public getBillingTaxIdNumber():string

Get the tax id number of the billing address.

public getDeliveryTaxIdNumber():string

Get the tax id number of the delivery address.

public getDate():string

Get the date.

public getHasEntryCertificate():bool

Get whether the delivery address ha sn entry cerificat or not.

ServiceProvider

Contracts

ShippingServiceProviderPluginRepositoryContract

The ShippingServiceProviderPluginRepositoryContract is the interface for the shipping service provider plugin repository. This interface allows to list shipping service provider plugins.

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Contracts

Methods
public plugins():void

Return list of shipping service provider plugins

public filteredPluginList($filter):void

Return list of shipping service provider plugins using a filter

Parameters

Name

Type

Description

$filter

string

Filter that restricts the search result

ShippingServiceProviderRepositoryContract

The ShippingServiceProviderRepositoryContract is the interface for the shipping service provider repository. This interface allows to list shipping service providers.

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Contracts

Methods
public all($columns = [], $page = 1, $itemsPerPage = 50, $filters = [], $with = []):void

Lists shipping service providers.

Parameters

Name

Type

Description

$columns

array

The columns to retrieve

$page

int

The page of results to search for

$itemsPerPage

int

The number of items to list per page

$filters

array

Filters that restrict the search result

$with

array

The releations to be loaded with the shipping service provider

public find($shippingServiceProviderId):Plenty\Modules\Order\Shipping\ServiceProvider\Models\ShippingServiceProvider
Return type: ShippingServiceProvider

Gets a shipping service provider. The ID of the shipping service provider must be specified.

Parameters

Name

Type

Description

$shippingServiceProviderId

int

The ID of the shipping service provider

public findByName($shippingServiceProviderName):Plenty\Modules\Order\Shipping\ServiceProvider\Models\ShippingServiceProvider
Return type: ShippingServiceProvider

Gets a shipping service provider. The name of the shipping service provider must be specified.

Parameters

Name

Type

Description

$shippingServiceProviderName

string

The name of the shipping service provider

public saveShippingServiceProvider($pluginName, $shippingServiceProviderName, $icon = null):Plenty\Modules\Order\Shipping\ServiceProvider\Models\ShippingServiceProvider
Return type: ShippingServiceProvider

Creates a shipping service provider or updates it if already existing

Parameters

Name

Type

Description

$pluginName

string

The plugin name the plugin is registered with

$shippingServiceProviderName

string

The name of the shipping service provider

$icon

string

The path of the icon

public clearCriteria():void

Resets all Criteria filters by creating a new instance of the builder object.

public applyCriteriaFromFilters():void

Applies criteria classes to the current repository.

Models

FailedRegisterShipment

The FailedRegisterShipment model.

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Models

Methods
public addErrorMessage($errorMessage):void
Parameters

Name

Type

Description

$errorMessage

string

public addException($exception):void
Parameters

Name

Type

Description

$exception

public setOrderId($orderId):void
Parameters

Name

Type

Description

$orderId

int

public get($key):void
Parameters

Name

Type

Description

$key

string

public hasGetMutator($key):bool

Determine if a get mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public setAttributes($attributes):void
Parameters

Name

Type

Description

$attributes

public setAttribute($key, $value):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set a given attribute on the model.

Parameters

Name

Type

Description

$key

string

$value

public hasSetMutator($key):bool

Determine if a set mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public changeValue($key, $callback):void
Parameters

Name

Type

Description

$key

string

$callback

callable

public offsetExists($offset):bool
Parameters

Name

Type

Description

$offset

public offsetGet($offset):void
Parameters

Name

Type

Description

$offset

public offsetSet($offset, $value):void
Parameters

Name

Type

Description

$offset

$value

public offsetUnset($offset):void
Parameters

Name

Type

Description

$offset

public toArray($translate = false):array
Parameters

Name

Type

Description

$translate

bool

Flag indicating if values should be translated.

public toJson($options):string
Parameters

Name

Type

Description

$options

int

public jsonSerialize():void
public fill($attributes):Plenty\Repositories\Models\DataModel
Return type: DataModel

Fill the model with an array of attributes.

Parameters

Name

Type

Description

$attributes

array

public isFillable($key):bool

Determine if the given attribute may be mass assigned.

Parameters

Name

Type

Description

$key

string

public getFillable():array

Get the fillable attributes for the model.

public fillable($fillable):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set the fillable attributes for the model.

Parameters

Name

Type

Description

$fillable

array

public hasCast($key, $types = null):bool

Determine whether an attribute should be cast to a native type.

Parameters

Name

Type

Description

$key

string

$types

public fromJson($value, $asObject = false):void

Decode the given JSON back into an array or object.

Parameters

Name

Type

Description

$value

string

$asObject

bool

RegisterShipmentResponse

The RegisterShipmentResponse model.

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Models

Methods
public addSuccessfullyRegisteredShipment($successfullyRegisteredShipment):void
Parameters

Name

Type

Description

$successfullyRegisteredShipment

SuccessfullyRegisteredShipment

Object containing data for successfully registering a shipment

public addFailedRegisterShipment($failedRegisterShipment):void
Parameters

Name

Type

Description

$failedRegisterShipment

FailedRegisterShipment

Object containing data when shipment registration was not successful, e.g. incorrect or missing postcode

public get($key):void
Parameters

Name

Type

Description

$key

string

public hasGetMutator($key):bool

Determine if a get mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public setAttributes($attributes):void
Parameters

Name

Type

Description

$attributes

public setAttribute($key, $value):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set a given attribute on the model.

Parameters

Name

Type

Description

$key

string

$value

public hasSetMutator($key):bool

Determine if a set mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public changeValue($key, $callback):void
Parameters

Name

Type

Description

$key

string

$callback

callable

public offsetExists($offset):bool
Parameters

Name

Type

Description

$offset

public offsetGet($offset):void
Parameters

Name

Type

Description

$offset

public offsetSet($offset, $value):void
Parameters

Name

Type

Description

$offset

$value

public offsetUnset($offset):void
Parameters

Name

Type

Description

$offset

public toArray($translate = false):array
Parameters

Name

Type

Description

$translate

bool

Flag indicating if values should be translated.

public toJson($options):string
Parameters

Name

Type

Description

$options

int

public jsonSerialize():void
public fill($attributes):Plenty\Repositories\Models\DataModel
Return type: DataModel

Fill the model with an array of attributes.

Parameters

Name

Type

Description

$attributes

array

public isFillable($key):bool

Determine if the given attribute may be mass assigned.

Parameters

Name

Type

Description

$key

string

public getFillable():array

Get the fillable attributes for the model.

public fillable($fillable):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set the fillable attributes for the model.

Parameters

Name

Type

Description

$fillable

array

public hasCast($key, $types = null):bool

Determine whether an attribute should be cast to a native type.

Parameters

Name

Type

Description

$key

string

$types

public fromJson($value, $asObject = false):void

Decode the given JSON back into an array or object.

Parameters

Name

Type

Description

$value

string

$asObject

bool

ShippingServiceProvider

The service provider model

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Models

Properties
Name Type Description

id

int

The ID of the shipping service provider

name

string

The name of the shipping service provider

pluginId

int

The optional ID of the plugin when the shipping service provider is registered as a plugin

icon

string

The optional path of the icon

createdAt

The time the shipping service provider was created

updatedAt

The time the shipping service provider was updated

Methods
public toArray()

Returns this model as an array.

SuccessfullyRegisteredShipment

The SuccessfullyRegisteredShipment model.

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Models

Methods
public setOrderId($orderId):void

Set the order ID.

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public setHasNewPackageNumber($hasNewPackageNumber):void

Set the variable $hasNewPackageNumber.

Parameters

Name

Type

Description

$hasNewPackageNumber

bool

Flag that indicates whether the order has a new package number

public addMessage($message):void

Add a message.

Parameters

Name

Type

Description

$message

string

The message

public addPackage($package):void

Add a package.

Parameters

Name

Type

Description

$package

OrderShippingPackage

The order shipping package

public get($key):void
Parameters

Name

Type

Description

$key

string

public hasGetMutator($key):bool

Determine if a get mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public setAttributes($attributes):void
Parameters

Name

Type

Description

$attributes

public setAttribute($key, $value):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set a given attribute on the model.

Parameters

Name

Type

Description

$key

string

$value

public hasSetMutator($key):bool

Determine if a set mutator exists for an attribute.

Parameters

Name

Type

Description

$key

string

public changeValue($key, $callback):void
Parameters

Name

Type

Description

$key

string

$callback

callable

public offsetExists($offset):bool
Parameters

Name

Type

Description

$offset

public offsetGet($offset):void
Parameters

Name

Type

Description

$offset

public offsetSet($offset, $value):void
Parameters

Name

Type

Description

$offset

$value

public offsetUnset($offset):void
Parameters

Name

Type

Description

$offset

public toArray($translate = false):array
Parameters

Name

Type

Description

$translate

bool

Flag indicating if values should be translated.

public toJson($options):string
Parameters

Name

Type

Description

$options

int

public jsonSerialize():void
public fill($attributes):Plenty\Repositories\Models\DataModel
Return type: DataModel

Fill the model with an array of attributes.

Parameters

Name

Type

Description

$attributes

array

public isFillable($key):bool

Determine if the given attribute may be mass assigned.

Parameters

Name

Type

Description

$key

string

public getFillable():array

Get the fillable attributes for the model.

public fillable($fillable):Plenty\Repositories\Models\DataModel
Return type: DataModel

Set the fillable attributes for the model.

Parameters

Name

Type

Description

$fillable

array

public hasCast($key, $types = null):bool

Determine whether an attribute should be cast to a native type.

Parameters

Name

Type

Description

$key

string

$types

public fromJson($value, $asObject = false):void

Decode the given JSON back into an array or object.

Parameters

Name

Type

Description

$value

string

$asObject

bool

Services

ShippingServiceProviderService

The ShippingServiceProviderService class offers the possibility to register a shipping provider class and method that can be called by plentymarkets shipping controllers.

Namespace

Plenty\Modules\Order\Shipping\ServiceProvider\Services

Methods
public registerShippingProvider($shippingServiceProviderCode, $shippingServiceProviderNames, $shippingServiceProviderClasses):bool

Registers a new shipping provider

Parameters

Name

Type

Description

$shippingServiceProviderCode

string

$shippingServiceProviderNames

$shippingServiceProviderClasses

public hasShippingServiceProviderMethod($shippingServiceProviderCode, $methodName):bool

Check if shipping service provider has specified method

Parameters

Name

Type

Description

$shippingServiceProviderCode

string

$methodName

string

Address

Contracts

OrderAddressRepositoryContract

The OrderAddressRepositoryContract is the interface for the order address repository. This interface allows you to get, create, update and delete addresses of an order.

Namespace

Plenty\Modules\Order\Address\Contracts

Methods
public findAddressByType($orderId, $typeId):Plenty\Modules\Account\Address\Models\Address
Return type: Address

Get an address of an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$typeId

int

The ID of the address type

public findSchedulerAddressByType($schedulerId, $typeId):Plenty\Modules\Account\Address\Models\Address
Return type: Address

Get an address of a scheduler order

Parameters

Name

Type

Description

$schedulerId

int

The ID of the scheduler

$typeId

int

The ID of the address type

public createOrderAddress($data, $orderId, $typeId = \Plenty\Modules\Account\Address\Models\AddressRelationType::BILLING_ADDRESS):Plenty\Modules\Account\Address\Models\Address
Return type: Address

Create an address for an order

Parameters

Name

Type

Description

$data

array

The address data

$orderId

int

The ID of the order

$typeId

int

[optional] The ID of the address type. The default ID is 1 for billing address. The types available are:

  • Billing address = 1

  • Delivery address = 2

  • Sender address = 3

  • Return address = 4

  • Client address = 5

  • Contractor address = 6

  • Warehouse address = 7

public updateOrderAddress($data, $addressId, $orderId, $typeId):Plenty\Modules\Account\Address\Models\Address
Return type: Address

Update an address of an order

Parameters

Name

Type

Description

$data

array

The address data

$addressId

int

The ID of address

$orderId

int

The ID of the order

$typeId

int

The ID of the address type. The types available are:

  • Billing address = 1

  • Delivery address = 2

  • Sender address = 3

  • Return address = 4

  • Client address = 5

  • Contractor address = 6

  • Warehouse address = 7

public getAddress($addressId, $with = []):Plenty\Modules\Account\Address\Models\Address
Return type: Address

Get an address

Parameters

Name

Type

Description

$addressId

int

The ID of the address

$with

array

The relations to load in the address instance. The relations available are "options", "contacts", "orders", "country".

public findAddresses($orderId):Illuminate\Database\Eloquent\Collection
Return type: Collection

List addresses of an an order

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public getAddressOfOrder($addressId, $orderId, $typeId):Plenty\Modules\Account\Address\Models\Address
Return type: Address

Get an address of an order

Parameters

Name

Type

Description

$addressId

int

The ID of the address

$orderId

int

The ID of the order

$typeId

int

The ID of the address type. The types available are:

  • Billing address = 1

  • Delivery address = 2

  • Sender address = 3

  • Return address = 4

  • Client address = 5

  • Contractor address = 6

  • Warehouse address = 7

public getAddressOfScheduler($addressId, $schedulerId, $typeId):Plenty\Modules\Account\Address\Models\Address
Return type: Address

Get an address of a scheduler

Parameters

Name

Type

Description

$addressId

int

The ID of the address

$schedulerId

int

The ID of the scheduler

$typeId

int

The ID of the address type. The types available are:

  • Billing address = 1

  • Delivery address = 2

  • Sender address = 3

  • Return address = 4

  • Client address = 5

  • Contractor address = 6

  • Warehouse address = 7

public addOrderAddress($addressId, $orderId, $typeId):void

Create an address relation from an order to an address

Parameters

Name

Type

Description

$addressId

int

The ID of the address

$orderId

int

The ID of the order

$typeId

int

The ID of the address type. The types available are:

  • Billing address = 1

  • Delivery address = 2

  • Sender address = 3

  • Return address = 4

  • Client address = 5

  • Contractor address = 6

  • Warehouse address = 7

public addSchedulerAddress($addressId, $schedulerId, $typeId):void

Create an address relation from a scheduler to an address

Parameters

Name

Type

Description

$addressId

int

The ID of the address

$schedulerId

int

The ID of the scheduler

$typeId

int

The ID of the address type. The types available are:

  • Billing address = 1

  • Delivery address = 2

  • Sender address = 3

  • Return address = 4

  • Client address = 5

  • Contractor address = 6

  • Warehouse address = 7

public deleteOrderAddress($addressId, $orderId, $typeId):bool

Delete an address relation from an order

Parameters

Name

Type

Description

$addressId

int

The ID of the address

$orderId

int

The ID of the order

$typeId

int

The ID of the address type. The types available are:

  • Billing address = 1

  • Delivery address = 2

  • Sender address = 3

  • Return address = 4

  • Client address = 5

  • Contractor address = 6

  • Warehouse address = 7

AdvanceOrder

Contracts

AdvanceOrderRepositoryContract

The AdvanceOrderRepositoryContract is the interface for the advance order repository. This interface allows you to create and update advance orders.

Namespace

Plenty\Modules\Order\AdvanceOrder\Contracts

Methods
public create($data, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Create an advance order

Parameters

Name

Type

Description

$data

array

$with

array

$lazyLoaded

bool

public createWithCoupons($data, $coupons = [], $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Create an advance order with coupon codes

Parameters

Name

Type

Description

$data

array

$coupons

array

$with

array

$lazyLoaded

bool

public update($orderId, $data, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Update an advance order

Parameters

Name

Type

Description

$orderId

int

$data

array

$with

array

$lazyLoaded

bool

public delete($orderId):void

Delete an advance order

Parameters

Name

Type

Description

$orderId

int

public deleteOrderItem($orderItemId):bool

Delete an order item from an advance order

Parameters

Name

Type

Description

$orderItemId

int

public createFromParent($orderId, $data):Plenty\Modules\Order\Models\Order
Return type: Order

Create an advance order from a parent order

Parameters

Name

Type

Description

$orderId

int

$data

array

public updateCurrency($orderId, $data):Plenty\Modules\Order\Models\Order
Return type: Order

Update currency

Parameters

Name

Type

Description

$orderId

int

$data

array

public convertFromSalesOrder($orderId):Plenty\Modules\Order\Models\Order
Return type: Order

Convert sales order into advance order

Parameters

Name

Type

Description

$orderId

int

The order ID

public detachVariation($orderItemId, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Change an order item of type "variation" to "unassigned variation".

Parameters

Name

Type

Description

$orderItemId

int

$with

array

$lazyLoaded

bool

public assignVariation($orderItemId, $variationId, $warehouseId = null, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Change an order item of type "unassigned variation" to "variation".

Parameters

Name

Type

Description

$orderItemId

int

$variationId

int

$warehouseId

int

$with

array

$lazyLoaded

bool

public previewCreate($data):array

Get an advance order create preview for the given order data.

Parameters

Name

Type

Description

$data

array

public previewCreateWithCoupons($data, $coupons = []):array

Get an advance order create preview for the given order data with coupon codes.

Parameters

Name

Type

Description

$data

array

$coupons

array

public previewUpdate($orderId, $data):array

Get an advance order update preview for the given order data.

Parameters

Name

Type

Description

$orderId

int

$data

array

Booking

Contracts

OrderBookingRepositoryContract

Book orders, order items and order item transactions.

Namespace

Plenty\Modules\Order\Booking\Contracts

Methods
public bookOrder($orderId, $deliveryNoteNumber = null):Plenty\Modules\Order\Booking\Models\OrderBooking
Return type: OrderBooking

Book an order

Parameters

Name

Type

Description

$orderId

int

$deliveryNoteNumber

string

public bookOrderItem($orderItemId, $deliveryNoteNumber = null):Plenty\Modules\Order\Booking\Models\OrderBooking
Return type: OrderBooking

Book an order item

Parameters

Name

Type

Description

$orderItemId

int

$deliveryNoteNumber

string

public bookOrderItemTransactions($transactionIds, $warehouseId = null, $deliveryNoteNumber = null):Plenty\Modules\Order\Booking\Models\OrderBooking
Return type: OrderBooking

Book order item transactions

Parameters

Name

Type

Description

$transactionIds

array

$warehouseId

int

$deliveryNoteNumber

string

Models

OrderBooking

The order booking model.

Namespace

Plenty\Modules\Order\Booking\Models

Properties
Name Type Description

success

array

The successfully booked transactions

failed

array

The transactions which failed to book

Methods
public toArray()

Returns this model as an array.

Template

Filters

OrderClientFilterBuilder

Used to represent the order client filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderCompletedAtFilterBuilder

Used to represent the order completed at filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderCreatedAtFilterBuilder

Used to represent the order created at filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderExcludeMainOrdersFilterBuilder

Used to represent the exclude main orders filter.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderIdFilterBuilder

Used to represent the order id filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():string

Returns an identifier for the filter

public setFilterData($filterData):void

This method will be filled by the specified values in a catalog. It should be used to provide the necessary manipulation so the filter that is returned by getFilter can be consumed by the export.

Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void

Returns the filter that will be given to the export

Parameters

Name

Type

Description

$settings

array

public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter

Returns the UI representation of the filter

OrderItemTypeFilterBuilder

Used to represent the order item type filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderItemVariationIdFilterBuilder

Used to represent the order item variation filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():string

Returns an identifier for the filter

public setFilterData($filterData):void

This method will be filled by the specified values in a catalog. It should be used to provide the necessary manipulation so the filter that is returned by getFilter can be consumed by the export.

Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void

Returns the filter that will be given to the export

Parameters

Name

Type

Description

$settings

array

public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter

Returns the UI representation of the filter

OrderOwnerFilterBuilder

Used to represent the order owner filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderPaidAtFilterBuilder

Used to represent the order paid at filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderPaymentMethodFilterBuilder

Used to represent the order payment method filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderReceivedDateFilterBuilder

Used to represent the order date filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderReferrerFilterBuilder

Used to represent the order referrer filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderShippingProfileFilterBuilder

Used to represent the shipping profile filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderStatusFilterBuilder

Used to represent the order status filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderTypeFilterBuilder

Used to represent the order status type in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderUpdatedAtFilterBuilder

Used to represent the order updated at filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

OrderWarehouseFilterBuilder

Used to represent the order warehouse filter in both the catalog export and UI.

Namespace

Plenty\Modules\Order\Catalogues\Order\Template\Filters

Methods
public getKey():void
public getUiFilter():Plenty\Modules\Catalog\Models\Filters\CatalogUiFilter
Return type: CatalogUiFilter
public setFilterData($filterData):void
Parameters

Name

Type

Description

$filterData

public getFilter($settings = []):void
Parameters

Name

Type

Description

$settings

array

ContactWish

Contracts

ContactWishRepositoryContract

This interface allows you to get and create contact wishes.

Namespace

Plenty\Modules\Order\ContactWish\Contracts

Methods
public getContactWish($orderId):Plenty\Modules\Order\ContactWish\Models\ContactWish
Return type: ContactWish

Get the contact wish

Parameters

Name

Type

Description

$orderId

int

The ID of the order

public createContactWish($orderId, $text):Plenty\Modules\Order\ContactWish\Models\ContactWish
Return type: ContactWish

Create a contact wish

Parameters

Name

Type

Description

$orderId

int

The ID of the order

$text

string

The text for the contact wish

Models

ContactWish

The contact wish model.

Namespace

Plenty\Modules\Order\ContactWish\Models

Properties
Name Type Description

text

string

The text of the contact wish

Methods
public toArray()

Returns this model as an array.

CreditNote

Contracts

CreditNoteRepositoryContract

The CreditNoteRepositoryContract is the interface for the credit note repository. This interface allows you to create and update credit notes.

Namespace

Plenty\Modules\Order\CreditNote\Contracts

Methods
public create($data, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Create a credit note

Parameters

Name

Type

Description

$data

array

$with

array

$lazyLoaded

bool

public update($orderId, $data, $with = [], $lazyLoaded = false):Plenty\Modules\Order\Models\Order
Return type: Order

Update a credit note

Parameters

Name

Type

Description

$orderId

int

$data

array

$with

array

$lazyLoaded

bool

public delete($orderId):void

Delete a credit note

Parameters

Name

Type

Description

$orderId

int

public deleteOrderItem($orderItemId):bool

Delete an order item from a credit note

Parameters

Name

Type

Description

$orderItemId

int

public createFromParent($orderId, $data):Plenty\Modules\Order\Models\Order
Return type: Order