Data Manager customization: editRecordForm
Data Manager customization: editRecordForm
The editRecordForm
customization allows you to completely overwrite the view for rendering the edit record form page. The crumb trail, permissions checks and page title will be taken care of, but the rest is up to you.
The handler should return a string (the rendered edit record form page) is provided the following in the args
struct.
objectName
: The name of the objectrecordId
: The ID of the record being editedrecord
: Struct of the record being editededitRecordAction
: URL for submitting the formuseVersioning
: Whether or not to use versioningversion
: Version number (for versioning only) of the record inargs.record
draftsEnabled
: Whether or not drafts are enabledcanSaveDraft
: Whether or not the current user can save drafts (for drafts only)canPublish
: Whether or not the current user can publish (for drafts only)cancelAction
: URL that any rendered 'cancel' link should use
For example:
// /application/handlers/admin/datamanager/blog.cfc
component {
private string function editRecordForm( event, rc, prc, args={} ) {
return renderView( view="/admin/my/custom/editrecordForm", args=args );
}
}