Bind value on Collection Metadatum select at Importer Page.
This commit is contained in:
parent
96d0058469
commit
72fba0ea5b
File diff suppressed because it is too large
Load Diff
|
@ -13,6 +13,7 @@
|
||||||
"html-to-json": "^0.6.0",
|
"html-to-json": "^0.6.0",
|
||||||
"mdi": "^2.2.43",
|
"mdi": "^2.2.43",
|
||||||
"moment": "^2.22.1",
|
"moment": "^2.22.1",
|
||||||
|
"npm": "^6.1.0",
|
||||||
"qs": "^6.5.2",
|
"qs": "^6.5.2",
|
||||||
"v-mask": "^1.3.2",
|
"v-mask": "^1.3.2",
|
||||||
"v-tooltip": "^2.0.0-rc.32",
|
"v-tooltip": "^2.0.0-rc.32",
|
||||||
|
|
|
@ -107,6 +107,7 @@
|
||||||
v-if="collectionMetadata != undefined &&
|
v-if="collectionMetadata != undefined &&
|
||||||
collectionMetadata.length > 0 &&
|
collectionMetadata.length > 0 &&
|
||||||
!isFetchingCollectionMetadata"
|
!isFetchingCollectionMetadata"
|
||||||
|
:value="checkCurrentSelectedCollectionMetadatum(source_metadatum)"
|
||||||
@input="onSelectCollectionMetadata($event, source_metadatum)"
|
@input="onSelectCollectionMetadata($event, source_metadatum)"
|
||||||
:placeholder="$i18n.get('label_select_metadatum')">
|
:placeholder="$i18n.get('label_select_metadatum')">
|
||||||
<option :value="undefined">
|
<option :value="undefined">
|
||||||
|
@ -340,6 +341,13 @@ export default {
|
||||||
checkIfMetadatumIsAvailable(metadatumId) {
|
checkIfMetadatumIsAvailable(metadatumId) {
|
||||||
return this.mappedCollection['mapping'][metadatumId] != undefined;
|
return this.mappedCollection['mapping'][metadatumId] != undefined;
|
||||||
},
|
},
|
||||||
|
checkCurrentSelectedCollectionMetadatum(sourceMetadatum) {
|
||||||
|
for (let key in this.mappedCollection['mapping']) {
|
||||||
|
if(this.mappedCollection['mapping'][key] == sourceMetadatum)
|
||||||
|
return key;
|
||||||
|
}
|
||||||
|
return undefined;
|
||||||
|
},
|
||||||
onInputURL(event) {
|
onInputURL(event) {
|
||||||
this.url = event;
|
this.url = event;
|
||||||
|
|
||||||
|
@ -433,9 +441,8 @@ export default {
|
||||||
|
|
||||||
if (removedKey != '')
|
if (removedKey != '')
|
||||||
delete this.mappedCollection['mapping'][removedKey];
|
delete this.mappedCollection['mapping'][removedKey];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Necessary for causing reactivity to re-check if metadata remains available
|
// Necessary for causing reactivity to re-check if metadata remains available
|
||||||
this.collectionMetadata.push("");
|
this.collectionMetadata.push("");
|
||||||
this.collectionMetadata.pop();
|
this.collectionMetadata.pop();
|
||||||
|
|
Loading…
Reference in New Issue