Skip to content
Snippets Groups Projects
Commit caf71a8d authored by Tobias Ullerich's avatar Tobias Ullerich
Browse files

#187 - Add new page-action, navigate-action

parent 3b200827
No related branches found
No related tags found
No related merge requests found
......@@ -21,5 +21,42 @@ module.exports = function (self) {
});
},
},
page_action: {
name: 'Set Page',
options: [
{
id: 'page',
type: 'number',
label: 'Page Number',
default: '',
},
],
callback: async (event) => {
self.sendToWebSocket('page-action', {
'page': event.options.page - 1
});
},
},
navigate_action: {
name: 'Navigate',
options: [
{
id: 'type',
type: 'dropdown',
choices: [
{ id: 'PREVIOUS', label: 'Previous' },
{ id: 'NEXT', label: 'Next' }
],
label: 'Action',
default: '',
},
],
callback: async (event) => {
self.sendToWebSocket('navigate-action', {
'action': event.options.type
});
},
}
})
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment