PaymentFormTrait
Add and edit form of a company profile payment item.
The FKs (company profile, tariff, category, user, payment) are chosen by pickers into hidden
scalar fields. Saving an active item updates the company profile state (paid,
expiration_date) in the Api manager, 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
- piIntOrNull() : 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
createComponentEditForm()
protected
createComponentEditForm() : Form
Return values
FormpiIntOrNull()
private
piIntOrNull(mixed $value) : int|null
Parameters
- $value : mixed
Return values
int|nullsavePaymentItemForm()
private
savePaymentItemForm(ArrayHash<string|int, mixed> $values) : bool
Parameters
- $values : ArrayHash<string|int, mixed>
Return values
boolsetPaymentItemFormDefaults()
private
setPaymentItemFormDefaults(Form $form) : void
Parameters
- $form : Form