Unify API keys and web hooks into a single admin nav header.

This commit is contained in:
Guo Xiang Tan
2016-09-19 16:43:06 +08:00
parent fa6b10cf3c
commit 547750e9dd
17 changed files with 86 additions and 53 deletions

View File

@ -33,7 +33,7 @@ export default Ember.Component.extend({
redeliver() {
return bootbox.confirm(I18n.t('admin.web_hooks.events.redeliver_confirm'), I18n.t('no_value'), I18n.t('yes_value'), result => {
if (result) {
ajax(`/admin/web_hooks/${this.get('model.web_hook_id')}/events/${this.get('model.id')}/redeliver`, { type: 'POST' }).then(json => {
ajax(`/admin/api/web_hooks/${this.get('model.web_hook_id')}/events/${this.get('model.id')}/redeliver`, { type: 'POST' }).then(json => {
this.set('model', json.web_hook_event);
}).catch(popupAjaxError);
}