From 7b75c533a80e258f64ddb0a541bddbf3600194aa Mon Sep 17 00:00:00 2001 From: SBD Date: Wed, 31 Jan 2024 13:23:50 +0300 Subject: [PATCH 1/3] 3 --- static/js/global_js.js | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/static/js/global_js.js b/static/js/global_js.js index 29324b7..dadf425 100644 --- a/static/js/global_js.js +++ b/static/js/global_js.js @@ -11,6 +11,25 @@ window.onload = function (){ middleWareJS() openOrCloseCurtainSupportChat() openOverlayOrClose() + if (window.location.href.includes('profile') && !window.location.href.includes('login') && !window.location.href.includes('registration')){ + let user_type = getInfoAboutUser() + if (user_type === 'mobile') { + open_curtain_w_btn_profile() + + } else { + if (!window.location.href.includes('profile')){ + open_curtain_w_btn_profile() + } + } + if (window.location.href.includes("profile")){ + setStandartSettingsToBlockOverlay() + } + + if (window.location.href.includes("profile")){ + selectTabProfileIfHisNotSelected(url) + } + deleteMarkerMessages(el) + } } // From b41f8c7eca13dcb6e7c2b6152d158ee5e2aabb5d Mon Sep 17 00:00:00 2001 From: SBD Date: Wed, 31 Jan 2024 13:37:31 +0300 Subject: [PATCH 2/3] 3 --- static/js/authorization.js | 2 +- static/js/global_js.js | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/static/js/authorization.js b/static/js/authorization.js index be0c42c..13de9b5 100644 --- a/static/js/authorization.js +++ b/static/js/authorization.js @@ -18,7 +18,7 @@ function SendLoginForm(el){ data: formData, success: function(data){ - location.href = `/profile/page/dashboard/?mobile=${getInfoAboutUser() === 'mobile'}` + location.href = `/profile/page/dashboard/` diff --git a/static/js/global_js.js b/static/js/global_js.js index dadf425..748fbc9 100644 --- a/static/js/global_js.js +++ b/static/js/global_js.js @@ -25,10 +25,13 @@ window.onload = function (){ setStandartSettingsToBlockOverlay() } - if (window.location.href.includes("profile")){ - selectTabProfileIfHisNotSelected(url) + // if (window.location.href.includes("profile")){ + // selectTabProfileIfHisNotSelected(url) + // } + let chats = document.querySelector(`[data-ajax-url='chats']`) + if (chats){ + deleteMarkerMessages() } - deleteMarkerMessages(el) } } // From 8db1d6fdce12045d88f913e231f7286bacee9799 Mon Sep 17 00:00:00 2001 From: SBD Date: Wed, 31 Jan 2024 13:41:47 +0300 Subject: [PATCH 3/3] 3 --- static/js/registration.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/static/js/registration.js b/static/js/registration.js index f199b3b..7defc91 100644 --- a/static/js/registration.js +++ b/static/js/registration.js @@ -15,7 +15,7 @@ function SendRegistrationForm(el){ data: formData, success: function(data){ - location.href = `/profile/page/dashboard/?mobile=${getInfoAboutUser() === 'mobile'}` + location.href = `/profile/page/dashboard/` }, error: function (data, exception){ document.querySelector(".register").innerHTML = data.responseJSON.html