mirror of
https://github.com/xdan/datetimepicker.git
synced 2024-11-18 06:24:22 +00:00
New version 2.5.4
This commit is contained in:
parent
ac1b591a96
commit
d35c53dd59
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "datetimepicker",
|
||||
"version": "2.5.3",
|
||||
"version": "2.5.4",
|
||||
"main": [
|
||||
"build/jquery.datetimepicker.full.min.js",
|
||||
"jquery.datetimepicker.css"
|
||||
|
@ -575,7 +575,7 @@ var DateFormatter;
|
||||
}
|
||||
};
|
||||
})();/**
|
||||
* @preserve jQuery DateTimePicker plugin v2.5.3
|
||||
* @preserve jQuery DateTimePicker plugin v2.5.4
|
||||
* @homepage http://xdsoft.net/jqplugins/datetimepicker/
|
||||
* @author Chupurnov Valeriy (<chupurnov@gmail.com>)
|
||||
*/
|
||||
@ -1501,7 +1501,8 @@ var DateFormatter;
|
||||
setPos,
|
||||
timer = 0,
|
||||
_xdsoft_datetime,
|
||||
forEachAncestorOf;
|
||||
forEachAncestorOf,
|
||||
throttle;
|
||||
|
||||
if (options.id) {
|
||||
datetimepicker.attr('id', options.id);
|
||||
@ -1854,8 +1855,20 @@ var DateFormatter;
|
||||
return !isNaN(d.getTime());
|
||||
};
|
||||
|
||||
_this.setCurrentTime = function (dTime) {
|
||||
_this.currentTime = (typeof dTime === 'string') ? _this.strToDateTime(dTime) : _this.isValidDate(dTime) ? dTime : _this.now();
|
||||
_this.setCurrentTime = function (dTime, requireValidDate) {
|
||||
if (typeof dTime === 'string') {
|
||||
_this.currentTime = _this.strToDateTime(dTime);
|
||||
}
|
||||
else if (_this.isValidDate(dTime)) {
|
||||
_this.currentTime = dTime;
|
||||
}
|
||||
else if (!dTime && !requireValidDate && options.allowBlank) {
|
||||
_this.currentTime = null;
|
||||
}
|
||||
else {
|
||||
_this.currentTime = _this.now();
|
||||
}
|
||||
|
||||
datetimepicker.trigger('xchange.xdsoft');
|
||||
};
|
||||
|
||||
@ -2008,7 +2021,7 @@ var DateFormatter;
|
||||
.find('.xdsoft_today_button')
|
||||
.on('touchend mousedown.xdsoft', function () {
|
||||
datetimepicker.data('changed', true);
|
||||
_xdsoft_datetime.setCurrentTime(0);
|
||||
_xdsoft_datetime.setCurrentTime(0, true);
|
||||
datetimepicker.trigger('afterOpen.xdsoft');
|
||||
}).on('dblclick.xdsoft', function () {
|
||||
var currentDate = _xdsoft_datetime.getCurrentTime(), minDate, maxDate;
|
||||
@ -2105,6 +2118,10 @@ var DateFormatter;
|
||||
xchangeTimer = setTimeout(function () {
|
||||
|
||||
if (_xdsoft_datetime.currentTime === undefined || _xdsoft_datetime.currentTime === null) {
|
||||
//In case blanks are allowed, delay construction until we have a valid date
|
||||
if (options.allowBlank)
|
||||
return;
|
||||
|
||||
_xdsoft_datetime.currentTime = _xdsoft_datetime.now();
|
||||
}
|
||||
|
||||
@ -2830,7 +2847,7 @@ var DateFormatter;
|
||||
}
|
||||
|
||||
triggerAfterOpen = true;
|
||||
_xdsoft_datetime.setCurrentTime(getCurrentValue());
|
||||
_xdsoft_datetime.setCurrentTime(getCurrentValue(), true);
|
||||
if(options.mask) {
|
||||
setMask(options);
|
||||
}
|
||||
|
4
build/jquery.datetimepicker.full.min.js
vendored
4
build/jquery.datetimepicker.full.min.js
vendored
File diff suppressed because one or more lines are too long
4
build/jquery.datetimepicker.min.js
vendored
4
build/jquery.datetimepicker.min.js
vendored
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "datetimepicker",
|
||||
"version": "2.5.3",
|
||||
"version": "2.5.4",
|
||||
"title": "jQuery Date and Time picker",
|
||||
"description": "jQuery plugin for date, time, or datetime manipulation in form",
|
||||
"keywords": [
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @preserve jQuery DateTimePicker plugin v2.5.3
|
||||
* @preserve jQuery DateTimePicker plugin v2.5.4
|
||||
* @homepage http://xdsoft.net/jqplugins/datetimepicker/
|
||||
* @author Chupurnov Valeriy (<chupurnov@gmail.com>)
|
||||
*/
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "jquery-datetimepicker",
|
||||
"version": "2.5.3",
|
||||
"version": "2.5.4",
|
||||
"description": "jQuery Plugin DateTimePicker it is DatePicker and TimePicker in one",
|
||||
"main": "build/jquery.datetimepicker.full.min.js",
|
||||
"scripts": {
|
||||
@ -8,7 +8,7 @@
|
||||
"concat": "concat-cli -f bower_components/php-date-formatter/js/php-date-formatter.js jquery.datetimepicker.js bower_components/jquery-mousewheel/jquery.mousewheel.js -o build/jquery.datetimepicker.full.js",
|
||||
"minify": "uglifyjs jquery.datetimepicker.js -c -m -o build/jquery.datetimepicker.min.js && uglifycss jquery.datetimepicker.css > build/jquery.datetimepicker.min.css",
|
||||
"minifyconcat": "uglifyjs build/jquery.datetimepicker.full.js -c -m -o build/jquery.datetimepicker.full.min.js",
|
||||
"github": "git add --all && git commit -m \"New version %npm_package_version% Fix devDependencies with concat-cli\" && git tag %npm_package_version% && git push --tags origin HEAD:master && npm publish",
|
||||
"github": "git add --all && git commit -m \"New version %npm_package_version% \" && git tag %npm_package_version% && git push --tags origin HEAD:master && npm publish",
|
||||
"build": "npm run minify && npm run concat && npm run minifyconcat"
|
||||
},
|
||||
"repository": {
|
||||
|
Loading…
Reference in New Issue
Block a user