content:form
Description
Creates a form, all inputs into the form are attached to a variable called model.
Adding a platform to the form will send the request to the Platform Store API and create the model as a new result .
Usage
as element:
<content:form [platform="{string}"] [legend="{string}"] [action="{string}"] [content="{Object}"]> </content:form>
Directive info
- This directive creates new scope.
Parameters
Param | Type | Details |
---|---|---|
platform (optional) | string | The platform to post the data to. |
legend (optional) | string | Text to display in the legend of the form. |
action (optional) | string | Whether the form should be creating a new record ( |
content (optional) | Object | Key value pair object or result to map the form data to. |
Events
contentFormPostError
When the content form is posted to the API unsuccessfully this event will be broadcasted with the error received from the API.
Type:
broadcastTarget:
root scopecontentFormPostSuccess
When the content form is posted to the API successfully this event will be broadcasted with the model sent to the API.
Type:
broadcastTarget:
root scope