Handle actions on learning plan templates via ajax.
- Source:
- Copyright:
- 2015 Damyon Wiese
- 2015 Damyon Wiese
- License:
- http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
Members
(inner) Action :Boolean
to apply to plans when deleting a template
Type:
- Boolean
(inner) pagecontextid :Number
The id of the context
Type:
- Number
(inner) templateid :Number
The id of the template
Type:
- Number
Methods
(inner) confirmDelete(e)
Handler for "Delete learning plan template" actions.
Parameters:
Name | Type | Description |
---|---|---|
e |
Event |
(inner) deleteHandler(e)
Expose the event handler for the delete.
Parameters:
Name | Type | Description |
---|---|---|
e |
Event |
(inner) doDelete()
Delete a template and reload the page.
(inner) doDuplicate(e)
Duplicate a template and reload the page.
Parameters:
Name | Type | Description |
---|---|---|
e |
Event |
(inner) duplicateHandler(e)
Expose the event handler for the duplicate.
Parameters:
Name | Type | Description |
---|---|---|
e |
Event |
(inner) init(contextid)
Initialise the module.
Parameters:
Name | Type | Description |
---|---|---|
contextid |
Number | The context id of the page. |
(inner) reloadList(context)
Callback to render the page template again and update the page.
Parameters:
Name | Type | Description |
---|---|---|
context |
Object | The context for the template. |
(inner) updatePage(newhtml, newjs)
Callback to replace the dom element with the rendered template.
Parameters:
Name | Type | Description |
---|---|---|
newhtml |
String | The new html to insert. |
newjs |
String | The new js to run. |