0.0.274
This commit is contained in:
@@ -16,6 +16,14 @@
|
||||
|
||||
}
|
||||
|
||||
.w-68{
|
||||
width: 68%;
|
||||
}
|
||||
|
||||
.f-r{
|
||||
float: right;
|
||||
}
|
||||
|
||||
.font-base{
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
@@ -1018,7 +1018,7 @@ h2.title_new_route{
|
||||
padding: 10px;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
height: 44px;
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
.menu_profile>div>a {
|
||||
|
||||
@@ -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 = "<img src='/static/img/svg/loader.svg' class='loader_filters_routes'/>"
|
||||
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 = "<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" +
|
||||
@@ -82,22 +106,12 @@ function ajax_for_filter (data_d,get_url){
|
||||
" </div>"
|
||||
|
||||
} 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 = "<img src='/static/img/svg/loader.svg' class='loader_filters_routes'/>"
|
||||
let ins_bef_el = document.querySelector(".block-finded-routes").firstChild
|
||||
$(div).insertBefore(ins_bef_el)
|
||||
|
||||
// window.history.pushState({data:get_url
|
||||
// },{})
|
||||
// clearTimeout(t)
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
{% load static %}
|
||||
{% load i18n %}
|
||||
|
||||
{% if route_form %}
|
||||
<form name="find_route">
|
||||
@@ -13,6 +14,18 @@
|
||||
|
||||
{% include "blocks/b_finded_routes.html" %}
|
||||
|
||||
|
||||
<div class="clear_both"></div>
|
||||
|
||||
{% if last_block_routes == False %}
|
||||
<div class="text-align-center w-68 f-r">
|
||||
<button class="button-find-more-routes" id="25" onclick="load_routes(this)">{% trans "Показать ещё 10" %}</button>
|
||||
<div class="width-100 text-align-center mb-10">
|
||||
<img class="loader_f_loading_routes" src="{% static "img/svg/loader.svg" %}">
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="clear_both"></div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
@@ -26,13 +26,6 @@
|
||||
<div class="page_routes_2">
|
||||
|
||||
</div>
|
||||
{% if last_block_routes == False %}
|
||||
<div class="text-align-center">
|
||||
<button class="button-find-more-routes" id="25" onclick="load_routes(this)">{% trans "Показать ещё 10" %}</button>
|
||||
<div class="width-100 text-align-center mb-10">
|
||||
<img class="loader_f_loading_routes" src="{% static "img/svg/loader.svg" %}">
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
|
||||
</div>
|
||||
@@ -74,9 +74,9 @@
|
||||
<img class="svg" src="/static/img/svg/User.svg">
|
||||
<a href="#">Мой профиль</a>
|
||||
</div>
|
||||
<div>
|
||||
<a href="/profile/logout">Выйти из профиля</a>
|
||||
</div>
|
||||
{# <div>#}
|
||||
{# <a href="/profile/logout">Выйти из профиля</a>#}
|
||||
{# </div>#}
|
||||
</div>
|
||||
<div class="info_profile">
|
||||
{% if not page_html %}
|
||||
|
||||
Reference in New Issue
Block a user