0
0
Fork 1
Spiegel von https://github.com/paviliondev/discourse-custom-wizard.git synchronisiert 2024-11-10 12:22:54 +01:00
discourse-custom-wizard/assets/javascripts/discourse/components/realtime-validation-settings.js.es6

18 Zeilen
453 B
Text

2021-01-27 06:08:26 +01:00
import Component from "@ember/component";
2021-01-30 18:46:04 +01:00
export default Component.extend({
init(){
this._super(...arguments);
if (!this.validations) return;
if (!this.field.validations) {
const validations = {};
this.validations.forEach((validation) => {
validations[validation] = {};
});
this.set('field.validations', EmberObject.create(validations));
}
}
});