geRenHuiFeiJiaoJiao.vue 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  1. <template>
  2. <view class="container">
  3. <view class="info-box">
  4. <view class="info-item-box flex">
  5. <view class="label">
  6. 用户名
  7. </view>
  8. <view class="text">
  9. {{ info.username }}
  10. </view>
  11. </view>
  12. <view class="info-item-box flex">
  13. <view class="label">
  14. 支付项目
  15. </view>
  16. <view class="text">
  17. {{ info.payProject }}
  18. </view>
  19. </view>
  20. <view class="info-item-box flex">
  21. <view class="label">
  22. 类型
  23. </view>
  24. <view class="text">
  25. {{ info.type }}
  26. </view>
  27. </view>
  28. <view class="info-item-box flex">
  29. <view class="label">
  30. 年份
  31. </view>
  32. <view class="text">
  33. {{ info.year }}年
  34. </view>
  35. </view>
  36. <view class="info-item-box flex">
  37. <view class="label">
  38. 金额
  39. </view>
  40. <view class="text">
  41. {{ info.price }}元
  42. </view>
  43. </view>
  44. <view class="info-item-box flex">
  45. <view class="label">
  46. 会籍有效期
  47. </view>
  48. <view class="text">
  49. {{ info.periodOfValidity }}
  50. </view>
  51. </view>
  52. <view class="info-item-box row">
  53. <view class="label">
  54. 描述:
  55. </view>
  56. <view class="text" v-html="info.remark"></view>
  57. </view>
  58. </view>
  59. <view class="bottom-box">
  60. <u-button type="error" shape="circle" @click="onSubmit">支付</u-button>
  61. </view>
  62. </view>
  63. </template>
  64. <script setup>
  65. import { ref } from 'vue'
  66. import { onLoad } from '@dcloudio/uni-app'
  67. import { useAuthStore } from '@/store/authStore'
  68. import { personPayment } from '@/api/cost.js'
  69. const authStore = useAuthStore()
  70. // 用户信息
  71. const user = ref({
  72. userIcon: '1',
  73. name: '某某某',
  74. corpName: '广州市xx地产有限公司',
  75. corpRegNo: '123xxxx'
  76. })
  77. const info = ref({
  78. username: '某某某',
  79. payProject: '2024年度个人会费',
  80. type: '个人会费',
  81. year: 2024,
  82. price: 200,
  83. periodOfValidity: '2024.05.1-2025.4.30',
  84. remark: '根据《协会章程》规定,个人会费200元/年/人,会员会籍为每年5月1日至4月30日。<br/>个人会员可享受以下会员服务:<br/>1、免费使用网络教育培训系统【系统已上线121个视频课程77本电子书,涵盖:政策法规、职业素养、商务礼仪、客户服务销售技能、市场营销、团队管理、办公软件等多个知识领域】<br/>2、优先优惠参加协会组织的公开培训课<br/>更多优惠请关注协会微信号【gzreavip】'
  85. })
  86. function onSubmit() {
  87. const form = {
  88. title: info.value.payProject,
  89. year: info.value.year,
  90. amount: info.value.price,
  91. desc: info.value.payProject
  92. }
  93. personPayment(form).then(res => {
  94. if (res && res.message === 'success') {
  95. console.log('会费缴交', res)
  96. }
  97. })
  98. }
  99. onLoad((load) => {
  100. user.value = authStore.userInfo
  101. info.value = {
  102. username: user.value.name,
  103. payProject: `${load.year}年度个人会费`,
  104. type: '个人会费',
  105. year: Number(load.year),
  106. price: Number(load.duePrice),
  107. periodOfValidity: `${Number(load.year)}.05.1-${Number(load.year) + 1}.4.30`,
  108. remark: '根据《协会章程》规定,个人会费200元/年/人,会员会籍为每年5月1日至4月30日。<br/>个人会员可享受以下会员服务:<br/>1、免费使用网络教育培训系统【系统已上线121个视频课程77本电子书,涵盖:政策法规、职业素养、商务礼仪、客户服务销售技能、市场营销、团队管理、办公软件等多个知识领域】<br/>2、优先优惠参加协会组织的公开培训课<br/>更多优惠请关注协会微信号【gzreavip】'
  109. }
  110. })
  111. </script>
  112. <style lang="scss" scoped>
  113. .container {
  114. height: 100vh;
  115. width: 100vw;
  116. background-color: $uni-bg-color;
  117. padding: 20rpx;
  118. .info-box {
  119. padding: 30rpx;
  120. background-color: $uni-bg-color-grey;
  121. border-radius: $uni-card-border-radius;
  122. .info-item-box {
  123. font-size: $uni-title-font-size-2;
  124. border-bottom: 1rpx solid #E6E6E6;
  125. height: 82rpx;
  126. .label {
  127. font-weight: bold;
  128. }
  129. }
  130. .flex {
  131. display: flex;
  132. align-items: center;
  133. .label {
  134. width: 30%;
  135. }
  136. .text {
  137. width: 70%;
  138. }
  139. }
  140. .row {
  141. .label {
  142. line-height: 62rpx;
  143. }
  144. .text {
  145. line-height: 42rpx;
  146. font-size: $uni-title-font-size-3;
  147. font-weight: bold;
  148. }
  149. }
  150. }
  151. .bottom-box {
  152. padding: 20rpx;
  153. position: absolute;
  154. bottom: 50rpx;
  155. width: 95%;
  156. }
  157. }
  158. </style>