-
Notifications
You must be signed in to change notification settings - Fork 41
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
Initial session update with "rough" sorting #1052
Initial session update with "rough" sorting #1052
Conversation
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.
Hey @BradleySappington the code looks good, have a couple of questions! I need to test the changes on the server as well.
} | ||
$.ajax({ |
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.
@BradleySappington this is clever. Have you seen what happens where the is a failure? Is anything reported to the page for the user to see?
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.
It will report it only in the console, so if you have the console up on your terminal you will see it. I didn't think a session not-updating is something that the user should be aware of.
@@ -342,7 +340,7 @@ def archive_thumbnails_ajax(request, inst, proposal, observation=None): | |||
inst = JWST_INSTRUMENT_NAMES_MIXEDCASE[inst.lower()] | |||
|
|||
data = thumbnails_ajax(inst, proposal, obs_num=observation) | |||
|
|||
data['thumbnail_sort'] = request.session.get("image_sort", "Ascending") |
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.
@BradleySappington is this an example of storing session data like we discussed in the past? Also, does this set the default for the thumbails to be in Ascending order?
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.
Yes and Yes
making the list used in previous/next buttons reflect the order of the thumbnails shown on the proposal page