diff --git a/static/css/styles.css b/static/css/styles.css index 6177bae..8ba27f5 100644 --- a/static/css/styles.css +++ b/static/css/styles.css @@ -802,7 +802,7 @@ input.deactive { box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.12); position: absolute; bottom: -10%; - left: 37%; + left: 40%; height: fit-content; width: 250px; padding: 10px; @@ -1105,7 +1105,10 @@ select { .errorlist>li{ color:red; - + margin-left: 12px; +} +span.errorlist{ + color: red; } .receive_msg_by_email{ @@ -1256,6 +1259,7 @@ form.new_route{ width: 392px; height: 60px; margin-top: 10px; + padding-left: 10px; } @@ -1282,7 +1286,8 @@ div.departure_arrival>div>input{ appearance: none; width: 392px; height: 60px; - padding-left: 2px; + padding-left: 10px; + padding-right: 10px; margin-top: 10px; @@ -1401,6 +1406,7 @@ div.from_to_place>div>select{ line-height: 22px; appearance: none; margin-top: 20px; + padding-left: 10px; } @@ -1616,6 +1622,103 @@ button.cancel_remove{ font-weight: 600; } + +/*Static_pages*/ +h2#title_static{ + text-align: center; + font-family: Inter; + font-size: 44px; + font-style: normal; + font-weight: 700; + line-height: 52px; + margin-bottom: 20px; +} +span#sub_title_static{ + display: block; + text-align: center; + margin-bottom: 40px; + font-family: Inter; + font-size: 16px; + font-style: normal; + font-weight: 500; + line-height: 22px; +} +button#more_button{ + display: block; + height: 60px; + width: 20%; + background: #FF613A; + color: #FFF; + font-family: Inter; + font-size: 18px; + font-style: normal; + font-weight: 600; + text-decoration: none; + line-height: 26px; + border-radius: 10px; + text-align: center; + box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.12); + margin: 0 auto; + + +} + +.top_block_static{ + position: relative; + width: 80%; + height: 194px; + margin: auto; + padding: 0px 40px; +} +.top_block_static img{ + position: absolute; + } + +.top_block_static img:nth-child(4) { + bottom: 0; /* Положение нижнего левого изображения */ + left: 129px; + bottom: -26px; + + +} + +.top_block_static img:nth-child(5) { + top: 11px; /* Положение верхнего левого изображения */ + left: 0; + + +} + +.top_block_static img:nth-child(6) { + /* Положение нижнего правого изображения */ + bottom: -33px; + right: 126px; + top: 58px; + +} + +.top_block_static img:nth-child(7) { + top: 0; /* Положение верхнего правого изображения */ + right: 0; + +} + + +.mid_block_static{ + margin-top: 120px; + +} +.benefit_img{ + display: flex; + height: 211px; + align-items: flex-start; + gap: 74px; + padding: 20px 40px 0px 40px; +} + + +/*end_static_pages*/ + /*my routes END*/ diff --git a/static/img/png/Box1.png b/static/img/png/Box1.png new file mode 100644 index 0000000..730cb0e Binary files /dev/null and b/static/img/png/Box1.png differ diff --git a/static/img/png/Box2.png b/static/img/png/Box2.png new file mode 100644 index 0000000..b2809a6 Binary files /dev/null and b/static/img/png/Box2.png differ diff --git a/static/img/png/Box3.png b/static/img/png/Box3.png new file mode 100644 index 0000000..823b065 Binary files /dev/null and b/static/img/png/Box3.png differ diff --git a/static/img/png/Box4.png b/static/img/png/Box4.png new file mode 100644 index 0000000..523c426 Binary files /dev/null and b/static/img/png/Box4.png differ diff --git a/static/img/png/pc.svg b/static/img/png/pc.svg new file mode 100644 index 0000000..9650b91 --- /dev/null +++ b/static/img/png/pc.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/static/img/svg/ad_img.svg b/static/img/svg/ad_img.svg new file mode 100644 index 0000000..9a82616 --- /dev/null +++ b/static/img/svg/ad_img.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/static/img/svg/effective_img.svg b/static/img/svg/effective_img.svg new file mode 100644 index 0000000..96e202a --- /dev/null +++ b/static/img/svg/effective_img.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/static/img/svg/offer_img.svg b/static/img/svg/offer_img.svg new file mode 100644 index 0000000..d764a98 --- /dev/null +++ b/static/img/svg/offer_img.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/static/img/svg/pc_img.svg b/static/img/svg/pc_img.svg new file mode 100644 index 0000000..9650b91 --- /dev/null +++ b/static/img/svg/pc_img.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/static/img/svg/uniq_user_img.svg b/static/img/svg/uniq_user_img.svg new file mode 100644 index 0000000..d18bbf4 --- /dev/null +++ b/static/img/svg/uniq_user_img.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/static/js/serch_town.js b/static/js/serch_town.js index dd868a3..38e5c55 100644 --- a/static/js/serch_town.js +++ b/static/js/serch_town.js @@ -1,127 +1,128 @@ -var listener = 0 -var cur_el_ins = null - -function focus_el_ins (el) { - if (el.value.length > 0) { - cur_el_ins = el - } -} - - -function searchTown(el){ - - // document.getElementById('id_from_address_point_txt').style.background = 'white url("/static/img/svg/loader.svg") no-repeat calc(100% - 15px) center'; - // document.getElementById('id_to_address_point_txt').style.background = 'white url("/static/img/svg/loader.svg") no-repeat calc(100% - 15px) center'; - - if(el.value.length >= 3){ - let timer = null - if (timer) { - clearTimeout(timer); - } - let element = el - timer = setTimeout(function(){ - - timer = null; - // let form = el.form; - let type_transport = 'road'; - let search_str = el.value; - let get_address_point = new Object({type_transport, search_str}); - get_address_point['ctrl_name'] = "govno" - get_address_point['for_filter'] = true - - $.ajax({ - headers: { "X-CSRFToken": $('input[name=csrfmiddlewaretoken]').val() }, - url: '/ru/reference_data/get_address_point/', - type: "POST", - // async: true, - cache: false, - processData: false, - contentType: false, - // enctype: 'json', - data: JSON.stringify(get_address_point), - success: function(data){ - // document.getElementById('id_from_address_point_txt').style.background = 'white url("/static/img/png/icon-arrow.svg") no-repeat calc(100% - 15px) center'; - // document.getElementById('id_to_address_point_txt').style.background = 'white url("/static/img/png/icon-arrow.svg") no-repeat calc(100% - 15px) center'; - - - getNewMessageSession() - let insert_place_1 = element.nextSibling - let insert_place_2 = insert_place_1.nextSibling - let insert_place = insert_place_2.nextSibling - if (data.res_search_list !== null || data.res_search_list !== ""){ - insert_place.innerHTML = data.res_search_list - insert_place.nextSibling.classList.add("show") - } else { - if (insert_place.classList.contains("show")){ - insert_place.classList.remove("show") - } - } - listener = 0 - // return insertSearchList(data, el.name + '_list'); - - }, - error: function (data){ - - console.log('Error') - listener = 1 - - } - }); - }, 1500); - } - -} - -function show_list_w_places (el){ - let value = el.value - if (value.length > 0){ - if (listener === 0){ - let listener_ev = document.querySelector("body") - listener_ev.setAttribute('onclick',"listen_body(event)") - } - } -} - -function listen_body (event){ - let input_1 = document.querySelector("#inp_form_find_route_w_abbreviation_1") - let input_2 = document.querySelector("#inp_form_find_route_w_abbreviation_2") - let place_1 = document.querySelectorAll(".insert-airports-place")[0] - let place_2 = document.querySelectorAll(".insert-airports-place")[1] - let list_els = [input_1,input_2,place_1,place_2] - let i = 0 - let true_ev = false - list_els.map(function (){ - if (event.target.id === list_els[i].id){ - console.log("true") - true_ev = true - if (cur_el_ins !== event.target){ - let cur_el_insert_1 = event.target.nextSibling - let cur_el_insert_2 = cur_el_insert_1.nextSibling - let cur_el_insert_3 = cur_el_insert_2.nextSibling - let cur_el_insert = cur_el_insert_3.nextSibling - if (cur_el_insert.classList.contains("show")) { - cur_el_insert.classList.remove("show") - } - } - } - i++ - }) - - if (true_ev === false) { - if (input_1.focus() === true){ - if (place_1.classList.contains("show")){ - place_1.remove("show") - listener++ - } - } else if (input_2.focus === true){ - if (place_2.classList.contains("show")){ - place_2.remove("show") - listener++ - } - } else { - console.log("error") - } - } - -} - +// var listener = 0 +// var cur_el_ins = null +// +// function focus_el_ins (el) { +// if (el.value.length > 0) { +// cur_el_ins = el +// } +// } +// +// +// function searchTown(el){ +// +// // document.getElementById('id_from_address_point_txt').style.background = 'white url("/static/img/svg/loader.svg") no-repeat calc(100% - 15px) center'; +// // document.getElementById('id_to_address_point_txt').style.background = 'white url("/static/img/svg/loader.svg") no-repeat calc(100% - 15px) center'; +// +// if(el.value.length >= 3){ +// let timer = null +// if (timer) { +// clearTimeout(timer); +// } +// let element = el +// timer = setTimeout(function(){ +// +// timer = null; +// // let form = el.form; +// let type_transport = 'road'; +// let search_str = el.value; +// let get_address_point = new Object({type_transport, search_str}); +// get_address_point['ctrl_name'] = "govno" +// get_address_point['for_filter'] = true +// +// $.ajax({ +// headers: { "X-CSRFToken": $('input[name=csrfmiddlewaretoken]').val() }, +// url: '/ru/reference_data/get_address_point/', +// type: "POST", +// // async: true, +// cache: false, +// processData: false, +// contentType: false, +// // enctype: 'json', +// data: JSON.stringify(get_address_point), +// success: function(data){ +// // document.getElementById('id_from_address_point_txt').style.background = 'white url("/static/img/png/icon-arrow.svg") no-repeat calc(100% - 15px) center'; +// // document.getElementById('id_to_address_point_txt').style.background = 'white url("/static/img/png/icon-arrow.svg") no-repeat calc(100% - 15px) center'; +// +// +// getNewMessageSession() +// let insert_place_1 = element.nextSibling +// let insert_place_2 = insert_place_1.nextSibling +// let insert_place = insert_place_2.nextSibling +// if (data.res_search_list !== null || data.res_search_list !== ""){ +// insert_place.innerHTML = data.res_search_list +// insert_place.nextSibling.classList.add("show") +// } else { +// if (insert_place.classList.contains("show")){ +// insert_place.classList.remove("show") +// } +// } +// listener = 0 +// // return insertSearchList(data, el.name + '_list'); +// +// }, +// error: function (data){ +// +// console.log('Error') +// listener = 1 +// +// } +// }); +// }, 1500); +// } +// +// } +// +// function show_list_w_places (el){ +// let value = el.value +// if (value.length > 0){ +// if (listener === 0){ +// let listener_ev = document.querySelector("body") +// listener_ev.setAttribute('onclick',"listen_body(event)") +// } +// } +// } +// +// function listen_body (event){ +// let input_1 = document.querySelector("#inp_form_find_route_w_abbreviation_1") +// let input_2 = document.querySelector("#inp_form_find_route_w_abbreviation_2") +// let place_1 = document.querySelectorAll(".insert-airports-place")[0] +// let place_2 = document.querySelectorAll(".insert-airports-place")[1] +// let list_els = [input_1,input_2,place_1,place_2] +// let i = 0 +// let true_ev = false +// list_els.map(function (){ +// if (event.target.id === list_els[i].id){ +// console.log("true") +// true_ev = true +// if (cur_el_ins !== event.target){ +// let cur_el_insert_1 = event.target.nextSibling +// let cur_el_insert_2 = cur_el_insert_1.nextSibling +// let cur_el_insert_3 = cur_el_insert_2.nextSibling +// let cur_el_insert = cur_el_insert_3.nextSibling +// if (cur_el_insert.classList.contains("show")) { +// cur_el_insert.classList.remove("show") +// } +// } +// } +// i++ +// }) +// +// if (true_ev === false) { +// if (input_1.focus() === true){ +// if (place_1.classList.contains("show")){ +// place_1.remove("show") +// listener++ +// } +// } else if (input_2.focus === true){ +// if (place_2.classList.contains("show")){ +// place_2.remove("show") +// listener++ +// } +// } else { +// console.log("error") +// } +// } +// } +// +// +// diff --git a/templates/blocks/b_footer.html b/templates/blocks/b_footer.html index a9b5c3b..42f0744 100644 --- a/templates/blocks/b_footer.html +++ b/templates/blocks/b_footer.html @@ -23,7 +23,7 @@
Перевезти посылку
Отправить посылку
Для отправителя
-
Для перевозчика
+
Для перевозчика
@@ -34,7 +34,7 @@
О Trip With Bonus
Новости
Партнерам
-
Реклама
+
Реклама
Служба поддержки
Контакты
diff --git a/templates/blocks/profile/b_new_route.html b/templates/blocks/profile/b_new_route.html index b842e6f..44b0799 100644 --- a/templates/blocks/profile/b_new_route.html +++ b/templates/blocks/profile/b_new_route.html @@ -68,6 +68,7 @@ {% if form.fields.departure_DT.required %} required{% endif %} id="id_departure_DT" class="el_form_b_new_route" + placeholder="Выберите дату и время" {% if form.initial.departure_DT %}value="{{ form.initial.departure_DT.date|date:"Y-m-d" }}T{{ form.initial.departure_DT.time|date:"H:i" }}"{% endif %} /> diff --git a/templates/blocks/static_pages_blocks/b_advertisement.html b/templates/blocks/static_pages_blocks/b_advertisement.html new file mode 100644 index 0000000..ea49c06 --- /dev/null +++ b/templates/blocks/static_pages_blocks/b_advertisement.html @@ -0,0 +1,41 @@ +{% load i18n %} +
+

{{ page.title }}

+ {{ page.description }} + + + + + +
+ +
+

{% translate "Почему это выгодно?" %}

+
+
+ +
{% translate "Полное брендирвоание страницы или раздела" %}
+
+
+ +
{% translate "Реклама для целевой аудитории" %}
+
+
+ +
{% translate "Индивидуальное согласование цены при объеме" %}
+
+
+ +
{% translate "Более чем 10 000 уникальных посещений в день" %}
+
+
+ +
{% translate "Высокая эффективность" %}
+
+
+
+ + + + + diff --git a/templates/pages/p_static_page.html b/templates/pages/p_static_page.html index 7494b42..5b1bb74 100644 --- a/templates/pages/p_static_page.html +++ b/templates/pages/p_static_page.html @@ -1,9 +1,11 @@ {% extends "tb_base.html" %} {% block content %} -

{{ page.title }}

-

{{ page.description }}

+ {% if page.url == 'customer_search' %} {% include "blocks/static_pages_blocks/b_customer_search.html" %} {% endif %} + {% if page.url == 'advertisement' %} + {% include "blocks/static_pages_blocks/b_advertisement.html" %} + {% endif %} {% endblock %} \ No newline at end of file