app.js 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. "use strict";
  2. Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
  3. const common_vendor = require("./common/vendor.js");
  4. const config_globalData = require("./config/globalData.js");
  5. const utils_common = require("./utils/common.js");
  6. const hook_useFrontEndConfigVersion_index = require("./hook/use-front-end-config-version/index.js");
  7. const hook_useFrontEndConfig_index = require("./hook/use-front-end-config/index.js");
  8. const hook_useAppStatus_index = require("./hook/use-app-status/index.js");
  9. const hook_useGetUpdateManager_index = require("./hook/use-get-update-manager/index.js");
  10. const hook_useSmallProgramLogin_index = require("./hook/use-small-program-login/index.js");
  11. const hook_useGetSysAppPageList_index = require("./hook/use-get-sys-app-page-list/index.js");
  12. const hook_usePreserMember_index = require("./hook/use-preser-member/index.js");
  13. if (!Math) {
  14. "./pages/business/tabbar/homePage/homePage.js";
  15. "./pages/business/tabbar/personalCenter/personalCenter.js";
  16. }
  17. let app = null;
  18. const beforeMain = async () => {
  19. utils_common.showLoading();
  20. await hook_useFrontEndConfigVersion_index.useFrontEndConfigVersion();
  21. let has = await hook_useFrontEndConfig_index.useSetFrontEndConfig();
  22. if (has)
  23. return;
  24. await hook_useAppStatus_index.useAppStatus();
  25. utils_common.hideLoading();
  26. if (!app.globalData.logSuccess) {
  27. main();
  28. } else {
  29. if (app.globalData.hasWebsocket) {
  30. connectWebsocket(true);
  31. }
  32. }
  33. };
  34. const main = async function() {
  35. let isUpdateManager = app.globalData.accountInfo.miniProgram.envVersion == "develop" ? false : await hook_useGetUpdateManager_index.useGetUpdateManager();
  36. if (isUpdateManager) {
  37. return;
  38. }
  39. utils_common.showLoading();
  40. app.globalData.smallPro_systemInfo = JSON.stringify(common_vendor.index.getSystemInfoSync());
  41. const resp = await hook_useSmallProgramLogin_index.useSmallProgramLogin(app);
  42. if (resp) {
  43. app.globalData.logSuccess = true;
  44. await hook_useGetSysAppPageList_index.useGetSysAppPageList();
  45. await hook_usePreserMember_index.usePreserMember();
  46. if (common_vendor.index.getStorageSync("frontEndConfigRequest") || utils_common.isEmpty(common_vendor.index.getStorageSync("formConfigList")))
  47. ;
  48. if (common_vendor.index.getStorageSync("frontEndConfigRequest") || utils_common.isEmpty(common_vendor.index.getStorageSync("menuList")))
  49. ;
  50. utils_common.hideLoading();
  51. if (app.globalData.hasWebsocket)
  52. ;
  53. }
  54. };
  55. const _sfc_main = {
  56. globalData: config_globalData.GLOBALDATA,
  57. onLaunch: function(options) {
  58. common_vendor.index.__f__("log", "at App.vue:89", "App Launch");
  59. common_vendor.index.__f__("log", "at App.vue:90", "应用启动路径:", options.path);
  60. app = this.$scope;
  61. app.globalData.accountInfo = common_vendor.index.getAccountInfoSync();
  62. },
  63. onShow: function(options) {
  64. common_vendor.index.__f__("log", "at App.vue:105", "App Show");
  65. common_vendor.index.__f__("log", "at App.vue:106", "应用启动路径:", options.path);
  66. beforeMain();
  67. },
  68. onHide: function() {
  69. common_vendor.index.__f__("log", "at App.vue:112", "App Hide");
  70. }
  71. };
  72. function createApp() {
  73. const app2 = common_vendor.createSSRApp(_sfc_main);
  74. return {
  75. app: app2
  76. };
  77. }
  78. createApp().app.mount("#app");
  79. exports.createApp = createApp;
  80. //# sourceMappingURL=../.sourcemap/mp-alipay/app.js.map