s-menu-tools.js 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145
  1. "use strict";
  2. const common_vendor = require("../../../common/vendor.js");
  3. const sheep_index = require("../../index.js");
  4. const sheep_hooks_useModal = require("../../hooks/useModal.js");
  5. require("../../api/index.js");
  6. require("../../api/distri/score.js");
  7. require("../../request/index.js");
  8. require("../../config/index.js");
  9. require("../../store/index.js");
  10. require("../../store/app.js");
  11. require("../../api/promotion/diy.js");
  12. require("../../platform/index.js");
  13. require("../../platform/provider/wechat/index.js");
  14. require("../../platform/provider/wechat/miniProgram.js");
  15. require("../../api/member/auth.js");
  16. require("../../api/member/social.js");
  17. require("../../api/member/user.js");
  18. require("../../platform/provider/apple/index.js");
  19. require("../../platform/share.js");
  20. require("../../router/index.js");
  21. require("../../helper/throttle.js");
  22. require("../../url/index.js");
  23. require("../../platform/pay.js");
  24. require("../../helper/index.js");
  25. require("../../helper/test.js");
  26. require("../../helper/digit.js");
  27. require("../../api/pay/order.js");
  28. require("../../store/user.js");
  29. require("../../store/cart.js");
  30. require("../../api/trade/cart.js");
  31. require("../../api/pay/wallet.js");
  32. require("../../api/trade/order.js");
  33. require("../../api/promotion/coupon.js");
  34. require("../../store/sys.js");
  35. require("../../store/modal.js");
  36. require("../../api/distri/share.js");
  37. require("../../api/distri/team.js");
  38. require("../../api/infra/file.js");
  39. require("../../api/member/address.js");
  40. require("../../api/member/point.js");
  41. require("../../api/member/signin.js");
  42. require("../../api/migration/app.js");
  43. require("../../api/migration/chat.js");
  44. require("../../api/migration/index.js");
  45. require("../../api/migration/third.js");
  46. require("../../api/pay/channel.js");
  47. require("../../api/product/category.js");
  48. require("../../api/product/comment.js");
  49. require("../../api/product/favorite.js");
  50. require("../../api/product/history.js");
  51. require("../../api/product/spu.js");
  52. require("../../api/promotion/activity.js");
  53. require("../../api/promotion/article.js");
  54. require("../../api/promotion/bargain.js");
  55. require("../../api/promotion/combination.js");
  56. require("../../api/promotion/rewardActivity.js");
  57. require("../../api/promotion/seckill.js");
  58. require("../../api/system/area.js");
  59. require("../../api/system/voice.js");
  60. require("../../api/trade/afterSale.js");
  61. require("../../api/trade/brokerage.js");
  62. require("../../api/trade/config.js");
  63. require("../../api/trade/delivery.js");
  64. require("../../config/zIndex.js");
  65. if (!Array) {
  66. const _easycom_su_status_bar2 = common_vendor.resolveComponent("su-status-bar");
  67. const _easycom_su_popup2 = common_vendor.resolveComponent("su-popup");
  68. (_easycom_su_status_bar2 + _easycom_su_popup2)();
  69. }
  70. const _easycom_su_status_bar = () => "../../ui/su-status-bar/su-status-bar.js";
  71. const _easycom_su_popup = () => "../../ui/su-popup/su-popup.js";
  72. if (!Math) {
  73. (_easycom_su_status_bar + _easycom_su_popup)();
  74. }
  75. const _sfc_main = {
  76. __name: "s-menu-tools",
  77. setup(__props) {
  78. const show = common_vendor.computed(() => sheep_index.sheep.$store("modal").menu);
  79. function onClick(item) {
  80. sheep_hooks_useModal.closeMenuTools();
  81. if (item.url)
  82. sheep_index.sheep.$router.go(item.url);
  83. }
  84. const list = [
  85. {
  86. url: "/pages/index/index",
  87. icon: "/static/images/home.png",
  88. title: "首页"
  89. },
  90. {
  91. url: "/pages/index/search",
  92. icon: "/static/images/search.png",
  93. title: "搜索"
  94. },
  95. {
  96. url: "/pages/index/user",
  97. icon: "/static/images/user.png",
  98. title: "个人中心"
  99. },
  100. {
  101. url: "/pages/index/cart",
  102. icon: "/static/images/cart.png",
  103. title: "购物车"
  104. },
  105. {
  106. url: "/pages/user/goods-log",
  107. icon: "/static/images/browse.png",
  108. title: "浏览记录"
  109. },
  110. {
  111. url: "/pages/user/goods-collect",
  112. icon: "/static/images/collect.png",
  113. title: "我的收藏"
  114. },
  115. {
  116. url: "/pages/chat/index",
  117. icon: "/static/images/service.png",
  118. title: "客服"
  119. }
  120. ];
  121. return (_ctx, _cache) => {
  122. return {
  123. a: common_vendor.f(list, (item, k0, i0) => {
  124. return common_vendor.e(show.value ? {
  125. a: common_vendor.unref(sheep_index.sheep).$url.static(item.icon)
  126. } : {}, {
  127. b: common_vendor.o(($event) => onClick(item), item.title),
  128. c: common_vendor.t(item.title),
  129. d: item.title
  130. });
  131. }),
  132. b: show.value,
  133. c: common_vendor.o(common_vendor.unref(sheep_hooks_useModal.closeMenuTools)),
  134. d: common_vendor.p({
  135. show: show.value,
  136. type: "top",
  137. round: "20",
  138. backgroundColor: "#F0F0F0"
  139. })
  140. };
  141. };
  142. }
  143. };
  144. const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-bbb37e35"], ["__file", "D:/zx/mall-front-app/sheep/components/s-menu-tools/s-menu-tools.vue"]]);
  145. wx.createComponent(Component);