%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /opt/pyxsoft/templates/settings/
Upload File :
Create Path :
Current File : //opt/pyxsoft/templates/settings/instant_protection_settings.tmpl

{% extends "template-base/index.tmpl" %}
{% block HTMLTitle %}{{ HTMLTitle }}{% endblock %}
{% block PageTitle %}{{ PageTitle }}{% endblock %}

{% block head %}
    <style>
        .list-group .list-group-item.active, .nav li.active > a, .nav li.active > a:focus, .nav li.active > a:hover, .popover-primary .popover-title, .popover-primary.popover-colorful, .popover-primary.popover-dark .popover-title, .popover-primary.popover-dark.popover-colorful, .select2-results__option--highlighted[aria-selected], .switcher-primary > input:checked ~ .switcher-indicator{
            background: mintcream;
        }
    </style>
{% endblock %}
{% block contenido %}
    <div class="alertMsg" style="position: fixed; margin-left:30%;"></div>
    <form class="" method="post" id="idForm" action="/settingsinst" style="width: 90%; margin: 0 auto;">
        <fieldset class="form-group">
            <h2>{{Tr(Lang,"settings.instant_settings")}}</h2>
            <div class="container-fluid">
                <div class="row-fluid">
                    <div class="span10">
                        <div class="col-md-8">
                                <div class="row">
                                    <div class="col-md-12">
                                        <div class="col-md-4">
                                            <p>{{Tr(Lang,"settings.enable_instant")}}</p>
                                        </div>
                                        <div class="col-md-3">
                                            <label for="EnableInstant" class="switcher switcher-rounded switcher-info">
                                                {% if configINST.Enabled == true %}
                                                    <input id="EnableInstant" name="EnableInstant" checked type="checkbox">
                                                    <div class="switcher-indicator" style="margin: auto;">
                                                        <div class="switcher-yes">YES</div>
                                                        <div class="switcher-no">NO</div>
                                                    </div>
                                                {% else %}
                                                    <input id="EnableInstant" name="EnableInstant" type="checkbox">
                                                    <div class="switcher-indicator" style="margin: auto;">
                                                        <div class="switcher-yes">YES</div>
                                                        <div class="switcher-no">NO</div>
                                                    </div>
                                                {% endif %}
                                            </label>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <div class="col-md-4">
                                            <p>{{Tr(Lang,"settings.mail_notifications")}}</p>
                                        </div>
                                        <div class="col-md-3">
                                            <label for="MailNotifications" class="switcher switcher-rounded switcher-info">
                                                {% if configINST.MailNotifications == true %}
                                                    <input id="MailNotifications" name="MailNotifications" checked type="checkbox">
                                                    <div class="switcher-indicator" style="margin: auto;">
                                                        <div class="switcher-yes">YES</div>
                                                        <div class="switcher-no">NO</div>
                                                    </div>
                                                {% else %}
                                                    <input id="MailNotifications" name="MailNotifications" type="checkbox">
                                                    <div class="switcher-indicator" style="margin: auto;">
                                                        <div class="switcher-yes">YES</div>
                                                        <div class="switcher-no">NO</div>
                                                    </div>
                                                {% endif %}
                                            </label>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <div class="col-md-3">
                                            <p>{{Tr(Lang,"settings.working_mode")}}</p>
                                        </div>
                                        <div class="col-md-3">
                                            <label for="working_mode" class="switcher switcher-rounded switcher-info" style="padding-left:0px;">
                                                {% if configINST.WorkingMode == 0 %}
                                                    <label class="radio-inline">
                                                        <input name="working_mode" class="working" id="working_mode" value="0" checked type="radio"> Normal
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="working_mode" class="working" id="working_mode" value="1" type="radio"> Light
                                                    </label>
                                                {% else %}
                                                    <label class="radio-inline">
                                                        <input name="working_mode" class="working" id="working_mode" value="0" type="radio"> Normal
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="working_mode" class="working" id="working_mode" value="1" checked type="radio"> Light
                                                    </label>
                                                {% endif %}
                                            </label>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12" id="normalOptions">
                                        <div class="col-md-3">
                                            <p>{{Tr(Lang,"settings.excluded_extensions")}}</p>
                                        </div>
                                        <div class="col-md-5">
                                            <input type="text" id="ExtensionsExcluded" name="ExtensionsExcluded" value="{{ excluded }}" data-role="tagsinput"/>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12" id="lightOptions">
                                        <div class="col-md-3">
                                            <p>{{Tr(Lang,"settings.scan_extensions")}}</p>
                                        </div>
                                        <div class="col-md-5">
                                            <input type="text" id="ExtensionsInclude" name="ExtensionsInclude" value="{{ scan  }}" data-role="tagsinput"/>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <div class="col-md-3">
                                            <p>{{Tr(Lang,"settings.malware_action")}}</p>
                                        </div>
                                        <div class="col-md-5">
                                            <label for="malware_action" class="switcher switcher-rounded switcher-info" style="padding-left:0px;">
                                                {% if configINST.MalwareDetectedAction == "quarantine" %}
                                                    <label class="radio-inline">
                                                        <input name="malware_action" value="quarantine" checked type="radio"> {{Tr(Lang,"settings.send_quarantine")}}
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="malware_action" value="reportonly" type="radio"> {{Tr(Lang,"settings.send_report")}}
                                                    </label>
                                                {% else %}
                                                    <label class="radio-inline">
                                                        <input name="malware_action" value="quarantine" type="radio"> {{Tr(Lang,"settings.send_quarantine")}}
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="malware_action" value="reportonly" checked type="radio"> {{Tr(Lang,"settings.send_report")}}
                                                    </label>
                                                {% endif %}
                                            </label>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <div class="col-md-3">
                                            <p>{{Tr(Lang,"settings.suspicius_action")}}</p>
                                        </div>
                                        <div class="col-md-5">
                                            <label for="suspicius_action" class="switcher switcher-rounded switcher-info" style="padding-left:0px;">
                                                {% if configINST.SuspFileDetectedAction == "reportonly" %}
                                                    <label class="radio-inline">
                                                        <input name="suspicius_action" value="reportonly" type="radio" checked> {{Tr(Lang,"settings.send_report")}}
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="suspicius_action" value="quarantine" style="color:red;" data-toggle="tooltip" title="{{ Tr(Lang,"settings.tip_suspicius") }}" type="radio"> {{Tr(Lang,"settings.send_quarantine")}}
                                                    </label>
                                                {% else %}
                                                    <label class="radio-inline">
                                                        <input name="suspicius_action" value="reportonly" type="radio"> {{Tr(Lang,"settings.send_report")}}
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="suspicius_action" value="quarantine" checked style="color:red;" data-toggle="tooltip" title="{{ Tr(Lang,"settings.tip_suspicius") }}" type="radio"> {{Tr(Lang,"settings.send_quarantine")}}
                                                    </label>
                                                {% endif %}
                                            </label>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <div class="col-md-3">
                                            <p>{{Tr(Lang,"settings.symlink_action")}}</p>
                                        </div>
                                        <div class="col-md-4">
                                            <label for="symlink_action" class="switcher switcher-rounded switcher-info" style="padding-left:0px;">
                                                {% if configINST.SymlinkDetectedAction == "delete" %}
                                                    <label class="radio-inline">
                                                        <input name="symlink_action" value="delete" checked type="radio"> {{Tr(Lang,"settings.delete_symlink")}}
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="symlink_action" value="reportonly" type="radio"> {{Tr(Lang,"settings.send_report")}}
                                                    </label>
                                                {% else %}
                                                    <label class="radio-inline">
                                                        <input name="symlink_action" value="delete" type="radio"> {{Tr(Lang,"settings.delete_symlink")}}
                                                    </label>
                                                    <label class="radio-inline">
                                                        <input name="symlink_action" value="reportonly" checked type="radio"> {{Tr(Lang,"settings.send_report")}}
                                                    </label>
                                                {% endif %}
                                            </label>
                                        </div>
                                    </div>
                                </div>
                        </div>
                    </div>
                    <div class="span2">
                        <div class="row">
                            <div class="col-md-4">
                                <ul class="list-group" style="background: white;">
                                    {% if scanStatus == 1 %} <li data-target="#wizard-example-step1" class="active list-group-item"> {% else %} <li data-target="#wizard-example-step1" class="list-group-item"> {% endif %}
                                        <span class="wizard-step-number">{% if scanStatus == 1 %}<i class="fa fa-check text-success"></i>{% else %}<i class="fas fa-lock"></i>{% endif %}</span>
                                        <span class="wizard-step-complete"><i class="fas fa-lock"></i></span>
                                        <span class="wizard-step-caption" style="color: black;">
                                      {{Tr(Lang,"settings.Starting")}}
                                                <span class="wizard-step-description" style="margin-top: 15%;">{{Tr(Lang,"settings.sub_Starting")}}</span>
                                    </span>
                                    </li>
                                    {% if scanStatus == 3 %} <li data-target="#wizard-example-step2" class="active list-group-item"> {% else %} <li class="list-group-item" data-target="#wizard-example-step2"> {% endif %}
                                        <span class="wizard-step-number">{% if scanStatus == 3 %}<i class="fa fa-check text-success"></i>{% else %}<i class="fas fa-lock"></i>{% endif %}</span>
                                        <span class="wizard-step-complete"><i class="fas fa-lock"></i></span>
                                        <span class="wizard-step-caption" style="color: black;">
                                  {{Tr(Lang,"settings.Working")}}
                                            <span class="wizard-step-description" style="margin-top: 15%;">{{Tr(Lang,"settings.sub_Working")}}</span>
                                </span>
                                    </li>
                                    {% if scanStatus == 0 %} <li data-target="#wizard-example-step3" class="active list-group-item"> {% else %} <li data-target="#wizard-example-step3" class="list-group-item"> {% endif %}
                                        <span class="wizard-step-number">{% if scanStatus == 0 %}<i class="fa fa-check text-success"></i>{% else %}<i class="fas fa-lock"></i>{% endif %}</span>
                                        <span class="wizard-step-complete"><i class="fas fa-lock"></i></span>
                                        <span class="wizard-step-caption" style="color: black;">
                                  {{Tr(Lang,"settings.Stopping")}}
                                            <span class="wizard-step-description" style="margin-top: 15%;">{{Tr(Lang,"settings.sub_Stopping")}}</span>
                                </span>
                                    </li>
                                    {% if scanStatus == 2 %} <li data-target="#wizard-example-step4" class="active list-group-item"> {% else %} <li class="list-group-item" data-target="#wizard-example-step4"> {% endif %}
                                        <span class="wizard-step-number">{% if scanStatus == 2 %}<i class="fa fa-check text-success"></i>{% else %}<i class="fas fa-lock"></i>{% endif %}</span>
                                        <span class="wizard-step-complete"><i class="fas fa-lock"></i></span>
                                        <span class="wizard-step-caption" style="color: black;">
                                  {{Tr(Lang,"settings.Error")}}
                                            <span class="wizard-step-description" style="margin-top: 15%;">{{Tr(Lang,"settings.sub_Error")}}</span>
                                </span>
                                    </li>
                                </ul>
                            </div>
                        </div>
                    </div>
                    <hr>
                    <div class="row">
                        <div class="pull-right">
                            <button type="submit" id="exam" value="submit" class="btn btn-info" onclick="success('{{Tr(Lang,"settings.save_msg")}}')">{{Tr(Lang,"settings.btn_save")}}</button>
                        </div>
                    </div>
                </div>
            </div>
        </fieldset>
    </form>

