@saltcorn/server 0.9.5-beta.16 → 0.9.5-beta.17
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/package.json +9 -9
- package/public/saltcorn-common.js +23 -0
- package/public/saltcorn.js +1 -0
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.17",
|
|
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.17",
|
|
11
|
+
"@saltcorn/builder": "0.9.5-beta.17",
|
|
12
|
+
"@saltcorn/data": "0.9.5-beta.17",
|
|
13
|
+
"@saltcorn/admin-models": "0.9.5-beta.17",
|
|
14
|
+
"@saltcorn/filemanager": "0.9.5-beta.17",
|
|
15
|
+
"@saltcorn/markup": "0.9.5-beta.17",
|
|
16
|
+
"@saltcorn/plugins-loader": "0.9.5-beta.17",
|
|
17
|
+
"@saltcorn/sbadmin2": "0.9.5-beta.17",
|
|
18
18
|
"@socket.io/cluster-adapter": "^0.2.1",
|
|
19
19
|
"@socket.io/sticky": "^1.0.1",
|
|
20
20
|
"adm-zip": "0.5.10",
|
|
@@ -1206,6 +1206,7 @@ async function common_done(res, viewname, isWeb = true) {
|
|
|
1206
1206
|
form.append(
|
|
1207
1207
|
`<input type="hidden" name="id" value="${res.set_fields[k]}">`
|
|
1208
1208
|
);
|
|
1209
|
+
reloadEmbeddedEditOwnViews(form, res.set_fields[k]);
|
|
1209
1210
|
return;
|
|
1210
1211
|
}
|
|
1211
1212
|
if (input.attr("type") === "checkbox")
|
|
@@ -1270,6 +1271,28 @@ async function common_done(res, viewname, isWeb = true) {
|
|
|
1270
1271
|
}
|
|
1271
1272
|
}
|
|
1272
1273
|
|
|
1274
|
+
function reloadEmbeddedEditOwnViews(form, id) {
|
|
1275
|
+
form.find("div[sc-load-on-assign-id]").each(function () {
|
|
1276
|
+
const $e = $(this);
|
|
1277
|
+
const viewname = $e.attr("sc-load-on-assign-id");
|
|
1278
|
+
const newUrl = `/view/${viewname}?id=${id}`;
|
|
1279
|
+
$.ajax(newUrl, {
|
|
1280
|
+
headers: {
|
|
1281
|
+
pjaxpageload: "true",
|
|
1282
|
+
localizedstate: "true", //no admin bar
|
|
1283
|
+
},
|
|
1284
|
+
success: function (res, textStatus, request) {
|
|
1285
|
+
const newE = `<div class="d-inline" data-sc-embed-viewname="${viewname}" data-sc-view-source="${newUrl}">${res}</div>`;
|
|
1286
|
+
$e.replaceWith(newE);
|
|
1287
|
+
initialize_page();
|
|
1288
|
+
},
|
|
1289
|
+
error: function (res) {
|
|
1290
|
+
notifyAlert({ type: "danger", text: res.responseText });
|
|
1291
|
+
},
|
|
1292
|
+
});
|
|
1293
|
+
});
|
|
1294
|
+
}
|
|
1295
|
+
|
|
1273
1296
|
const repeaterCopyValuesToForm = (form, editor, noTriggerChange) => {
|
|
1274
1297
|
const vs = JSON.parse(editor.getString());
|
|
1275
1298
|
|
package/public/saltcorn.js
CHANGED