CRM_Contribute_Form_SoftCredit
in package
This class build form elements for select existing or create new soft block.
Table of Contents
Methods
- addPCPFields() : mixed
- Add PCP fields for the new contribution form and others.
- buildQuickForm() : CRM_Core_Form
- Function used to build form element for soft credit block.
- formRule() : array<string|int, mixed>
- Global form rule.
- setDefaultValues() : mixed
- Function used to set defaults for soft credit block.
Methods
addPCPFields()
Add PCP fields for the new contribution form and others.
public
static addPCPFields(CRM_Core_Form $form[, string $suffix = '' ]) : mixed
Parameters
- $form : CRM_Core_Form
-
The form being built.
- $suffix : string = ''
-
A suffix to add to field names.
buildQuickForm()
Function used to build form element for soft credit block.
public
static buildQuickForm(CRM_Core_Form &$form) : CRM_Core_Form
Parameters
- $form : CRM_Core_Form
Return values
CRM_Core_FormformRule()
Global form rule.
public
static formRule(array<string|int, mixed> $fields, mixed $errors, self $self) : array<string|int, mixed>
Parameters
- $fields : array<string|int, mixed>
-
The input form values.
- $errors : mixed
- $self : self
Return values
array<string|int, mixed> —Array of errors
setDefaultValues()
Function used to set defaults for soft credit block.
public
static setDefaultValues(mixed &$defaults, mixed &$form) : mixed
Parameters
- $defaults : mixed
- $form : mixed