This commit is contained in:
2023-10-27 18:02:18 +03:00
parent b64f58c237
commit 0864a07cdf

View File

@@ -38,16 +38,19 @@ function select_tab_profile (el,url,owner_type=null) {
el.classList.add('selected') el.classList.add('selected')
let body = document.querySelector("body") let body = document.querySelector("body")
body.style.overflow = "hidden" body.style.overflow = "hidden"
let confirm_url_f_lang = '' let confirm_url_f_lang_ru = ''
let confirm_url_f_lang_en = ''
if (owner_type){ if (owner_type){
window.history.pushState(null, null, `/${document.documentElement.lang}/profile/page/${profile_tabs_f_static_map.get(`${url}_${owner_type}`)}/`) window.history.pushState(null, null, `/${document.documentElement.lang}/profile/page/${profile_tabs_f_static_map.get(`${url}_${owner_type}`)}/`)
confirm_url_f_lang = `/${document.documentElement.lang}/profile/page/${profile_tabs_f_static_map.get(`${url}_${owner_type}`)}/` confirm_url_f_lang_ru = `/ru/profile/page/${profile_tabs_f_static_map.get(`${url}_${owner_type}`)}/`
confirm_url_f_lang_en = `/en/profile/page/${profile_tabs_f_static_map.get(`${url}_${owner_type}`)}/`
} else { } else {
window.history.pushState(null, null, `/${document.documentElement.lang}/profile/page/${profile_tabs_f_static_map.get(url)}/`) window.history.pushState(null, null, `/${document.documentElement.lang}/profile/page/${profile_tabs_f_static_map.get(url)}/`)
confirm_url_f_lang = `/${document.documentElement.lang}/profile/page/${profile_tabs_f_static_map.get(url)}/` confirm_url_f_lang_ru = `/ru/profile/page/${profile_tabs_f_static_map.get(url)}/`
confirm_url_f_lang_en = `/en/profile/page/${profile_tabs_f_static_map.get(url)}/`
} }
document.querySelector("#ru_lang").href = confirm_url_f_lang document.querySelector("#ru_lang").href = confirm_url_f_lang_ru
document.querySelector("#en_lang").href = confirm_url_f_lang document.querySelector("#en_lang").href = confirm_url_f_lang_en
middleWareJS() middleWareJS()