Marius Burkard
2016-06-17 768b3f3affbb059b6423e96d306590fc54f16cfd
interface/web/themes/default/assets/javascripts/ispconfig.js
@@ -364,9 +364,11 @@
   },
   loadInitContent: function() {
      var startpage = $('#pageContent').attr('data-startpage');
      if(!startpage) startpage = 'dashboard/dashboard.php';
      var pageContentObject = $.ajax({
         type: "GET",
         url: "dashboard/dashboard.php",
         url: startpage,
         data: "",
         dataType: "html",
         beforeSend: function() {
@@ -616,9 +618,12 @@
   }
});
var $page = $('html, body');
$(document).on('click', 'a[data-load-content],button[data-load-content]', function(e) {
   e.preventDefault();
   $('html, body').animate({scrollTop: 0}, 1000);
   $page.on('scroll mousedown wheel DOMMouseScroll mousewheel keyup touchmove', function() { $page.stop(); });
   $page.animate({scrollTop: 0}, 1000, function() { $page.off('scroll mousedown wheel DOMMouseScroll mousewheel keyup touchmove', function() { $page.stop(); }); });
   
   var content_to_load = $(this).attr('data-load-content');
   if(!content_to_load) return this;
@@ -628,7 +633,8 @@
$(document).on('click', 'a[data-capp],button[data-capp]', function(e) {
   e.preventDefault();
   $('html, body').animate({scrollTop: 0}, 1000);
   $page.on('scroll mousedown wheel DOMMouseScroll mousewheel keyup touchmove', function() { $page.stop(); });
   $page.animate({scrollTop: 0}, 1000, function() { $page.off('scroll mousedown wheel DOMMouseScroll mousewheel keyup touchmove', function() { $page.stop(); }); });
   
   var content_to_load = $(this).attr('data-capp');
   if(!content_to_load) return this;
@@ -638,7 +644,8 @@
$(document).on('click', 'a[data-submit-form],button[data-submit-form]', function(e) {
   e.preventDefault();
   $('html, body').animate({scrollTop: 0}, 1000);
   $page.on('scroll mousedown wheel DOMMouseScroll mousewheel keyup touchmove', function() { $page.stop(); });
   $page.animate({scrollTop: 0}, 1000, function() { $page.off('scroll mousedown wheel DOMMouseScroll mousewheel keyup touchmove', function() { $page.stop(); }); });
   
   var $el = $(this);
   var act = $el.attr('data-form-action');
@@ -655,9 +662,9 @@
      $("#pageForm .table #Filter").trigger('click');
   }
   //Use $ submit with keypress Enter in forms
   if (event.which == '13' && $(".pnl_formsarea button.positive").length > 0 && event.target.localName != 'textarea' && $(event.target).is(':input')) {
   if (event.which == '13' && $(".tab-content button.formbutton-success").length > 0 && event.target.localName != 'textarea' && $(event.target).is(':input')) {
      event.preventDefault();
      $(".pnl_formsarea button.positive:first").not("[disabled='disabled']").trigger('click');
      $(".tab-content button.formbutton-success").not("[disabled='disabled']").trigger('click');
   }
});