-
Notifications
You must be signed in to change notification settings - Fork 2
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
feat: Restrict access to "offline" flows #3196
Conversation
🤖 Hasura Change Summary compared a subset of table metadata including permissions: Updated Tables (2)
|
c27ad55
to
b2356a0
Compare
ceb2317
to
f1aaee8
Compare
Removed vultr server and associated DNS entries |
05e665f
to
ff0119b
Compare
export const OfflinePage: React.FC = () => ( | ||
<StatusPage bannerHeading="Offline"> | ||
<Typography variant="body2"> | ||
This service is not currently available. Please check back later. |
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.
Content here feels very minimal... open to suggestions!
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.
Here's a maybe curveball question / suggestion (sorry!):
This service is not currently available to new applicants. Please check back later.
If you're resuming an application you previously started, please use the link sent to you via email.
Basically, what's our plan for handling active sessions for an "offline" service? Can we disable the /published
route when no query params are present, but enable it for folks coming with query params email
& sessionId
? Otherwise I fear we get into much murkier questions around extending session expiry periods if offline, etc.
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.
Also I can imagine a future enhancement to the editor form could be simple rich text input to control what your "Offline" page says (eg add a specific date if they choose - like after winter holidays). But default copy would be this?
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.
Thanks for copy suggestion, updated ✅
No need to apologise - it's good to raise and be explicit here about the behaviour. I agree that this is actually the smartest way forward, and best for users. I've made change which implements this, but as it needs to be at a "higher level" than Save and Return, I've opted to use a layout which wraps this view.
export const OfflinePage: React.FC = () => ( | ||
<StatusPage bannerHeading="Offline"> | ||
<Typography variant="body2"> | ||
This service is not currently available. Please check back later. |
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.
Here's a maybe curveball question / suggestion (sorry!):
This service is not currently available to new applicants. Please check back later.
If you're resuming an application you previously started, please use the link sent to you via email.
Basically, what's our plan for handling active sessions for an "offline" service? Can we disable the /published
route when no query params are present, but enable it for folks coming with query params email
& sessionId
? Otherwise I fear we get into much murkier questions around extending session expiry periods if offline, etc.
f31edd1
to
97e6622
Compare
97e6622
to
587de80
Compare
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.
Thanks for latest updates here, works exactly as expected !
return isFlowAccessible ? children : <OfflinePage />; | ||
}; | ||
|
||
export default OfflineLayout; |
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.
Super clear solution ➕
What does this PR do?
flow.status
to/published
routespublic
role access to theanalytics
andanalytics_logs
table✅ Regression tests passing here https://github.com/theopensystemslab/planx-new/actions/runs/9288490634