Commit 4b7fecb8 authored by Rob Commeren's avatar Rob Commeren 🐒
Browse files

translation fixes

parent fd013f5f
Pipeline #3538 passed with stages
in 16 seconds
This diff is collapsed.
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -174,40 +174,41 @@ export default {
? organizedBuckets.filter((el) => el.doc_count > 0)
: [];
if (selected.length > 0 && !this.fired) {
if (this.translation) {
organizedBuckets.forEach((element, i) => {
const transKey = this.translations[element.key];
if (
transKey
&& transKey.printouts[this.translation]
) {
if (transKey.printouts[this.translation][0].fulltext) {
organizedBuckets[i].name = transKey.printouts[this.translation][0].fulltext;
} else {
[organizedBuckets[i].name] = transKey.printouts[this.translation];
}
if (this.translation) {
organizedBuckets.forEach((element, i) => {
const transKey = this.translations[element.key];
if (
transKey
&& transKey.printouts[this.translation]
) {
if (transKey.printouts[this.translation][0].fulltext) {
organizedBuckets[i].name = transKey.printouts[this.translation][0].fulltext;
} else {
[organizedBuckets[i].name] = transKey.printouts[this.translation];
}
});
}
}
});
}
selected.forEach((element, i) => {
if (this.translation) {
const transValue = this.translations[element.value];
selected.forEach((element, i) => {
if (this.translation) {
const transValue = this.translations[element.value];
if (
transValue
&& transValue.printouts[this.translation]
) {
if (
transValue
&& transValue.printouts[this.translation]
transValue.printouts[this.translation][0].fulltext
) {
if (
transValue.printouts[this.translation][0].fulltext
) {
selected[i].name = transValue.printouts[this.translation][0].fulltext;
} else {
[selected[i].name] = transValue.printouts[this.translation];
}
Vue.set(this.$store.state.selected, i, selected[i]);
selected[i].name = transValue.printouts[this.translation][0].fulltext;
} else {
[selected[i].name] = transValue.printouts[this.translation];
}
Vue.set(this.$store.state.selected, i, selected[i]);
}
}
if (!selected[i].name) {
const value = this.config.facetSettings[selected[i].key]
? this.config.facetSettings[selected[i].key] : false;
if (value) {
......@@ -215,11 +216,9 @@ export default {
selected[i].name = valueLabel;
}
Vue.set(this.$store.state.selected, i, selected[i]);
});
this.fired = true;
} else {
this.fired = true;
}
}
});
this.fired = true;
if (this.type === 'date') {
this.strippedBuckets = organizedBuckets.reverse();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment