[ Web Proxy ]
URL:
Viewing: https://adminforth.dev/docs/api/Back/type-aliases/BeforeEditSaveFunction/ [Back]  [Original]

BeforeEditSaveFunction | Agent-first open-source admin panel framework
Skip to main content
On this page

BeforeEditSaveFunction

BeforeEditSaveFunction = (params) => Promise<{ error?: string | null; ok: boolean; }>

Parameters

ParameterTypeDescription
params{ adminforth: IAdminForth; adminUser: AdminUser; extra?: HttpExtra; oldRecord: any; record: any; recordId: any; resource: AdminForthResource; response: IAdminForthHttpResponse; updates: any; }-
params.adminforthIAdminForthAdminforth instance.
params.adminUserAdminUserAdmin user performing the action.
params.extra?HttpExtraExtra HTTP information. Prefer using extra.response over the top-level response field.
params.oldRecordanyRecord data before update.
params.recordanyRecord with updates @deprecated. Will be removed in 4.0.0. Use updates instead.
params.recordIdanyPrimary key value of the record to delete.
params.resourceAdminForthResourceResource info.
params.responseIAdminForthHttpResponseHTTP response object. Deprecated Since 1.2.9. Will be removed in 4.0.0. Use extra.response instead.
params.updatesany-

Returns

Promise<{ error?: string | null; ok: boolean; }>

Previous
BeforeDeleteSaveFunction
Next
BeforeLoginAttemptFunction

Web Proxy Viewer  |  New URL  |  Original Page