Arrumar Modtools

2 participantes

Ver o tópico anterior Ver o tópico seguinte Ir para baixo

Tópico resolvido Arrumar Modtools

Mensagem por SkoLL 21.11.18 19:26

Detalhes da questão


Endereço do fórum: http://nwk-nwd.forumeiros.com
Versão do fórum: ModernBB

Descrição


Código:
/**
     * Title        : Forumotion tools for moderation
     * Version      : 1.0.2
     * Author        : Zeus
     * Author URI    : http://help.forumgratuit.ro
     * License      : GNU - General Public License v3.0
     * Documentation : https://github.com/zeusmaximus/Moderation-tools-for-Forumotion/
     */
    if (typeof zModConfig === 'undefined') var zModConfig = [{
        icon: "https://i.servimg.com/u/f58/11/80/17/98/chat-110.png"
    }];
 
    if (typeof zModTabels === 'undefined') var zModTabels = [{
            type: "blue_check",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]check[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "red_delete_sweep",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]delete_sweep[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "orange_refresh",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]refresh[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "orange_lock_open",
            body_start: '/[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]lock_open[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "green_check_circle",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]green_check_circle[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "red_clear",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]clear[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "orange_lock",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]lock[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        }
 
    ];
 
    if (typeof zModMessages === 'undefined') var zModMessages = [{
 
            name: "Aprovado",
            message: '[h4]Recrutamento Aceito[/h4]\nRecrutamento aprovado e movido para "Recrutamentos Aceitos".',
            group_id: 0,
            type: "green_check_circle"
        },
        {
            name: "Em Aguardo",
            message: '[h4]Usuário aguardando teste[/h4]\nUsuário aguardando realização do teste".',
            group_id: 0,
            type: "orange_refresh"
        },
        {
            name: "Recrutamento Negado",
            message: '[h4]Recrutamento Negado[/h4]\nRecrutamento negado e movido para "Recrutamentos Negados".',
            group_id: 0,
            type: "red_clear"
        },
        {
            name: "Revisão Aceita",
            message: '[h4]Membro retornará ao clã[/h4]\nMovido para "Revisão aceitas".',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Será punido",
            message: '[h4]Tópico resolvido[/h4]\nJogador a aguardar suspensão..',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Punido",
            message: '[h4]Tópico resolvido[/h4]\nJogador suspenso e movido para "Denúncias Resolvidas"',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Denúncia ignorada",
            message: '[h4]Tópico ignorado[/h4]Movido para ''Denúncia Ignoradas".',
            group_id: 2,
            type: "red_clear"
        },
        {
            name: "Revisão Negada",
            message: '[h4]Tópico negado[/h4]\nJogador não voltará ao clã e movido para "Revisão Negadas"',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Pedido Entregue",
            message: '[h4]Pedido entregue[/h4]Pedido entregue, membro satisfeito e movido para "Pedidos Entregues".',
            group_id: 2,
            type: "red_clear"
        },
        {
            name: "Pedido Negado",
            message: '[h4]Pedido negado[/h4]Abandono ou pedido do autor, movido para "Pedidos Negados".',
            group_id: 2,
            type: "green_check_circle"
        },
        {
            name: "Bloqueado",
            message: '[b]Tópico bloqueado.[/b]Aguardando superior',
            group_id: 2,
            type: "orange_lock"
        },
        {
            name: "Desbloqueado",
            message: '[b]Tópico desbloqueado.[/b]',
            group_id: 2,
            type: "orange_lock_open"
        },
        {
            name: "Abandonado",
            message: '[h4]Tópico abandonado[/h4]Este tópico foi abandonado pelo autor, visto que este não postou nenhuma mensagem num prazo de 2 dias.',
            group_id: 2,
            type: "red_clear"
        },
        {
            name: "Apagado",
            message: 'Tópico movido para a lixeira.',
            group_id: 2,
            type: "red_delete_sweep"
        }
 
 
    ];
 
    if (typeof zModGroups === 'undefined') var zModGroups = [{
            id: 0,
            name: 'Administradores'
        },
        {
            id: 1,
            name: 'Moderadores'
        },
        {
            id: 2,
            name: 'Ajudantes'
        }
    ];
 
    $(function() {
        $('<style type="text/css">.sceditor-button-staff div {background: url(' + zModConfig[0].icon + ') !important; }</style>').appendTo("head");
 
        var list = "";
 
 
        $(window).load(function() {
            function zModGetTable(type, body) {
                var str = "";
                for (var y = 0; y < zModTabels.length; y++) str += (zModTabels[y].type === type) ? (body === "start") ? zModTabels[y].body_start : zModTabels[y].body_end : "";
                return str;
            }
 
            function zModGetModMessageByGroupId(f, g) {
                var str = "",
                    c = 0;
                for (var z = 0; z < zModMessages.length; z++) {
                    if (zModMessages[z].group_id == f) {
                        str += "<li class='mod_editor_message group_" + zModMessages[z].group_id + "' id='group_" + z + "_" + zModMessages[z].group_id + "'><a style='cursor: pointer'>" + zModMessages[z].name + "</a></li>\n";
                        if (g === 0) zModInsertToSCEditor('#group_' + z + '_' + zModMessages[z].group_id + ' a', zModMessages[z].message, zModMessages[z].type);
                        c++;
                    }
                }
                if (g === 1) str = c;
 
                return str;
            }
 
            function zModInsertToSCEditor(e, t, i) {
                $(e).live("click", function(e) {
                    $("#text_editor_textarea").sceditor("instance").insertText(zModGetTable(i, "start") + t, zModGetTable(i, "end"));
                });
            }
 
            function zModToggleSCEditor(o, i) {
                $(o).live("click", function(o) {
                    $(i).toggle();
                });
            }
 
            for (var x = 0; x < zModGroups.length; x++) {
                if (zModGetModMessageByGroupId(zModGroups[x].id, 1) > 0) {
                    list += "<li class='mod_editor_section' id='list_" + zModGroups[x].id + "'><a style='cursor: pointer'>" + zModGroups[x].name + " (" + zModGetModMessageByGroupId(zModGroups[x].id, 1) + ")</a></li>" + zModGetModMessageByGroupId(zModGroups[x].id, 0);
                    zModToggleSCEditor("#list_" + zModGroups[x].id + " a", ".group_" + zModGroups[x].id + "");
                }
            }
 
            zModToggleSCEditor('.sceditor-button.sceditor-button-staff', '.mod_box');
 
            $("textarea, .sceditor-button").click(function() {
                $(".mod_box").hide();
            });
 
            $(".sceditor-button-source").click(function() {
                $(".sceditor-button-staff").removeClass("disabled");
            });
 
            if (_userdata.user_level === 1 | _userdata.user_level === 2) $(".sceditor-group:last-child").before('<div class="sceditor-group"><a class="sceditor-button sceditor-button-staff" title="Moderação"><div unselectable="on">Moderação</div></a><div class="mod_box" style="display: none;"><ul class="mod_groups" id="mod_box_i">' + list + '<li class="copyright_e"> ©️️️️️️️️️️️ Created by Zeus - Alterações efetuadas por Roger123</li></div></div></div>');
 
        });
 
    });

Esse código não está funcionando, esse icone não esta aparecendo o que faço?
SkoLL

SkoLL
**

Membro desde : 20/08/2017
Mensagens : 58
Pontos : 96

http://sixgold-ner.forumeiros.com

Ir para o topo Ir para baixo

Admineiro

Tópico resolvido Re: Arrumar Modtools

Mensagem por tikky 21.11.18 19:56

Olá @SkoLL,
Mude o seu código para:
Código:
/**
     * Title        : Forumotion tools for moderation
     * Version      : 1.0.2
     * Author        : Zeus
     * Author URI    : http://help.forumgratuit.ro
     * License      : GNU - General Public License v3.0
     * Documentation : https://github.com/zeusmaximus/Moderation-tools-for-Forumotion/
     */
    if (typeof zModConfig === 'undefined') var zModConfig = [{
        icon: "https://i.servimg.com/u/f58/11/80/17/98/chat-110.png"
    }];
 
    if (typeof zModTabels === 'undefined') var zModTabels = [{
            type: "blue_check",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]check[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "red_delete_sweep",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]delete_sweep[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "orange_refresh",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]refresh[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "orange_lock_open",
            body_start: '/[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]lock_open[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "green_check_circle",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]green_check_circle[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "red_clear",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]clear[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        },
        {
            type: "orange_lock",
            body_start: '[table style="background-color: #00B5D1;border: solid 2px #00B5D1;border-radius: 2px;margin: 1em 25px 1em 1em;min-width: 90%!important;"][tr style=][td style="font-size: 25px;margin-right: 15px;padding: 15px!important;color: white;display: table-cell;vertical-align: middle;"][font=material icons]lock[/font][/td][td style="width: 100%;color: white"]',
            body_end: "[/td][/tr][/table]\n\n"
        }
 
    ];
 
    if (typeof zModMessages === 'undefined') var zModMessages = [{
 
            name: "Aprovado",
            message: '[h4]Recrutamento Aceito[/h4]\nRecrutamento aprovado e movido para "Recrutamentos Aceitos".',
            group_id: 0,
            type: "green_check_circle"
        },
        {
            name: "Em Aguardo",
            message: '[h4]Usuário aguardando teste[/h4]\nUsuário aguardando realização do teste".',
            group_id: 0,
            type: "orange_refresh"
        },
        {
            name: "Recrutamento Negado",
            message: '[h4]Recrutamento Negado[/h4]\nRecrutamento negado e movido para "Recrutamentos Negados".',
            group_id: 0,
            type: "red_clear"
        },
        {
            name: "Revisão Aceita",
            message: '[h4]Membro retornará ao clã[/h4]\nMovido para "Revisão aceitas".',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Será punido",
            message: '[h4]Tópico resolvido[/h4]\nJogador a aguardar suspensão..',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Punido",
            message: '[h4]Tópico resolvido[/h4]\nJogador suspenso e movido para "Denúncias Resolvidas"',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Denúncia ignorada",
            message: '[h4]Tópico ignorado[/h4]Movido para "Denúncia Ignoradas".',
            group_id: 2,
            type: "red_clear"
        },
        {
            name: "Revisão Negada",
            message: '[h4]Tópico negado[/h4]\nJogador não voltará ao clã e movido para "Revisão Negadas"',
            group_id: 1,
            type: "green_check_circle"
        },
        {
            name: "Pedido Entregue",
            message: '[h4]Pedido entregue[/h4]Pedido entregue, membro satisfeito e movido para "Pedidos Entregues".',
            group_id: 2,
            type: "red_clear"
        },
        {
            name: "Pedido Negado",
            message: '[h4]Pedido negado[/h4]Abandono ou pedido do autor, movido para "Pedidos Negados".',
            group_id: 2,
            type: "green_check_circle"
        },
        {
            name: "Bloqueado",
            message: '[b]Tópico bloqueado.[/b]Aguardando superior',
            group_id: 2,
            type: "orange_lock"
        },
        {
            name: "Desbloqueado",
            message: '[b]Tópico desbloqueado.[/b]',
            group_id: 2,
            type: "orange_lock_open"
        },
        {
            name: "Abandonado",
            message: '[h4]Tópico abandonado[/h4]Este tópico foi abandonado pelo autor, visto que este não postou nenhuma mensagem num prazo de 2 dias.',
            group_id: 2,
            type: "red_clear"
        },
        {
            name: "Apagado",
            message: 'Tópico movido para a lixeira.',
            group_id: 2,
            type: "red_delete_sweep"
        }
 
 
    ];
 
    if (typeof zModGroups === 'undefined') var zModGroups = [{
            id: 0,
            name: 'Administradores'
        },
        {
            id: 1,
            name: 'Moderadores'
        },
        {
            id: 2,
            name: 'Ajudantes'
        }
    ];
 
    $(function() {
        $('<style type="text/css">.sceditor-button-staff div {background: url(' + zModConfig[0].icon + ') !important; }</style>').appendTo("head");
 
        var list = "";
 
 
        $(window).load(function() {
            function zModGetTable(type, body) {
                var str = "";
                for (var y = 0; y < zModTabels.length; y++) str += (zModTabels[y].type === type) ? (body === "start") ? zModTabels[y].body_start : zModTabels[y].body_end : "";
                return str;
            }
 
            function zModGetModMessageByGroupId(f, g) {
                var str = "",
                    c = 0;
                for (var z = 0; z < zModMessages.length; z++) {
                    if (zModMessages[z].group_id == f) {
                        str += "<li class='mod_editor_message group_" + zModMessages[z].group_id + "' id='group_" + z + "_" + zModMessages[z].group_id + "'><a style='cursor: pointer'>" + zModMessages[z].name + "</a></li>\n";
                        if (g === 0) zModInsertToSCEditor('#group_' + z + '_' + zModMessages[z].group_id + ' a', zModMessages[z].message, zModMessages[z].type);
                        c++;
                    }
                }
                if (g === 1) str = c;
 
                return str;
            }
 
            function zModInsertToSCEditor(e, t, i) {
                $(e).live("click", function(e) {
                    $("#text_editor_textarea").sceditor("instance").insertText(zModGetTable(i, "start") + t, zModGetTable(i, "end"));
                });
            }
 
            function zModToggleSCEditor(o, i) {
                $(o).live("click", function(o) {
                    $(i).toggle();
                });
            }
 
            for (var x = 0; x < zModGroups.length; x++) {
                if (zModGetModMessageByGroupId(zModGroups[x].id, 1) > 0) {
                    list += "<li class='mod_editor_section' id='list_" + zModGroups[x].id + "'><a style='cursor: pointer'>" + zModGroups[x].name + " (" + zModGetModMessageByGroupId(zModGroups[x].id, 1) + ")</a></li>" + zModGetModMessageByGroupId(zModGroups[x].id, 0);
                    zModToggleSCEditor("#list_" + zModGroups[x].id + " a", ".group_" + zModGroups[x].id + "");
                }
            }
 
            zModToggleSCEditor('.sceditor-button.sceditor-button-staff', '.mod_box');
 
            $("textarea, .sceditor-button").click(function() {
                $(".mod_box").hide();
            });
 
            $(".sceditor-button-source").click(function() {
                $(".sceditor-button-staff").removeClass("disabled");
            });
 
            if (_userdata.user_level === 1 | _userdata.user_level === 2) $(".sceditor-group:last-child").before('<div class="sceditor-group"><a class="sceditor-button sceditor-button-staff" title="Moderação"><div unselectable="on">Moderação</div></a><div class="mod_box" style="display: none;"><ul class="mod_groups" id="mod_box_i">' + list + '<li class="copyright_e"> ©️️️️️️️️️️️️ Created by Zeus - Alterações efetuadas por Roger123</li></div></div></div>');
 
        });
 
    });


Cordialmente,
pedxz.


Título alterado de 'Mensagens moderativas 2 ' para 'Arrumar Modtools'.
tikky

tikky
Admineiro
Admineiro

Membro desde : 13/01/2017
Mensagens : 7806
Pontos : 9049

Ir para o topo Ir para baixo

Tópico resolvido Re: Arrumar Modtools

Mensagem por SkoLL 21.11.18 20:03

SkoLL

SkoLL
**

Membro desde : 20/08/2017
Mensagens : 58
Pontos : 96

http://sixgold-ner.forumeiros.com

Ir para o topo Ir para baixo

Admineiro

Tópico resolvido Re: Arrumar Modtools

Mensagem por tikky 21.11.18 20:06

Adicione na sua Folha de estilo, o seguinte código:
Código:
 .mod_groups {
            line-height: 1.5;
            font-size: 11px;
            font-weight: 400;
        }
       
        .mod_box {
            -moz-background-clip: padding;
            -moz-border-radius: 2px;
            -moz-box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.2);
            -webkit-background-clip: padding-box;
            -webkit-border-radius: 2px;
            -webkit-box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.2);
            background: #fff;
            background-clip: padding-box;
            border: 1px solid #ccc;
            border-radius: 2px;
            box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.2);
            color: #333;
            width: 200px;
            line-height: 1;
            padding: 10px;
            position: absolute;
            z-index: 999;
        }
       
        .mod_editor_section {
            background: #f1f1f1;
            padding: 5px;
            font-weight: bold;
            border-bottom: 1px solid #d7d7d7;
            text-align: left;
            text-transform: uppercase;
        }
       
        .copyright_e {
            margin-top: 5px;
            background: #f8f8f8;
            border-top: 1px solid #d7d7d7;
            text-align: left;
            padding: 2px 5px;
            font-size: 9px;
            color: #777;
            text-shadow: 1px 1px 0px white;
        }
       
        .mod_editor_message {
            padding: 2px 5px;
            text-align: left;
        }
       
        .mod_groups {
            height: 150px;
            overflow-y: scroll;
        }
       
        .mod_groups li {
            list-style-type: none;
            margin-left: -40px;
        }
       
        .sceditor-button-staff {
            position: relative;
        }
       
        .mod_box {
            top: 73px;
        }
       
        #quick_reply .mod_groups li {
            margin-left: 0px;
        }
       
        #quick_reply .mod_box {
            top: 35px;
        }
       
        .sceditor-button-staff.disabled div {
            opacity: 1.0 !important;
            filter: alpha(opacity=100) !important;
        }
tikky

tikky
Admineiro
Admineiro

Membro desde : 13/01/2017
Mensagens : 7806
Pontos : 9049

Ir para o topo Ir para baixo

Tópico resolvido Re: Arrumar Modtools

Mensagem por SkoLL 21.11.18 20:08

Pronto, pode fechar.
SkoLL

SkoLL
**

Membro desde : 20/08/2017
Mensagens : 58
Pontos : 96

http://sixgold-ner.forumeiros.com

Ir para o topo Ir para baixo

Admineiro

Tópico resolvido Re: Arrumar Modtools

Mensagem por tikky 21.11.18 20:08

Tópico resolvido


Movido para "Questões resolvidas".
tikky

tikky
Admineiro
Admineiro

Membro desde : 13/01/2017
Mensagens : 7806
Pontos : 9049

Ir para o topo Ir para baixo

Ver o tópico anterior Ver o tópico seguinte Ir para o topo

- Tópicos semelhantes

Permissões neste sub-fórum
Não podes responder a tópicos