@saltcorn/markup
Advanced tools
Comparing version 0.7.2 to 0.7.3-beta.0
@@ -368,8 +368,12 @@ "use strict"; | ||
if (action_url) { | ||
const dest = (configuration && configuration.after_delete_url) || "/"; | ||
const dest = configuration && configuration.after_delete_url; | ||
if (isNode && !form.req?.smr) { | ||
return mkBtn(`onClick="${confirmStr}ajax_post('${action_url}', {success:()=>window.location.href='${dest}'})" type="button"`); | ||
return mkBtn(`onClick="${confirmStr}ajax_post('${action_url}', {success:()=>{${form.req?.xhr ? `close_saltcorn_modal();` : ""}${dest | ||
? `window.location.href='${dest}';` | ||
: form.req?.xhr | ||
? `location.reload();` | ||
: `history.back();`}}})" type="button"`); | ||
} | ||
else { | ||
return mkBtn(`onClick="${confirmStr}local_post('${action_url}', {after_delete_url:'${dest}'})" type="button"`); | ||
return mkBtn(`onClick="${confirmStr}local_post('${action_url}', {after_delete_url:'${dest || "/"}'})" type="button"`); | ||
} | ||
@@ -383,2 +387,5 @@ } | ||
} | ||
if (action_name === "Cancel") { | ||
return mkBtn(`onClick="${confirmStr}cancel_form($(this).closest('form'))" type="button"`); | ||
} | ||
if (action_name === "GoBack") { | ||
@@ -385,0 +392,0 @@ const isWeb = isNode && !form.req?.smr; |
{ | ||
"name": "@saltcorn/markup", | ||
"version": "0.7.2", | ||
"version": "0.7.3-beta.0", | ||
"description": "Markup for Saltcorn, open-source no-code platform", | ||
@@ -36,3 +36,3 @@ "homepage": "https://saltcorn.com", | ||
"devDependencies": { | ||
"@saltcorn/types": "0.7.2", | ||
"@saltcorn/types": "0.7.3-beta.0", | ||
"@types/escape-html": "^1.0.1", | ||
@@ -39,0 +39,0 @@ "@types/jest": "^27.0.3", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
236042
2568