function hideButtons() {
    $.post("/status", function (data) {
        var status = data.split(' ');
        if (status[0] == 'True') {
            $('#btnLogout').show();
            $('#btnSetUser').show();
            $('#btnLogin').hide();
        } else {
            $('#btnLogout').hide();
            $('#btnSetUser').hide();
            $('#btnLogin').show();
        }

        if (status[1] == 'True' && status[2] == 'True') {
            $('#btnSetRepo').show();
            $('#btnCommit').show();
            $('#btnNewFile').show();
            $('#btnPull').show();
            $('#btnReset').show();
        } else {
            if (status[1] == 'True') {
                $('#btnSetRepo').show();
                $('#btnCommit').hide();
                $('#btnNewFile').hide();
                $('#btnPull').hide();
                $('#btnReset').hide();
            } else {
                $('#btnSetRepo').hide();
                $('#btnCommit').hide();
                $('#btnNewFile').hide();
                $('#btnPull').hide();
                $('#btnReset').hide();
            }
        }

        $(window).resize();
    })
}
/**
 * Hide buttons for version control which are not allowed to use.
 */
Hide buttons for version control which are not allowed to use.
Hide buttons for version control which are not allowed to use .
function hideButtons() {
    $.post("/status", function (data) {
        var status = data.split(' ');
        if (status[0] == 'True') {
            $('#btnLogout').show();
            $('#btnSetUser').show();
            $('#btnLogin').hide();
        } else {
            $('#btnLogout').hide();
            $('#btnSetUser').hide();
            $('#btnLogin').show();
        }
        if (status[1] == 'True' && status[2] == 'True') {
            $('#btnSetRepo').show();
            $('#btnCommit').show();
            $('#btnNewFile').show();
            $('#btnPull').show();
            $('#btnReset').show();
        } else {
            if (status[1] == 'True') {
                $('#btnSetRepo').show();
                $('#btnCommit').hide();
                $('#btnNewFile').hide();
                $('#btnPull').hide();
                $('#btnReset').hide();
            } else {
                $('#btnSetRepo').hide();
                $('#btnCommit').hide();
                $('#btnNewFile').hide();
                $('#btnPull').hide();
                $('#btnReset').hide();
            }
        }
        $(window).resize();
    })
}
function hideButtons ( ) { $ . post ( "/status" , function ( data ) { var status = data . split ( ' ' ) ; if ( status [ 0 ] == 'True' ) { $ ( '#btnLogout' ) . show ( ) ; $ ( '#btnSetUser' ) . show ( ) ; $ ( '#btnLogin' ) . hide ( ) ; } else { $ ( '#btnLogout' ) . hide ( ) ; $ ( '#btnSetUser' ) . hide ( ) ; $ ( '#btnLogin' ) . show ( ) ; } if ( status [ 1 ] == 'True' && status [ 2 ] == 'True' ) { $ ( '#btnSetRepo' ) . show ( ) ; $ ( '#btnCommit' ) . show ( ) ; $ ( '#btnNewFile' ) . show ( ) ; $ ( '#btnPull' ) . show ( ) ; $ ( '#btnReset' ) . show ( ) ; } else { if ( status [ 1 ] == 'True' ) { $ ( '#btnSetRepo' ) . show ( ) ; $ ( '#btnCommit' ) . hide ( ) ; $ ( '#btnNewFile' ) . hide ( ) ; $ ( '#btnPull' ) . hide ( ) ; $ ( '#btnReset' ) . hide ( ) ; } else { $ ( '#btnSetRepo' ) . hide ( ) ; $ ( '#btnCommit' ) . hide ( ) ; $ ( '#btnNewFile' ) . hide ( ) ; $ ( '#btnPull' ) . hide ( ) ; $ ( '#btnReset' ) . hide ( ) ; } } $ ( window ) . resize ( ) ; } ) }
Hide buttons for version control which are not allowed to use.
Hide buttons for version control which are not allowed to use .