diff --git a/frontend/App.vue b/frontend/App.vue index 34ff321..3733106 100644 --- a/frontend/App.vue +++ b/frontend/App.vue @@ -169,8 +169,8 @@ item type
- {{isa_labels[isa_qid]}} ({{isa_qid}}) + v-for="isa in edit.wikidata.isa_list"> + {{ isa.label }} ({{isa.qid}})
@@ -451,8 +451,9 @@
item type - -
{{isa_labels[isa_qid]}} ({{isa_qid}}) + +
{{isa.label}} ({{isa.qid}}) +
@@ -467,11 +468,12 @@
heritage designation -
{{ wd_item.heritage_designation.join("; ") }} + +
{{hd.label}} ({{hd.qid}}) +
-
@@ -813,7 +815,7 @@ export default { return count; }, item_is_selceted(item) { - return item.wikidata.isa_list.some(isa => this.isa_ticked.includes(isa)); + return item.wikidata.isa_list.some(isa => this.isa_ticked.includes(isa.qid)); }, selected_items() { var ret = {}; @@ -825,7 +827,7 @@ export default { if (!this.linked && item.osm) continue; if (!this.not_linked && !item.osm) continue; - if (item.wikidata.isa_list.some(isa => this.isa_ticked.includes(isa))) { + if (item.wikidata.isa_list.some(isa => this.isa_ticked.includes(isa.qid))) { ret[qid] = item; } } @@ -864,9 +866,7 @@ export default { } var params = { q: value }; - var isa_search_url = `${this.api_base_url}/api/1/isa_search`; - - axios.get(isa_search_url, { params: params }).then((response) => { + this.api_call("isa_search", { params: params }).then((response) => { this.item_type_hits = response.data.items; }); }, @@ -920,7 +920,7 @@ export default { for(const item of Object.values(this.selected_items)) { // var opacity = 0.9; if (highlight_isa) { - var match = item.wikidata.isa_list.some(isa => isa == highlight_isa.qid); + var match = item.wikidata.isa_list.some(isa => isa.qid == highlight_isa.qid); // opacity = match ? 1 : 0.2; if (match) { this.add_hover_circles(item);