0.0.58 upd route_info
This commit is contained in:
@@ -1118,10 +1118,16 @@ input#id_cargo_type{
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
.errorlist.hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
/*my routes*/
|
||||
|
||||
.my_route{
|
||||
width: 100%;
|
||||
height: 296px;
|
||||
background-color: White;
|
||||
border-radius: 10px;
|
||||
margin: 2% 0 0 0;
|
||||
@@ -1129,16 +1135,85 @@ input#id_cargo_type{
|
||||
}
|
||||
|
||||
.route_info{
|
||||
vertical-align: top;
|
||||
border-style: inset;
|
||||
border-width: 1px;
|
||||
border-color: transparent #F8F8F8 transparent transparent;
|
||||
width: 59%;
|
||||
float: left;
|
||||
height: 280px;
|
||||
display: inline-block;
|
||||
|
||||
}
|
||||
.route_info_about>span:first-child{
|
||||
background: url("/static/img/png/Tag.png") left center no-repeat;
|
||||
margin: 0 20px 0 20px;
|
||||
padding-left: 15px;
|
||||
|
||||
}
|
||||
.route_info_about>span:nth-child(2){
|
||||
background: url("/static/img/png/Scales.png") left center no-repeat;
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
.route_info_about>span:last-child{
|
||||
background: url("/static/img/png/Airplane.png") left center no-repeat;
|
||||
float: right;
|
||||
margin-right: 20px;
|
||||
padding-left: 15px;
|
||||
}
|
||||
|
||||
.route_contact{
|
||||
width: 40%;
|
||||
float: right;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
/*my routes*/
|
||||
#edit_route {
|
||||
display: block;
|
||||
height: 44px;
|
||||
width: 285px;
|
||||
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;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
.button_remove_route {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
|
||||
button#remove_route {
|
||||
height: 44px;
|
||||
width: 285px;
|
||||
}
|
||||
.confirm_remove{
|
||||
width: 43% !important;
|
||||
background: #ff0000a8;
|
||||
border-radius: 10px;
|
||||
color: white;
|
||||
font-size: 18px;
|
||||
font-style: normal;
|
||||
font-weight: 600;
|
||||
|
||||
|
||||
|
||||
}
|
||||
button.cancel_remove{
|
||||
height: 44px;
|
||||
width: 43%;
|
||||
background: #808080cc;
|
||||
border-radius: 10px;
|
||||
color: white;
|
||||
font-size: 18px;
|
||||
font-style: normal;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
/*my routes END*/
|
||||
|
||||
BIN
static/img/png/Airplane.png
Normal file
BIN
static/img/png/Airplane.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 372 B |
BIN
static/img/png/Car.png
Normal file
BIN
static/img/png/Car.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 330 B |
BIN
static/img/png/Scales.png
Normal file
BIN
static/img/png/Scales.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 508 B |
BIN
static/img/png/Tag.png
Normal file
BIN
static/img/png/Tag.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 346 B |
@@ -84,3 +84,12 @@ function onblurInputField(event,el){
|
||||
|
||||
// }
|
||||
}
|
||||
|
||||
|
||||
// function hideErrorMsg(el) {
|
||||
// let hide_element = document.querySelector()
|
||||
// if(el.value !== 0){
|
||||
// hide_element.classList.add('hide')
|
||||
// }
|
||||
//
|
||||
// }
|
||||
@@ -69,4 +69,5 @@ function getRoute(){
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -62,35 +62,24 @@ function OnSelectionChange(el) {
|
||||
// location.href = '/profile'
|
||||
document.querySelector(".info_profile").innerHTML = data.html
|
||||
//
|
||||
// $(document).ready(function (e){
|
||||
// $('#id_weight').ionRangeSlider({
|
||||
// skin: "round",
|
||||
// type: "single",
|
||||
// min: 0,
|
||||
// max: 1000,
|
||||
// from: 100,
|
||||
// step: 1,
|
||||
// grid: true,
|
||||
// grid_num: 5,
|
||||
// }
|
||||
|
||||
//get dynamic value
|
||||
// let fromCountry = document.getElementById('id_from_country');
|
||||
// let toCounytry = document.getElementById('id_to_country')
|
||||
//
|
||||
// toCounytry.oninput = function (){
|
||||
// console.log(toCounytry.value)
|
||||
// }
|
||||
// fromCountry.oninput = function (){
|
||||
// console.log(fromCountry.value)
|
||||
//
|
||||
// };
|
||||
$('#id_weight').ionRangeSlider({
|
||||
skin: "round",
|
||||
type: "single",
|
||||
min: 0,
|
||||
max: 1000,
|
||||
from: 0,
|
||||
step: 1,
|
||||
grid: true,
|
||||
grid_num: 5,
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -92,4 +92,20 @@ function myProfile(){
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function confirmRemove(el) {
|
||||
let place = document.querySelector('.button_remove_route')
|
||||
// let new_button = document.querySelector('.cancel_remove')
|
||||
// if(!button){
|
||||
let cancel_button = document.createElement('button')
|
||||
cancel_button.className = "cancel_remove";
|
||||
cancel_button.innerText = "Отменить удаление";
|
||||
place.appendChild(cancel_button);
|
||||
// }
|
||||
|
||||
|
||||
el.classList.add('confirm_remove')
|
||||
el.innerText = 'Подтвердить удаление'
|
||||
|
||||
}
|
||||
@@ -123,6 +123,7 @@
|
||||
<label for="id_from_place">{{ form.fields.from_place.label }}</label>
|
||||
<select
|
||||
name="from_place"
|
||||
{# onchange="hideErrorMsg(this)"#}
|
||||
id="id_from_place"
|
||||
{% if form.fields.from_place.required %} required{% endif %}>
|
||||
{% for item in form.fields.from_place.choices %}
|
||||
|
||||
@@ -1,47 +1,69 @@
|
||||
{% for route in routes %}
|
||||
<div class="my_route">
|
||||
<div class="route_info">
|
||||
{{ route.get_cargo_type_display }}
|
||||
{{ route.weight }}
|
||||
{{ route.get_type_transport_display }}
|
||||
<div class="route_info_point">
|
||||
{{ route.from_country.name }}/{{ route.from_city.name }}
|
||||
<br>
|
||||
{{ route.to_country.name }}/{{ route.to_city.name }}
|
||||
</div>
|
||||
<div class="route_info_date">
|
||||
Отправка: {{route.departure_DT }}
|
||||
Прибытие: {{route.arrival_DT }}
|
||||
</div>
|
||||
<div class="route_info_ft_place">
|
||||
Откуда заберёт:{{ route.from_place }}
|
||||
Куда доставит:{{ route.to_place }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="route_info_about">
|
||||
<span>
|
||||
Тип:{{ route.get_cargo_type_display }}
|
||||
</span>
|
||||
|
||||
<div class="route_contact">
|
||||
<h2>Контакты перевозчика:</h2>
|
||||
<span>
|
||||
Вес:{{ route.weight }} кг
|
||||
</span>
|
||||
|
||||
<div class="route_contact_name">
|
||||
{{ route.owner.last_name }} {{ route.owner.first_name }}
|
||||
</div>
|
||||
<span>
|
||||
|
||||
{{ route.get_type_transport_display }}
|
||||
</span>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="route_info_point">
|
||||
{{ route.from_country.name }}/{{ route.from_city.name }}
|
||||
<br>
|
||||
{{ route.to_country.name }}/{{ route.to_city.name }}
|
||||
</div>
|
||||
|
||||
<div class="route_info_date">
|
||||
Отправка: {{route.departure_DT }}
|
||||
Прибытие: {{route.arrival_DT }}
|
||||
</div>
|
||||
|
||||
<div class="route_info_ft_place">
|
||||
Откуда заберёт:{{ route.from_place }}
|
||||
Куда доставит:{{ route.to_place }}
|
||||
</div>
|
||||
|
||||
<div class="route_contact_phone_email">
|
||||
{{ route.phone }}
|
||||
<br>
|
||||
{{ route.extra_phone }}
|
||||
<br>
|
||||
{{ route.owner.email }}
|
||||
</div>
|
||||
|
||||
|
||||
<div class="route_contact">
|
||||
|
||||
<h2>Контакты перевозчика:</h2>
|
||||
|
||||
<div class="route_contact_name">
|
||||
{{ route.owner.last_name }} {{ route.owner.first_name }}
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="route_contact_phone_email">
|
||||
{{ route.phone }}
|
||||
<br>
|
||||
{{ route.extra_phone }}
|
||||
<br>
|
||||
{{ route.owner.email }}
|
||||
</div>
|
||||
<div class="button_edit_route">
|
||||
<button
|
||||
id="edit_route">
|
||||
Редактировать
|
||||
</button>
|
||||
</div>
|
||||
<div class="button_remove_route">
|
||||
<button
|
||||
onclick="confirmRemove(this)"
|
||||
id="remove_route">
|
||||
Удалить
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user