index.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775
  1. <template>
  2. <view class="distributor" :style="viewColor">
  3. <view class="headerBg" :style="{'background-image': `url(${domain}/static/diy/distribution${keyColor}.png)`}">
  4. <view v-if="openActivity" class="explain" @click="explain">分销说明</view>
  5. <view class="picTxt acea-row row-middle">
  6. <view class="pictrue">
  7. <image class="avatar" :src='userInfo.avatar' v-if="userInfo.avatar"></image>
  8. <image v-else class="avatar" src="/static/images/f.png" mode=""></image>
  9. </view>
  10. <view class="text">
  11. <view class="name line1">{{userInfo.nickname}}</view>
  12. <view class="info line1">直接推广人越多,获得的奖励越多哦!</view>
  13. </view>
  14. </view>
  15. </view>
  16. <!-- menu -->
  17. <view class='nav acea-row' v-if="menus.length && openActivity">
  18. <block v-for="(item,index) in menus" :key="index">
  19. <view class='item'>
  20. <view class='pictrue' style="width: 90rpx; height: 90rpx; background-color: #FFF8EC; border-radius: 100%; text-align: center;">
  21. <image :src='item.img'></image>
  22. </view>
  23. <view class="menu-txt area-row">{{item.title}}</view>
  24. </view>
  25. </block>
  26. </view>
  27. <!-- 推荐礼包 -->
  28. <view class="recommend" v-if="openActivity">
  29. <view v-if="fastList.length > 0" class="public_title acea-row row-center-wrapper">
  30. <image :src="domain+'/static/diy/linefx'+keyColor+'.png'"></image>
  31. <view class="name">推荐礼包</view>
  32. <image :src="domain+'/static/diy/linefx'+keyColor+'.png'" class="right"></image>
  33. </view>
  34. <view v-if="fastList.length > 0" class='scroll-product'>
  35. <scroll-view class="scroll-view_x" scroll-x style="width:auto;overflow:hidden;">
  36. <block v-for="(item,index) in fastList" :key='index'>
  37. <view class="itemCon">
  38. <view class="item acea-row row-right">
  39. <view class="picTxt acea-row row-between-wrapper" @click="godDetail(item)">
  40. <view class="pictrue">
  41. <image :src="item.image"></image>
  42. </view>
  43. <view class="text">
  44. <view class="name line1">{{item.store_name}}</view>
  45. <!-- <text v-if="item.merchant && item.merchant.type_name" class="font-bg-red mt8 b-color">{{item.merchant.type_name}}</text>
  46. <text v-else-if="item.merchant && item.merchant.is_trader" class="font-bg-red mt8 b-color">自营</text> -->
  47. <view class="acea-row row-bottom price_count">
  48. <view class="money p-color"><text class="num">{{item.price}}</text></view>
  49. <view v-if="item.show_svip_info&&item.show_svip_info.show_svip_price&&item.svip_price" class="acea-row row-middle svip-count">
  50. <text class='vip-money'>{{item.svip_price}}</text>
  51. <view class="vipImg">
  52. <image :src="`${domain}/static/images/svip.png`"></image>
  53. </view>
  54. </view>
  55. </view>
  56. </view>
  57. </view>
  58. <view class="circular"></view>
  59. <view class="open b-color" @click="goBuy(item)">立即开通</view>
  60. </view>
  61. </view>
  62. </block>
  63. </scroll-view>
  64. </view>
  65. </view>
  66. <view class="pin" v-if="openActivity">
  67. <view class="public_title acea-row row-center-wrapper">
  68. <image :src="domain+'/static/diy/linefx'+keyColor+'.png'"></image>
  69. <view class="name">{{title}}</view>
  70. <image :src="domain+'/static/diy/linefx'+keyColor+'.png'" class="right"></image>
  71. </view>
  72. <view class="list">
  73. <view class="item acea-row row-between-wrapper" v-for="(item, index) in distribution" :key='index' @click="godDetail(item)">
  74. <view class="pictrue">
  75. <image :src="item.image"></image>
  76. </view>
  77. <view class="text">
  78. <view class="name line1">
  79. <!-- <text v-if="item.merchant && item.merchant.type_name" class="font-bg-red ml8 b-color">{{item.merchant.type_name}}</text>
  80. <text v-else-if="item.merchant && item.merchant.is_trader" class="font-bg-red ml8 b-color">自营</text> -->
  81. {{item.store_name}}
  82. </view>
  83. <view class="acea-row">
  84. <view class="money p-color"><text class="num">{{item.price}}</text></view>
  85. <view v-if="item.show_svip_info&&item.show_svip_info.show_svip_price&&item.svip_price" class="acea-row row-middle svip-count">
  86. <text class='vip-money'>{{item.svip_price}}</text>
  87. <view class="vipImg">
  88. <image :src="`${domain}/static/images/svip.png`"></image>
  89. </view>
  90. </view>
  91. </view>
  92. <view class="open b-color" @click.stop="goBuy(item)">立即开通</view>
  93. </view>
  94. </view>
  95. </view>
  96. <view class='loadingicon acea-row row-center-wrapper' v-if='distribution.length > 0 '>
  97. <text class='loading iconfont icon-jiazai' :hidden='loading==false'></text>{{loadTitle}}
  98. </view>
  99. </view>
  100. <view class="explainTxt" :class="explainShow?'on':''">
  101. <view class="name">分销说明<text class="iconfont icon-guanbi" @click="close"></text></view>
  102. <view class="conter">{{explainTxt}}</view>
  103. </view>
  104. <view class="mask" v-if="explainShow"></view>
  105. <!-- 组件 -->
  106. <productWindow :attr="attr" :isShow='1' :iSplus='1' :destri='1' :svipPrice="true" @myevent="onMyEvent" @ChangeAttr="ChangeAttr"
  107. @attrVal="attrVal" @iptCartNum="iptCartNum" @goCat="goPay" id='product-window'></productWindow>
  108. </view>
  109. </template>
  110. <script>
  111. // +----------------------------------------------------------------------
  112. // | CRMEB [ CRMEB赋能开发者,助力企业发展 ]
  113. // +----------------------------------------------------------------------
  114. // | Copyright (c) 2016~2024 https://www.crmeb.com All rights reserved.
  115. // +----------------------------------------------------------------------
  116. // | Licensed CRMEB并不是自由软件,未经许可不能去掉CRMEB相关版权
  117. // +----------------------------------------------------------------------
  118. // | Author: CRMEB Team <admin@crmeb.com>
  119. // +----------------------------------------------------------------------
  120. import { getUserInfo } from '@/api/user.js';
  121. import { goShopDetail } from '@/libs/order.js'
  122. import { postCartAdd } from '@/api/store.js';
  123. import { bagExplain, bagRecommend, productBag, getProductDetail } from '@/api/store.js';
  124. import ProductWindow from "@/components/productWindow";
  125. import { mapGetters } from "vuex";
  126. import { HTTP_REQUEST_URL } from '@/config/app';
  127. export default {
  128. components: {
  129. ProductWindow
  130. },
  131. computed: mapGetters(['viewColor','keyColor']),
  132. data() {
  133. return {
  134. domain: HTTP_REQUEST_URL,
  135. explainShow: false,
  136. menus: [],
  137. fastList: [],
  138. userInfo: {},
  139. distribution: [],
  140. explainTxt: '',
  141. attr: {
  142. cartAttr: false,
  143. productAttr: [],
  144. productSelect: {}
  145. },
  146. productValue: [], //系统属性
  147. storeInfo: {},
  148. attrValue: '', //已选属性
  149. attrTxt: '请选择', //属性页面提示
  150. cart_num: 1, //购买数量
  151. id: 0, //产品id
  152. loadend: false,
  153. loading: false,
  154. loadTitle: '加载更多',
  155. where: {
  156. page: 1,
  157. limit: 20,
  158. },
  159. openActivity: false,
  160. title: "推荐礼包"
  161. }
  162. },
  163. onLoad() {},
  164. onShow: function() {
  165. this.bagExplain();
  166. this.productBag();
  167. this.bagRecommend();
  168. this.getUserInfo();
  169. },
  170. // 滚动到底部
  171. onReachBottom() {
  172. this.productBag();
  173. },
  174. methods: {
  175. goBuy: function(item) {
  176. let that = this;
  177. that.id = item.product_id;
  178. that.getGoodsDetails(item);
  179. },
  180. onMyEvent: function() {
  181. this.$set(this.attr, 'cartAttr', false);
  182. },
  183. /**
  184. * 获取产品详情
  185. *
  186. */
  187. getGoodsDetails: function(item) {
  188. uni.showLoading({
  189. title: '加载中',
  190. mask: true
  191. });
  192. let that = this;
  193. getProductDetail(item.product_id).then(res => {
  194. uni.hideLoading();
  195. that.attr.cartAttr = true;
  196. let storeInfo = res.data;
  197. that.$set(that, 'storeInfo', storeInfo);
  198. that.$set(that.attr, 'productAttr', res.data.attr);
  199. that.$set(that, 'productValue', res.data.sku);
  200. that.DefaultSelect();
  201. }).catch(err => {
  202. uni.hideLoading();
  203. })
  204. },
  205. /**
  206. * 属性变动赋值
  207. *
  208. */
  209. ChangeAttr: function(res) {
  210. let productSelect = this.productValue[res];
  211. if (productSelect && productSelect.stock > 0) {
  212. this.$set(this.attr.productSelect, "image", productSelect.image);
  213. this.$set(this.attr.productSelect, "price", productSelect.price);
  214. this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
  215. this.$set(this.attr.productSelect, "stock", productSelect.stock);
  216. this.$set(this.attr.productSelect, "unique", productSelect.unique);
  217. this.$set(this.attr.productSelect, "cart_num", 1);
  218. this.$set(this, "attrValue", res);
  219. this.$set(this, "attrTxt", "已选择");
  220. } else {
  221. this.$set(this.attr.productSelect, "image", this.storeInfo.image);
  222. this.$set(this.attr.productSelect, "price", this.storeInfo.price);
  223. this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
  224. this.$set(this.attr.productSelect, "stock", 0);
  225. this.$set(this.attr.productSelect, "unique", "");
  226. this.$set(this.attr.productSelect, "cart_num", 0);
  227. this.$set(this, "attrValue", "");
  228. this.$set(this, "attrTxt", "请选择");
  229. }
  230. },
  231. /**
  232. * 默认选中属性
  233. *
  234. */
  235. DefaultSelect: function() {
  236. let productAttr = this.attr.productAttr;
  237. let value = [];
  238. let arr = [];
  239. let unSortArr = [];
  240. for (var key in this.productValue) {
  241. if (this.productValue[key].stock > 0) {
  242. value = this.attr.productAttr.length ? key.split(",") : [];
  243. break;
  244. }
  245. }
  246. for (let i = 0; i < productAttr.length; i++) {
  247. this.$set(productAttr[i], "index", value[i]);
  248. }
  249. //sort();排序函数:数字-英文-汉字;
  250. let productSelect = this.productValue[value.join(",")];
  251. if (productSelect && productAttr.length) {
  252. this.$set(
  253. this.attr.productSelect,
  254. "store_name",
  255. this.storeInfo.store_name
  256. );
  257. this.$set(this.attr.productSelect, "image", productSelect.image);
  258. this.$set(this.attr.productSelect, "price", productSelect.price);
  259. this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
  260. this.$set(this.attr.productSelect, "stock", productSelect.stock);
  261. this.$set(this.attr.productSelect, "unique", productSelect.unique);
  262. this.$set(this, "attrValue", value.join(","));
  263. this.$set(this, "attrTxt", "已选择");
  264. if (productSelect.stock == 0) {
  265. this.$set(this.attr.productSelect, "cart_num", 0);
  266. } else {
  267. this.$set(this.attr.productSelect, "cart_num", 1);
  268. }
  269. } else if (!productSelect && productAttr.length) {
  270. this.$set(
  271. this.attr.productSelect,
  272. "store_name",
  273. this.storeInfo.store_name
  274. );
  275. this.$set(this.attr.productSelect, "image", this.storeInfo.image);
  276. this.$set(this.attr.productSelect, "price", this.storeInfo.price);
  277. this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
  278. this.$set(this.attr.productSelect, "stock", 0);
  279. this.$set(this.attr.productSelect, "unique", "");
  280. this.$set(this.attr.productSelect, "cart_num", 0);
  281. this.$set(this, "attrValue", "");
  282. this.$set(this, "attrTxt", "请选择");
  283. } else if (!productSelect && !productAttr.length) {
  284. this.$set(
  285. this.attr.productSelect,
  286. "store_name",
  287. this.storeInfo.store_name
  288. );
  289. this.$set(this.attr.productSelect, "image", this.storeInfo.image);
  290. this.$set(this.attr.productSelect, "price", this.storeInfo.price);
  291. this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
  292. this.$set(this.attr.productSelect, "stock", this.storeInfo.stock);
  293. this.$set(
  294. this.attr.productSelect,
  295. "unique",
  296. this.storeInfo.unique || ""
  297. );
  298. this.$set(this.attr.productSelect, "cart_num", 1);
  299. this.$set(this, "attrValue", "");
  300. this.$set(this, "attrTxt", "请选择");
  301. } else if (productSelect && !productAttr.length) {
  302. this.$set(
  303. this.attr.productSelect,
  304. "store_name",
  305. this.storeInfo.store_name
  306. );
  307. this.$set(this.attr.productSelect, "image", productSelect.image);
  308. this.$set(this.attr.productSelect, "price", productSelect.price);
  309. this.$set(this.attr.productSelect, "svip_price", productSelect.svip_price);
  310. this.$set(this.attr.productSelect, "stock", productSelect.stock);
  311. this.$set(this.attr.productSelect, "unique", productSelect.unique);
  312. this.$set(this, "attrValue", value.join(","));
  313. this.$set(this, "attrTxt", "已选择");
  314. if (productSelect.stock == 0) {
  315. this.$set(this.attr.productSelect, "cart_num", 0);
  316. } else {
  317. this.$set(this.attr.productSelect, "cart_num", 1);
  318. }
  319. }
  320. },
  321. /**
  322. * 购物车数量加和数量减
  323. *
  324. */
  325. ChangeCartNum: function(changeValue) {
  326. //changeValue:是否 加|减
  327. //获取当前变动属性
  328. let productSelect = this.productValue[this.attrValue];
  329. //如果没有属性,赋值给商品默认库存
  330. if (productSelect === undefined && !this.attr.productAttr.length)
  331. productSelect = this.attr.productSelect;
  332. //无属性值即库存为0;不存在加减;
  333. if (productSelect === undefined) return;
  334. let stock = productSelect.stock || 0;
  335. let num = this.attr.productSelect;
  336. if (changeValue) {
  337. num.cart_num++;
  338. if (num.cart_num > stock) {
  339. this.$set(this.attr.productSelect, "cart_num", stock);
  340. this.$set(this, "cart_num", stock);
  341. }
  342. } else {
  343. num.cart_num--;
  344. if (num.cart_num < 1) {
  345. this.$set(this.attr.productSelect, "cart_num", 1);
  346. this.$set(this, "cart_num", 1);
  347. }
  348. }
  349. },
  350. attrVal(val) {
  351. this.$set(this.attr.productAttr[val.indexw], 'index', this.attr.productAttr[val.indexw].attr_values[val.indexn]);
  352. },
  353. /**
  354. * 购物车手动填写
  355. *
  356. */
  357. iptCartNum: function(e) {
  358. this.$set(this.attr.productSelect, 'cart_num', e);
  359. },
  360. // 立即购买
  361. goPay() {
  362. let that = this,
  363. productSelect = that.productValue[this.attrValue];
  364. if (
  365. that.attr.productAttr.length &&
  366. productSelect.stock == 0
  367. )
  368. return that.$util.Tips({
  369. title: "产品库存不足,请选择其它"
  370. });
  371. let q = {
  372. product_id: that.id,
  373. cart_num: Number(that.attr.productSelect.cart_num),
  374. is_new: 1,
  375. product_attr_unique: that.attr.productSelect !== undefined ? that.attr.productSelect.unique : ""
  376. };
  377. postCartAdd(q)
  378. .then(function(res) {
  379. that.attr.cartAttr = false;
  380. uni.navigateTo({
  381. url: '/pages/users/order_confirm/index?cartId=' + res.data.cart_id
  382. });
  383. })
  384. .catch(res => {
  385. return that.$util.Tips({
  386. title: res
  387. });
  388. });
  389. },
  390. // 去商品详情
  391. godDetail(item) {
  392. goShopDetail(item).then(res => {
  393. uni.navigateTo({
  394. url: `/pages/goods_details/index?id=${item.product_id}`
  395. })
  396. })
  397. },
  398. // 分销
  399. productBag: function() {
  400. let that = this;
  401. if (that.loadend) return;
  402. if (that.loading) return;
  403. that.loading = true;
  404. that.loadTitle = '';
  405. productBag(that.where).then(res => {
  406. let list = res.data.list;
  407. let productList = that.$util.SplitArray(list, that.distribution);
  408. let loadend = list.length < that.where.limit;
  409. that.loadend = loadend;
  410. that.loading = false;
  411. that.loadTitle = loadend ? '已全部加载' : '加载更多';
  412. that.title = res.data.title;
  413. that.$set(that, 'distribution', productList);
  414. that.$set(that.where, 'page', that.where.page + 1);
  415. }).catch(err => {
  416. that.loading = false;
  417. that.loadTitle = '加载更多';
  418. });
  419. },
  420. // 推荐
  421. bagRecommend: function() {
  422. let that = this;
  423. bagRecommend().then(res => {
  424. this.fastList = res.data.list
  425. })
  426. },
  427. /**
  428. * 获取个人用户信息
  429. */
  430. getUserInfo: function() {
  431. let that = this;
  432. getUserInfo().then(res => {
  433. that.userInfo = res.data
  434. });
  435. },
  436. // 说明以及导航
  437. bagExplain: function() {
  438. let that = this;
  439. bagExplain().then(res => {
  440. let data = res.data;
  441. this.menus = data.data;
  442. this.explainTxt = data.explain;
  443. this.openActivity = true
  444. }).catch(res => {
  445. this.openActivity = false
  446. return that.$util.Tips({
  447. title: res
  448. });
  449. });
  450. },
  451. explain() {
  452. this.explainShow = true;
  453. },
  454. close() {
  455. this.explainShow = false;
  456. }
  457. }
  458. }
  459. </script>
  460. <style lang="scss" scoped>
  461. page {
  462. background-color: #fff;
  463. }
  464. .area-row {
  465. overflow: hidden;
  466. text-overflow: ellipsis;
  467. white-space: nowrap;
  468. display: block;
  469. width: 80%;
  470. text-align: center;
  471. }
  472. .b-color {
  473. border: 1rpx solid var(--view-theme);
  474. background-color: var(--view-theme);
  475. }
  476. .vip-money {
  477. color: #282828;
  478. font-size: 22rpx;
  479. margin-left: 6rpx;
  480. font-weight: bold;
  481. }
  482. .vipImg {
  483. width: 65rpx;
  484. height: 28rpx;
  485. margin: 4rpx 0 0 4rpx;
  486. image {
  487. width: 100%;
  488. height: 100%;
  489. display: block;
  490. }
  491. }
  492. .distributor {
  493. .headerBg {
  494. width: 100%;
  495. height: 371rpx;
  496. background-size: 100% 100%;
  497. background-repeat: no-repeat;
  498. position: relative;
  499. .explain {
  500. position: absolute;
  501. top: 30rpx;
  502. right: 0;
  503. width: 134rpx;
  504. height: 40rpx;
  505. background: linear-gradient(-90deg, rgba(239, 215, 168, 1) 0%, rgba(248, 230, 193, 1) 100%);
  506. border-radius: 20px 0px 0px 20px;
  507. color: var(--view-theme);
  508. font-size: 24rpx;
  509. font-weight: 500;
  510. text-align: center;
  511. line-height: 40rpx;
  512. }
  513. .picTxt {
  514. position: absolute;
  515. left: 60rpx;
  516. bottom: 38rpx;
  517. .pictrue {
  518. width: 84rpx;
  519. height: 84rpx;
  520. border-radius: 50%;
  521. image {
  522. width: 100%;
  523. height: 100%;
  524. border-radius: 50%;
  525. }
  526. }
  527. .text {
  528. font-size: 34rpx;
  529. color: #814C07;
  530. margin-left: 19rpx;
  531. width: 500rpx;
  532. }
  533. .info {
  534. font-size: 28rpx;
  535. color: #BB8D59;
  536. margin-top: 10rpx;
  537. }
  538. }
  539. }
  540. .nav {
  541. padding: 0 0rpx 30rpx;
  542. flex-wrap: wrap;
  543. .item {
  544. display: flex;
  545. flex-direction: column;
  546. align-items: center;
  547. justify-content: center;
  548. width: 25%;
  549. margin-top: 30rpx;
  550. image {
  551. width: 48rpx;
  552. height: 48rpx;
  553. border-radius: 50%;
  554. position: relative;
  555. top: 20rpx;
  556. }
  557. .picture{
  558. border: 40rpx solid #FFF8EC;
  559. }
  560. .menu-txt {
  561. color: #B99450;
  562. font-size: 32rpx;
  563. margin-top: 20rpx;
  564. }
  565. }
  566. }
  567. .public_title {
  568. margin-top: 20rpx;
  569. image {
  570. width: 119rpx;
  571. height: 15rpx;
  572. &.right {
  573. transform: rotate(180deg);
  574. }
  575. }
  576. .name {
  577. font-size: 34rpx;
  578. color: var(--view-theme);
  579. margin: 0 19rpx;
  580. }
  581. }
  582. .recommend {
  583. .scroll-product {
  584. white-space: nowrap;
  585. margin-top: 45rpx;
  586. padding-left: 30rpx;
  587. height: 200rpx;
  588. .scroll-view_x {
  589. height: 100%;
  590. }
  591. .itemCon {
  592. display: inline-block;
  593. .item {
  594. width: 430rpx;
  595. height: 156rpx;
  596. margin-right: 30rpx;
  597. border-radius: 8rpx;
  598. position: relative;
  599. box-shadow: 0 10rpx 20rpx -5rpx #eee;
  600. .circular {
  601. width: 20rpx;
  602. height: 20rpx;
  603. border-radius: 50%;
  604. position: absolute;
  605. top: 50%;
  606. margin-top: -10rpx;
  607. right: 40rpx;
  608. background: var(--view-theme);
  609. }
  610. .open {
  611. width: 60rpx;
  612. writing-mode: vertical-lr;
  613. writing-mode: tb-lr;
  614. color: #fff;
  615. height: 100%;
  616. text-align: center;
  617. line-height: 70rpx;
  618. border-radius: 0 8rpx 8rpx 0;
  619. border: none;
  620. }
  621. .picTxt {
  622. width: 382rpx;
  623. height: 100%;
  624. border-radius: 0 8rpx 8rpx 0;
  625. position: absolute;
  626. left: 0;
  627. top: 0;
  628. background-color: #fff;
  629. .pictrue {
  630. width: 156rpx;
  631. height: 100%;
  632. image {
  633. width: 100%;
  634. height: 100%;
  635. border-radius: 8rpx 0 0 8rpx;
  636. }
  637. }
  638. .text {
  639. width: 210rpx;
  640. padding-right: 10rpx;
  641. box-sizing: border-box;
  642. .name {
  643. width: 210rpx;
  644. font-size: 26rpx;
  645. color: #282828;
  646. white-space: nowrap;
  647. text-overflow: ellipsis;
  648. overflow: hidden;
  649. margin-bottom: 20rpx;
  650. }
  651. .price_count{
  652. height: 76rpx;
  653. }
  654. .money {
  655. font-size: 28rpx;
  656. color: var(--view-priceColor);
  657. font-weight: bold;
  658. .num {
  659. font-size: 32rpx;
  660. }
  661. }
  662. }
  663. }
  664. }
  665. }
  666. }
  667. }
  668. .pin {
  669. .list {
  670. padding-left: 30rpx;
  671. margin-top: 50rpx;
  672. .item {
  673. position: relative;
  674. .pictrue {
  675. width: 210rpx;
  676. height: 210rpx;
  677. border-radius: 16px;
  678. image {
  679. width: 100%;
  680. height: 100%;
  681. }
  682. }
  683. &~.item {
  684. margin-top: 60rpx;
  685. .text {
  686. &::after {
  687. width: 100%;
  688. height: 1px;
  689. position: absolute;
  690. content: '';
  691. top: -30rpx;
  692. background-color: #F0F0F0;
  693. }
  694. }
  695. }
  696. .text {
  697. position: relative;
  698. width: 460rpx;
  699. font-size: 30rpx;
  700. color: #282828;
  701. padding: 10rpx 30rpx 24rpx 0;
  702. .name{
  703. height: 70rpx;
  704. }
  705. .money {
  706. font-size: 28rpx;
  707. color: var(--view-priceColor);
  708. font-weight: bold;
  709. .num {
  710. font-size: 36rpx;
  711. }
  712. }
  713. .open {
  714. width: 144rpx;
  715. height: 48rpx;
  716. border-radius: 24rpx;
  717. color: #fff;
  718. text-align: center;
  719. line-height: 48rpx;
  720. font-size: 24rpx;
  721. right: 30rpx;
  722. border: none;
  723. margin-top: 40rpx;
  724. }
  725. }
  726. }
  727. }
  728. }
  729. .explainTxt {
  730. position: fixed;
  731. top: 20%;
  732. left: 50%;
  733. width: 600rpx;
  734. background-color: #fff;
  735. margin-left: -300rpx;
  736. border-radius: 8rpx;
  737. z-index: 32;
  738. padding: 33rpx;
  739. transition: all 0.3s ease-in-out 0s;
  740. opacity: 0;
  741. transform: scale(0);
  742. &.on {
  743. opacity: 1;
  744. transform: scale(1);
  745. }
  746. .name {
  747. font-size: 38rpx;
  748. position: relative;
  749. text-align: center;
  750. color: var(--view-theme);
  751. .iconfont {
  752. position: absolute;
  753. color: #999999;
  754. font-size: 37rpx;
  755. top: -10rpx;
  756. right: 0rpx;
  757. }
  758. }
  759. .conter {
  760. margin-top: 30rpx;
  761. font-size: 26rpx;
  762. color: #282828;
  763. line-height: 1.6;
  764. max-height: 600rpx;
  765. overflow-y: auto;
  766. }
  767. }
  768. }
  769. </style>