ViewAction
Overview
Full-page view for executing a model action. Renders a page title with a "Go Back" button and embeds a ModelActionForm for the specified app, model, and action. Accepts an optional primary key and initial form values to pre-populate the form.
Theme entry: ViewAction
Props
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| themeOverride | Object | null | A partial ThemeObject keyed by component name, merged over this component's theme and provided to descendants. | |
| app | string | yes | Django app label that owns the model. | |
| model | string | yes | Django model name the action belongs to. | |
| pk | string|number|array | undefined | Primary key(s) of the object(s) to act on; pass an array for multi-object actions. | |
| action | string | yes | Name of the action to execute. | |
| title | string | undefined | Page title override. The default title is the start-cased action name followed by the model's verbose name. When pk lists more than one object, the default uses the verbose plural name. The default is empty until the verbose name is known, so the layout shows a skeleton. | |
| initialFormValues | object | undefined | Initial field values pre-populated into the action form. |
Slots
return-button
Scoped slot.
Bindings
| Name | Description |
|---|---|
default
Scoped slot.
Bindings
| Name | Description |
|---|---|
| action | |
| app | |
| formContext | |
| model | |
| pk |
Source
client/lib/views/ViewAction.vue