-
-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix the NSF award API endpoint #2244
Conversation
- Update the default grantsUrl to point to a proxy relative to the repository’s domain - Remove unused getGrant method from the LookupModel - Use native fetch API instead of jQuery.ajax to retrieve grants - Show spinner to indicate that grants are being retrieved (was set up but not used) - Move some logic from the getGrantAutocomplete method to new, smaller methods - Add missing JS docs - Add error handling Issue #2233
@rushirajnenuji, no rush, but if would you have a chance to give this a quick test to make sure everything's ok? You should only need to set the theme to "arctic" in order for the funding autocomplete field to work in the editor. |
Thank you @robyngit -- I'll test it out and get back to you. |
@rushirajnenuji forgot to point out that I did identify some improvements that are needed to this in the future: #2243 (just to save you some time in case you come to the same conclusions) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed these changes on my local instance of MetacatUI and they look good. Thank you for getting this fix in @robyngit!
Thanks @rushirajnenuji ! |
The major part of the fix involved setting up the ADC proxy to point to the new NSF grants API endpoint, then using the proxy in MetacatUI rather than the endpoint directly since it doesn't support CORS. Other minor fixes and improvements made along the way include: