diff --git a/assets/javascripts/wizard/components/wizard-field-upload.js.es6 b/assets/javascripts/wizard/components/wizard-field-upload.js.es6 index b7bc9868..f7f82faf 100644 --- a/assets/javascripts/wizard/components/wizard-field-upload.js.es6 +++ b/assets/javascripts/wizard/components/wizard-field-upload.js.es6 @@ -1,10 +1,8 @@ import getUrl from "discourse-common/lib/get-url"; -import computed from "ember-addons/ember-computed-decorators"; import { getToken } from "wizard/lib/ajax"; -import { getOwner } from "discourse-common/lib/get-owner"; export default Ember.Component.extend({ - classNames: ["wizard-image-row"], + classNames: ["wizard-field-upload"], uploading: false, didInsertElement() { @@ -28,8 +26,10 @@ export default Ember.Component.extend({ $upload.on("fileuploadsubmit", () => this.set("uploading", true)); $upload.on("fileuploaddone", (e, response) => { - this.set("field.value", response.result.url); - this.set("uploading", false); + this.setProperties({ + "field.value": response.result, + "uploading": false + }); }); $upload.on("fileuploadfail", (e, response) => { diff --git a/assets/javascripts/wizard/templates/components/wizard-field-upload.hbs b/assets/javascripts/wizard/templates/components/wizard-field-upload.hbs index 42414a54..4d984912 100644 --- a/assets/javascripts/wizard/templates/components/wizard-field-upload.hbs +++ b/assets/javascripts/wizard/templates/components/wizard-field-upload.hbs @@ -1,10 +1,16 @@ -