Fixed members CSV uploader for non-devExperiments version

This commit is contained in:
Nazar Gargol 2020-07-13 20:30:32 +12:00
parent 21a5b2ad38
commit caf08b1021

View File

@ -209,13 +209,17 @@ export default ModalComponent.extend({
},
upload() {
if (this.file && this.mapping.getKeyByValue('email')) {
this.generateRequest();
if (this.config.get('enableDeveloperExperiments')) {
if (this.file && this.mapping.getKeyByValue('email')) {
this.generateRequest();
} else {
this.set('uploadErrors', [{
message: 'Import as "Email" value is missing.',
context: 'The CSV import has to have selected import as "Email" field.'
}]);
}
} else {
this.set('uploadErrors', [{
message: 'Import as "Email" value is missing.',
context: 'The CSV import has to have selected import as "Email" field.'
}]);
this.generateRequest();
}
},