diff --git a/static/css/styles(boris).css b/static/css/styles(boris).css index 91baa3d..3861397 100644 --- a/static/css/styles(boris).css +++ b/static/css/styles(boris).css @@ -16,6 +16,14 @@ } +.w-68{ + width: 68%; +} + +.f-r{ + float: right; +} + .font-base{ font-size: 16px; } diff --git a/static/css/styles.css b/static/css/styles.css index db03066..5fd5a36 100644 --- a/static/css/styles.css +++ b/static/css/styles.css @@ -1018,7 +1018,7 @@ h2.title_new_route{ padding: 10px; text-align: center; position: relative; - height: 44px; + height: 40px; } .menu_profile>div>a { diff --git a/static/js/filters_functions_find_route.js b/static/js/filters_functions_find_route.js index 8dbe40a..37bace9 100644 --- a/static/js/filters_functions_find_route.js +++ b/static/js/filters_functions_find_route.js @@ -68,7 +68,31 @@ function ajax_for_filter (data_d,get_url){ // enctype: 'json', data: JSON.stringify(data_d), success: function(data){ - document.querySelector(".block-finded-routes").innerHTML = data.html + let old_page_iterator = page_iterator + page_iterator++ + history.pushState({'data':data_d,'str_data':get_url}, "state_filters", `?${get_url}`); + // let element = document.createElement("img") + // element.classList.add("loader_filters_routes") + // element.src = "/static/img/svg/loader.svg" + let div = document.createElement("div") + div.classList.add("width-100") + div.classList.add("text-align-center") + div.classList.add("mb-10") + + div.innerHTML = "" + let ins_bef_el = document.querySelector(".block-finded-routes").firstChild + + $(div).insertBefore(ins_bef_el) + + let new_page_routes = document.createElement("div") + new_page_routes.classList.add("page_routes_" + page_iterator) + $(new_page_routes).insertAfter(".page_routes_" + old_page_iterator); + let line_separator = document.createElement("div") + line_separator.classList.add("line_separator_page_w_el") + $(line_separator).insertAfter(".page_routes_" + separator_iterator); + // document.querySelector(".info_profile").innerHTML = data.html; + separator_iterator++ + // document.querySelector(".block-finded-routes").innerHTML = data.html if (data.html === "\n\n\n\n\n"){ // document.querySelector(".block-finded-routes").innerHTML = "Нечего не найдено!" document.querySelector(".block-finded-routes").innerHTML = "
\n" + @@ -82,22 +106,12 @@ function ajax_for_filter (data_d,get_url){ "
" } else { - document.querySelector(".block-finded-routes").innerHTML = data.html + document.querySelector(`.page_routes_${old_page_iterator}`).innerHTML = data.html } // window.location.href = window.location.href + "?" + get_url // window.location.search = "?" + get_url - history.pushState({'data':data_d,'str_data':get_url}, "state_filters", `?${get_url}`); - // let element = document.createElement("img") - // element.classList.add("loader_filters_routes") - // element.src = "/static/img/svg/loader.svg" - let div = document.createElement("div") - div.classList.add("width-100") - div.classList.add("text-align-center") - div.classList.add("mb-10") - div.innerHTML = "" - let ins_bef_el = document.querySelector(".block-finded-routes").firstChild - $(div).insertBefore(ins_bef_el) + // window.history.pushState({data:get_url // },{}) // clearTimeout(t) diff --git a/templates/blocks/b_find_route_form.html b/templates/blocks/b_find_route_form.html index 3250b10..47d05a7 100644 --- a/templates/blocks/b_find_route_form.html +++ b/templates/blocks/b_find_route_form.html @@ -1,4 +1,5 @@ {% load static %} +{% load i18n %} {% if route_form %}
@@ -13,6 +14,18 @@ {% include "blocks/b_finded_routes.html" %} + +
+ + {% if last_block_routes == False %} +
+ +
+ +
+
+ {% endif %} +
{% endif %} diff --git a/templates/blocks/b_finded_routes.html b/templates/blocks/b_finded_routes.html index 25b70bc..c4d7b85 100644 --- a/templates/blocks/b_finded_routes.html +++ b/templates/blocks/b_finded_routes.html @@ -26,13 +26,6 @@
- {% if last_block_routes == False %} -
- -
- -
-
- {% endif %} + \ No newline at end of file diff --git a/templates/blocks/b_user_profile.html b/templates/blocks/b_user_profile.html index fd7c993..b2acc72 100644 --- a/templates/blocks/b_user_profile.html +++ b/templates/blocks/b_user_profile.html @@ -74,9 +74,9 @@ Мой профиль -
- Выйти из профиля -
+{#
#} +{# Выйти из профиля#} +{#
#}
{% if not page_html %}