Skip to content

Commit

Permalink
Merge pull request #1594 from UNC-Libraries/collection-list-fix
Browse files Browse the repository at this point in the history
Fix issue with advanced search collection list call being routed through Vue
  • Loading branch information
sharonluong authored Jul 18, 2023
2 parents 4552c0d + 90e3b40 commit adae4f3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion static/js/vue-cdr-access/src/components/advancedSearch.vue
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export default {
methods: {
getCollections() {
get('/advancedSearch/collections').then((response) => {
get('/advancedSearch/collectionsJson').then((response) => {
this.collections = response.data;
}).catch(function (error) {
console.log(error);
Expand Down
2 changes: 1 addition & 1 deletion static/js/vue-cdr-access/tests/unit/advancedSearch.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ describe('advancedSearch.vue', () => {
],
"id":"fc77a9be-b49d-4f4e-b656-1644c9e964fc", "title":"testCollection"
}];
moxios.stubRequest('/advancedSearch/collections', {
moxios.stubRequest('/advancedSearch/collectionsJson', {
status: 200,
response: JSON.stringify(collections)
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public class AdvancedSearchFormController extends AbstractErrorHandlingSearchCon
.sorted()
.collect(Collectors.toList());

@RequestMapping(path = "/advancedSearch/collections", produces = APPLICATION_JSON_VALUE)
@RequestMapping(path = "/advancedSearch/collectionsJson", produces = APPLICATION_JSON_VALUE)
public @ResponseBody String getCollections() {
AccessGroupSet accessGroups = GroupsThreadStore.getPrincipals();
SearchResultResponse collectionResultResponse = queryLayer.getCollectionList(accessGroups);
Expand Down

0 comments on commit adae4f3

Please sign in to comment.