sinatra-hexacta 1.6.2 → 1.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 78f1773a5ead7859db82845bc336a8b7604966c2615040b999d26fe68bdf7890
|
4
|
+
data.tar.gz: 2fb2dcc0b7ffc764ae6f0144675211e18b16b4d8845e308546b4b137329cbff0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 394106abc4d70aee85c3a06c661f7516b5ecce020ff92b30de64e16c734d95a7fbdb1a593a7dd0d3992d6f001c05875c0c4af9a65749c761cab57d820cab7739
|
7
|
+
data.tar.gz: 52714579e8106c1c0000e52e4a701d4f9b1ee685d2820f800ed5b3646783b01aa2925326639775146998aca047f8a853467d02b92cad711511eda69cef3aefa6
|
@@ -30,31 +30,35 @@ function update_html_elements() {
|
|
30
30
|
var datastring = $(this).serialize();
|
31
31
|
var url = $(this).attr('action');
|
32
32
|
$(this).closest('.modal').modal('hide');
|
33
|
-
|
34
|
-
|
33
|
+
//$('body').append('<div aria-labelledby="loading" class="modal bounceIn animated" id="loading-modal" role="dialog" tabindex="-1" data-backdrop="static" data-keyboard="false"><div class="modal-dialog modal-sm" style="width:150px !Important;"><div class="modal-content"><div class="modal-body p-20 text-center"><div class="preloader pl-lg"><svg class="pl-circular" viewBox="25 25 50 50"><circle class="plc-path" cx="50" cy="50" r="20"></circle></svg></div></div><div class="modal-footer" style="text-align: center !Important;"><div class="btn btn-link waves-effect c-gray">Espere...</div></div></div></div></div>');
|
34
|
+
//$('#loading-modal').modal('show');
|
35
35
|
$.ajax({
|
36
36
|
|
37
37
|
type: "POST",
|
38
38
|
url: url,
|
39
39
|
data: datastring,
|
40
40
|
success: function(data) {
|
41
|
-
|
42
|
-
|
41
|
+
//$('#loading-modal').modal('hide');
|
42
|
+
//$('#loading-modal').remove();
|
43
43
|
$('body').append('<div aria-labelledby="ok" class="modal bounceIn animated" id="ok-modal" role="dialog" tabindex="-1"><div class="modal-dialog modal-sm" style="width:150px !Important;"><div class="modal-content"><div class="modal-body p-20 text-center"><i class="zmdi zmdi-hc-3x zmdi-check-circle c-green"></i></div><div class="modal-footer" style="text-align: center !Important;"><div class="btn btn-link waves-effect c-gray">¡Listo!</div></div></div></div></div>');
|
44
44
|
$('#ok-modal').modal('show');
|
45
45
|
setTimeout(function () {
|
46
46
|
location.reload();
|
47
47
|
}, 1000)
|
48
48
|
},
|
49
|
-
error: function(
|
50
|
-
|
51
|
-
|
52
|
-
$('
|
49
|
+
error: function(error) {
|
50
|
+
//$('#loading-modal').modal('hide');
|
51
|
+
//$('#loading-modal').remove();
|
52
|
+
if ($('#error-modal')[0]) {
|
53
|
+
$('#error-modal').remove();
|
54
|
+
}
|
55
|
+
$('body').append('<div aria-labelledby="error" class="modal bounceIn animated" id="error-modal" role="dialog" tabindex="-1"><div class="modal-dialog modal-sm" style="min-width:150px !Important;"><div class="modal-content"><div class="modal-body p-20 text-center"><i class="zmdi zmdi-hc-3x zmdi-alert-polygon c-red"></i></div><div class="modal-footer" style="text-align: center !Important;"><div class="f-900 c-gray">' + error.responseText + '</div></div></div></div></div>');
|
53
56
|
$('#error-modal').modal('show');
|
54
57
|
}
|
55
58
|
});
|
56
59
|
});
|
57
60
|
|
61
|
+
|
58
62
|
// Fix modal inside other components
|
59
63
|
$('.modal').appendTo("body");
|
60
64
|
|
@@ -548,13 +552,15 @@ if (elementToObserve != null) {
|
|
548
552
|
|
549
553
|
|
550
554
|
function start_load() {
|
551
|
-
if (!$("#
|
552
|
-
$(
|
555
|
+
if (!$("#loading-modal")[0]) {
|
556
|
+
$('body').append('<div aria-labelledby="loading" class="modal bounceIn animated" id="loading-modal" role="dialog" tabindex="-1" data-backdrop="static" data-keyboard="false"><div class="modal-dialog modal-sm" style="width:150px !Important;"><div class="modal-content"><div class="modal-body p-20 text-center"><div class="preloader pl-lg"><svg class="pl-circular" viewBox="25 25 50 50"><circle class="plc-path" cx="50" cy="50" r="20"></circle></svg></div></div><div class="modal-footer" style="text-align: center !Important;"><div class="btn btn-link waves-effect c-gray">Espere...</div></div></div></div></div>');
|
557
|
+
$('#loading-modal').modal('show');
|
553
558
|
}
|
554
559
|
}
|
555
560
|
|
556
561
|
function stop_load() {
|
557
|
-
$(
|
562
|
+
$('#loading-modal').modal('hide');
|
563
|
+
$('#loading-modal').remove();
|
558
564
|
}
|
559
565
|
|
560
566
|
|
@@ -3,11 +3,13 @@ var hide_results_timeout = false;
|
|
3
3
|
class Finder {
|
4
4
|
|
5
5
|
static find(query){
|
6
|
+
$('body').append('<div id="loading-modal"></div>'); //Compliant with automatic loader
|
6
7
|
$.ajax({
|
7
8
|
url: "/find",
|
8
9
|
type: 'GET',
|
9
10
|
data: { query: query }
|
10
11
|
}).done(function(result) {
|
12
|
+
$('#loading-modal').remove(); //Compliant with automatic loader
|
11
13
|
$("#header .results").html(result);
|
12
14
|
|
13
15
|
$('#header .results *').click(function() {
|
@@ -18,11 +20,13 @@ class Finder {
|
|
18
20
|
}
|
19
21
|
|
20
22
|
static do_find(url,query,html){
|
23
|
+
$('body').append('<div id="loading-modal"></div>'); //Compliant with automatic loader
|
21
24
|
$.ajax({
|
22
25
|
url: url,
|
23
26
|
type: 'GET',
|
24
27
|
data: { query: query }
|
25
28
|
}).done(function(result) {
|
29
|
+
$('#loading-modal').remove(); //Compliant with automatic loader
|
26
30
|
$(html).html(result);
|
27
31
|
});
|
28
32
|
}
|
@@ -82,6 +86,7 @@ $(document).ready(function(){
|
|
82
86
|
if (last_query != $.trim($('#header input').val())) {
|
83
87
|
last_query = $.trim($('#header input').val());
|
84
88
|
if (last_query.length > 2) {
|
89
|
+
$('body').append('<div id="loading-modal"></div>'); //Compliant with automatic loader
|
85
90
|
Finder.find(last_query);
|
86
91
|
}
|
87
92
|
}
|
@@ -1,15 +1,16 @@
|
|
1
1
|
class View {
|
2
2
|
|
3
|
-
static get(url,
|
4
|
-
$(destination).html('<div class="text-center" style="padding:100px;"><div class="preloader pls-teal bgm-none"><svg class="pl-circular" viewBox="25 25 50 50"><circle class="plc-path" cx="50" cy="50" r="20"></circle></svg></div><h5>Cargando...</h5></div>');
|
3
|
+
static get(url,data,destination){
|
5
4
|
$.ajax({
|
6
5
|
url: url,
|
7
6
|
type: 'GET',
|
8
|
-
data:
|
7
|
+
data: data,
|
9
8
|
}).done(function(result) {
|
10
9
|
$(destination).html(result);
|
10
|
+
$('.modal').appendTo("body");
|
11
11
|
}).error(function(result) {
|
12
12
|
$(destination).html('<div class="lv-item p-20 bgm-red m-b-5 animated fadeIn"><div class="media"><div class="pull-left"><i class="zmdi zmdi-hc-3x zmdi-alert-octagon c-white"></i></div><div class="media-body"><div class="lv-title c-white">Algo salió mal</div><small class="lv-small c-white">Los administradores acaban de ser informados de este error, ni bien tengan una solución se te notificará. Disculpá las molestias.</small></div></div></div>');
|
13
13
|
});
|
14
14
|
}
|
15
|
-
}
|
15
|
+
}
|
16
|
+
|
@@ -8,6 +8,7 @@ script src="/sinatra-hexacta/vendors/chartist/chartist-plugin-legend.js"
|
|
8
8
|
script src="/sinatra-hexacta/js/app.js?ver=#{settings.version}" type='text/javascript'
|
9
9
|
script src="/sinatra-hexacta/js/finder.js?ver=#{settings.version}" type='text/javascript'
|
10
10
|
script src="/sinatra-hexacta/js/process.js?ver=#{settings.version}" type='text/javascript'
|
11
|
+
script src="/sinatra-hexacta/js/view.js?ver=#{settings.version}" type='text/javascript'
|
11
12
|
|
12
13
|
javascript:
|
13
14
|
const storeScroll = () => {
|