Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 11 additions & 6 deletions jquery.daterangepicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -1080,9 +1080,6 @@
{
opt.start = time;
opt.end = false;
if (opt.time.enabled) {
changeTime("start", opt.start);
}
}
else if (opt.batchMode === 'week')
{
Expand Down Expand Up @@ -1113,9 +1110,6 @@
{
opt.start = handleStart(time);
opt.end = false;
if (opt.time.enabled) {
changeTime("start", opt.start);
}
}
else if (opt.start)
{
Expand All @@ -1125,6 +1119,17 @@
}
}

//Update time in case it is enabled and timestamps are available
if(opt.time.enabled) {
if(opt.start) {
changeTime("start", opt.start);
}
if(opt.end) {
changeTime("end", opt.end);
}
}

//In case the start is after the end, swap the timestamps
if (!opt.singleDate && opt.start && opt.end && opt.start > opt.end)
{
var tmp = opt.end;
Expand Down