Merge remote-tracking branch 'origin/main'

This commit is contained in:
2023-11-30 14:43:46 +03:00
27 changed files with 342 additions and 128 deletions

View File

@@ -2817,4 +2817,31 @@
text-align: left;
top: 0;
left: 19px;
}
.btn_a_anchor{
border-radius: 10px;
background: #E6E6E6;
width: 20%;
height: 60px;
font-size: 18px;
font-style: normal;
font-weight: 600;
line-height: 26px;
color: rgba(39, 36, 36, 0.60);
margin-left: 5px;
display: block;
}
.btn_a_anchor.partners{
background: #FF613A;
color: #FFF;
}
.text_in_btn_a_anchor{
padding-top: 20px;
}
.anchor{
scroll-margin-top: 60px;
}

View File

@@ -1964,8 +1964,8 @@ button#more_button{
border-radius: 10px;
text-align: center;
box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.12);
margin: 0 auto;
margin-left: 0;
margin-right: 0;
}
@@ -2203,23 +2203,26 @@ figure{
text-align: -moz-center;
width: 100%;
margin-top: 40px;
display: flex;
justify-content: center;
flex-wrap: wrap;
}
#how_it_work_b{
border-radius: 10px;
background: #E6E6E6;
width: 20%;
height: 60px;
font-size: 18px;
font-style: normal;
font-weight: 600;
line-height: 26px;
color: rgba(39, 36, 36, 0.60);
margin-left: 5px;
/*#how_it_work_b{*/
/* border-radius: 10px;*/
/* background: #E6E6E6;*/
/* width: 20%;*/
/* height: 60px;*/
/* font-size: 18px;*/
/* font-style: normal;*/
/* font-weight: 600;*/
/* line-height: 26px;*/
/* color: rgba(39, 36, 36, 0.60);*/
/* margin-left: 5px;*/
}
/*}*/
.benefit_img_item{
width: 30%;

View File

@@ -114,17 +114,9 @@ function ajax_for_filter (data_d,get_url){
}
}
}
if (data.html === "\n\n\n\n\n"){
if (data.html.includes("not_found_routes")){
// document.querySelector(".block-finded-routes").innerHTML = "<span style='color: #ff0000;font-weight: 800;font-size: 18px;padding: 10px;'>Нечего не найдено!</span>"
document.querySelector(".block-finded-routes").innerHTML = "<div class=\"not_found_routes show\">\n" +
" <div class=\"text-align-center fw-700 font-large c-txt-b2 m-a w-80 m-t-8p\">\n" +
" Упс... <span class=\"orange-text\">Ничего не найдено</span>, попробуйте\n" +
" изменить параметры поиска или оставьте заявку\n" +
" на перевозку посылки\n" +
" </div>\n" +
" <img class=\"boxes_not_fond_routes left\" src=\"/static/img/boxes_for_not_found_routes/b_1.svg\"\">\n" +
" <img class=\"boxes_not_fond_routes right\" src=\"/static/img/boxes_for_not_found_routes/b_2.svg\"\">\n" +
" </div>"
document.querySelector(".block-finded-routes").innerHTML = data.html
} else {

View File

@@ -5,31 +5,6 @@
// window.onfocus = function () {
// getSocketState()
// }
let map_of_words_en = new Map([
['закрыть'],['Close']
])
let map_of_words_ru = new Map([
['close'],['Закрыть']
])
function translate_words (word,lang){
let corr_word = word.toLowersCase()
let trans_word = null
if (lang === 'ru'){
trans_word = map_of_words_ru.get(`${corr_word}`)
} else if (lang === 'en') {
trans_word = map_of_words_en.get(`${corr_word}`)
}
}
function check_return_trans_word (str) {
if (!str === undefined && str === '' && str){
return str
} else {
console.log(`error! str = ${str}`)
}
}
window.onload = function (){
middleWareJS()

View File

@@ -332,7 +332,9 @@ function selectItemAddrPoint(id, name, ctrl_name,){
tap_txt_cont.setAttribute('title',name)
let tap_cont = document.querySelector("#id_" + ctrl_name.slice(0, -4));
tap_cont.value = id;
changeWidthEL(tap_txt_cont)
if (!window.location.href.includes("profile")){
changeWidthEL(tap_txt_cont)
}
input_list.classList.remove('show');
if (document.querySelector(".container_form_search_carrier")){
document.querySelector(".container_form_search_carrier").style.zIndex = 'unset'
@@ -522,15 +524,21 @@ function sendRoute(el, routeID = null){
data: JSON.stringify(obj_w_el_form),
success: function(data){
let data_route_id = data.route_id
// location.href = '/profile'
document.querySelector(".info_profile").innerHTML = data.html
let el_route = document.querySelector(`[data-number-of-route="${routeID}"]`);
el_route.scrollIntoView(true);
let el_route = document.querySelector(`[data-number-of-route="${data_route_id}"]`);
if (routeID){
el_route = document.querySelector(`[data-number-of-route="${routeID}"]`);
}
el_route.scrollIntoView({
behavior:"smooth",
block:'start',
inline:'start'
});