index.vue 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594
  1. <template>
  2. <view class="content">
  3. <view class="all">
  4. <view class="title">
  5. <!-- <image class="logo" :src="logoImg" mode="heightFix"></image> -->
  6. 高投短视频分销系统
  7. </view>
  8. <!-- 顶部提示语 -->
  9. <!-- <view class="tips">
  10. <view class="tips-title">
  11. <text class="title-text">请选择适合您团队的套餐</text>
  12. <image :src="lineBg" class="line" mode="widthFix"></image>
  13. </view>
  14. <view class="tips-content">
  15. <view class="">不同套餐所享受权益不同,您可按需采购</view>
  16. <view class="flex aic">
  17. <text>有任何疑问请</text>
  18. <text class="cantant">联系客服</text>
  19. </view>
  20. </view>
  21. </view> -->
  22. <!-- 内容 -->
  23. <view class="tabs-wrapper">
  24. <!-- 成片/素材 -->
  25. <view class="tabs">
  26. <view class="tab-item" :class="tabStatus == 0 ? 'select' : ''" @click="tabStatusChange(0)">拍成片</view>
  27. <view class="tab-item" :class="tabStatus == 1 ? 'select' : ''" @click="tabStatusChange(1)">拍素材</view>
  28. </view>
  29. <!-- 套餐tabs -->
  30. <view class="tab_menus flex jcsb aic">
  31. <view class="tab-menu-item flex aic" v-for="(item, index) in tabLists" :key="index"
  32. @click="changeTabs(item,index)">
  33. <text :class="tabIndex == index ? 'now_menu' : ''">{{ item }}</text>
  34. <image v-if="index == tabIndex" :src="biaoqianImg"></image>
  35. </view>
  36. </view>
  37. <!-- 套餐内容 -->
  38. <view class="menu_con" :class="tabIndex == 0 ? 'bg1' : tabIndex == 1 ? 'bg2' : 'bg3'">
  39. <view class="cons">
  40. <view class="menu_title">
  41. <text class="metit">{{ setData.packageName }}</text>
  42. <view class="exmple flex aic">
  43. <image class="play" :src="playImg"></image>
  44. <text>案例</text>
  45. </view>
  46. </view>
  47. <view class="amounts">
  48. <view class="now flex aife">
  49. <view class="money flex aife">
  50. <text class="dw fs40">¥</text>
  51. <text class="num">{{ setData.currentPrice }}</text>
  52. <text class="unit">/条</text>
  53. </view>
  54. <view class="limit">限时</view>
  55. </view>
  56. <view class="past flex aic">
  57. <text class="past_text fs28">原价</text>
  58. <text class="past_num fs32">¥{{ setData.originalPrice }}/条</text>
  59. </view>
  60. </view>
  61. <view class="choose">
  62. <view v-for="(item, index) in setData.descriptions" :key="index" class="choose_item-box flex aic jcsb">
  63. <view class="choose_item flex aic">
  64. <image :src="guoxuanImg"></image>
  65. <text>{{ item }}</text>
  66. </view>
  67. <view v-if="index == 0" class="choose_item-more flex aic" @click="isList = !isList">
  68. <text>查看更多</text>
  69. <image :src="!isList?moreImg:more_maxdown"></image>
  70. </view>
  71. </view>
  72. <!-- <view class="choose_item flex aic">
  73. <image :src="guoxuanImg"></image>
  74. <text>交付周期 3 天</text>
  75. </view>
  76. <view class="choose_item flex aic">
  77. <image :src="guoxuanImg"></image>
  78. <text>交付周期 3 天</text>
  79. </view>
  80. <view class="choose_item flex aic">
  81. <image :src="guoxuanImg"></image>
  82. <text>交付周期 3 天</text>
  83. </view> -->
  84. </view>
  85. </view>
  86. </view>
  87. <!-- 三大套餐对比 -->
  88. <view v-if="isList" class="menu_tmps">
  89. <view class="tips">
  90. <view class="tips-title">
  91. <text class="title-text">三大套餐所有内容对比</text>
  92. <image :src="lineBg" class="line" mode="widthFix"></image>
  93. </view>
  94. <!-- <view class="tips-content">适用于TikTok、亚马逊、YouTub、INS</view> -->
  95. </view>
  96. <view class="menu_table">
  97. <view class="table-prop flex jcsb aic">
  98. <view class="table-prop-item">内容板块</view>
  99. <view v-for="item in tabLists" :key="item" class="table-prop-item">{{ item }}</view>
  100. <!-- <view class="table-prop-item">B类套餐</view>
  101. <view class="table-prop-item">C类套餐</view> -->
  102. </view>
  103. <view v-for="(item, index) in configs" :key="index" class="table-item">
  104. <view class="table-title flex aic jcsb">
  105. <text class="ttitle">{{ item.name }}</text>
  106. <view class="cutout flex aic" @click="item.flag=!item.flag">
  107. <text>{{ !item.flag ? '展开' : '收起' }}</text>
  108. <image :src="!item.flag?more_mindown:more_minup"></image>
  109. </view>
  110. </view>
  111. <view v-if="item.flag" v-for="(items, indexs) in item.data" :key="indexs" class="table-content">
  112. <view class="row flex aic jcsb">
  113. <view class="row_name">
  114. <text>{{ items.name }}</text>
  115. </view>
  116. <view v-for="(itm,inx) in items.data" :key="inx" class="row_value">
  117. <image v-if="!itm || itm == ''" :src="emptyImg" class="row_empty"></image>
  118. <text v-else>{{ itm }}</text>
  119. </view>
  120. </view>
  121. </view>
  122. </view>
  123. </view>
  124. </view>
  125. </view>
  126. </view>
  127. <view class="btom bg1">
  128. <view class="btn" :style="{ background: 'url(' + buybtnBg + ')' }" @click="toBuy()">立即购买</view>
  129. </view>
  130. </view>
  131. </template>
  132. <script>
  133. import {home} from '@/apis/index'
  134. import {getWxUserInfo} from "../../utils/wxAuth";
  135. export default {
  136. data() {
  137. return {
  138. logoImg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/img_logo.png',
  139. lineBg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_line.png',
  140. biaoqianImg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_biaoqian.png',
  141. playImg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_play.png',
  142. guoxuanImg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_guoxuan.png',
  143. moreImg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_more.png',
  144. more_minup: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_more_minup.png',
  145. more_mindown: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_more_mindown.png',
  146. more_maxdown: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_more_maxdown.png',
  147. emptyImg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_empty.png',
  148. buybtnBg: 'https://ovp-shop.oss-cn-hangzhou.aliyuncs.com/static/9dshop/ic_buy.png',
  149. tabStatus: 0,// 成片/素材
  150. tabIndex: 0,// 套餐tabs角标
  151. tabLists: [],// 套餐tabs列表
  152. packagesEntity: [],
  153. setData: {},
  154. isList: false,
  155. configs: []
  156. }
  157. },
  158. onLoad() {
  159. this.changeTabbar()
  160. if (!uni.getStorageSync('token')) {
  161. this.getUserInfo()
  162. }
  163. this.getData()
  164. },
  165. onShow() {
  166. },
  167. methods: {
  168. // 跳转到购买详情页
  169. toBuy() {
  170. uni.navigateTo({
  171. url: '/pages/order/order_confirm?id=' + this.setData.packageId + '&strip=' + this.setData.count + '&type=' + this.tabStatus
  172. })
  173. },
  174. async getUserInfo() {
  175. try {
  176. await getWxUserInfo();
  177. } catch (error) {
  178. console.error('获取用户信息失败', error);
  179. }
  180. },
  181. // 成片/素材
  182. tabStatusChange(num) {
  183. this.tabStatus = num
  184. this.getData()
  185. },
  186. // 套餐tabs角标
  187. changeTabs(data, num) {
  188. this.tabIndex = num
  189. this.setData = this.packagesEntity.find(item => item.packageName === data)
  190. },
  191. // 获取列表
  192. getData() {
  193. home({type: this.tabStatus}).then(res => {
  194. this.tabLists = res.packages
  195. this.packagesEntity = res.packagesEntity
  196. this.setData = this.packagesEntity[0]
  197. this.configs = res.configs
  198. console.log(res, 'res66666');
  199. })
  200. },
  201. // tabbar样式
  202. changeTabbar() {
  203. uni.setTabBarStyle({
  204. color: '#9EA3B1',
  205. selectedColor: '#FFFFFF',
  206. backgroundColor: '#0D121A'
  207. })
  208. }
  209. }
  210. }
  211. </script>
  212. <style lang="scss" scoped>
  213. .content {
  214. width: 100%;
  215. // min-height: 100vh;
  216. background-color: #0D121A;
  217. position: absolute;
  218. top: 0;
  219. bottom: 0;
  220. display: flex;
  221. flex-direction: column;
  222. .all {
  223. flex: 1;
  224. overflow: auto;
  225. padding: 0 24 rpx 24 rpx;
  226. }
  227. .title {
  228. padding: 16 rpx 8 rpx;
  229. font-weight: normal;
  230. font-size: 32 rpx;
  231. color: #FFFFFF;
  232. .logo {
  233. height: 56 rpx;
  234. }
  235. }
  236. .tips {
  237. display: flex;
  238. flex-direction: column;
  239. justify-content: center;
  240. align-items: center;
  241. margin-top: 96 rpx;
  242. .tips-title {
  243. display: flex;
  244. flex-direction: column;
  245. align-items: flex-end;
  246. .title-text {
  247. font-weight: bold;
  248. font-size: 40 rpx;
  249. color: transparent;
  250. background: linear-gradient(54.35820730218651deg, #00C1FF 0%, #2FFFFC 100%);
  251. -webkit-background-clip: text;
  252. }
  253. .line {
  254. width: 112 rpx;
  255. }
  256. }
  257. .tips-content {
  258. font-size: 32 rpx;
  259. color: #F8FAFF;
  260. margin-top: 28 rpx;
  261. .cantant {
  262. font-weight: 400;
  263. font-size: 32 rpx;
  264. color: #00ECFF;
  265. background: linear-gradient(54.35820730218651deg, #00C1FF 0%, #2FFFFC 100%);
  266. -webkit-background-clip: text;
  267. text-decoration: underline;
  268. margin-left: 8 rpx;
  269. }
  270. }
  271. }
  272. .tabs-wrapper {
  273. display: flex;
  274. flex-direction: column;
  275. align-items: center;
  276. margin-top: 52 rpx;
  277. .tabs {
  278. display: flex;
  279. justify-content: center;
  280. width: 368 rpx;
  281. height: 72 rpx;
  282. background: rgba($color: #FFF, $alpha: 0.1);
  283. border-radius: 36 rpx;
  284. .tab-item {
  285. display: flex;
  286. justify-content: center;
  287. align-items: center;
  288. font-size: 28 rpx;
  289. width: 50%;
  290. height: 64 rpx;
  291. color: #F6F8FF;
  292. }
  293. }
  294. .select {
  295. background: linear-gradient(144deg, #00C1FF 0%, #2FFFFC 100%);
  296. border-radius: 32 rpx;
  297. color: #0D121A !important;
  298. }
  299. .tab_menus {
  300. padding: 64 rpx 40 rpx 56 rpx;
  301. width: 100%;
  302. .tab-menu-item {
  303. color: #9EA3B1;
  304. font-size: 28 rpx;
  305. .now_menu {
  306. font-size: 36 rpx;
  307. color: #F8FAFF !important;
  308. margin-right: 10 rpx;
  309. }
  310. image {
  311. width: 36 rpx;
  312. height: 36 rpx;
  313. }
  314. }
  315. }
  316. .menu_con {
  317. width: 100%;
  318. border-radius: 24 rpx;
  319. border: 2 rpx solid rgba(255, 255, 255, 0.12);
  320. margin: 0 24 rpx;
  321. padding: 56 rpx 32 rpx 48 rpx;
  322. .cons {
  323. padding: 0 16 rpx;
  324. }
  325. .menu_title {
  326. display: flex;
  327. justify-content: space-between;
  328. align-items: center;
  329. .metit {
  330. font-size: 44 rpx;
  331. color: #F8FAFF;
  332. }
  333. .exmple {
  334. width: 156 rpx;
  335. height: 64 rpx;
  336. background: #0D121A;
  337. border-radius: 12 rpx;
  338. display: flex;
  339. align-items: center;
  340. justify-content: center;
  341. font-size: 28 rpx;
  342. color: #FFFFFF;
  343. .play {
  344. width: 32 rpx;
  345. height: 32 rpx;
  346. margin-right: 12 rpx;
  347. }
  348. }
  349. }
  350. .amounts {
  351. margin-top: 72 rpx;
  352. .now {
  353. .money {
  354. font-size: 32 rpx;
  355. color: #FFFFFF;
  356. .dw {
  357. line-height: 40 rpx;
  358. }
  359. .num {
  360. font-size: 72 rpx;
  361. line-height: 56 rpx;
  362. }
  363. .unit {
  364. margin-left: 24 rpx;
  365. }
  366. }
  367. .limit {
  368. margin-left: 24 rpx;
  369. width: 72 rpx;
  370. height: 40 rpx;
  371. background: linear-gradient(144deg, #00C1FF 0%, #2FFFFC 100%);
  372. border-radius: 8 rpx;
  373. font-weight: 500;
  374. font-size: 24 rpx;
  375. color: #0D121A;
  376. text-align: center;
  377. line-height: 40 rpx;
  378. }
  379. }
  380. .past {
  381. color: #BCC0C5;
  382. margin-top: 34 rpx;
  383. .past_text {
  384. margin-right: 8 rpx;
  385. }
  386. }
  387. }
  388. .choose {
  389. margin-top: 64 rpx;
  390. .choose_item-box {
  391. margin-top: 16 rpx;
  392. image {
  393. width: 48 rpx;
  394. height: 48 rpx;
  395. margin-right: 24 rpx;
  396. }
  397. text {
  398. color: #F8FAFF;
  399. font-size: 28 rpx;
  400. }
  401. }
  402. .choose_item-more {
  403. text {
  404. font-size: 28 rpx;
  405. background: linear-gradient(54.35820730218651deg, #00C1FF 0%, #2FFFFC 100%);
  406. color: transparent;
  407. -webkit-background-clip: text;
  408. }
  409. image {
  410. width: 32 rpx;
  411. height: 32 rpx;
  412. margin-left: 12 rpx;
  413. }
  414. }
  415. .choose_item-box:nth-child(1) {
  416. margin-top: 0;
  417. }
  418. }
  419. }
  420. .menu_tmps {
  421. width: 100%;
  422. .menu_table {
  423. background: linear-gradient(180deg, rgba(9, 155, 255, 0.12) 0%, rgba(66, 121, 192, 0.08) 100%);
  424. border-radius: 24 rpx;
  425. border: 2 rpx solid #003849;
  426. margin-top: 48 rpx;
  427. .table-prop {
  428. padding: 36 rpx 40 rpx;
  429. color: #F8FAFF;
  430. font-size: 24 rpx;
  431. border-bottom: #1D3A4A 2 rpx solid;
  432. }
  433. .table-item {
  434. padding: 40 rpx;
  435. font-size: 24 rpx;
  436. border-bottom: #1D3A4A 2 rpx solid;
  437. .table-title {
  438. .ttitle {
  439. background: linear-gradient(311.670791165708deg, #00C1FF 0%, #2FFFFC 100%);
  440. -webkit-background-clip: text;
  441. color: transparent;
  442. }
  443. .cutout {
  444. text {
  445. background: linear-gradient(54.35820730218651deg, #00C1FF 0%, #2FFFFC 100%);
  446. -webkit-background-clip: text;
  447. color: transparent;
  448. }
  449. image {
  450. width: 32 rpx;
  451. height: 32 rpx;
  452. margin-left: 8 rpx;
  453. }
  454. }
  455. }
  456. .table-content {
  457. margin-top: 40 rpx;
  458. color: #FFFFFF;
  459. .row {
  460. margin-top: 40 rpx;
  461. width: 100%;
  462. .row_name {
  463. white-space: nowrap;
  464. width: 15%;
  465. display: flex;
  466. flex-direction: column;
  467. text:nth-child(2) {
  468. font-size: 20 rpx;
  469. text-align: center;
  470. }
  471. }
  472. .row_value {
  473. width: 15%;
  474. text-align: center;
  475. display: flex;
  476. justify-content: center;
  477. }
  478. .row_empty {
  479. width: 32 rpx;
  480. height: 32 rpx;
  481. }
  482. }
  483. .row:nth-child(1) {
  484. margin-top: 0;
  485. }
  486. }
  487. }
  488. .table-item:last-child {
  489. border: none;
  490. }
  491. }
  492. }
  493. }
  494. .bg1 {
  495. background: linear-gradient(180deg, rgba(99, 113, 235, 0.2) 0%, rgba(94, 108, 228, 0.08) 100%);
  496. }
  497. .bg2 {
  498. background: linear-gradient(180deg, rgba(31, 113, 227, 0.2) 0%, rgba(31, 113, 227, 0.08) 100%);
  499. }
  500. .bg3 {
  501. background: linear-gradient(180deg, rgba(0, 161, 205, 0.2) 0%, rgba(0, 161, 205, 0.08) 100%);
  502. }
  503. .btom {
  504. flex-shrink: 1;
  505. padding: 24 rpx 32 rpx;
  506. .btn {
  507. background-size: 100% 100% !important;
  508. width: 100%;
  509. height: 84 rpx;
  510. text-align: center;
  511. line-height: 84 rpx;
  512. font-weight: bold;
  513. font-size: 32 rpx;
  514. color: #0D121A;
  515. }
  516. }
  517. }
  518. </style>