Initial POC for a facility that uses redirects#1357
Conversation
|
@Fingel is there a branch of the OCS that this relies on to work? The redirection to the OCS looks good, but I'm guessing this relies on OCS changes to be fully functional. It would be nice to have something running locally before merging this. |
|
OCS PR here: LCOGT/observation-portal-frontend#130 |
Screencast-2025-12-03-13_02.mp4 |
jchate6
left a comment
There was a problem hiding this comment.
Looks great. I love the simplicity.
Let's add some small notes for ourselves in the ReadtheDocs about what's expected from a redirect facility on the TOM side and on the Facility side to make this work.
Specifically what the facility should expect and what they need to pass back.
| } | ||
| return urllib.parse.urlencode(set_fields) | ||
|
|
||
| def observation_portal_uri(self) -> str: |
| user = request.user | ||
| if not all([facility, target_id, observation_id]): | ||
| messages.error(self.request, 'Missing required parameters: facility, target_id, observation_id') | ||
| return redirect(reverse('tom_observations:list')) |
There was a problem hiding this comment.
Might be nice to redirect back to target detail page if target_id exists
|
I added a couple paragraphs about the Redirect Facility to the sphinx docs. I'm reluctant to add anything more specific as the implementation might change. |
I think that's exactly the right level of detail. |
This is how this flow works:
User is at the TOM:
Now at the OCS:
Now back at the TOM: