Files
discourse-subscriptions/assets/javascripts/discourse/controllers/admin-plugins-discourse-patrons-plans-show.js.es6
T
Rimian Perkins 6f9195a7d4 Create Plans
* rescue and respond to error from stripe
* save plan name and id
2019-10-08 15:55:38 +11:00

15 lines
326 B
JavaScript

import { popupAjaxError } from "discourse/lib/ajax-error";
export default Ember.Controller.extend({
actions: {
createPlan() {
this.get("model")
.save()
.then(() => {
this.transitionToRoute("adminPlugins.discourse-patrons.plans");
})
.catch(popupAjaxError);
}
}
});