Spaces:
Sleeping
Sleeping
Update templates/redirect_page.html
Browse files- templates/redirect_page.html +6 -11
templates/redirect_page.html
CHANGED
@@ -5,26 +5,21 @@
|
|
5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6 |
<title>Logging Out...</title>
|
7 |
<script type="text/javascript">
|
8 |
-
// Get the table number from Flask
|
9 |
var tableNumber = "{{ table_number }}";
|
10 |
-
|
11 |
window.onload = function() {
|
12 |
-
// Construct the logout redirect URL with table number
|
13 |
-
let redirectURL = "
|
14 |
if (tableNumber) {
|
15 |
redirectURL += "?table=" + encodeURIComponent(tableNumber);
|
16 |
}
|
17 |
-
|
18 |
-
|
19 |
-
window.open(redirectURL, "_blank");
|
20 |
-
|
21 |
-
// Optionally, also redirect the current tab:
|
22 |
-
// window.location.href = redirectURL;
|
23 |
};
|
24 |
</script>
|
25 |
</head>
|
26 |
<body>
|
27 |
<h1>Logging out...</h1>
|
28 |
-
<p>Please wait while we log you out and redirect you.</p>
|
29 |
</body>
|
30 |
</html>
|
|
|
5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6 |
<title>Logging Out...</title>
|
7 |
<script type="text/javascript">
|
8 |
+
// Get the table number from Flask (if needed)
|
9 |
var tableNumber = "{{ table_number }}";
|
|
|
10 |
window.onload = function() {
|
11 |
+
// Construct the logout redirect URL with table number (optional)
|
12 |
+
let redirectURL = "/login"; // Redirect to login page
|
13 |
if (tableNumber) {
|
14 |
redirectURL += "?table=" + encodeURIComponent(tableNumber);
|
15 |
}
|
16 |
+
// Optionally, redirect the current tab to the login page
|
17 |
+
window.location.href = redirectURL;
|
|
|
|
|
|
|
|
|
18 |
};
|
19 |
</script>
|
20 |
</head>
|
21 |
<body>
|
22 |
<h1>Logging out...</h1>
|
23 |
+
<p>Please wait while we log you out and redirect you to the login page.</p>
|
24 |
</body>
|
25 |
</html>
|