"use strict"; const common_vendor = require("../../common/vendor.js"); const common_assets = require("../../common/assets.js"); const _sfc_main = { __name: "index", setup(__props) { const userInfo = common_vendor.ref({ name: "小毛🥚", avatar: "@/static/avatar/default.png", cardNo: "1234567890", vipLevel: "VIP 99" }); const quickAccess = common_vendor.ref([ { label: "待就诊", count: 1, path: "/pages/appointment/record" }, { label: "待付款", count: 2, path: "/pages/payment/record" }, { label: "待评价", count: 3, path: "/pages/my/reviews" }, { label: "优惠券", count: 5, path: "/pages/my/coupons" } ]); const functionList = common_vendor.ref([ { title: "案例服务", items: [ { label: "上报案例", icon: "icon-record", path: "/pages/case/CaseDetails" }, { label: "我的上报", icon: "icon-payment", path: "/pages/case/index" }, { label: "转运登记", icon: "icon-medical", path: "/pages/case/transfer" }, { label: "审查记录", icon: "icon-contacts", path: "/pages/ethicalReview/index" } ] }, // { // title: "健康服务", // items: [ // { // label: "健康档案", // icon: "icon-health", // path: "/pages/my/health-records", // }, // { // label: "检查报告", // icon: "icon-report", // path: "/pages/records/reports", // tag: "新", // }, // ], // }, { title: "账户设置", items: [ // { // label: "实名认证", // icon: "icon-verify", // path: "/pages/my/verify", // value: "已认证", // }, // { // label: "支付方式", // icon: "icon-wallet", // path: "/pages/my/payment-method", // }, { label: "消息通知", icon: "icon-notification", path: "/pages/my/notification" } ] } // { // items: [ // { // label: "客服中心", // icon: "icon-service", // path: "/pages/my/service", // }, // { // label: "设置", // icon: "icon-settings", // path: "/pages/my/settings", // }, // ], // }, ]); const navigateTo = (url) => { common_vendor.index.navigateTo({ url, fail: (err) => { common_vendor.index.__f__("error", "at pages/my/index.vue:171", "导航失败:", err); common_vendor.index.redirectTo({ url, fail: (err2) => { common_vendor.index.__f__("error", "at pages/my/index.vue:176", "重定向失败:", err2); } }); } }); }; const handleLogout = () => { common_vendor.index.showModal({ title: "提示", content: "确定要退出登录吗?", success: (res) => { if (res.confirm) { common_vendor.index.clearStorageSync(); common_vendor.index.reLaunch({ url: "/pages/login/Login" }); } } }); }; return (_ctx, _cache) => { return { a: common_assets._imports_0$1, b: common_vendor.t(userInfo.value.name), c: common_vendor.t(userInfo.value.cardNo), d: common_vendor.o(($event) => navigateTo("/pages/my/profile")), e: common_vendor.t(userInfo.value.vipLevel), f: common_vendor.o(($event) => navigateTo("/pages/my/vip")), g: common_vendor.f(quickAccess.value, (item, index, i0) => { return { a: common_vendor.t(item.count), b: common_vendor.t(item.label), c: index, d: common_vendor.o(($event) => navigateTo(item.path), index) }; }), h: common_vendor.f(functionList.value, (section, idx, i0) => { return common_vendor.e({ a: section.title }, section.title ? { b: common_vendor.t(section.title) } : {}, { c: common_vendor.f(section.items, (item, index, i1) => { return common_vendor.e({ a: common_vendor.n(item.icon), b: common_vendor.t(item.label), c: item.value }, item.value ? { d: common_vendor.t(item.value) } : {}, { e: item.tag }, item.tag ? { f: common_vendor.t(item.tag) } : {}, { g: index, h: common_vendor.o(($event) => navigateTo(item.path), index) }); }), d: idx }); }), i: common_vendor.o(handleLogout), j: common_vendor.gei(_ctx, "") }; }; } }; wx.createPage(_sfc_main); //# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/my/index.js.map