Skip to content
Snippets Groups Projects
Select Git revision
  • 0f18be8809c0ffa4080bd001f41a469b51a44d43
  • master default protected
  • 7771-harden-postgres-backup
  • pgsql-dump-with-snapshots
  • update-colors
  • update-docs-css
  • usb-repair-stick
  • desktop-notification
  • 7000-corrections
  • db-detector
10 results

backup.sh

Blame
  • functions.js 11.88 KiB
    
    /**
     * initialize soft scrolling for links with css class "scroll-link"
     * @see http://css-tricks.com/snippets/jquery/smooth-scrolling/
     * @returns {undefined}
     */
    function initSoftscroll(){
        $(function() {
          // $('a[href*=#]:not([href=#])').click(function() {
          $('a.scroll-link').click(function() {
            if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) {
              var target = $(this.hash);
              target = target.length ? target : $('[name=' + this.hash.slice(1) +']');
              if (target.length) {
                $('html,body').animate({
                  scrollTop: target.offset().top - 70
                }, 300);
                return false;
              }
            }
          });
        });
    }
    
    function showModalMessage(sMessage){
       $('#divmodalmessage').html(sMessage);
       $('#divmodal').show();
    }
    function showIdAsModalMessage(sId){
       var o=$('#'+sId);
       var sHtml='<a href="#" onclick="return hideModalMessage()" class="btn btn-danger" style="float:right"> X </a>' 
               + o.html()
               + '<hr><a href="#" onclick="return hideModalMessage()" class="btn btn-primary"><i class="fa fa-check"></i> OK </a>'
                ;
       $('#divmodalmessage').html(sHtml);
       $('#divmodal').show();
       return false;
    }   
    
    function hideModalMessage(){
       $('#divmodal').hide();
       return false;
    }
    
    // ----------------------------------------------------------------------
    // general init in each page
    // ----------------------------------------------------------------------
    
    $(document).ready(function() {
        initSoftscroll();
        // $(".optionName").popover({trigger: "hover"});
        // $("#content").hide().fadeIn(300);
    });
    
    
    // ----------------------------------------------------------------------
    // action log
    // ----------------------------------------------------------------------
    
    /**
     * get filtered action log table
     * @returns {undefined}
    
    function __REMOVEME___updateActionlog(){
        var sUrlBase="/webservice/?class=Actionlog&action=getLogs&type=json&args=";
        var aArgs={};
    
        var aFilteritems=["project", "where", "order", "limit"];
        var aTableitems=["id", "time", "loglevel", "ip", "user", "project", "action", "message"];