homepage.wxml 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. <view class="container1">
  2. <!-- 顶部背景和Logo -->
  3. <view class="header">
  4. <image class="background" src="{{images.background}}" mode="widthFix" />
  5. <image class="logo" src="{{images.logo}}" mode="aspectFit" />
  6. </view>
  7. <!-- 卡片区域 -->
  8. <view class="cards-container">
  9. <!-- 用户信息卡片 -->
  10. <view class="user-card">
  11. <view class="user-info-section">
  12. <view class="info-row">
  13. <text class="label">户名</text>
  14. <text class="value">{{userInfo.name}}</text>
  15. <view class="switch-btn" bindtap="handleSwitchMeter">切换水表</view>
  16. </view>
  17. <view class="info-row">
  18. <text class="label">户号信息</text>
  19. <text class="value">{{userInfo.accountNumber}}</text>
  20. </view>
  21. <view class="info-row">
  22. <text class="label">住址信息</text>
  23. <text class="value">{{userInfo.address}}</text>
  24. </view>
  25. </view>
  26. </view>
  27. <!-- 票据式分割线 -->
  28. <view class="card-divider"></view>
  29. <!-- 水费金额信息卡片 -->
  30. <view class="amount-card">
  31. <!-- 水费金额信息 -->
  32. <view class="amount-section">
  33. <!-- 左侧水滴背景图 -->
  34. <image class="water-drop" src="{{images.kapiantubiao}}" mode="aspectFit"></image>
  35. <!-- 中间金额显示 -->
  36. <view class="amount-display">
  37. <view class="total-amount">{{billInfo.totalAmount}}</view>
  38. <view class="amount-label">总计应缴(元)</view>
  39. <view class="amount-details">
  40. <view class="detail-item">
  41. <text class="number">{{billInfo.waterUsage}}</text>
  42. <text class="label">用水量(m³)</text>
  43. </view>
  44. <!-- 添加分隔线 -->
  45. <view class="detail-divider"></view>
  46. <view class="detail-item">
  47. <text class="number blue">{{billInfo.balance}}</text>
  48. <text class="label">账号余额(元)</text>
  49. </view>
  50. </view>
  51. </view>
  52. </view>
  53. <!-- 充值缴费按钮 -->
  54. <button class="pay-btn" bindtap="handlePayment">充值缴费</button>
  55. </view>
  56. </view>
  57. <!-- 功能按钮区域 -->
  58. <view class="function-area">
  59. <view class="function-grid">
  60. <view class="function-item" wx:for="{{functionList}}" wx:key="text" bindtap="handleFunctionClick" data-index="{{index}}">
  61. <image src="{{item.icon}}" mode="aspectFit"></image>
  62. <text>{{item.text}}</text>
  63. </view>
  64. </view>
  65. </view>
  66. <!-- 活动区域 -->
  67. <view class="activity-area">
  68. <view class="area-header">
  69. <text class="title">精选活动</text>
  70. <text class="more" bindtap="handleMoreActivity">更多 ></text>
  71. </view>
  72. <view class="activity-item">
  73. <image class="activity-image" src="{{activity.imageUrl}}" mode="aspectFill"></image>
  74. </view>
  75. </view>
  76. </view>