@saltcorn/mobile-app 1.6.0-beta.9 → 1.6.0-rc.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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@saltcorn/mobile-app",
3
3
  "displayName": "Saltcorn mobile app",
4
- "version": "1.6.0-beta.9",
4
+ "version": "1.6.0-rc.2",
5
5
  "description": "Saltcorn mobile app for Android and iOS",
6
6
  "main": "index.js",
7
7
  "scripts": {
@@ -16,7 +16,7 @@
16
16
  },
17
17
  "dependencies": {
18
18
  "universal-router": "9.2.1",
19
- "axios": "0.30.3",
19
+ "axios": "0.32.0",
20
20
  "jwt-decode": "4.0.0",
21
21
  "i18next": "24.2.2",
22
22
  "i18next-sprintf-postprocessor": "0.2.2",
@@ -204,7 +204,7 @@ async function inline_local_submit(e, opts1) {
204
204
  }
205
205
 
206
206
  function saveAndContinueAsync(e, action) {
207
- return new Promise((resolve, reject) => {
207
+ return new Promise((resolve, _reject) => {
208
208
  saveAndContinue(e, action, (x) => resolve(x));
209
209
  });
210
210
  }
@@ -744,7 +744,7 @@ async function clear_state(omit_fields_str, e) {
744
744
  try {
745
745
  showLoadSpinner();
746
746
  const newhref = get_current_state_url(e);
747
- const { path, query, hash } =
747
+ const { path, query } =
748
748
  parent.saltcorn.mobileApp.navigation.splitPathQuery(newhref);
749
749
  let newQuery = "";
750
750
  if (omit_fields_str) {
@@ -763,8 +763,6 @@ async function clear_state(omit_fields_str, e) {
763
763
  }
764
764
  }
765
765
 
766
- let last_route_viewname;
767
-
768
766
  async function view_post(viewnameOrElem, route, data, onDone, sendState) {
769
767
  const viewname =
770
768
  typeof viewnameOrElem === "string"
@@ -772,13 +770,12 @@ async function view_post(viewnameOrElem, route, data, onDone, sendState) {
772
770
  : $(viewnameOrElem)
773
771
  .closest("[data-sc-embed-viewname]")
774
772
  .attr("data-sc-embed-viewname");
775
- last_route_viewname = viewname;
773
+ window.last_route_viewname = viewname;
776
774
  const buildQuery = () => {
777
775
  const query = parent.saltcorn.mobileApp.navigation.currentQuery();
778
776
  return query ? `?${query}` : "";
779
777
  };
780
778
  const mobileConfig = parent.saltcorn.data.state.getState().mobileConfig;
781
- const view = parent.saltcorn.data.models.View.findOne({ name: viewname });
782
779
  try {
783
780
  showLoadSpinner();
784
781
  let respData = undefined;
@@ -1038,3 +1035,38 @@ async function updateMatchingRows(e, viewname) {
1038
1035
  function reload_on_init() {
1039
1036
  console.log("not yet supported");
1040
1037
  }
1038
+
1039
+ window.runUrl = runUrl;
1040
+ window.execNavbarLink = execNavbarLink;
1041
+ window.sc_form_submit_in_progress = sc_form_submit_in_progress;
1042
+ window.ajaxSubmitForm = ajaxSubmitForm;
1043
+ window.inline_local_submit = inline_local_submit;
1044
+ window.saveAndContinueAsync = saveAndContinueAsync;
1045
+ window.publicLogin = publicLogin;
1046
+ window.logout = logout;
1047
+ window.signupFormSubmit = signupFormSubmit;
1048
+ window.loginFormSubmit = loginFormSubmit;
1049
+ window.loginWith = loginWith;
1050
+ window.local_post_btn = local_post_btn;
1051
+ window.stateFormSubmit = stateFormSubmit;
1052
+ window.set_state_field = set_state_field;
1053
+ window.unset_state_field = unset_state_field;
1054
+ window.sortby = sortby;
1055
+ window.gopage = gopage;
1056
+ window.ajax_modal = ajax_modal;
1057
+ window.closeModal = closeModal;
1058
+ window.ajax_post = ajax_post;
1059
+ window.ajax_post_json = ajax_post_json;
1060
+ window.make_unique_field = make_unique_field;
1061
+ window.openFile = openFile;
1062
+ window.openInAppBrowser = openInAppBrowser;
1063
+ window.select_id = select_id;
1064
+ window.check_state_field = check_state_field;
1065
+ window.clear_state = clear_state;
1066
+ window.view_post = view_post;
1067
+ window.switchNetworkMode = switchNetworkMode;
1068
+ window.callSync = callSync;
1069
+ window.deleteOfflineDataClicked = deleteOfflineDataClicked;
1070
+ window.getPicture = getPicture;
1071
+ window.updateMatchingRows = updateMatchingRows;
1072
+ window.reload_on_init = reload_on_init;