From 0e3a54bc2c299b8317e046fa4fb75cdf0e29b82f Mon Sep 17 00:00:00 2001 From: Daniel Molina Date: Fri, 7 Mar 2014 16:25:48 +0100 Subject: [PATCH] Remove timepicker dependency --- install.sh | 6 +----- src/sunstone/public/vendor/4.0/jquery.timePicker.min.js | 1 - src/sunstone/views/index.erb | 1 - 3 files changed, 1 insertion(+), 7 deletions(-) delete mode 100755 src/sunstone/public/vendor/4.0/jquery.timePicker.min.js diff --git a/install.sh b/install.sh index bb9195592e..29ff9ce675 100755 --- a/install.sh +++ b/install.sh @@ -518,9 +518,7 @@ INSTALL_SUNSTONE_FILES=( SUNSTONE_PUBLIC_NEW_VENDOR_FONTAWESOME_CSS:$SUNSTONE_LOCATION/public/vendor/4.0/fontawesome/css SUNSTONE_PUBLIC_NEW_VENDOR_NOUISLIDER:$SUNSTONE_LOCATION/public/vendor/4.0/nouislider SUNSTONE_PUBLIC_NEW_VENDOR_JDPICKER:$SUNSTONE_LOCATION/public/vendor/4.0/jdpicker_1.1 - SUNSTONE_PUBLIC_NEW_VENDOR_JDPICKER_IMAGES:$SUNSTONE_LOCATION/public/vendor/4.0/jdpicker_1.1/images - SUNSTONE_PUBLIC_NEW_VENDOR_TIMEPICKER:$SUNSTONE_LOCATION/public/vendor/4.0/ - SUNSTONE_PUBLIC_IMAGES_FILES:$SUNSTONE_LOCATION/public/images + SUNSTONE_PUBLIC_NEW_VENDOR_JDPICKER_IMAGES:$SUNSTONE_LOCATION/public/vendor/4.0/jdpicker_1.1/imagesTISUNSTONE_PUBLIC_IMAGES_FILES:$SUNSTONE_LOCATION/public/images SUNSTONE_PUBLIC_LOCALE_CA:$SUNSTONE_LOCATION/public/locale/ca SUNSTONE_PUBLIC_LOCALE_CS_CZ:$SUNSTONE_LOCATION/public/locale/cs_CZ SUNSTONE_PUBLIC_LOCALE_DE:$SUNSTONE_LOCATION/public/locale/de @@ -1597,8 +1595,6 @@ SUNSTONE_PUBLIC_NEW_VENDOR_JDPICKER_IMAGES="\ src/sunstone/public/vendor/4.0/jdpicker_1.1/images/bg_selectable.png \ src/sunstone/public/vendor/4.0/jdpicker_1.1/images/bg_selected.png" -SUNSTONE_PUBLIC_NEW_VENDOR_TIMEPICKER="src/sunstone/public/vendor/4.0/jquery.timePicker.min.js" - SUNSTONE_PUBLIC_IMAGES_FILES="src/sunstone/public/images/ajax-loader.gif \ src/sunstone/public/images/favicon.ico \ src/sunstone/public/images/login_over.png \ diff --git a/src/sunstone/public/vendor/4.0/jquery.timePicker.min.js b/src/sunstone/public/vendor/4.0/jquery.timePicker.min.js deleted file mode 100755 index 2e092fda8e..0000000000 --- a/src/sunstone/public/vendor/4.0/jquery.timePicker.min.js +++ /dev/null @@ -1 +0,0 @@ -(function(a){function g(a){a.setFullYear(2001),a.setMonth(0),a.setDate(0);return a}function f(a,b){if(a){var c=a.split(b.separator),d=parseFloat(c[0]),e=parseFloat(c[1]);b.show24Hours||(d===12&&a.indexOf("AM")!==-1?d=0:d!==12&&a.indexOf("PM")!==-1&&(d+=12));var f=new Date(0,0,0,d,e,0);return g(f)}return null}function e(a,b){return typeof a=="object"?g(a):f(a,b)}function d(a){return(a<10?"0":"")+a}function c(a,b){var c=a.getHours(),e=b.show24Hours?c:(c+11)%12+1,f=a.getMinutes();return d(e)+b.separator+d(f)+(b.show24Hours?"":c<12?" AM":" PM")}function b(b,c,d,e){b.value=a(c).text(),a(b).change(),a.browser.msie||b.focus(),d.hide()}a.fn.timePicker=function(b){var c=a.extend({},a.fn.timePicker.defaults,b);return this.each(function(){a.timePicker(this,c)})},a.timePicker=function(b,c){var d=a(b)[0];return d.timePicker||(d.timePicker=new jQuery._timePicker(d,c))},a.timePicker.version="0.3",a._timePicker=function(d,h){var i=!1,j=!1,k=e(h.startTime,h),l=e(h.endTime,h),m="selected",n="li."+m;a(d).attr("autocomplete","OFF");var o=[],p=new Date(k);while(p<=l)o[o.length]=c(p,h),p=new Date(p.setMinutes(p.getMinutes()+h.step));var q=a('
'),r=a("");for(var s=0;s"+o[s]+"");q.append(r),q.appendTo("body").hide(),q.mouseover(function(){i=!0}).mouseout(function(){i=!1}),a("li",r).mouseover(function(){j||(a(n,q).removeClass(m),a(this).addClass(m))}).mousedown(function(){i=!0}).click(function(){b(d,this,q,h),i=!1});var t=function(){if(q.is(":visible"))return!1;a("li",q).removeClass(m);var b=a(d).offset();q.css({top:b.top+d.offsetHeight,left:b.left}),q.show();var e=d.value?f(d.value,h):k,i=k.getHours()*60+k.getMinutes(),j=e.getHours()*60+e.getMinutes()-i,n=Math.round(j/h.step),o=g(new Date(0,0,0,0,n*h.step+i,0));o=kf+q[0].offsetHeight&&(q[0].scrollTop=f+i.offsetHeight)):(e.removeClass(m),i=a("li:first",r).addClass(m)[0],q[0].scrollTop=0);return!1;case 13:if(q.is(":visible")){var k=a(n,r)[0];b(d,k,q,h)}return!1;case 27:q.hide();return!1}return!0}),a(d).keyup(function(a){j=!1}),this.getTime=function(){return f(d.value,h)},this.setTime=function(b){d.value=c(e(b,h),h),a(d).change()}},a.fn.timePicker.defaults={step:30,startTime:new Date(0,0,0,0,0,0),endTime:new Date(0,0,0,23,30,0),separator:":",show24Hours:!0}})(jQuery) \ No newline at end of file diff --git a/src/sunstone/views/index.erb b/src/sunstone/views/index.erb index f8e9545956..23e84b3fcc 100644 --- a/src/sunstone/views/index.erb +++ b/src/sunstone/views/index.erb @@ -16,7 +16,6 @@ -