CoolCMS API

PaymentFormTrait

Add/edit form of a topping payment item.

The FKs (message/tariff/user/payment) are chosen by pickers into hidden scalar fields. Saving an active item extends the message's toped_until in the Api manager's afterSave, not here.

Table of Contents

Constants

PI_DT_FORMAT  : mixed = 'Y-m-d\TH:i'
Value format of `<input type=datetime-local>`.

Methods

createComponentEditForm()  : Form
intOrNull()  : int|null
savePaymentItemForm()  : bool
setPaymentItemFormDefaults()  : void

Constants

PI_DT_FORMAT

Value format of `<input type=datetime-local>`.

private mixed PI_DT_FORMAT = 'Y-m-d\TH:i'

Methods

intOrNull()

private intOrNull(mixed $value) : int|null
Parameters
$value : mixed
Return values
int|null

savePaymentItemForm()

private savePaymentItemForm(ArrayHash<string|int, mixed> $values) : bool
Parameters
$values : ArrayHash<string|int, mixed>
Return values
bool
On this page

Search results