The OrderPageAbstract
class extends the Kirby’s Page class.
You have to create your own OrderPage class.
The OrderPageAbstract
class extends the Kirby’s Page class.
You have to create your own OrderPage class.
Returns validation errors.
$orderPageAbstract->errors(): array
Since Merx 1.7
array
$errors = $orderPage->errors();
echo json_encode($errors);
{
"name": {
"label": "Name",
"message": {
"required": "Please enter something",
"minlength": "Please enter a longer value. (min. 3 characters)"
}
},
"streetaddress": {
"label": "Street",
"message": {
"required": "Please enter something",
"minlength": "Please enter a longer value. (min. 3 characters)"
}
}
}
Cart of this Order.
5 character long string based on the sorting number.
$orderPageAbstract->invoiceNumber(): string
string
$orderPage->invoiceNumber(); // 00003
Learn how to generate custom invoice numbers with the Custom Invoice Numbers cookbook.
Helper method that returns paidDate or payedDate field of the OrderPage.
$orderPageAbstract->payedDate(): Field
Kirby\Cms\Field
Since Merx 1.7, the date when the payment of an order is completed is no longer stored in the payedDate
field. Instead, it is stored in the paidDate
field. This method which returns the payedDate
field (for orders before Merx 1.7) or the paidDate
field.