index.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743
  1. <template>
  2. <view class="container">
  3. <!-- TabTransition overlay -->
  4. <tab-transition v-if="showTabTransition" dimCode="wealth" ref="tabTransition" @close="showTabTransition = false" />
  5. <!-- 未登录时显示精简内容 -->
  6. <template v-if="!isLoggedIn">
  7. <PageBanner theme="wealth"
  8. tagline="利他创富 · 价值共享"
  9. quote="富足源于利他与坚持" />
  10. <!-- 登录引导 -->
  11. <view class="login-guide-section">
  12. <text class="login-guide-text">登录后查看财富能量、推广收益、邀请返利等更多内容</text>
  13. <button class="login-btn" @click="goLogin">登录 / 注册</button>
  14. </view>
  15. </template>
  16. <template v-else>
  17. <!-- 品牌头部 -->
  18. <PageBanner theme="wealth"
  19. tagline="利他创富 · 价值共享"
  20. quote="富足源于利他与坚持" />
  21. <!-- 家庭成员选择条 -->
  22. <FamilyMemberStrip
  23. v-if="isLoggedIn"
  24. :members="familyMembersVisible"
  25. :selectedMemberId="selectedMemberId"
  26. @select="onFamilyMemberSelect"
  27. @removed="loadFamilyMembersVisible" />
  28. <!-- 模式切换 / 退出切换入口(家长未切时显示"切换到孩子视角";已切时显示"退出切换") -->
  29. <!-- 已切孩子态:点击"退出切换"回到家长模式 -->
  30. <view v-if="isSwitchedChild" class="exit-switch" @click="exitSwitch">
  31. <text>🔄 退出切换</text>
  32. </view>
  33. <!-- 家长且未切孩子态:此处展示"切换到孩子视角",点击完成模式切换 -->
  34. <view v-else class="exit-switch" @click="onSwitchMode">
  35. <text>👶 切换到孩子视角</text>
  36. </view>
  37. <!-- 身克富杠杆警告 -->
  38. <body-wealth-alert
  39. :status="bodyWealthStatus"
  40. :message="bodyWealthMessage"
  41. :showTip="true" />
  42. <!-- 财富子维度卡片 -->
  43. <wealth-sub-scores
  44. :role="role"
  45. :income="wealthIncome"
  46. :achievement="wealthAchievement"
  47. :network="wealthNetwork"
  48. :education="wealthEducation"
  49. :social="wealthSocial"
  50. :points="wealthPoints" />
  51. <!-- 心的子维度(仅孩子) -->
  52. <view class="section" v-if="role !== 'parent'">
  53. <view class="section-header">
  54. <text class="section-title">🔥 心的子维度</text>
  55. </view>
  56. <view class="sub-dim-grid heart-sub-dim">
  57. <view class="sub-dim-card" @click="childSubDimClick('emotion')">
  58. <text class="sub-dim-score">{{ heartEmotionStable || '-' }}</text>
  59. <text class="sub-dim-label">情绪稳定</text>
  60. <text class="sub-dim-desc">EMI情绪管理</text>
  61. </view>
  62. <view class="sub-dim-card" @click="childSubDimClick('understanding')">
  63. <text class="sub-dim-score">{{ heartUnderstanding || '-' }}</text>
  64. <text class="sub-dim-label">理解包容</text>
  65. <text class="sub-dim-desc">共情+社交适应</text>
  66. </view>
  67. <view class="sub-dim-card" @click="childSubDimClick('legacy')">
  68. <text class="sub-dim-score">{{ heartLegacy || '-' }}</text>
  69. <text class="sub-dim-label">传承传递</text>
  70. <text class="sub-dim-desc">未来开放</text>
  71. </view>
  72. </view>
  73. </view>
  74. <!-- 财富数据(仅家长) -->
  75. <view class="section" v-if="role === 'parent'">
  76. <view class="section-header">
  77. <text class="section-title">💰 财富数据</text>
  78. </view>
  79. <view class="wealth-card">
  80. <view class="wealth-item">
  81. <text class="wealth-value">{{ wealthData.totalEarnings || 0 }}</text>
  82. <text class="wealth-label">累计收益</text>
  83. </view>
  84. <view class="wealth-divider"></view>
  85. <view class="wealth-item">
  86. <text class="wealth-value">{{ wealthData.availableAmount || 0 }}</text>
  87. <text class="wealth-label">可提现</text>
  88. </view>
  89. <view class="wealth-divider"></view>
  90. <view class="wealth-item">
  91. <text class="wealth-value">{{ wealthData.referralCount || 0 }}</text>
  92. <text class="wealth-label">邀请人数</text>
  93. </view>
  94. </view>
  95. <!-- 邀请码复制 -->
  96. <view class="referral-code-bar" v-if="wealthData.referralCode" @click="copyReferralCode">
  97. <text class="referral-code-label">我的邀请码</text>
  98. <text class="referral-code-value">{{ wealthData.referralCode }}</text>
  99. <text class="referral-code-copy">复制</text>
  100. </view>
  101. </view>
  102. <!-- 增值服务入口 -->
  103. <view class="section">
  104. <view class="section-header">
  105. <text class="section-title">🚀 增值服务</text>
  106. </view>
  107. <view class="service-grid">
  108. <view class="service-item" @click="goToCheckin">
  109. <text class="service-icon">📝</text>
  110. <text class="service-label">记账打卡</text>
  111. </view>
  112. <view class="service-item" @click="goToInsurance">
  113. <text class="service-icon">🛡️</text>
  114. <text class="service-label">保单管理</text>
  115. </view>
  116. <view class="service-item" @click="goToCreator">
  117. <text class="service-icon">🎨</text>
  118. <text class="service-label">创客中心</text>
  119. </view>
  120. </view>
  121. </view>
  122. <!-- 消费中心 -->
  123. <view class="section">
  124. <view class="section-header">
  125. <text class="section-title">🛍️ 消费中心</text>
  126. </view>
  127. <view class="service-grid">
  128. <view class="service-item" @click="goToShop">
  129. <text class="service-icon">🏪</text>
  130. <text class="service-label">商城首页</text>
  131. </view>
  132. <view class="service-item" @click="goToCart">
  133. <text class="service-icon">🛒</text>
  134. <text class="service-label">购物车</text>
  135. </view>
  136. <view class="service-item" @click="goToOrders">
  137. <text class="service-icon">📋</text>
  138. <text class="service-label">我的订单</text>
  139. </view>
  140. <view class="service-item" @click="goToAfterSales">
  141. <text class="service-icon">🔄</text>
  142. <text class="service-label">售后服务</text>
  143. </view>
  144. </view>
  145. </view>
  146. <!-- 底部菜单 -->
  147. <view class="menu-list">
  148. <view class="menu-item" @click="goToProfile">
  149. <text>👤 个人中心</text>
  150. <text class="arrow">›</text>
  151. </view>
  152. <view class="menu-item" @click="goToPointsLogs">
  153. <text>📊 积分记录</text>
  154. <text class="arrow">›</text>
  155. </view>
  156. <view class="menu-item logout-item" @click="logout">
  157. <text>🚪 退出登录</text>
  158. <text class="arrow">›</text>
  159. </view>
  160. </view>
  161. </template>
  162. </view>
  163. </template>
  164. <script>
  165. import TabTransition from '../../components/tab-transition.vue'
  166. import PageBanner from '../../components/PageBanner.vue'
  167. import WealthSubScores from '../../components/WealthSubScores.vue'
  168. import BodyWealthAlert from '../../components/BodyWealthAlert.vue'
  169. import FamilyMemberStrip from '../../components/FamilyMemberStrip.vue'
  170. import {
  171. verifyPassword,
  172. getChildren,
  173. getWealthDetail,
  174. getReferralCode,
  175. getReferralSummary,
  176. getCommissionSummary,
  177. getVisibleFamilyMembers
  178. } from '../../utils/api.js'
  179. export default {
  180. components: { TabTransition, PageBanner, WealthSubScores, BodyWealthAlert, FamilyMemberStrip },
  181. data() {
  182. return {
  183. showTabTransition: true,
  184. isLoggedIn: false,
  185. role: 'parent',
  186. isSwitchedChild: false,
  187. // 五维评分
  188. bodyScore: 0,
  189. mindScore: 0,
  190. wisdomScore: 0,
  191. actionScore: 0,
  192. wealthScore: 0,
  193. // 心的子维度(仅孩子有真实数据)
  194. heartEmotionStable: null,
  195. heartUnderstanding: null,
  196. heartLegacy: null,
  197. // 子维度 - parent
  198. wealthIncome: null,
  199. wealthAchievement: null,
  200. wealthNetwork: null,
  201. // 子维度 - child
  202. wealthEducation: null,
  203. wealthSocial: null,
  204. wealthPoints: null,
  205. // 身克富杠杆
  206. bodyWealthStatus: 'normal',
  207. bodyWealthMessage: '',
  208. // 财富数据
  209. wealthData: {
  210. totalEarnings: 0,
  211. availableAmount: 0,
  212. referralCount: 0,
  213. referralCode: ''
  214. },
  215. children: [],
  216. familyMembersVisible: [],
  217. selectedMemberId: null,
  218. articlesLoading: false,
  219. }
  220. },
  221. computed: {
  222. activeChildId() {
  223. if (this.role === 'child') {
  224. return uni.getStorageSync('currentChildId')
  225. }
  226. return ''
  227. }
  228. },
  229. onShow() {
  230. this.showTabTransition = true
  231. var token = uni.getStorageSync('token')
  232. if (!token) {
  233. this.isLoggedIn = false
  234. this._watchPageReady()
  235. return
  236. }
  237. this.isLoggedIn = true
  238. var currentRole = uni.getStorageSync('currentRole') || uni.getStorageSync('role') || 'parent'
  239. if (currentRole === 'teacher') {
  240. uni.redirectTo({ url: '/pages/teacher/teacher-profile' })
  241. return
  242. }
  243. this.role = currentRole
  244. this.isSwitchedChild = uni.getStorageSync('isSwitchedChild') || false
  245. this.loadChildren()
  246. this.loadWealthDetail()
  247. this.loadWealthData()
  248. this.loadFamilyMembersVisible()
  249. this._watchPageReady()
  250. },
  251. methods: {
  252. onFamilyMemberSelect(member) {
  253. this.selectedMemberId = member.id
  254. },
  255. loadFamilyMembersVisible() {
  256. var self = this
  257. getVisibleFamilyMembers().then(function(res) {
  258. self.familyMembersVisible = res.data || []
  259. }).catch(function(e) {
  260. console.log('获取可见家庭成员失败', e)
  261. self.familyMembersVisible = []
  262. })
  263. },
  264. goLogin() {
  265. uni.navigateTo({ url: '/pages/login/login' })
  266. },
  267. _watchPageReady() {
  268. var self = this
  269. this.$nextTick(function() {
  270. if (self.$refs.tabTransition) self.$refs.tabTransition.markReady()
  271. })
  272. },
  273. async loadChildren() {
  274. try {
  275. var res = await getChildren()
  276. this.children = res.data || []
  277. } catch (e) {
  278. console.error('获取孩子列表失败', e)
  279. }
  280. },
  281. async loadWealthDetail() {
  282. var memberId = null
  283. var memberType = this.role
  284. if (this.role === 'child') {
  285. memberId = uni.getStorageSync('currentChildId')
  286. if (!memberId && this.children.length > 0) {
  287. memberId = this.children[0].id
  288. }
  289. } else {
  290. memberId = uni.getStorageSync('userId')
  291. }
  292. if (!memberId) return
  293. try {
  294. var res = await getWealthDetail(memberId, memberType)
  295. if (res && res.data) {
  296. var d = res.data
  297. this.wealthScore = d.wealthScore || 0
  298. if (memberType === 'parent') {
  299. this.wealthIncome = d.wealthIncome
  300. this.wealthAchievement = d.wealthAchievement
  301. this.wealthNetwork = d.wealthNetwork
  302. } else {
  303. this.wealthEducation = d.wealthEducation
  304. this.wealthSocial = d.wealthSocial
  305. this.wealthPoints = d.wealthPoints
  306. this.heartEmotionStable = d.heartEmotionStable
  307. this.heartUnderstanding = d.heartUnderstanding
  308. this.heartLegacy = d.heartLegacy
  309. }
  310. // 身克富杠杆状态
  311. this.bodyWealthStatus = d.bodyWealthStatus || 'normal'
  312. this.bodyWealthMessage = d.bodyWealthMessage || ''
  313. }
  314. } catch (e) {
  315. console.error('获取富维度详情失败', e)
  316. }
  317. },
  318. async loadWealthData() {
  319. if (this.role !== 'parent') return
  320. try {
  321. var codeRes = await getReferralCode()
  322. if (codeRes && codeRes.code === 200 && codeRes.data) {
  323. this.wealthData.referralCode = codeRes.data.code || codeRes.data || ''
  324. }
  325. } catch (e) {
  326. console.error('获取邀请码失败', e)
  327. }
  328. try {
  329. var summaryRes = await getReferralSummary()
  330. if (summaryRes && summaryRes.code === 200 && summaryRes.data) {
  331. this.wealthData.referralCount = summaryRes.data.totalCount || summaryRes.data.count || 0
  332. }
  333. } catch (e) {
  334. console.error('获取邀请统计失败', e)
  335. }
  336. try {
  337. var commissionRes = await getCommissionSummary()
  338. if (commissionRes && commissionRes.code === 200 && commissionRes.data) {
  339. this.wealthData.totalEarnings = commissionRes.data.totalEarnings || 0
  340. this.wealthData.availableAmount = commissionRes.data.availableAmount || 0
  341. }
  342. } catch (e) {
  343. console.error('获取佣金统计失败', e)
  344. }
  345. },
  346. copyReferralCode() {
  347. if (!this.wealthData.referralCode) return
  348. uni.setClipboardData({
  349. data: this.wealthData.referralCode,
  350. success: function() {
  351. uni.showToast({ title: '邀请码已复制', icon: 'success' })
  352. }
  353. })
  354. },
  355. onSwitchMode() {
  356. if (this.role === 'child') {
  357. this.exitSwitch()
  358. return
  359. }
  360. // parent → switch to child
  361. if (this.children.length === 0) {
  362. this.loadChildren()
  363. if (this.children.length === 0) {
  364. uni.showModal({
  365. title: '提示',
  366. content: '您还没有添加孩子,请先在家庭成员中添加',
  367. success: function(res) {
  368. if (res.confirm) {
  369. uni.navigateTo({ url: '/pages/profile-extra/family-members' })
  370. }
  371. }
  372. })
  373. return
  374. }
  375. }
  376. if (this.children.length === 1) {
  377. this.$store.commit('switchToChild', this.children[0].id)
  378. this.role = 'child'
  379. this.isSwitchedChild = true
  380. uni.showToast({ title: '已切换为孩子模式', icon: 'success' })
  381. return
  382. }
  383. var self = this
  384. uni.showActionSheet({
  385. itemList: this.children.map(function(c) { return c.nickname }),
  386. success: function(res) {
  387. var selectedChild = self.children[res.tapIndex]
  388. self.$store.commit('switchToChild', selectedChild.id)
  389. self.role = 'child'
  390. self.isSwitchedChild = true
  391. uni.showToast({ title: '已切换为' + selectedChild.nickname + '模式', icon: 'success' })
  392. }
  393. })
  394. },
  395. exitSwitch() {
  396. if (!this.isSwitchedChild) return
  397. var self = this
  398. uni.showModal({
  399. title: '退出切换',
  400. content: '请输入家长密码以确认退出',
  401. editable: true,
  402. success: function(res) {
  403. if (res.confirm && res.content) {
  404. verifyPassword(res.content).then(function(result) {
  405. if (result.code === 200) {
  406. uni.removeStorageSync('isSwitchedChild')
  407. uni.removeStorageSync('currentChildId')
  408. self.isSwitchedChild = false
  409. self.role = 'parent'
  410. if (self.$store && self.$store.commit) {
  411. self.$store.commit('switchBackToParent')
  412. }
  413. uni.showToast({ title: '已退出切换', icon: 'success' })
  414. setTimeout(function() {
  415. uni.reLaunch({ url: '/pages/index-home/index' })
  416. }, 1000)
  417. } else {
  418. uni.showToast({ title: '密码错误', icon: 'none' })
  419. }
  420. }).catch(function() {
  421. uni.showToast({ title: '验证失败', icon: 'none' })
  422. })
  423. }
  424. }
  425. })
  426. },
  427. logout() {
  428. uni.showModal({
  429. title: '退出登录',
  430. content: '确定要退出登录吗?',
  431. success: function(res) {
  432. if (res.confirm) {
  433. uni.clearStorageSync()
  434. uni.reLaunch({ url: '/pages/login/login' })
  435. }
  436. }
  437. })
  438. },
  439. goToProfile() {
  440. uni.navigateTo({ url: '/pages/profile-main/profile' })
  441. },
  442. goToCheckin() {
  443. uni.navigateTo({ url: '/pages/wealth-sub/checkin' })
  444. },
  445. goToInsurance() {
  446. uni.navigateTo({ url: '/pages/wealth-sub/insurance-list' })
  447. },
  448. goToCreator() {
  449. uni.navigateTo({ url: '/pages/promotion/index' })
  450. },
  451. goToPointsLogs() {
  452. uni.navigateTo({ url: '/pages/points/points' })
  453. },
  454. goToShop() {
  455. uni.navigateTo({ url: '/pages/shop/index/index' })
  456. },
  457. goToCart() {
  458. uni.navigateTo({ url: '/pages/shop/cart/cart' })
  459. },
  460. goToOrders() {
  461. uni.navigateTo({ url: '/pages/shop/order-list/order-list' })
  462. },
  463. goToAfterSales() {
  464. uni.navigateTo({ url: '/pages/shop/after-sales/after-sales' })
  465. },
  466. goToIncome() {
  467. uni.navigateTo({ url: '/pages/promotion/commission' })
  468. },
  469. goToAchievements() {
  470. uni.navigateTo({ url: '/pages/rewards/badge' })
  471. },
  472. goToNetwork() {
  473. uni.navigateTo({ url: '/pages/promotion/team' })
  474. },
  475. childSubDimClick(key) {
  476. var routes = {
  477. education: '/pages/assessment/results',
  478. social: '/pages/activity/index',
  479. points: '/pages/shop/index',
  480. emotion: '/pages/mind-detail/emotion-report',
  481. understanding: '/pages/mind-detail/emotion-trend',
  482. legacy: '/pages/wishes/index'
  483. }
  484. var url = routes[key]
  485. if (url) {
  486. uni.navigateTo({ url: url })
  487. }
  488. }
  489. }
  490. }
  491. </script>
  492. <style scoped>
  493. .container {
  494. min-height: 100vh;
  495. background: #f5f7fa;
  496. padding-bottom: 120rpx;
  497. }
  498. .section {
  499. margin: 20rpx 30rpx;
  500. }
  501. .section-header {
  502. display: flex;
  503. justify-content: space-between;
  504. align-items: center;
  505. margin-bottom: 20rpx;
  506. }
  507. .section-title {
  508. font-size: 30rpx;
  509. font-weight: bold;
  510. color: #333;
  511. }
  512. .section-more {
  513. font-size: 24rpx;
  514. color: #999;
  515. }
  516. /* 切换区域 */
  517. .switch-section {
  518. margin: 0 30rpx 20rpx;
  519. }
  520. .btn-switch {
  521. background: linear-gradient(135deg, #F59E0B, #FBBF24);
  522. color: #fff;
  523. font-size: 26rpx;
  524. padding: 16rpx 0;
  525. border-radius: 40rpx;
  526. text-align: center;
  527. line-height: 1.5;
  528. }
  529. /* 财富数据卡片 */
  530. .wealth-card {
  531. background: #fff;
  532. border-radius: 20rpx;
  533. padding: 30rpx 20rpx;
  534. display: flex;
  535. align-items: center;
  536. box-shadow: 0 2rpx 12rpx rgba(0,0,0,0.06);
  537. }
  538. .wealth-item {
  539. flex: 1;
  540. display: flex;
  541. flex-direction: column;
  542. align-items: center;
  543. }
  544. .wealth-value {
  545. font-size: 40rpx;
  546. font-weight: bold;
  547. color: #F97316;
  548. }
  549. .wealth-label {
  550. font-size: 24rpx;
  551. color: #999;
  552. margin-top: 8rpx;
  553. }
  554. .wealth-divider {
  555. width: 1rpx;
  556. height: 60rpx;
  557. background: #f0f0f0;
  558. }
  559. /* 邀请码复制条 */
  560. .referral-code-bar {
  561. display: flex;
  562. align-items: center;
  563. background: #fff;
  564. margin-top: 16rpx;
  565. border-radius: 16rpx;
  566. padding: 24rpx 30rpx;
  567. box-shadow: 0 2rpx 12rpx rgba(0,0,0,0.06);
  568. }
  569. .referral-code-label {
  570. font-size: 26rpx;
  571. color: #666;
  572. margin-right: 16rpx;
  573. }
  574. .referral-code-value {
  575. flex: 1;
  576. font-size: 30rpx;
  577. font-weight: bold;
  578. color: #F59E0B;
  579. letter-spacing: 2rpx;
  580. }
  581. .referral-code-copy {
  582. font-size: 24rpx;
  583. color: #fff;
  584. background: linear-gradient(135deg, #F59E0B, #FBBF24);
  585. padding: 8rpx 24rpx;
  586. border-radius: 20rpx;
  587. }
  588. /* 三子维度卡片 */
  589. .sub-dim-grid {
  590. display: flex;
  591. }
  592. .sub-dim-card {
  593. flex: 1;
  594. margin-right: 16rpx;
  595. background: #fff;
  596. border-radius: 16rpx;
  597. padding: 24rpx 16rpx;
  598. display: flex;
  599. flex-direction: column;
  600. align-items: center;
  601. box-shadow: 0 2rpx 12rpx rgba(0,0,0,0.06);
  602. }
  603. .sub-dim-card:last-child {
  604. margin-right: 0;
  605. }
  606. .sub-dim-score {
  607. font-size: 48rpx;
  608. font-weight: bold;
  609. color: #F59E0B;
  610. }
  611. .heart-sub-dim .sub-dim-score {
  612. color: #FF6B9D;
  613. }
  614. .sub-dim-label {
  615. font-size: 24rpx;
  616. color: #333;
  617. margin-top: 8rpx;
  618. font-weight: 500;
  619. }
  620. .sub-dim-desc {
  621. font-size: 20rpx;
  622. color: #999;
  623. margin-top: 4rpx;
  624. }
  625. /* 增值服务 */
  626. .service-grid {
  627. display: flex;
  628. flex-wrap: wrap;
  629. background: #fff;
  630. border-radius: 20rpx;
  631. padding: 24rpx 16rpx;
  632. box-shadow: 0 2rpx 12rpx rgba(0,0,0,0.06);
  633. }
  634. .service-item {
  635. width: 25%;
  636. display: flex;
  637. flex-direction: column;
  638. align-items: center;
  639. padding: 16rpx 0;
  640. }
  641. .service-icon {
  642. font-size: 48rpx;
  643. margin-bottom: 8rpx;
  644. }
  645. .service-label {
  646. font-size: 22rpx;
  647. color: #666;
  648. }
  649. /* 底部菜单 */
  650. .menu-list {
  651. margin: 30rpx 30rpx 0;
  652. background: #fff;
  653. border-radius: 16rpx;
  654. }
  655. .menu-item {
  656. padding: 30rpx;
  657. border-bottom: 1rpx solid #f0f0f0;
  658. display: flex;
  659. justify-content: space-between;
  660. font-size: 28rpx;
  661. }
  662. .menu-item:last-child {
  663. border-bottom: none;
  664. }
  665. .arrow {
  666. color: #ccc;
  667. font-size: 32rpx;
  668. }
  669. .logout-item {
  670. color: #EF4444;
  671. }
  672. /* 未登录 */
  673. .login-guide-section {
  674. display: flex;
  675. flex-direction: column;
  676. align-items: center;
  677. padding: 60rpx 40rpx;
  678. margin: 30rpx;
  679. background: #fff;
  680. border-radius: 20rpx;
  681. box-shadow: 0 2rpx 12rpx rgba(0,0,0,0.06);
  682. }
  683. .login-guide-text {
  684. font-size: 26rpx;
  685. color: #999;
  686. text-align: center;
  687. margin-bottom: 30rpx;
  688. line-height: 1.6;
  689. }
  690. .login-guide-section .login-btn {
  691. width: 60%;
  692. height: 80rpx;
  693. line-height: 80rpx;
  694. background: linear-gradient(135deg, #5B9BD5, #3A7CC4);
  695. color: #fff;
  696. font-size: 30rpx;
  697. font-weight: bold;
  698. border-radius: 40rpx;
  699. text-align: center;
  700. border: none;
  701. }
  702. .login-prompt .login-btn::after {
  703. border: none;
  704. }
  705. /* 退出切换 */
  706. .exit-switch {
  707. margin: 20rpx 30rpx 0;
  708. padding: 16rpx 24rpx;
  709. background: #FEF3C7;
  710. border-radius: 12rpx;
  711. text-align: center;
  712. font-size: 26rpx;
  713. color: #92400E;
  714. }
  715. </style>