QuickAddNewExtension:: useAddNew
Tell this form field to apply the add new UI and fucntionality
Signature
public function useAddNew(string
$class,
Function
$sourceCallback,
[FieldList
$fields = NULL,
[RequiredFields
$required = NULL,
[boolean
$isFrontend = false]]] )
Parameters
$class
—
string
- the class name of the object being managed on the relationship
$sourceCallback
—
object
- the function called to repopulate the field's source array
$fields
—
FieldList
- Fields to create the object via dialog form - defaults to the object's getAddNewFields() method
$required
—
RequiredFields
- to create the validator for the dialog form
$isFrontend
—
boolean
- If this is set to true, the css classes for the CMS ui will not be set of the form elements this also opens the opportunity to manipulate the form for Frontend uses via an extension
Returns
FormField
$this->owner
Generated using phpDox 0.12.0 - Copyright (C) 2010 - 2021 by Arne Blankerts and Contributors