benefits.vue 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364
  1. <template>
  2. <view class="page">
  3. <view class="header dis a-end j-s mb-2">
  4. <view class="dis a-c ">
  5. <image :src="backLogo" mode=""></image>
  6. <view class="dis f-c title ml-3">
  7. <text>创始人</text>
  8. <text>我的佣金比例</text>
  9. </view>
  10. </view>
  11. <view class="ratio dis a-end ">
  12. <text class="mr-1">0.8%</text>
  13. <u-icon name="arrow-right" color="#999" size="28"></u-icon>
  14. </view>
  15. </view>
  16. <view class="wrap ">
  17. <view class="tabs dis a-end">
  18. <view v-for="(item, index) in tabList" :key="index" class="tab dis a-c j-c" :class="{
  19. active: activeTab === index,
  20. tab1: activeTab !== index,
  21. left: activeTab === 0,
  22. right: activeTab === 1
  23. }" @click="handleTab(index)">
  24. <view class="tabtitle">
  25. <image v-if="activeTab==index" src="/static/image/Vector 22.png" mode=""></image>
  26. <view class="">
  27. {{ item.label }}
  28. </view>
  29. </view>
  30. </view>
  31. </view>
  32. <view class="content-container">
  33. <view class="content-wrap contentwrap1 dis f-c a-c" v-show="activeTab === 0">
  34. <text class="title">- 成为创始人已解锁的权益 -</text>
  35. <view class="benefits dis f-c ">
  36. <text>发展管理人</text>
  37. <text>邀请管理人加入,获得管理人车险订单0.1%的收益</text>
  38. </view>
  39. <view class="benefits dis f-c ">
  40. <text>成为管理人</text>
  41. <text>邀请合伙人,获得合伙人0.1-0.5的收益</text>
  42. </view>
  43. <view class="benefits dis f-c ">
  44. <text>成为合伙人</text>
  45. <text>邀请工作室,获得下辖团队出单业务的0.1-0.5的收益</text>
  46. </view>
  47. <view class="benefits dis f-c ">
  48. <text>成为工作室</text>
  49. <text>邀请团队,获得下辖团队出单业务的0.1-0.5的收益</text>
  50. </view>
  51. </view>
  52. <view class="content-wrap contentwrap2 dis f-c a-c" v-show="activeTab === 1">
  53. <text class="title">- 各类身份的佣金权益 -</text>
  54. <view class="ratio-benefits dis f-c ">
  55. <view class=" dis a-c j-s mb-5">
  56. <view class="item " v-for="(item,index) in ratioList" :class="{active:index==ratioindex}"
  57. :key="index" @click="itemclick(item,index)">
  58. <image :src="index==ratioindex?item.activeImg:item.img" mode=""></image>
  59. <text>{{item.title}}</text>
  60. </view>
  61. </view>
  62. <text class="content">{{content}}</text>
  63. </view>
  64. </view>
  65. </view>
  66. </view>
  67. </view>
  68. </template>
  69. <script>
  70. import {
  71. mapState,
  72. mapMutations
  73. } from "vuex"
  74. export default {
  75. data() {
  76. return {
  77. ratioindex: 0,
  78. content: "创始人身份可享受邀请的所有管理人发展的团队成员车险订单的0.1% \n例如:创始人邀请了管理人A,管理人A邀请了合伙人B,合伙人B邀请了工作室C,工作室C邀请了团队D,团队D内的成员出单保费1000元(除车船税),管理人即可获得1000*0.1% = 1元",
  79. activeTab: 1,
  80. backLogo: '', //等级标志
  81. tabList: [{
  82. label: "身份权益"
  83. },
  84. {
  85. label: "佣金权益"
  86. }
  87. ],
  88. ratioList: [{
  89. title: "创始人",
  90. img: "/static/image/my/benefits/1.png",
  91. activeImg: "/static/image/my/benefits/active1.png",
  92. Text: "创始人身份可享受邀请的所有管理人发展的团队成员车险订单的0.1% \n例如:创始人邀请了管理人A,管理人A邀请了合伙人B,合伙人B邀请了工作室C,工作室C邀请了团队D,团队D内的成员出单保费1000元(除车船税),管理人即可获得1000*0.1% = 1元"
  93. },
  94. {
  95. title: "管理人",
  96. img: "/static/image/my/benefits/2.png",
  97. activeImg: "/static/image/my/benefits/active2.png",
  98. Text: "管理人身份可享受邀请的所有合伙人发展的团队成员车险订单的0.15-0.5%;\n 邀请合伙人1-3人,为0.1%,\n 邀请合伙人4-6人,为0.3,\n 邀请合伙人7人以上,为0.5\n 例如:管理人邀请了合伙人A,B,C,达成了0.1%的奖励;合伙人A邀请了工作室B,工作室B邀请了团队C,团队C内的成员出单保费1000元(除车船税),管理人即可获得1000*0.1% = 1元"
  99. },
  100. {
  101. title: "合伙人",
  102. img: "/static/image/my/benefits/3.png",
  103. activeImg: "/static/image/my/benefits/active3.png",
  104. Text: "合伙人身份可享受邀请的所有工作室发展的团队成员车险订单的0.15-0.5%;\n 邀请工作室1-3人,为0.1%,\n 邀请工作室4-6人,为0.3,\n 邀请工作室7人以上,为0.5 \n例如:合伙人邀请了工作室A,B,C,达成了0.1%的奖励;合伙人A邀请了工作室B,工作室B邀请了团队C,团队C内的成员出单保费1000元(除车船税),管理人即可获得1000*0.1% = 1元"
  105. }, {
  106. title: "工作室",
  107. img: "/static/image/my/benefits/4.png",
  108. activeImg: "/static/image/my/benefits/active4.png",
  109. Text: "工作室身份可享受邀请的所有发展的团队成员 车险订单的0.15-0.5%;\n 邀请团队1-3人,为0.1%,\n 邀请团队4-6人,为0.3,\n 邀请团队7人以上,为0.5 \n例如:工作室请了团队A,B,C,达成了0.1%的奖励;工作室邀请了团队A,团队A内的成员出单保费1000元(除车船税),管理人即可获得1000*0.1% = 1元"
  110. }
  111. ]
  112. }
  113. },
  114. computed: {
  115. ...mapState(['userInfo', "userCheckInfo"]),
  116. },
  117. onShow() {
  118. this.backLogo = this.userInfo.sysUser.sysPartnerConfig ? this.userInfo.sysUser.sysPartnerConfig.logo : ''
  119. },
  120. onLoad() {
  121. },
  122. methods: {
  123. itemclick(item, index) {
  124. this.ratioindex = index;
  125. this.content = item.Text;
  126. },
  127. handleTab(index) {
  128. this.activeTab = index
  129. }
  130. }
  131. }
  132. </script>
  133. <style lang="scss" scoped>
  134. .page {
  135. background-color: #F7F7F7;
  136. padding: 20rpx 30rpx;
  137. box-sizing: border-box;
  138. }
  139. .header {
  140. height: 170rpx;
  141. background: #fff;
  142. border-radius: 10rpx 10rpx 10rpx 10rpx;
  143. padding: 30rpx 40rpx;
  144. box-sizing: border-box;
  145. background-image: url('/static/image/my/benefits/benefits-back1.png');
  146. background-size: 100% 100%;
  147. image {
  148. width: 110rpx;
  149. height: 110rpx;
  150. }
  151. .title {
  152. text:first-child {
  153. font-size: 36rpx;
  154. color: #333;
  155. font-weight: bold;
  156. }
  157. text:last-child {
  158. font-size: 28rpx;
  159. color: #666;
  160. }
  161. }
  162. .ratio {
  163. text {
  164. font-size: 50rpx;
  165. color: #333;
  166. font-weight: bold;
  167. line-height: 0.8;
  168. }
  169. }
  170. }
  171. .wrap {
  172. position: relative;
  173. width: 100%;
  174. margin: 0 auto;
  175. box-sizing: border-box;
  176. border-radius: 0px 10rpx 10rpx 10rpx;
  177. }
  178. .tabs {
  179. display: flex;
  180. position: relative;
  181. overflow: hidden;
  182. border-radius: 10rpx 10rpx 0 0;
  183. }
  184. .tab {
  185. flex: 1;
  186. height: 90rpx;
  187. color: #999;
  188. font-size: 30rpx;
  189. position: relative;
  190. border-top-right-radius: 10rpx;
  191. border-top-left-radius: 10rpx;
  192. &.active {
  193. background: #fff;
  194. color: #333;
  195. font-size: 30rpx;
  196. font-weight: bold;
  197. border-top-right-radius: 10rpx;
  198. border-top-left-radius: 10rpx;
  199. }
  200. &.left.active {
  201. border-top-right-radius: 0;
  202. &::after {
  203. content: "";
  204. position: absolute;
  205. top: 0;
  206. right: -50px;
  207. height: 100%;
  208. width: 50px;
  209. z-index: 2;
  210. background-color: #fff;
  211. clip-path: path("M0 0 C12.5 0 13.5 25 25 45 L0 50 Z");
  212. }
  213. }
  214. // 右侧标签的曲线
  215. &.right.active {
  216. border-top-left-radius: 0;
  217. &::before {
  218. content: "";
  219. position: absolute;
  220. top: 0;
  221. left: -49px;
  222. height: 100%;
  223. width: 50px;
  224. z-index: 2;
  225. background-color: #fff;
  226. clip-path: path("M50 0 C37.5 0 37.5 25 25 45 L50 50 Z");
  227. }
  228. }
  229. }
  230. .tab1 {
  231. flex: 1;
  232. height: 90rpx;
  233. position: relative;
  234. border-top-right-radius: 10rpx;
  235. border-top-left-radius: 10rpx;
  236. background-color: #FAFAFA;
  237. }
  238. .tabtext {
  239. margin-left: 50rpx;
  240. }
  241. .tabtext1 {
  242. margin-right: 50rpx;
  243. }
  244. .content-container {
  245. position: relative;
  246. height: auto;
  247. background: #fff;
  248. ;
  249. border-radius: 10rpx 10rpx 10rpx 10rpx;
  250. }
  251. .content-wrap {
  252. height: 100%;
  253. box-sizing: border-box;
  254. border: 4rpx solid #FFFFFF;
  255. border-top: none;
  256. .title {
  257. font-size: 26rpx;
  258. color: #333;
  259. margin-bottom: 30rpx;
  260. }
  261. .benefits {
  262. width: 100%;
  263. padding: 30rpx;
  264. box-sizing: border-box;
  265. border-radius: 10rpx;
  266. background-image: url('/static/image/my/benefits/benefits-back2.png');
  267. background-size: 100% 100%;
  268. margin-bottom: 30rpx;
  269. text:first-child {
  270. font-size: 30rpx;
  271. color: #333;
  272. }
  273. text:last-child {
  274. font-size: 22rpx;
  275. color: #666;
  276. }
  277. }
  278. .ratio-benefits {
  279. width: 100%;
  280. .item {
  281. font-size: 30rpx;
  282. color: #999;
  283. image {
  284. width: 82rpx;
  285. height: 82rpx;
  286. }
  287. }
  288. .active {
  289. font-size: 30rpx;
  290. color: #333;
  291. font-weight: bold;
  292. }
  293. }
  294. }
  295. .contentwrap1 {
  296. border-radius: 10rpx 10rpx 10rpx 10rpx;
  297. padding: 30rpx 35rpx;
  298. box-sizing: border-box;
  299. }
  300. .contentwrap2 {
  301. border-radius: 10rpx 10rpx 10rpx 10rpx;
  302. padding: 30rpx 35rpx;
  303. box-sizing: border-box;
  304. }
  305. .tabtitle {
  306. position: relative;
  307. z-index: 1; // 父级降低层级
  308. // 文字部分
  309. &__text {
  310. position: relative; // 必须定位元素才能生效z-index
  311. z-index: 3; // 高于装饰图片
  312. display: inline-block;
  313. }
  314. // 装饰图片
  315. image {
  316. position: absolute;
  317. bottom: -14rpx; // 根据实际图片高度调整
  318. left: 50%;
  319. transform: translateX(-50%);
  320. z-index: 2; // 介于父级和文字之间
  321. width: 100%;
  322. height: 20rpx;
  323. }
  324. }
  325. </style>