@saltcorn/server 0.9.5-beta.20 → 0.9.5-beta.22
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.
- package/locales/en.json +2 -1
- package/package.json +9 -9
- package/public/saltcorn-common.js +34 -2
- package/s3storage.js +1 -0
package/locales/en.json
CHANGED
|
@@ -1413,5 +1413,6 @@
|
|
|
1413
1413
|
"Retain a local backup copy in this directory (optional)": "Retain a local backup copy in this directory (optional)",
|
|
1414
1414
|
"Do not wrap response in a success object": "Do not wrap response in a success object",
|
|
1415
1415
|
"Use table description instead of name as header": "Use table description instead of name as header",
|
|
1416
|
-
"Description header": "Description header"
|
|
1416
|
+
"Description header": "Description header",
|
|
1417
|
+
"Lazy load views": "Lazy load views"
|
|
1417
1418
|
}
|
package/package.json
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@saltcorn/server",
|
|
3
|
-
"version": "0.9.5-beta.
|
|
3
|
+
"version": "0.9.5-beta.22",
|
|
4
4
|
"description": "Server app for Saltcorn, open-source no-code platform",
|
|
5
5
|
"homepage": "https://saltcorn.com",
|
|
6
6
|
"main": "index.js",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@aws-sdk/client-s3": "^3.451.0",
|
|
10
|
-
"@saltcorn/base-plugin": "0.9.5-beta.
|
|
11
|
-
"@saltcorn/builder": "0.9.5-beta.
|
|
12
|
-
"@saltcorn/data": "0.9.5-beta.
|
|
13
|
-
"@saltcorn/admin-models": "0.9.5-beta.
|
|
14
|
-
"@saltcorn/filemanager": "0.9.5-beta.
|
|
15
|
-
"@saltcorn/markup": "0.9.5-beta.
|
|
16
|
-
"@saltcorn/plugins-loader": "0.9.5-beta.
|
|
17
|
-
"@saltcorn/sbadmin2": "0.9.5-beta.
|
|
10
|
+
"@saltcorn/base-plugin": "0.9.5-beta.22",
|
|
11
|
+
"@saltcorn/builder": "0.9.5-beta.22",
|
|
12
|
+
"@saltcorn/data": "0.9.5-beta.22",
|
|
13
|
+
"@saltcorn/admin-models": "0.9.5-beta.22",
|
|
14
|
+
"@saltcorn/filemanager": "0.9.5-beta.22",
|
|
15
|
+
"@saltcorn/markup": "0.9.5-beta.22",
|
|
16
|
+
"@saltcorn/plugins-loader": "0.9.5-beta.22",
|
|
17
|
+
"@saltcorn/sbadmin2": "0.9.5-beta.22",
|
|
18
18
|
"@socket.io/cluster-adapter": "^0.2.1",
|
|
19
19
|
"@socket.io/sticky": "^1.0.1",
|
|
20
20
|
"adm-zip": "0.5.10",
|
|
@@ -37,6 +37,13 @@ function init_bs5_dropdowns() {
|
|
|
37
37
|
}
|
|
38
38
|
);
|
|
39
39
|
}
|
|
40
|
+
|
|
41
|
+
function reset_nearest_form(that) {
|
|
42
|
+
const form = $(that).closest("form");
|
|
43
|
+
form.trigger("reset");
|
|
44
|
+
form.find("select").trigger("change");
|
|
45
|
+
}
|
|
46
|
+
|
|
40
47
|
function add_repeater(nm) {
|
|
41
48
|
var es = $("div.form-repeat.repeat-" + nm);
|
|
42
49
|
var e = es.first();
|
|
@@ -447,8 +454,12 @@ function get_form_record(e_in, select_labels) {
|
|
|
447
454
|
} else rec[name] = $this.val();
|
|
448
455
|
//postprocess
|
|
449
456
|
if ($this.attr("data-postprocess")) {
|
|
450
|
-
const f = new Function(
|
|
451
|
-
|
|
457
|
+
const f = new Function(
|
|
458
|
+
"it",
|
|
459
|
+
"$e",
|
|
460
|
+
"return " + $this.attr("data-postprocess")
|
|
461
|
+
);
|
|
462
|
+
rec[name] = f(rec[name], $this);
|
|
452
463
|
}
|
|
453
464
|
});
|
|
454
465
|
return rec;
|
|
@@ -915,6 +926,27 @@ function initialize_page() {
|
|
|
915
926
|
.find(".show[rendered='server-side'][type='success']")
|
|
916
927
|
.removeClass("show");
|
|
917
928
|
}, 5000);
|
|
929
|
+
$(".lazy-accoordion").on("show.bs.collapse", function (e) {
|
|
930
|
+
const $e = $(e.target).find("[data-sc-view-source]");
|
|
931
|
+
if ($.trim($e.html()) == "") {
|
|
932
|
+
const url = $e.attr("data-sc-view-source");
|
|
933
|
+
$e.html("Loading...");
|
|
934
|
+
$.ajax(url, {
|
|
935
|
+
headers: {
|
|
936
|
+
pjaxpageload: "true",
|
|
937
|
+
localizedstate: "true", //no admin bar
|
|
938
|
+
},
|
|
939
|
+
success: function (res, textStatus, request) {
|
|
940
|
+
$e.html(res);
|
|
941
|
+
initialize_page();
|
|
942
|
+
},
|
|
943
|
+
error: function (res) {
|
|
944
|
+
notifyAlert({ type: "danger", text: res.responseText });
|
|
945
|
+
if ($e.html() === "Loading...") $e.html("");
|
|
946
|
+
},
|
|
947
|
+
});
|
|
948
|
+
}
|
|
949
|
+
});
|
|
918
950
|
}
|
|
919
951
|
|
|
920
952
|
$(initialize_page);
|