Back to Opencart

Class Opencart\Catalog\Model\Checkout\Voucher

docs/api/Opencart.Catalog.Model.Checkout.Voucher.html

4.1.0.34.9 KB
Original Source

Namespaces

Classes

Class Opencart[Catalog](http://localhost\opencart-master/docs/api/namespace-Opencart.Catalog.html)\[Model](http://localhost\opencart-master/docs/api/namespace-Opencart.Catalog.Model.html)\[Checkout](http://localhost\opencart-master/docs/api/namespace-Opencart.Catalog.Model.Checkout.html)\[Voucher](http://localhost\opencart-master/docs/api/Opencart.Catalog.Model.Checkout.Voucher.html)

| extends | Model |

Class Voucher

Located at catalog\model\checkout\voucher.php

Methods
`
public

			` | `addVoucher(int $order_id, array<string, mixed> $data): int`

Add Voucher

Add Voucher

| # | | `

public

			` | `deleteVouchersByOrderId(int $order_id): void`

Delete Vouchers By Order ID

Delete Vouchers By Order ID

| # | | `

public

			` | `disableVoucher(int $order_id): void`

Disable Voucher

Disable Voucher

| # | | `

public

			` | `getVoucher(string $code): array<string, mixed>`

Get Voucher

Get Voucher

| # | | `

public

			` | `getVoucherByCode(string $code): array<string, mixed>`

Get Voucher By Code

Get Voucher By Code

| # | | `

public

			` | `getVoucherTotal(int $voucher_id): float`

Get Voucher Total

Get Voucher Total

| # | | `

public

			` | `addHistory(int $voucher_id, int $order_id, float $value): int`

Add History

Add History

| # | | `

public

			` | `deleteHistoriesByOrderId(int $order_id): void`

Delete Voucher Histories By Order ID

Delete Voucher Histories By Order ID

| # |

Methods inherited from Opencart\System\Engine\Model
__construct(),__get(), __set(),__isset()
Properties inherited from Opencart\System\Engine\Model
$registry

OpenCart API API documentation generated by ApiGen dev-master