DEV: Transition from Ember constant to imports (#34)

This commit is contained in:
Justin DiRose 2020-11-30 10:35:21 -06:00 committed by GitHub
parent d430098bad
commit 443fdc3ec6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -2,10 +2,11 @@ import Controller from "@ember/controller";
import Subscription from "discourse/plugins/discourse-subscriptions/discourse/models/subscription";
import Transaction from "discourse/plugins/discourse-subscriptions/discourse/models/transaction";
import I18n from "I18n";
import { not } from "@ember/object/computed";
export default Controller.extend({
selectedPlan: null,
isAnonymous: Ember.computed.not("currentUser"),
isAnonymous: not("currentUser"),
init() {
this._super(...arguments);

View File

@ -1,8 +1,9 @@
import EmberObject from "@ember/object";
import discourseComputed from "discourse-common/utils/decorators";
import { computed } from "@ember/object";
const Plan = EmberObject.extend({
amountDollars: Ember.computed("unit_amount", {
amountDollars: computed("unit_amount", {
get() {
return parseFloat(this.get("unit_amount") / 100).toFixed(2);
},