0.0.265
This commit is contained in:
@@ -410,7 +410,9 @@
|
|||||||
}, remove: function () {
|
}, remove: function () {
|
||||||
this.container.remove(), this.element.off(".daterangepicker"), this.element.removeData()
|
this.container.remove(), this.element.off(".daterangepicker"), this.element.removeData()
|
||||||
}
|
}
|
||||||
}, e.fn.daterangepicker = function (t, i) {
|
},
|
||||||
|
|
||||||
|
e.fn.daterangepicker = function (t, i) {
|
||||||
var s = e.extend(!0, {}, e.fn.daterangepicker.defaultOptions, t);
|
var s = e.extend(!0, {}, e.fn.daterangepicker.defaultOptions, t);
|
||||||
return this.each(function () {
|
return this.each(function () {
|
||||||
var t = e(this);
|
var t = e(this);
|
||||||
|
|||||||
4
static/js/jquery_3_2_1.js
vendored
Normal file
4
static/js/jquery_3_2_1.js
vendored
Normal file
File diff suppressed because one or more lines are too long
7
static/js/moment_js.js
Normal file
7
static/js/moment_js.js
Normal file
File diff suppressed because one or more lines are too long
@@ -43,23 +43,23 @@
|
|||||||
// });
|
// });
|
||||||
// }
|
// }
|
||||||
// });
|
// });
|
||||||
|
function init_arrival_DT (){
|
||||||
|
|
||||||
$(function () {
|
|
||||||
let onl_param = ""
|
let onl_param = ""
|
||||||
if (window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_mover/" || window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_customer/"){
|
if (window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_mover/" || window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_customer/"){
|
||||||
onl_param = "singleDatePicker: true"
|
onl_param = "singleDatePicker"
|
||||||
}
|
}
|
||||||
let place_1 = document.querySelector("#id_arrival_DT")
|
let place_1 = document.querySelector("#id_arrival_DT")
|
||||||
if (place_1) {
|
if (place_1) {
|
||||||
$(place_1).daterangepicker({
|
$(place_1).daterangepicker({
|
||||||
"autoapply": true,
|
"autoapply": true,
|
||||||
"linkedCalendars": false,
|
"linkedCalendars": false,
|
||||||
|
"singleDatePicker":true
|
||||||
},
|
},
|
||||||
function (start, end, label) {
|
function (start, end, label) {
|
||||||
|
|
||||||
// $('#displayRegervation').text('Registration date is: ' + start.format('YYYY-MM-DD') + ' to ' + end.format('YYYY-MM-DD'));
|
// $('#displayRegervation').text('Registration date is: ' + start.format('YYYY-MM-DD') + ' to ' + end.format('YYYY-MM-DD'));
|
||||||
$('#id_arrival_DT').val(start.format('DD.MM.YYYY') + " - " + end.format('DD.MM.YYYY'))
|
$('#id_arrival_DT').val(start.format('DD.MM.YYYY'))
|
||||||
});
|
});
|
||||||
|
|
||||||
$(`${place_1.id} .drp-calendar.right`).hide();
|
$(`${place_1.id} .drp-calendar.right`).hide();
|
||||||
@@ -74,7 +74,76 @@ $(function () {
|
|||||||
el.append('<span></span>');
|
el.append('<span></span>');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
|
||||||
|
}
|
||||||
|
|
||||||
|
function init_departure_DT (){
|
||||||
|
|
||||||
|
let place_1 = document.querySelector("#id_departure_DT")
|
||||||
|
let onl_param = ""
|
||||||
|
if (window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_mover/" || window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_customer/"){
|
||||||
|
onl_param = "singleDatePicker"
|
||||||
|
}
|
||||||
|
if (place_1) {
|
||||||
|
$(place_1).daterangepicker({
|
||||||
|
"autoapply": true,
|
||||||
|
"linkedCalendars": false,
|
||||||
|
"singleDatePicker":true
|
||||||
|
},
|
||||||
|
function(start, end, label) {
|
||||||
|
// $('#displayRegervation').text('Registration date is: ' + start.format('YYYY-MM-DD') + ' to ' + end.format('YYYY-MM-DD'));
|
||||||
|
// $('#regervation')[0].dataset['departure_DT'] = start.format('YYYY-MM-DD');
|
||||||
|
// $('#regervation')[0].dataset['arrival_DT'] = end.format('YYYY-MM-DD');
|
||||||
|
$('#id_departure_DT').val(start.format('DD.MM.YYYY'))
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
$(`${place_1.id} .drp-calendar.right`).hide();
|
||||||
|
$(`${place_1.id} .drp-calendar.left`).addClass('single');
|
||||||
|
|
||||||
|
$(`${place_1.id} .calendar-table`).on('DOMSubtreeModified', function() {
|
||||||
|
var el = $(`${place_1.id} .prev.available`).parent().children().last();
|
||||||
|
if (el.hasClass('next available')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
el.addClass('next available');
|
||||||
|
el.append('<span></span>');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
$(function () {
|
||||||
|
let onl_param = ""
|
||||||
|
if (window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_mover/" || window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_customer/"){
|
||||||
|
onl_param = "singleDatePicker: true"
|
||||||
|
}
|
||||||
|
let place_1 = document.querySelector("#id_arrival_DT")
|
||||||
|
if (place_1) {
|
||||||
|
$(place_1).daterangepicker({
|
||||||
|
"autoapply": true,
|
||||||
|
"linkedCalendars": false,
|
||||||
|
|
||||||
|
},
|
||||||
|
function (start, end, label) {
|
||||||
|
|
||||||
|
// $('#displayRegervation').text('Registration date is: ' + start.format('YYYY-MM-DD') + ' to ' + end.format('YYYY-MM-DD'));
|
||||||
|
$('#id_arrival_DT').val(start.format('DD.MM.YYYY') + " - " + end.format('DD.MM.YYYY'))
|
||||||
|
});
|
||||||
|
|
||||||
|
$(`${place_1.id} .drp-calendar.right`).hide();
|
||||||
|
$(`${place_1.id} .drp-calendar.left`).addClass('single');
|
||||||
|
|
||||||
|
$(`${place_1.id} .calendar-table`).on('DOMSubtreeModified', function () {
|
||||||
|
var el = $(`${place_1.id} .prev.available`).parent().children().last();
|
||||||
|
if (el.hasClass('next available')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
el.addClass('next available');
|
||||||
|
el.append('<span></span>');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
let place_1 = document.querySelector("#id_departure_DT")
|
let place_1 = document.querySelector("#id_departure_DT")
|
||||||
|
|||||||
@@ -571,76 +571,17 @@ function OnSelectionChange(el) {
|
|||||||
// if(checkbox_width.childElementCount === 4){
|
// if(checkbox_width.childElementCount === 4){
|
||||||
// checkbox_width.classList.add('width')
|
// checkbox_width.classList.add('width')
|
||||||
// }
|
// }
|
||||||
sliderInit();
|
sliderInit();
|
||||||
$(function () {
|
|
||||||
let onl_param = ""
|
|
||||||
if (window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_mover/" || window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_customer/"){
|
|
||||||
onl_param = "singleDatePicker: true"
|
|
||||||
}
|
|
||||||
let place_1 = document.querySelector("#id_arrival_DT")
|
|
||||||
if (place_1) {
|
|
||||||
$(place_1).daterangepicker({
|
|
||||||
"autoapply": true,
|
|
||||||
"linkedCalendars": false,
|
|
||||||
|
|
||||||
},
|
init_arrival_DT()
|
||||||
function (start, end, label) {
|
init_departure_DT()
|
||||||
|
|
||||||
// $('#displayRegervation').text('Registration date is: ' + start.format('YYYY-MM-DD') + ' to ' + end.format('YYYY-MM-DD'));
|
|
||||||
$('#id_arrival_DT').val(start.format('DD.MM.YYYY') + " - " + end.format('DD.MM.YYYY'))
|
|
||||||
});
|
|
||||||
|
|
||||||
$(`${place_1.id} .drp-calendar.right`).hide();
|
|
||||||
$(`${place_1.id} .drp-calendar.left`).addClass('single');
|
|
||||||
|
|
||||||
$(`${place_1.id} .calendar-table`).on('DOMSubtreeModified', function () {
|
|
||||||
var el = $(`${place_1.id} .prev.available`).parent().children().last();
|
|
||||||
if (el.hasClass('next available')) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
el.addClass('next available');
|
|
||||||
el.append('<span></span>');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
$(function() {
|
|
||||||
let place_1 = document.querySelector("#id_departure_DT")
|
|
||||||
let onl_param = ""
|
|
||||||
if (window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_mover/" || window.location.href === "http://localhost:8016/ru/profile/page/create_route_for_customer/"){
|
|
||||||
onl_param = "singleDatePicker: true"
|
|
||||||
}
|
|
||||||
if (place_1) {
|
|
||||||
$(place_1).daterangepicker({
|
|
||||||
"autoapply": true,
|
|
||||||
"linkedCalendars": false,
|
|
||||||
onl_param
|
|
||||||
},
|
|
||||||
function(start, end, label) {
|
|
||||||
// $('#displayRegervation').text('Registration date is: ' + start.format('YYYY-MM-DD') + ' to ' + end.format('YYYY-MM-DD'));
|
|
||||||
// $('#regervation')[0].dataset['departure_DT'] = start.format('YYYY-MM-DD');
|
|
||||||
// $('#regervation')[0].dataset['arrival_DT'] = end.format('YYYY-MM-DD');
|
|
||||||
$('#id_departure_DT').val(start.format('DD.MM.YYYY') + " - " + end.format('DD.MM.YYYY'))
|
|
||||||
|
|
||||||
});
|
|
||||||
|
|
||||||
$(`${place_1.id} .drp-calendar.right`).hide();
|
|
||||||
$(`${place_1.id} .drp-calendar.left`).addClass('single');
|
|
||||||
|
|
||||||
$(`${place_1.id} .calendar-table`).on('DOMSubtreeModified', function() {
|
|
||||||
var el = $(`${place_1.id} .prev.available`).parent().children().last();
|
|
||||||
if (el.hasClass('next available')) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
el.addClass('next available');
|
|
||||||
el.append('<span></span>');
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
};
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -60,17 +60,17 @@
|
|||||||
<label for="id_departure_DT">{{ form.fields.departure_DT.label }}</label>
|
<label for="id_departure_DT">{{ form.fields.departure_DT.label }}</label>
|
||||||
|
|
||||||
|
|
||||||
<input
|
{# <input#}
|
||||||
type="datetime-local"
|
{# type="datetime-local"#}
|
||||||
min= {% now "Y-m-d" %}T{% now "H:i" %}
|
{# min= {% now "Y-m-d" %}T{% now "H:i" %}#}
|
||||||
name="departure_DT"
|
{# name="departure_DT"#}
|
||||||
onchange="checkDate()"
|
{# onchange="checkDate()"#}
|
||||||
{% if form.fields.departure_DT.required %} required{% endif %}
|
{# {% if form.fields.departure_DT.required %} required{% endif %}#}
|
||||||
id="id_departure_DT"
|
{# id="id_departure_DT"#}
|
||||||
class="el_form_b_new_route"
|
{# class="el_form_b_new_route"#}
|
||||||
placeholder="Выберите дату и время"
|
{# 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 %}
|
{# {% 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 %}#}
|
||||||
/>
|
{# />#}
|
||||||
{# boris change input #}
|
{# boris change input #}
|
||||||
<input class="el_form_find_route" type="text" id="id_departure_DT" name="departure_DT" placeholder="" {% if route_form.initial.departure_DT %} value="{{ route_form.initial.departure_DT }}"{% endif %}/>
|
<input class="el_form_find_route" type="text" id="id_departure_DT" name="departure_DT" placeholder="" {% if route_form.initial.departure_DT %} value="{{ route_form.initial.departure_DT }}"{% endif %}/>
|
||||||
<div id="displayRegervation"></div>
|
<div id="displayRegervation"></div>
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
{% include "connect_ws_js.html" %}
|
{% include "connect_ws_js.html" %}
|
||||||
<script src="{% static "js/filters_functions_find_route.js" %}"></script>
|
<script src="{% static "js/filters_functions_find_route.js" %}"></script>
|
||||||
<script src="{% static "js/dynamic_loading_routes.js" %}"></script>
|
<script src="{% static "js/dynamic_loading_routes.js" %}"></script>
|
||||||
|
{# <script src="{% static "js/range_calendar.js" %}"></script>#}
|
||||||
|
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
|
|
||||||
{% block meta %}
|
{% block meta %}
|
||||||
<script src='{% static "js/jquery_v3_6_4.js" %}'> </script>
|
{# <script src='{% static "js/jquery_v3_6_4.js" %}'> </script>#}
|
||||||
<script src='{% static "js/ion.rangeSlider.min.js" %}'> </script>
|
<script src='{% static "js/ion.rangeSlider.min.js" %}'> </script>
|
||||||
<link href="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.css" rel="stylesheet">
|
<link href="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.css" rel="stylesheet">
|
||||||
<script src='{% static "js/user_profile.js" %}'> </script>
|
<script src='{% static "js/user_profile.js" %}'> </script>
|
||||||
|
|||||||
@@ -8,12 +8,12 @@
|
|||||||
<title>Title</title>
|
<title>Title</title>
|
||||||
|
|
||||||
|
|
||||||
<script src='{% static "js/jquery_v3_6_4.js" %}'> </script>
|
{# <script src='{% static "js/jquery_v3_6_4.js" %}'> </script>#}
|
||||||
<script type="text/javascript" src="https://cdn.jsdelivr.net/jquery/latest/jquery.min.js"></script>
|
<script type="text/javascript" src="{% static "js/jquery_3_2_1.js" %}"></script>
|
||||||
<script type="text/javascript" src="https://cdn.jsdelivr.net/momentjs/latest/moment.min.js"></script>
|
<script type="text/javascript" src="{% static "js/moment_js.js" %}"></script>
|
||||||
<script type="text/javascript" src="{% static "js/datarangepicker.js" %}"></script>
|
<script type="text/javascript" src="{% static "js/datarangepicker.js" %}"></script>
|
||||||
<script src="{% static "js/rangecalendartech.js" %}"></script>
|
<script src="{% static "js/rangecalendartech.js" %}"></script>
|
||||||
<script src="{% static "js/range_calendar.js" %}"></script>
|
|
||||||
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.css" />
|
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.css" />
|
||||||
|
|
||||||
|
|
||||||
@@ -45,7 +45,8 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
{# <script src="{% static "js/range_calendar.js" %}"></script>#}
|
||||||
|
<script src="{% static "js/range_calendar.js" %}"></script>
|
||||||
|
|
||||||
{% block meta %}
|
{% block meta %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
Reference in New Issue
Block a user