-
Notifications
You must be signed in to change notification settings - Fork 4
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: no redirect on save #599
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.
Det holder ikke å bare ikke gjøre en redirect her. Du må også sørge for at formen har riktig status med tanke på initial lastet begrep.
b091dee
to
2e07107
Compare
@@ -196,6 +196,12 @@ export const FormConceptPure: FC<Props> = ({ | |||
return () => {}; | |||
}, [dirty, showUserPrompt, saveCalled, deleteCalled]); | |||
|
|||
useEffect(() => { | |||
if (saveCalled) { | |||
window.location.reload(); |
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.
Hva skjer hvis du nå lagrer et helt nytt begrep?
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.
Tror lagringsfunksjonaliteten vil fungere som før, men i stedet for å bli redirectet til begrepskatalogen etter lagring, så refreshes siden på nytt for å hente sise oppdateringene som ble lagret etter click på lagre-knappen.
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.
joa, men vil den da ikke tro at du vil opprette enda et nytt begrep?
siden du ikke har id i uri-feltet
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.
Har testet nå. Den lander på samme uri hver gang. Men kan hende jeg misforstår deg
2e07107
to
3a6225a
Compare
3a6225a
to
273dfb3
Compare
Denne kan lukkes! |
fixes #585