FormPayment
class FormPayment extends FormComponent
Class FormPayment
Properties
protected array | $config | from FormBase | |
bool | $save_requires_edit_var | from FormBase | |
Form | $form | from FormComponent | |
protected | $field_disable_save | Set to false if this field is not "saveable", e.g. static test |
from FormBase |
$REQUEST_VARS | from FormComponent | ||
$name | from FormComponent | ||
callable|bool | $db_handler | from FormComponent |
Methods
This method should be always called after a form is successfuly submited and the payment process is finished. This will reset the process for the reference.
Displays the form component depended on given options.
Special Field Display for Print Purposes
Return Dom Selector for this field within the current form (This is NOT necessary unique if you are having 2 forms with identical names in form and field names
Get Element Visibility Class Formerly known as tag class
This method can be used after the form is proccesed and validated.
Returns the from this component generated process id. This process id is saved in the session and it will keep until the product is bougth.
Does this component use combined input fields which required special handling from form?
Get all hooks that registered for payment.service hook. A GET parameter names a_payment_service is used to choose the right module and payment service. If this GET parameter is once set, it will be saved in the session. The value is a concated string of provider and service separated by a dot (e.g. micropayment.creditcard).
Checks if the field is hidden by a tag. It is important when validating
No description
Show Custom Error Message for this field
Field is to be loaded from and saved to database.
Field is considered to be translatable. This is usually determined automatically reading the instance configuration of the calling instance
Consider Field as required
Set Field label
Manipulate another fields data when the value of the current field changes.
Add Custom HTML before the field element
Set Visibility Dependency if you want your field only to be shown if another field has a specify value Array Syntax: tag, tag_source
Set field to be the event source for another dependent field. Changes of this fields values will trigger events to their dependent fields and change their visibility in the frontend
This method is called when the form is submited and checks whether user has payed or not.
Details
in
FormBase at line 31
__construct()
FormBase constructor.
The constructor is able to set an array of properties options
in
FormBase at line 200
append(string $name, mixed $value, bool|string $key = false)
No description
at line 255
complete_payment_process()
This method should be always called after a form is successfuly submited and the payment process is finished. This will reset the process for the reference.
in
FormBase at line 185
void
concat(string $name, string $value)
No description
in
FormBase at line 170
mixed
destroy($name)
No description
at line 171
string
display_field($fieldname, $default_value = false)
Displays the form component depended on given options.
in
FormComponent at line 296
string
display_field_print(string $fieldname, string $default_value = '')
Special Field Display for Print Purposes
in
FormBase at line 76
mixed
get(string $name)
No description
in
FormBase at line 83
array
getConfig()
No description
in
FormComponent at line 583
string
getDomSelector()
Return Dom Selector for this field within the current form (This is NOT necessary unique if you are having 2 forms with identical names in form and field names
in
FormComponent at line 595
protected string
getElementVisibilityClass()
Get Element Visibility Class Formerly known as tag class
in
FormComponent at line 496
bool
getIsVisible()
Determine visibilty based on user input on dependent fields
in
FormComponent at line 168
string
get_description()
No description
in
FormComponent at line 274
mixed
get_display_value()
returns the displayed value
in
FormBase at line 219
array
get_group(string $prefix)
No description
in
FormComponent at line 149
string
get_help_tooltip_icon()
No description
at line 237
get_payment_data()
This method can be used after the form is proccesed and validated.
It returns all necessary data of payment. Following data are returned as array.
instance_id => ID of the payment module instance process_id => The process_id reference_id
at line 224
string
get_process_id()
Returns the from this component generated process id. This process id is saved in the session and it will keep until the product is bougth.
in
FormBase at line 91
array
get_properties()
No description
in
FormComponent at line 47
array|bool
get_validation_options()
No description
in
FormComponent at line 187
get_value()
No description
in
FormComponent at line 39
bool
hasCombinedInputFields()
Does this component use combined input fields which required special handling from form?
at line 75
init()
Get all hooks that registered for payment.service hook. A GET parameter names a_payment_service is used to choose the right module and payment service. If this GET parameter is once set, it will be saved in the session. The value is a concated string of provider and service separated by a dot (e.g. micropayment.creditcard).
Further this method process the payment data set on this component. For more information about this payment option see class doc. To the given payment option parameter more advanced data will set by this component.
form_instance_id => The instance_id of the module that uses this component
Also this component generated a process id for each reference that can be used from begin until payment (call method complete_payment_process).
in
FormBase at line 39
init_obj()
Initializes the form base
in
FormComponent at line 544
$this
insertAfter(FormComponent $formComponent = null)
Insert this field after the specified field
in
FormComponent at line 529
$this
insertBefore(FormComponent $formComponent = null)
Insert this field before the specified field
in
FormComponent at line 369
bool
isReadonly()
Returns TRUE if field is readonly, FALSE otherwise.
in
FormBase at line 239
bool
is_displayed()
Checks if the field is hidden by a tag. It is important when validating
in
FormComponent at line 257
void
post_process()
No description
in
FormComponent at line 181
void
process()
Process e.g. file upload, resize etc.
in
FormComponent at line 198
string
render(string|false $name = false, string|false $value = false)
No description
in
FormComponent at line 248
mixed
save()
No description
in
FormBase at line 103
$this
set(string $name, mixed $value)
No description
in
FormComponent at line 391
$this
setCSSClassName(string $class = null)
Set Field Row CSS class name
in
FormComponent at line 559
$this
setCustomErrorText(string $error_msg)
Show Custom Error Message for this field
in
FormComponent at line 380
$this
setDefaultValue(mixed $value = null)
Set Field default value
in
FormComponent at line 413
$this
setDescriptionText(string $description = null)
Set Field Help Text
in
FormComponent at line 573
$this
setGridClass(string $gridClass = null)
Set Flexbox Grid Class
in
FormComponent at line 402
$this
setHelpText(string $help = null)
Set Field Help Text
in
FormComponent at line 336
$this
setIsDBField(bool $bool = true)
Field is to be loaded from and saved to database.
in
FormComponent at line 349
$this
setIsI18NField(bool $bool = true)
Field is considered to be translatable. This is usually determined automatically reading the instance configuration of the calling instance
in
FormComponent at line 360
$this
setIsReadonly(bool $bool = true)
Consider Field as readonly
in
FormComponent at line 325
$this
setIsRequired(bool $bool = true, bool $onlyRequiredIfVisible = true)
Consider Field as required
in
FormComponent at line 311
$this
setLabel(string $label = '', string $icon_class = '', int $width_in_px = null)
Set Field label
in
FormComponent at line 448
$this
setPopulateField(FormComponent $target, string $dataURL = null)
Manipulate another fields data when the value of the current field changes.
Common usage: Populate a second select once user chooses from the first select
in
FormComponent at line 424
$this
setPrefixHTML(string $html = null)
Add Custom HTML before the field element
in
FormComponent at line 435
$this
setSuffixHTML(string $html = null)
Add Custom HTML after the field element
in
FormComponent at line 462
$this
setVisibilityDependsOn(FormComponent $formComponent = null, array $matchingValues = [])
Set Visibility Dependency if you want your field only to be shown if another field has a specify value Array Syntax: tag, tag_source
in
FormComponent at line 486
$this
setVisibilityIsSource(bool $bool = true)
Set field to be the event source for another dependent field. Changes of this fields values will trigger events to their dependent fields and change their visibility in the frontend
Fields are automatically set to be a source if used in a call of setVisibilityDependsOn()
Array Syntax: tag_source
in
FormComponent at line 265
set_display_value(mixed $value)
set the displayed value
in
FormBase at line 155
void
set_properties(array $array)
No description
in
FormComponent at line 31
set_request_vars($request)
No description
at line 273
bool|string
validate()
This method is called when the form is submited and checks whether user has payed or not.