{% endblock %}
{% block finalScripts %}
    <script>

        $(function() {
            $('#wizard-basic').pxWizard();
        });

        $(".working").click(function(){
            if($(this).attr("value")=="0"){
                $("#normalOptions").show('slow');
                $("#lightOptions").hide('slow');
            }else{
                $("#lightOptions").show('slow');
                $("#normalOptions").hide('slow');
            }
        });

        //$('input[type="radio"]').trigger('click');  // trigger the event

        $("#ExtensionsExcluded").val()
        $("#ExtensionsExcluded").tagsinput('items')
        $("#ExtensionsExcluded").tagsinput({
            confirmKeys: [13, 124]
        });

        $("#ExtensionsInclude").val()
        $("#ExtensionsInclude").tagsinput('items')
        $("#ExtensionsInclude").tagsinput({
            confirmKeys: [13, 124]
        });

        $("#idForm").submit(function(e) {
            var form = $(this);
            var url = form.attr('action');

            $.ajax({
                type: "POST",
                url: url,
                data: form.serialize(), // serializes the form's elements.
                success: function(data)
                {
                    //alert(data); // show response from the php script.
                }
            });

            e.preventDefault(); // avoid to execute the actual submit of the form.
        });

        window.success = function(msg) {
            $.growl({ title: "Success", message: "Settings saved!", style: "notice", size: "large" });
        }
    </script>
{% endblock %}



Zerion Mini Shell 1.0