modules/Leads/LeadFormBase.php
\LeadFormBase
FormBase.php
- Parent(s)
- \PersonFormBase < \FormBase
- Author
- Collin Lee This is an abstract class to provide common functionality across the form base code used in the application.
Properties
Methods
buildTableForm(
\$rows $rows
)
:
\$form
This function creates a table with form data. It is used by the form base code when checking for duplicates
Name | Type | Description |
---|---|---|
$rows | \$rows | Array of duplicate row data |
Type | Description |
---|---|
\$form | The HTML form data |
checkForDuplicates(
\$prefix $prefix
=
''
)
:
\$rows
This function is used to locate any duplicate Leads that may be created when a new Lead is saved. It is called from the handleSave method of this class.
Name | Type | Description |
---|---|---|
$prefix | \$prefix | String value of any prefix to the form input names |
Type | Description |
---|---|
\$rows | Array of matching Leads entries found; null if none found |
getDuplicateQuery(
\$focus $focus, \$prefix $prefix
=
''
)
:
\SQL
getDuplicateQuery
This function returns the SQL String used for initial duplicate Leads check
Name | Type | Description |
---|---|---|
$focus | \$focus | sugarbean |
$prefix | \$prefix | String value of prefix that may be present in $_POST variables |
Type | Description |
---|---|
\SQL | String of the query that should be used for the initial duplicate lookup check |
- See
- \checkForDuplicates
getFormBody(
$prefix, $mod
=
'', $formname
=
''
)
:
void
Name | Type | Description |
---|---|---|
$prefix | ||
$mod | ||
$formname |
getWideFormBody(
$prefix, $mod
=
'', $formname
=
''
)
:
void
Name | Type | Description |
---|---|---|
$prefix | ||
$mod | ||
$formname |
handleSave(
$prefix, $redirect
=
true, $useRequired
=
false, $do_save
=
true, $exist_lead
=
null
)
:
void
Name | Type | Description |
---|---|---|
$prefix | ||
$redirect | ||
$useRequired | ||
$do_save | ||
$exist_lead |
isEmptyReturnModuleAndAction(
)
:
bool
isEmptyReturnModuleAndAction
Inherited from: \FormBase::isEmptyReturnModuleAndAction()\PersonFormBase::isEmptyReturnModuleAndAction()This is a function to help assist in determining if a save operation has been performed without a return module and action specified. This will likely be the case where we use AJAX to change the state of a record, but wish to keep the user remaining on the same view. For example, this is true when closing Calls and Meetings from dashlets or from from subpanels.
Type | Description |
---|---|
bool | Boolean value indicating whether or not a return module and return action are specified in request |
isSaveFromDCMenu(
)
:
bool
isSaveFromDCMenu
Inherited from: \FormBase::isSaveFromDCMenu()\PersonFormBase::isSaveFromDCMenu()This is a function to help assist in determining if a save operation has been performed from the DCMenu (the shortcut bar up top available for most themes).
Type | Description |
---|---|
bool | Boolean value indicating whether or not the save operation was triggered from DCMenu |