info.js 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. "use strict";
  2. const common_vendor = require("../../common/vendor.js");
  3. if (!Array) {
  4. const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
  5. _easycom_uni_icons2();
  6. }
  7. const _easycom_uni_icons = () => "../../uni_modules/uni-icons/components/uni-icons/uni-icons.js";
  8. if (!Math) {
  9. (_easycom_uni_icons + circle)();
  10. }
  11. const circle = () => "./components/circle.js";
  12. const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
  13. __name: "info",
  14. setup(__props) {
  15. var _a;
  16. (_a = common_vendor.getCurrentInstance()) == null ? void 0 : _a.appContext.config.globalProperties.$api;
  17. const info = common_vendor.ref({ id: 1, name: "测试球队", score: "39" });
  18. const id = common_vendor.ref("");
  19. common_vendor.onLoad(async (options) => {
  20. id.value = options && options.id;
  21. await search();
  22. });
  23. const search = async () => {
  24. if (id.value)
  25. ;
  26. };
  27. const menuList = common_vendor.ref([
  28. { name: "队员", icon: "icon-a-14-chengyuanguanli", color: "#333333" },
  29. { name: "相册", icon: "icon-xiangce", color: "#333333" },
  30. { name: "账本", icon: "icon-zhangben", color: "#333333" },
  31. { name: "战术板", icon: "icon-cricket-pitch", color: "#333333" }
  32. ]);
  33. const toEdit = (item) => {
  34. common_vendor.index.navigateTo({
  35. url: `/pagesHome/team/index?id=${item._id || item.id}`
  36. });
  37. };
  38. const toSave = () => {
  39. };
  40. return (_ctx, _cache) => {
  41. return {
  42. a: info.value.logo || "/static/qiudui.png",
  43. b: common_vendor.t(info.value.name || "暂无名称"),
  44. c: common_vendor.t(info.value.ranking || "暂无排名"),
  45. d: common_vendor.o(($event) => toEdit(info.value)),
  46. e: common_vendor.p({
  47. type: "plusempty",
  48. size: "12",
  49. color: "#ffffff"
  50. }),
  51. f: common_vendor.o(toSave),
  52. g: common_vendor.o(toSave),
  53. h: common_vendor.p({
  54. type: "list",
  55. size: "18"
  56. }),
  57. i: common_vendor.f(menuList.value, (item, index, i0) => {
  58. return {
  59. a: "b14ffc51-2-" + i0,
  60. b: common_vendor.p({
  61. ["custom-prefix"]: "iconfont",
  62. type: item.icon,
  63. size: "25",
  64. color: item.color
  65. }),
  66. c: common_vendor.t(item.name),
  67. d: index,
  68. e: common_vendor.o(($event) => _ctx.toInfo(item), index)
  69. };
  70. }),
  71. j: common_vendor.t(info.value.score || 0),
  72. k: common_vendor.p({
  73. pro: 16 / 100,
  74. border_back_color: "#f1f1f1",
  75. border_color: "#FF0000",
  76. content: "16"
  77. }),
  78. l: common_vendor.p({
  79. pro: 5 / 100,
  80. border_back_color: "#f1f1f1",
  81. border_color: "#35BD7B",
  82. content: "5"
  83. }),
  84. m: common_vendor.p({
  85. pro: 17 / 100,
  86. border_back_color: "#f1f1f1",
  87. border_color: "#FFA500",
  88. content: "17"
  89. }),
  90. n: common_vendor.p({
  91. type: "forward",
  92. size: "25",
  93. color: "#858585"
  94. })
  95. };
  96. };
  97. }
  98. });
  99. const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-b14ffc51"], ["__file", "D:/project/足球比赛/match_applet/pagesHome/team/info.vue"]]);
  100. wx.createPage(MiniProgramPage);