Fixes on importer file upload.
This commit is contained in:
parent
87bdecf223
commit
5ea408e974
|
@ -2,7 +2,8 @@
|
|||
<div
|
||||
class="page-container"
|
||||
:class="{'repository-level-page' : isNewCollection }">
|
||||
<tainacan-title />
|
||||
<tainacan-title
|
||||
:bread-crumb-items="[{ path: '', label: $i18n.get('collection') }]"/>
|
||||
<form
|
||||
v-if="collection != null && collection != undefined"
|
||||
class="tainacan-form"
|
||||
|
|
|
@ -85,7 +85,7 @@
|
|||
<div
|
||||
class="control selected-source-file"
|
||||
v-if="importerFile != undefined">
|
||||
<span>{{ importerFile[0].name }}</span>
|
||||
<span>{{ (importerFile.length != undefined && importerFile.length > 0 ) ? importerFile[0].name : importerFile.name }}</span>
|
||||
<a
|
||||
target="_blank"
|
||||
@click.prevent="importerFile = undefined">
|
||||
|
@ -255,7 +255,7 @@ export default {
|
|||
},
|
||||
onUploadFile() {
|
||||
return new Promise((resolve, reject) => {
|
||||
this.updateImporterFile({ sessionId: this.sessionId, file: this.importerFile[0] })
|
||||
this.updateImporterFile({ sessionId: this.sessionId, file: (this.importerFile.length != undefined && this.importerFile.length > 0) ? this.importerFile[0] : this.importerFile})
|
||||
.then(updatedImporter => {
|
||||
this.importer = updatedImporter;
|
||||
resolve();
|
||||
|
|
Loading…
Reference in New Issue