0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-24 23:48:13 -05:00

Merge pull request #4048 from novaugust/delete-post-shortcut

[Feature request] Add delete post shortcut to content screen
This commit is contained in:
John O'Nolan 2014-09-19 17:22:42 +02:00
commit 439e56028d

View file

@ -55,11 +55,15 @@ var PostsPostRoute = Ember.Route.extend(SimpleAuth.AuthenticatedRouteMixin, load
}, },
shortcuts: { shortcuts: {
'enter': 'openEditor' 'enter': 'openEditor',
'command+backspace, ctrl+backspace': 'deletePost'
}, },
actions: { actions: {
openEditor: function () { openEditor: function () {
this.transitionTo('editor.edit', this.get('controller.model')); this.transitionTo('editor.edit', this.get('controller.model'));
},
deletePost: function () {
this.send('openModal', 'delete-post', this.get('controller.model'));
} }
} }
}); });