Merged in feat/SW-1676-modify-contact-details-my-stay-anonymous (pull request #1468)

Feat/SW-1676 modify contact details my stay anonymous

* feat(SW-1676): Modify guest details step 1

* feat(SW-1676) Integration to api to update guest details

* feat(SW-1676) Reuse of old modal

* feat(SW-1676) updated modify guest

* feat(SW-1676) cleanup

* feat(SW-1676) updated myStayReturnRoute to sessionStorage


Approved-by: Niclas Edenvin
This commit is contained in:
Pontus Dreij
2025-03-07 13:41:25 +00:00
parent 2c7d72c540
commit 2509794d0c
33 changed files with 528 additions and 251 deletions

View File

@@ -94,10 +94,10 @@ export default function Form({ user }: EditFormProps) {
// Kept logout out of Next router forcing browser to navigate on logout url
window.location.href = logout[lang]
} else {
const myStayReturnRoute = localStorage.getItem("myStayReturnRoute")
const myStayReturnRoute = sessionStorage.getItem("myStayReturnRoute")
if (myStayReturnRoute) {
const returnRoute = JSON.parse(myStayReturnRoute)
localStorage.removeItem("myStayReturnRoute")
sessionStorage.removeItem("myStayReturnRoute")
router.push(returnRoute.path)
} else {
router.push(profile[lang])