%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /var/www/html/bbw/farmaci/kritik-portale/public/js/
Upload File :
Create Path :
Current File : /var/www/html/bbw/farmaci/kritik-portale/public/js/modal.js

var modal = {
    options: {
        element : null
    },
    init: function() {
        this.options.element = $("#modal");
        this.options.element.on('hidden.bs.modal', function (e) {
            modal.options.element.find("#link_available").remove();
            modal.options.element.find("#link_denial").remove();
            modal.options.element.find(".modal-title").empty();
            modal.options.element.find(".modal-title").removeClass("modal-validate");
            modal.options.element.find(".modal-dialog").removeClass("modal-trash");
            modal.options.element.find(".modal-content").removeClass("modal-mail");
            modal.options.element.find(".modal-body").html("Bitte warten ...");
            modal.options.element.find(".save").unbind("click");
            modal.options.element.find(".save").html("Suchen");
            modal.options.element.find(".cancel").unbind("click");
            modal.options.element.find(".cancel").html("Schließen");
            modal.options.element.find(".save").removeClass("btn-danger");
            modal.options.element.find(".save").show();
            
        });
    },
    getElement: function() {
        return this.options.element;
    },
    show: function() {
        this.options.element.modal("show");
    },
    infoBox: function(msg){
        var dialog = modal.getElement();
        dialog.modal("hide");
        dialog.find(".modal-title").html("Information");
        dialog.find(".modal-body").html(msg);
        dialog.find(".save").hide();
        dialog.find(".cancel").unbind("click");
        dialog.find(".cancel").html("OK");
        dialog.find(".cancel").show();
        dialog.modal("show");
    },
    waitBox: function(){
        var dialog = modal.getElement();
        dialog.modal("hide");
        dialog.find(".modal-title").html("Information");
        dialog.find(".modal-body").html("<div style='text-align:center;'>Bitte warten ... <br /><img src='/images/kreis.gif'></div>");
        dialog.find(".save").hide();
        dialog.find(".cancel").hide();
        dialog.modal("show");
    },
    progress: function(type) {
        if(type === "show"){
            this.options.element.find(".progress").show();
        } else {
            this.options.element.find(".progress").hide();
        }
    }
};

Zerion Mini Shell 1.0