diff --git a/src/components/panels/edit/modals/SubjectEditor.vue b/src/components/panels/edit/modals/SubjectEditor.vue index 6b9937f6..1a9cf690 100644 --- a/src/components/panels/edit/modals/SubjectEditor.vue +++ b/src/components/panels/edit/modals/SubjectEditor.vue @@ -2599,6 +2599,8 @@ updated: function() { // preselect the search type, if a children's subject if (this.searchType.includes("Childrens")){ this.searchMode = "CHILD" + } else { + this.searchMode = "LCSHNAF" } // this was opened from an existing subject let profileData = this.profileData diff --git a/src/lib/utils_network.js b/src/lib/utils_network.js index d88845c3..a7a12fbf 100644 --- a/src/lib/utils_network.js +++ b/src/lib/utils_network.js @@ -1879,7 +1879,7 @@ const utilsNetwork = { } //CYAK subdivisions - if (resultsPayloadSubjectsSimpleSubdivision.length>0 && searchType.includes(":Topic:Childrens:")){ + if (resultsChildrenSubDiv.length>0 && searchType.includes(":Topic:Childrens:")){ for (let r of resultsChildrenSubDiv){ // lower case, remove end space, make double whitespace into one and remove any punctuation if (heading.label.toLowerCase().trim().replace(/\s+/g,' ').replace(/[\p{P}$+<=>^`|~]/gu, '') == r.label.toLowerCase().trim().replace(/[\p{P}$+<=>^`|~]/gu, '')){ @@ -1891,6 +1891,7 @@ const utilsNetwork = { } } if (foundHeading){ continue } + } if (!foundHeading){