Documentation

Afform extends AbstractEntity
in package

User-configurable forms.

Afform stands for The Affable Administrative Angular Form Framework.

This API provides actions for

  1. Managing forms: The create, get, save, update, & revert actions read/write form html & json files.
  2. Using forms: The prefill and submit actions are used for preparing forms and processing submissions.
Tags
see
https://lab.civicrm.org/extensions/afform
labelField

title

iconField

type:icon

since
5.31

Table of Contents

Methods

__callStatic()  : AbstractAction
Magic method to return the action object for an api.
autocomplete()  : AutocompleteAction
checkAccess()  : CheckAccessAction
convert()  : Convert
create()  : Create
get()  : Get
getActions()  : GetActions
getEntityName()  : string
Get entity name from called class
getFields()  : BasicGetFieldsAction
getInfo()  : array{name: string, title: string, description: string, title_plural: string, type: string, paths: array, class: string, primary_key: array, searchable: string, dao: string, label_field: string, icon: string}
Reflection function called by Entity::get()
getLinks()  : GetLinks
getOptions()  : GetOptions
permissions()  : array<string|int, mixed>
Returns a list of permissions needed to access the various actions in this api.
prefill()  : Prefill
process()  : Process
revert()  : Revert
save()  : Save
submit()  : Submit
submitFile()  : SubmitFile
update()  : Update
getDaoName()  : CRM_Core_DAO|string|null
getEntityTitle()  : string
Overridable function to return a localized title for this entity.

Methods

convert()

public static convert([bool $checkPermissions = TRUE ]) : Convert
Parameters
$checkPermissions : bool = TRUE
Return values
Convert

create()

public static create([bool $checkPermissions = TRUE ]) : Create
Parameters
$checkPermissions : bool = TRUE
Return values
Create

get()

public static get([bool $checkPermissions = TRUE ]) : Get
Parameters
$checkPermissions : bool = TRUE
Return values
Get

getEntityName()

Get entity name from called class

public static getEntityName() : string
Return values
string

getInfo()

Reflection function called by Entity::get()

public static getInfo() : array{name: string, title: string, description: string, title_plural: string, type: string, paths: array, class: string, primary_key: array, searchable: string, dao: string, label_field: string, icon: string}
Tags
inheritDoc
Return values
array{name: string, title: string, description: string, title_plural: string, type: string, paths: array, class: string, primary_key: array, searchable: string, dao: string, label_field: string, icon: string}
public static getLinks([bool $checkPermissions = TRUE ]) : GetLinks
Parameters
$checkPermissions : bool = TRUE
Return values
GetLinks

getOptions()

public static getOptions([bool $checkPermissions = TRUE ]) : GetOptions
Parameters
$checkPermissions : bool = TRUE
Return values
GetOptions

permissions()

Returns a list of permissions needed to access the various actions in this api.

public static permissions() : array<string|int, mixed>
Return values
array<string|int, mixed>

prefill()

public static prefill([bool $checkPermissions = TRUE ]) : Prefill
Parameters
$checkPermissions : bool = TRUE
Return values
Prefill

process()

public static process([bool $checkPermissions = TRUE ]) : Process
Parameters
$checkPermissions : bool = TRUE
Return values
Process

revert()

public static revert([bool $checkPermissions = TRUE ]) : Revert
Parameters
$checkPermissions : bool = TRUE
Return values
Revert

save()

public static save([bool $checkPermissions = TRUE ]) : Save
Parameters
$checkPermissions : bool = TRUE
Return values
Save

submit()

public static submit([bool $checkPermissions = TRUE ]) : Submit
Parameters
$checkPermissions : bool = TRUE
Return values
Submit

submitFile()

public static submitFile([bool $checkPermissions = TRUE ]) : SubmitFile
Parameters
$checkPermissions : bool = TRUE
Return values
SubmitFile

update()

public static update([bool $checkPermissions = TRUE ]) : Update
Parameters
$checkPermissions : bool = TRUE
Return values
Update

getEntityTitle()

Overridable function to return a localized title for this entity.

protected static getEntityTitle([bool $plural = FALSE ]) : string
Parameters
$plural : bool = FALSE

Whether to return a plural title.

Return values
string

        
On this page

Search results