From 7d5ef825c4bcbd5649aff2cfff1131f1a197c5b5 Mon Sep 17 00:00:00 2001 From: f-osorio Date: Fri, 24 Jan 2025 08:15:15 -0500 Subject: [PATCH 1/3] Add styling for undifferentiated names Name in the results is red, the info panel has a note about the name being undiffereniated. --- .../panels/edit/modals/ComplexLookupModal.vue | 13 ++++++++----- src/lib/utils_network.js | 10 +++++++++- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/src/components/panels/edit/modals/ComplexLookupModal.vue b/src/components/panels/edit/modals/ComplexLookupModal.vue index 4a4e65de..0ac0a00f 100644 --- a/src/components/panels/edit/modals/ComplexLookupModal.vue +++ b/src/components/panels/edit/modals/ComplexLookupModal.vue @@ -77,7 +77,7 @@ let options = [] // add in the the defaul search ALL of everything possible //options.push({label: 'All', urls:null, processor:null}) - + this.structure.valueConstraint.useValuesFrom.forEach((l)=>{ if (this.lookupConfig[l]){ this.lookupConfig[l].modes.forEach((mode)=>{ @@ -220,7 +220,7 @@ this.searchValueLocal = event.target.value } } - } + } }, @@ -298,7 +298,7 @@ event.preventDefault() return false } - // all macros use the ctrl key + // all macros use the ctrl key if (event.ctrlKey == true){ if (this.diacriticUse.length>0){ for (let macro of this.diacriticUseValues){ @@ -410,7 +410,7 @@ inputV.value = macro.codeEscape this.searchValueLocal = inputV.value } - + }else{ @@ -811,7 +811,7 @@ Searching... - @@ -836,6 +836,9 @@
DEPRECIATED AUTHORITY
+
+ THIS 1XX FIELD CANNOT BE USED UNDER RDA UNTIL THIS UNDIFFERENTIATED RECORD HAS BEEN HANDLED FOLLOWING THE GUIDELINES IN DCM Z1 008/32. +
view on id.loc.gov diff --git a/src/lib/utils_network.js b/src/lib/utils_network.js index 77103343..dcb14b1c 100644 --- a/src/lib/utils_network.js +++ b/src/lib/utils_network.js @@ -335,6 +335,7 @@ const utilsNetwork = { * @return {array} - An array of {@link searchComplexResult} results */ searchComplex: async function(searchPayload){ + console.info("searchComplex") // console.log("searchPayload",searchPayload) let returnUrls = useConfigStore().returnUrls @@ -382,6 +383,8 @@ const utilsNetwork = { url = url.replace('q=?','q=') } + url = url.replace('https://id.loc.gov','https://preprod-8287.id.loc.gov') + console.info("URL: ", url) let r = await this.fetchSimpleLookup(url, false, searchPayload.signal) //Config only allows 25 results, this will add something to the results @@ -412,7 +415,8 @@ const utilsNetwork = { literal:false, depreciated: false, extra: '', - total: r.count + total: r.count, + undifferentiated: false } @@ -421,6 +425,9 @@ const utilsNetwork = { hitAdd.label = hitAdd.suggestLabel.split('(DEPRECATED')[0] + ' DEPRECATED' hitAdd.depreciated = true } + if (hit.more && hit.more.undifferentiated && hit.more.undifferentiated == 'Name not-unique'){ + hitAdd.undifferentiated = true + } results.push(hitAdd) } @@ -466,6 +473,7 @@ const utilsNetwork = { }) } + console.info("results: ", results) // console.log(results," Date: Fri, 24 Jan 2025 08:27:47 -0500 Subject: [PATCH 2/3] Clean up --- src/lib/utils_network.js | 4 ---- src/stores/config.js | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/src/lib/utils_network.js b/src/lib/utils_network.js index dcb14b1c..990b3d35 100644 --- a/src/lib/utils_network.js +++ b/src/lib/utils_network.js @@ -335,7 +335,6 @@ const utilsNetwork = { * @return {array} - An array of {@link searchComplexResult} results */ searchComplex: async function(searchPayload){ - console.info("searchComplex") // console.log("searchPayload",searchPayload) let returnUrls = useConfigStore().returnUrls @@ -383,8 +382,6 @@ const utilsNetwork = { url = url.replace('q=?','q=') } - url = url.replace('https://id.loc.gov','https://preprod-8287.id.loc.gov') - console.info("URL: ", url) let r = await this.fetchSimpleLookup(url, false, searchPayload.signal) //Config only allows 25 results, this will add something to the results @@ -473,7 +470,6 @@ const utilsNetwork = { }) } - console.info("results: ", results) // console.log(results," Date: Fri, 24 Jan 2025 08:28:32 -0500 Subject: [PATCH 3/3] version++ --- src/stores/config.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/stores/config.js b/src/stores/config.js index d129d8ec..6c23d58b 100644 --- a/src/stores/config.js +++ b/src/stores/config.js @@ -7,7 +7,7 @@ export const useConfigStore = defineStore('config', { versionMajor: 0, versionMinor: 17, - versionPatch: 26, + versionPatch: 27, regionUrls: {