View File Name : 1940.js
'),i=e('
'),o.append(i),s.addClass("xdsoft_scroller_box").append(o),p=function(e){var t=d(e).y-f+g;t<0&&(t=0),t+i[0].offsetHeight>h&&(t=h-i[0].offsetHeight),s.trigger("scroll_element.xdsoft_scroller",[u?t/u:0])},i.on("touchstart.xdsoft_scroller mousedown.xdsoft_scroller",(function(a){n||s.trigger("resize_scroll.xdsoft_scroller",[t]),f=d(a).y,g=parseInt(i.css("margin-top"),10),h=o[0].offsetHeight,"mousedown"===a.type||"touchstart"===a.type?(document&&e(document.body).addClass("xdsoft_noselect"),e([document.body,window]).on("touchend mouseup.xdsoft_scroller",(function t(){e([document.body,window]).off("touchend mouseup.xdsoft_scroller",t).off("mousemove.xdsoft_scroller",p).removeClass("xdsoft_noselect")})),e(document.body).on("mousemove.xdsoft_scroller",p)):(m=!0,a.stopPropagation(),a.preventDefault())})).on("touchmove",(function(e){m&&(e.preventDefault(),p(e))})).on("touchend touchcancel",(function(){m=!1,g=0})),s.on("scroll_element.xdsoft_scroller",(function(e,t){n||s.trigger("resize_scroll.xdsoft_scroller",[t,!0]),t=t>1?1:t<0||isNaN(t)?0:t,i.css("margin-top",u*t),setTimeout((function(){a.css("marginTop",-parseInt((a[0].offsetHeight-n)*t,10))}),10)})).on("resize_scroll.xdsoft_scroller",(function(e,t,d){var l,f;n=s[0].clientHeight,r=a[0].offsetHeight,f=(l=n/r)*o[0].offsetHeight,l>1?i.hide():(i.show(),i.css("height",parseInt(f>10?f:10,10)),u=o[0].offsetHeight-i[0].offsetHeight,!0!==d&&s.trigger("scroll_element.xdsoft_scroller",[t||Math.abs(parseInt(a.css("marginTop"),10))/(r-n)]))})),s.on("mousewheel",(function(e){var t=Math.abs(parseInt(a.css("marginTop"),10));return(t-=20*e.deltaY)<0&&(t=0),s.trigger("scroll_element.xdsoft_scroller",[t/(r-n)]),e.stopPropagation(),!1})),s.on("touchstart",(function(e){l=d(e),c=Math.abs(parseInt(a.css("marginTop"),10))})),s.on("touchmove",(function(e){if(l){e.preventDefault();var t=d(e);s.trigger("scroll_element.xdsoft_scroller",[(c-(t.y-l.y))/(r-n)])}})),s.on("touchend touchcancel",(function(){l=!1,c=0}))),s.trigger("resize_scroll.xdsoft_scroller",[t])):s.find(".xdsoft_scrollbar").hide()}))},e.fn.datetimepicker=function(r,i){var s,d,l=this,f=48,c=57,h=96,m=105,g=17,p=46,y=13,v=27,b=8,k=37,D=38,x=39,S=40,T=9,w=116,M=65,O=67,_=86,W=90,C=89,F=!1,P=e.isPlainObject(r)||!r?e.extend(!0,{},a,r):e.extend(!0,{},a),A=0,Y=function(e){e.on("open.xdsoft focusin.xdsoft mousedown.xdsoft touchstart",(function t(){e.is(":disabled")||e.data("xdsoft_datetimepicker")||(clearTimeout(A),A=setTimeout((function(){e.data("xdsoft_datetimepicker")||s(e),e.off("open.xdsoft focusin.xdsoft mousedown.xdsoft touchstart",t).trigger("open.xdsoft")}),100))}))};return s=function(a){var i,s,d,l,A,Y,H,j=e('
'),z=e('
'),J=e('
'),I=e('
'),N=e('
'),L=e('
'),E=L.find(".xdsoft_time_box").eq(0),R=e('
'),B=e('
'),V=e('
'),G=e('
'),U=!1,X=0;function q(){var e,t=!1;return P.startDate?t=A.strToDate(P.startDate):(t=P.value||(a&&a.val&&a.val()?a.val():""))?t=A.strToDateTime(t):P.defaultDate&&(t=A.strToDateTime(P.defaultDate),P.defaultTime&&(e=A.strtotime(P.defaultTime),t.setHours(e.getHours()),t.setMinutes(e.getMinutes()))),t&&A.isValidDate(t)?j.data("changed",!0):t="",t||0}function K(t){var n=function(e,t){var a=e.replace(/([\[\]\/\{\}\(\)\-\.\+]{1})/g,"\\$1").replace(/_/g,"{digit+}").replace(/([0-9]{1})/g,"{digit$1}").replace(/\{digit([0-9]{1})\}/g,"[0-$1_]{1}").replace(/\{digit[\+]\}/g,"[0-9_]{1}");return new RegExp(a).test(t)},r=function(e){try{if(document.selection&&document.selection.createRange)return document.selection.createRange().getBookmark().charCodeAt(2)-2;if(e.setSelectionRange)return e.selectionStart}catch(e){return 0}},o=function(e,t){if(!(e="string"==typeof e||e instanceof String?document.getElementById(e):e))return!1;if(e.createTextRange){var a=e.createTextRange();return a.collapse(!0),a.moveEnd("character",t),a.moveStart("character",t),a.select(),!0}return!!e.setSelectionRange&&(e.setSelectionRange(t,t),!0)};t.mask&&a.off("keydown.xdsoft"),!0===t.mask&&("undefined"!=typeof moment?t.mask=t.format.replace(/Y{4}/g,"9999").replace(/Y{2}/g,"99").replace(/M{2}/g,"19").replace(/D{2}/g,"39").replace(/H{2}/g,"29").replace(/m{2}/g,"59").replace(/s{2}/g,"59"):t.mask=t.format.replace(/Y/g,"9999").replace(/F/g,"9999").replace(/m/g,"19").replace(/d/g,"39").replace(/H/g,"29").replace(/i/g,"59").replace(/s/g,"59")),"string"===e.type(t.mask)&&(n(t.mask,a.val())||(a.val(t.mask.replace(/[0-9]/g,"_")),o(a[0],0)),a.on("keydown.xdsoft",(function(i){var s,d,u=this.value,l=i.which;if(l>=f&&l<=c||l>=h&&l<=m||l===b||l===p){for(s=r(this),d=l!==b&&l!==p?String.fromCharCode(h<=l&&l<=m?l-f:l):"_",l!==b&&l!==p||!s||(s-=1,d="_");/[^0-9_]/.test(t.mask.substr(s,1))&&s
0;)s+=l===b||l===p?-1:1;if(u=u.substr(0,s)+d+u.substr(s+1),""===e.trim(u))u=t.mask.replace(/[0-9]/g,"_");else if(s===t.mask.length)return i.preventDefault(),!1;for(s+=l===b||l===p?0:1;/[^0-9_]/.test(t.mask.substr(s,1))&&s0;)s+=l===b||l===p?-1:1;n(t.mask,u)?(this.value=u,o(this,s)):""===e.trim(u)?this.value=t.mask.replace(/[0-9]/g,"_"):a.trigger("error_input.xdsoft")}else if(-1!==[M,O,_,W,C].indexOf(l)&&F||-1!==[v,D,S,k,x,w,g,T,y].indexOf(l))return!0;return i.preventDefault(),!1})))}P.id&&j.attr("id",P.id),P.style&&j.attr("style",P.style),P.weeks&&j.addClass("xdsoft_showweeks"),P.rtl&&j.addClass("xdsoft_rtl"),j.addClass("xdsoft_"+P.theme),j.addClass(P.className),I.find(".xdsoft_month span").after(V),I.find(".xdsoft_year span").after(G),I.find(".xdsoft_month,.xdsoft_year").on("touchstart mousedown.xdsoft",(function(t){var a,n,r=e(this).find(".xdsoft_select").eq(0),o=0,i=0,s=r.is(":visible");for(I.find(".xdsoft_select").hide(),A.currentTime&&(o=A.currentTime[e(this).hasClass("xdsoft_month")?"getMonth":"getFullYear"]()),r[s?"hide":"show"](),a=r.find("div.xdsoft_option"),n=0;n=0&&a<24&&r>=0&&r<60?e(this).val([a,r].map((function(e){return e>9?e:"0"+e})).join(":")):e(this).val(n.formatDate(A.now(),P.format))}j.data("xdsoft_datetime").setCurrentTime(e(this).val())}j.trigger("changedatetime.xdsoft"),j.trigger("close.xdsoft")})),P.dayOfWeekStartPrev=0===P.dayOfWeekStart?6:P.dayOfWeekStart-1,j.trigger("xchange.xdsoft").trigger("afterOpen.xdsoft")},j.data("options",P).on("touchstart mousedown.xdsoft",(function(e){return e.stopPropagation(),e.preventDefault(),G.hide(),V.hide(),!1})),E.append(R),E.xdsoftScroller(),j.on("afterOpen.xdsoft",(function(){E.xdsoftScroller()})),j.append(J).append(L),!0!==P.withoutCopyright&&j.append(z),J.append(I).append(N).append(B),e(P.parentID).append(j),A=new function(){var t=this;t.now=function(e){var a,n,r=new Date;return!e&&P.defaultDate&&(a=t.strToDateTime(P.defaultDate),r.setFullYear(a.getFullYear()),r.setMonth(a.getMonth()),r.setDate(a.getDate())),P.yearOffset&&r.setFullYear(r.getFullYear()+P.yearOffset),!e&&P.defaultTime&&(n=t.strtotime(P.defaultTime),r.setHours(n.getHours()),r.setMinutes(n.getMinutes())),r},t.isValidDate=function(e){return"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e.getTime())},t.setCurrentTime=function(e,a){"string"==typeof e?t.currentTime=t.strToDateTime(e):t.isValidDate(e)?t.currentTime=e:e||a||!P.allowBlank?t.currentTime=t.now():t.currentTime=null,j.trigger("xchange.xdsoft")},t.empty=function(){t.currentTime=null},t.getCurrentTime=function(e){return t.currentTime},t.nextMonth=function(){void 0!==t.currentTime&&null!==t.currentTime||(t.currentTime=t.now());var a,n=t.currentTime.getMonth()+1;return 12===n&&(t.currentTime.setFullYear(t.currentTime.getFullYear()+1),n=0),a=t.currentTime.getFullYear(),t.currentTime.setDate(Math.min(new Date(t.currentTime.getFullYear(),n+1,0).getDate(),t.currentTime.getDate())),t.currentTime.setMonth(n),P.onChangeMonth&&e.isFunction(P.onChangeMonth)&&P.onChangeMonth.call(j,A.currentTime,j.data("input")),a!==t.currentTime.getFullYear()&&e.isFunction(P.onChangeYear)&&P.onChangeYear.call(j,A.currentTime,j.data("input")),j.trigger("xchange.xdsoft"),n},t.prevMonth=function(){void 0!==t.currentTime&&null!==t.currentTime||(t.currentTime=t.now());var a=t.currentTime.getMonth()-1;return-1===a&&(t.currentTime.setFullYear(t.currentTime.getFullYear()-1),a=11),t.currentTime.setDate(Math.min(new Date(t.currentTime.getFullYear(),a+1,0).getDate(),t.currentTime.getDate())),t.currentTime.setMonth(a),P.onChangeMonth&&e.isFunction(P.onChangeMonth)&&P.onChangeMonth.call(j,A.currentTime,j.data("input")),j.trigger("xchange.xdsoft"),a},t.getWeekOfYear=function(t){if(P.onGetWeekOfYear&&e.isFunction(P.onGetWeekOfYear)){var a=P.onGetWeekOfYear.call(j,t);if(void 0!==a)return a}var n=new Date(t.getFullYear(),0,1);return 4!=n.getDay()&&n.setMonth(0,1+(4-n.getDay()+7)%7),Math.ceil(((t-n)/864e5+n.getDay()+1)/7)},t.strToDateTime=function(e){var a,r,o=[];return e&&e instanceof Date&&t.isValidDate(e)?e:((o=/^(\+|\-)(.*)$/.exec(e))&&(o[2]=n.parseDate(o[2],P.formatDate)),o&&o[2]?(a=o[2].getTime()-6e4*o[2].getTimezoneOffset(),r=new Date(t.now(!0).getTime()+parseInt(o[1]+"1",10)*a)):r=e?n.parseDate(e,P.format):t.now(),t.isValidDate(r)||(r=t.now()),r)},t.strToDate=function(e){if(e&&e instanceof Date&&t.isValidDate(e))return e;var a=e?n.parseDate(e,P.formatDate):t.now(!0);return t.isValidDate(a)||(a=t.now(!0)),a},t.strtotime=function(e){if(e&&e instanceof Date&&t.isValidDate(e))return e;var a=e?n.parseDate(e,P.formatTime):t.now(!0);return t.isValidDate(a)||(a=t.now(!0)),a},t.str=function(){return n.formatDate(t.currentTime,P.format)},t.currentTime=this.now()},B.on("touchend click",(function(e){e.preventDefault(),j.data("changed",!0),A.setCurrentTime(q()),a.val(A.str()),j.trigger("close.xdsoft")})),I.find(".xdsoft_today_button").on("touchend mousedown.xdsoft",(function(){j.data("changed",!0),A.setCurrentTime(0,!0),j.trigger("afterOpen.xdsoft")})).on("dblclick.xdsoft",(function(){var e,t,n=A.getCurrentTime();n=new Date(n.getFullYear(),n.getMonth(),n.getDate()),e=A.strToDate(P.minDate),n<(e=new Date(e.getFullYear(),e.getMonth(),e.getDate()))||(t=A.strToDate(P.maxDate),n>(t=new Date(t.getFullYear(),t.getMonth(),t.getDate()))||(a.val(A.str()),a.trigger("change"),j.trigger("close.xdsoft")))})),I.find(".xdsoft_prev,.xdsoft_next").on("touchend mousedown.xdsoft",(function(){var t=e(this),a=0,n=!1;!function e(r){t.hasClass(P.next)?A.nextMonth():t.hasClass(P.prev)&&A.prevMonth(),P.monthChangeSpinner&&(n||(a=setTimeout(e,r||100)))}(500),e([document.body,window]).on("touchend mouseup.xdsoft",(function t(){clearTimeout(a),n=!0,e([document.body,window]).off("touchend mouseup.xdsoft",t)}))})),L.find(".xdsoft_prev,.xdsoft_next").on("touchend mousedown.xdsoft",(function(){var t=e(this),a=0,n=!1,r=110;!function e(o){var i=E[0].clientHeight,s=R[0].offsetHeight,d=Math.abs(parseInt(R.css("marginTop"),10));t.hasClass(P.next)&&s-i-P.timeHeightInTimePicker>=d?R.css("marginTop","-"+(d+P.timeHeightInTimePicker)+"px"):t.hasClass(P.prev)&&d-P.timeHeightInTimePicker>=0&&R.css("marginTop","-"+(d-P.timeHeightInTimePicker)+"px"),E.trigger("scroll_element.xdsoft_scroller",[Math.abs(parseInt(R[0].style.marginTop,10)/(s-i))]),r=r>10?10:r-10,n||(a=setTimeout(e,o||r))}(500),e([document.body,window]).on("touchend mouseup.xdsoft",(function t(){clearTimeout(a),n=!0,e([document.body,window]).off("touchend mouseup.xdsoft",t)}))})),i=0,j.on("xchange.xdsoft",(function(t){clearTimeout(i),i=setTimeout((function(){if(void 0===A.currentTime||null===A.currentTime){if(P.allowBlank)return;A.currentTime=A.now()}for(var t,i,s,d,u,l,f,c,h,m,g="",p=new Date(A.currentTime.getFullYear(),A.currentTime.getMonth(),1,12,0,0),y=0,v=A.now(),b=!1,k=!1,D=[],x=!0,S="";p.getDay()!==P.dayOfWeekStart;)p.setDate(p.getDate()-1);for(g+="",P.weeks&&(g+=" | "),t=0;t<7;t+=1)g+=""+P.i18n[o].dayOfWeekShort[(t+P.dayOfWeekStart)%7]+" | ";for(g+="
",g+="",!1!==P.maxDate&&(b=A.strToDate(P.maxDate),b=new Date(b.getFullYear(),b.getMonth(),b.getDate(),23,59,59,999)),!1!==P.minDate&&(k=A.strToDate(P.minDate),k=new Date(k.getFullYear(),k.getMonth(),k.getDate()));y0?-1===P.allowDates.indexOf(n.formatDate(p,P.formatDate))&&D.push("xdsoft_disabled"):(!1!==b&&p>b||!1!==k&&p",x=!1,P.weeks&&(g+=""+f+" | ")),g+=''+d+" | ",p.getDay()===P.dayOfWeekStartPrev&&(g+="",x=!0),p.setDate(d+1);if(g+="
",N.html(g),I.find(".xdsoft_label span").eq(0).text(P.i18n[o].months[A.currentTime.getMonth()]),I.find(".xdsoft_label span").eq(1).text(A.currentTime.getFullYear()),S="",l="",h=function(t,r){var o,i,s=A.now(),d=P.allowTimes&&e.isArray(P.allowTimes)&&P.allowTimes.length;s.setHours(t),t=parseInt(s.getHours(),10),s.setMinutes(r),r=parseInt(s.getMinutes(),10),(o=new Date(A.currentTime)).setHours(t),o.setMinutes(r),D=[],(!1!==P.minDateTime&&P.minDateTime>o||!1!==P.maxTime&&A.strtotime(P.maxTime).getTime()s.getTime()||!1!==P.minDateTime&&P.minDateTime>o||!1!==P.disabledMinTime&&s.getTime()>A.strtotime(P.disabledMinTime).getTime()&&!1!==P.disabledMaxTime&&s.getTime()59||i.getMinutes()===parseInt(r,10))&&(P.defaultSelect||j.data("changed")?D.push("xdsoft_current"):P.initTime&&D.push("xdsoft_init_time")),parseInt(v.getHours(),10)===parseInt(t,10)&&parseInt(v.getMinutes(),10)===parseInt(r,10)&&D.push("xdsoft_today"),S+=''+n.formatDate(s,P.formatTime)+"
"},P.allowTimes&&e.isArray(P.allowTimes)&&P.allowTimes.length)for(y=0;y'+y+" ";for(G.children().eq(0).html(r),y=parseInt(P.monthStart,10),r="";y<=parseInt(P.monthEnd,10);y+=1)r+='