You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

204 lines
12 KiB

4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
  1. "use strict";
  2. const common_vendor = require("../../../common/vendor.js");
  3. const config_site_config = require("../../../config/site.config.js");
  4. const config_api = require("../../../config/api.js");
  5. const store_index = require("../../../store/index.js");
  6. require("../../../uni_modules/uview-plus/index.js");
  7. require("../../../uni_modules/uview-plus/libs/mixin/mixin.js");
  8. require("../../../uni_modules/uview-plus/libs/vue.js");
  9. require("../../../uni_modules/uview-plus/libs/function/index.js");
  10. require("../../../uni_modules/uview-plus/libs/function/test.js");
  11. require("../../../uni_modules/uview-plus/libs/function/digit.js");
  12. require("../../../uni_modules/uview-plus/libs/config/config.js");
  13. require("../../../uni_modules/uview-plus/libs/util/route.js");
  14. require("../../../uni_modules/uview-plus/libs/mixin/mpMixin.js");
  15. require("../../../uni_modules/uview-plus/libs/luch-request/core/Request.js");
  16. require("../../../uni_modules/uview-plus/libs/luch-request/core/dispatchRequest.js");
  17. require("../../../uni_modules/uview-plus/libs/luch-request/adapters/index.js");
  18. require("../../../uni_modules/uview-plus/libs/luch-request/helpers/buildURL.js");
  19. require("../../../uni_modules/uview-plus/libs/luch-request/utils.js");
  20. require("../../../uni_modules/uview-plus/libs/luch-request/core/buildFullPath.js");
  21. require("../../../uni_modules/uview-plus/libs/luch-request/helpers/isAbsoluteURL.js");
  22. require("../../../uni_modules/uview-plus/libs/luch-request/helpers/combineURLs.js");
  23. require("../../../uni_modules/uview-plus/libs/luch-request/core/settle.js");
  24. require("../../../uni_modules/uview-plus/libs/luch-request/core/InterceptorManager.js");
  25. require("../../../uni_modules/uview-plus/libs/luch-request/core/mergeConfig.js");
  26. require("../../../uni_modules/uview-plus/libs/luch-request/core/defaults.js");
  27. require("../../../uni_modules/uview-plus/libs/luch-request/utils/clone.js");
  28. require("../../../uni_modules/uview-plus/libs/function/colorGradient.js");
  29. require("../../../uni_modules/uview-plus/libs/function/debounce.js");
  30. require("../../../uni_modules/uview-plus/libs/function/throttle.js");
  31. require("../../../uni_modules/uview-plus/libs/config/props.js");
  32. require("../../../uni_modules/uview-plus/libs/config/props/actionSheet.js");
  33. require("../../../uni_modules/uview-plus/libs/config/props/album.js");
  34. require("../../../uni_modules/uview-plus/libs/config/props/alert.js");
  35. require("../../../uni_modules/uview-plus/libs/config/props/avatar.js");
  36. require("../../../uni_modules/uview-plus/libs/config/props/avatarGroup.js");
  37. require("../../../uni_modules/uview-plus/libs/config/props/backtop.js");
  38. require("../../../uni_modules/uview-plus/libs/config/props/badge.js");
  39. require("../../../uni_modules/uview-plus/libs/config/props/button.js");
  40. require("../../../uni_modules/uview-plus/libs/config/props/calendar.js");
  41. require("../../../uni_modules/uview-plus/libs/config/props/carKeyboard.js");
  42. require("../../../uni_modules/uview-plus/libs/config/props/cell.js");
  43. require("../../../uni_modules/uview-plus/libs/config/props/cellGroup.js");
  44. require("../../../uni_modules/uview-plus/libs/config/props/checkbox.js");
  45. require("../../../uni_modules/uview-plus/libs/config/props/checkboxGroup.js");
  46. require("../../../uni_modules/uview-plus/libs/config/props/circleProgress.js");
  47. require("../../../uni_modules/uview-plus/libs/config/props/code.js");
  48. require("../../../uni_modules/uview-plus/libs/config/props/codeInput.js");
  49. require("../../../uni_modules/uview-plus/libs/config/props/col.js");
  50. require("../../../uni_modules/uview-plus/libs/config/props/collapse.js");
  51. require("../../../uni_modules/uview-plus/libs/config/props/collapseItem.js");
  52. require("../../../uni_modules/uview-plus/libs/config/props/columnNotice.js");
  53. require("../../../uni_modules/uview-plus/libs/config/props/countDown.js");
  54. require("../../../uni_modules/uview-plus/libs/config/props/countTo.js");
  55. require("../../../uni_modules/uview-plus/libs/config/props/datetimePicker.js");
  56. require("../../../uni_modules/uview-plus/libs/config/props/divider.js");
  57. require("../../../uni_modules/uview-plus/libs/config/props/empty.js");
  58. require("../../../uni_modules/uview-plus/libs/config/props/form.js");
  59. require("../../../uni_modules/uview-plus/libs/config/props/formItem.js");
  60. require("../../../uni_modules/uview-plus/libs/config/props/gap.js");
  61. require("../../../uni_modules/uview-plus/libs/config/props/grid.js");
  62. require("../../../uni_modules/uview-plus/libs/config/props/gridItem.js");
  63. require("../../../uni_modules/uview-plus/libs/config/props/icon.js");
  64. require("../../../uni_modules/uview-plus/libs/config/props/image.js");
  65. require("../../../uni_modules/uview-plus/libs/config/props/indexAnchor.js");
  66. require("../../../uni_modules/uview-plus/libs/config/props/indexList.js");
  67. require("../../../uni_modules/uview-plus/libs/config/props/input.js");
  68. require("../../../uni_modules/uview-plus/libs/config/props/keyboard.js");
  69. require("../../../uni_modules/uview-plus/libs/config/props/line.js");
  70. require("../../../uni_modules/uview-plus/libs/config/props/lineProgress.js");
  71. require("../../../uni_modules/uview-plus/libs/config/props/link.js");
  72. require("../../../uni_modules/uview-plus/libs/config/props/list.js");
  73. require("../../../uni_modules/uview-plus/libs/config/props/listItem.js");
  74. require("../../../uni_modules/uview-plus/libs/config/props/loadingIcon.js");
  75. require("../../../uni_modules/uview-plus/libs/config/props/loadingPage.js");
  76. require("../../../uni_modules/uview-plus/libs/config/props/loadmore.js");
  77. require("../../../uni_modules/uview-plus/libs/config/props/modal.js");
  78. require("../../../uni_modules/uview-plus/libs/config/props/navbar.js");
  79. require("../../../uni_modules/uview-plus/libs/config/color.js");
  80. require("../../../uni_modules/uview-plus/libs/config/props/noNetwork.js");
  81. require("../../../uni_modules/uview-plus/libs/config/props/noticeBar.js");
  82. require("../../../uni_modules/uview-plus/libs/config/props/notify.js");
  83. require("../../../uni_modules/uview-plus/libs/config/props/numberBox.js");
  84. require("../../../uni_modules/uview-plus/libs/config/props/numberKeyboard.js");
  85. require("../../../uni_modules/uview-plus/libs/config/props/overlay.js");
  86. require("../../../uni_modules/uview-plus/libs/config/props/parse.js");
  87. require("../../../uni_modules/uview-plus/libs/config/props/picker.js");
  88. require("../../../uni_modules/uview-plus/libs/config/props/popup.js");
  89. require("../../../uni_modules/uview-plus/libs/config/props/radio.js");
  90. require("../../../uni_modules/uview-plus/libs/config/props/radioGroup.js");
  91. require("../../../uni_modules/uview-plus/libs/config/props/rate.js");
  92. require("../../../uni_modules/uview-plus/libs/config/props/readMore.js");
  93. require("../../../uni_modules/uview-plus/libs/config/props/row.js");
  94. require("../../../uni_modules/uview-plus/libs/config/props/rowNotice.js");
  95. require("../../../uni_modules/uview-plus/libs/config/props/scrollList.js");
  96. require("../../../uni_modules/uview-plus/libs/config/props/search.js");
  97. require("../../../uni_modules/uview-plus/libs/config/props/section.js");
  98. require("../../../uni_modules/uview-plus/libs/config/props/skeleton.js");
  99. require("../../../uni_modules/uview-plus/libs/config/props/slider.js");
  100. require("../../../uni_modules/uview-plus/libs/config/props/statusBar.js");
  101. require("../../../uni_modules/uview-plus/libs/config/props/steps.js");
  102. require("../../../uni_modules/uview-plus/libs/config/props/stepsItem.js");
  103. require("../../../uni_modules/uview-plus/libs/config/props/sticky.js");
  104. require("../../../uni_modules/uview-plus/libs/config/props/subsection.js");
  105. require("../../../uni_modules/uview-plus/libs/config/props/swipeAction.js");
  106. require("../../../uni_modules/uview-plus/libs/config/props/swipeActionItem.js");
  107. require("../../../uni_modules/uview-plus/libs/config/props/swiper.js");
  108. require("../../../uni_modules/uview-plus/libs/config/props/swipterIndicator.js");
  109. require("../../../uni_modules/uview-plus/libs/config/props/switch.js");
  110. require("../../../uni_modules/uview-plus/libs/config/props/tabbar.js");
  111. require("../../../uni_modules/uview-plus/libs/config/props/tabbarItem.js");
  112. require("../../../uni_modules/uview-plus/libs/config/props/tabs.js");
  113. require("../../../uni_modules/uview-plus/libs/config/props/tag.js");
  114. require("../../../uni_modules/uview-plus/libs/config/props/text.js");
  115. require("../../../uni_modules/uview-plus/libs/config/props/textarea.js");
  116. require("../../../uni_modules/uview-plus/libs/config/props/toast.js");
  117. require("../../../uni_modules/uview-plus/libs/config/props/toolbar.js");
  118. require("../../../uni_modules/uview-plus/libs/config/props/tooltip.js");
  119. require("../../../uni_modules/uview-plus/libs/config/props/transition.js");
  120. require("../../../uni_modules/uview-plus/libs/config/props/upload.js");
  121. require("../../../uni_modules/uview-plus/libs/config/zIndex.js");
  122. require("../../../uni_modules/uview-plus/libs/function/platform.js");
  123. if (!Array) {
  124. const _component_avabtnBox = common_vendor.resolveComponent("avabtnBox");
  125. const _easycom_u_icon2 = common_vendor.resolveComponent("u-icon");
  126. (_component_avabtnBox + _easycom_u_icon2)();
  127. }
  128. const _easycom_u_icon = () => "../../../uni_modules/uview-plus/components/u-icon/u-icon.js";
  129. if (!Math) {
  130. _easycom_u_icon();
  131. }
  132. const _sfc_main = {
  133. __name: "mine",
  134. setup(__props) {
  135. const { imgUrl } = config_site_config.obj;
  136. const topBgUrl = imgUrl + "minebg.png";
  137. const counterStore = store_index.userStore();
  138. const configList = common_vendor.ref([
  139. { text: "用户协议", url: "/pages/subPage/privacyAgreement/privacyAgreement?type=1" },
  140. { text: "隐私政策", url: "/pages/subPage/privacyAgreement/privacyAgreement?type=2" }
  141. ]);
  142. function logOutFn() {
  143. common_vendor.index.showModal({
  144. content: "确定要退出登录吗?",
  145. success: async function(res) {
  146. if (res.confirm) {
  147. await config_api.logOut();
  148. counterStore.goLogin();
  149. } else if (res.cancel) {
  150. console.log("用户点击取消");
  151. }
  152. }
  153. });
  154. }
  155. async function getUserInfoFn() {
  156. const { data: res } = await config_api.getUserInfo();
  157. counterStore.upDateUseInfo("name", res.userName);
  158. counterStore.upDateUseInfo("userPhone", res.userPhone);
  159. console.log(res);
  160. }
  161. common_vendor.onShow(() => {
  162. counterStore.upDateUseInfo("name", "");
  163. if (counterStore.token && !counterStore.userInfo.name) {
  164. getUserInfoFn();
  165. }
  166. });
  167. return (_ctx, _cache) => {
  168. return common_vendor.e({
  169. a: _ctx.avaUrl
  170. }, _ctx.avaUrl ? {
  171. b: _ctx.avaUrl
  172. } : {}, {
  173. c: common_vendor.unref(counterStore).token
  174. }, common_vendor.unref(counterStore).token ? {
  175. d: common_vendor.t(common_vendor.unref(counterStore).userInfo.name),
  176. e: common_vendor.t(common_vendor.unref(counterStore).userInfo.userPhone)
  177. } : {
  178. f: common_vendor.o(($event) => _ctx.$goPage("/pages/subPage/login/login"))
  179. }, {
  180. g: common_vendor.f(configList.value, (item, index, i0) => {
  181. return {
  182. a: common_vendor.t(item.text),
  183. b: "23ed4277-1-" + i0,
  184. c: index,
  185. d: common_vendor.o(($event) => _ctx.$goPage(item.url), index)
  186. };
  187. }),
  188. h: common_vendor.p({
  189. name: "arrow-right"
  190. }),
  191. i: common_vendor.p({
  192. name: "arrow-right"
  193. }),
  194. j: common_vendor.unref(counterStore).token
  195. }, common_vendor.unref(counterStore).token ? {
  196. k: common_vendor.o(logOutFn)
  197. } : {}, {
  198. l: "url(" + topBgUrl + ") #F5F5F5 no-repeat"
  199. });
  200. };
  201. }
  202. };
  203. const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-23ed4277"], ["__file", "D:/work/xinjiangMiniProgram/pages/tabbar/mine/mine.vue"]]);
  204. wx.createPage(MiniProgramPage);