index.vue 22 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120
  1. <template>
  2. <view class="container">
  3. <view class="carousel-section">
  4. <!-- 背景色区域 -->
  5. <view class="bg"></view>
  6. <!-- 标题栏和状态栏占位符 -->
  7. <!-- #ifdef H5 -->
  8. <view class="titleNview-placing"></view>
  9. <!-- #endif -->
  10. <!-- 搜素栏 -->
  11. <view class="search flex">
  12. <view class="input-box flex" @click.stop="clickSearch">
  13. <view class=" input-content flex">
  14. <view class="iconfont iconsearch"></view>
  15. <view class="input"><input type="text" disabled value="好物从搜索开始" /></view>
  16. </view>
  17. </view>
  18. </view>
  19. <swiper class="carousel" autoplay="true" duration="400" interval="5000" @change="swiperChange"
  20. :indicator-dots="true" indicator-active-color="#FFFFFF">
  21. <swiper-item v-for="(item, index) in carouselList" :key="index" class="carousel-item">
  22. <image :src="item.pic" mode="aspectFill" @click="bannerNavToUrl(item)"></image>
  23. </swiper-item>
  24. </swiper>
  25. </view>
  26. <view class="navbar">
  27. <view class="navbar-box flex">
  28. <view class="navbar-item" @click="navTo('/pages/product/list')">
  29. <image class="nitem-image" src="../../static/sy/sy12.png" mode=""></image>
  30. <view class="nitem-font">全部分类</view>
  31. </view>
  32. <view class="navbar-item" @click="navTo('/pages/index/vipShop')">
  33. <image class="nitem-image" src="../../static/sy/sy14.png" mode=""></image>
  34. <view class="nitem-font">超值拼团</view>
  35. </view>
  36. <view class="navbar-item" @click="navTo('/user/page/couponList')">
  37. <image class="nitem-image" src="../../static/sy/sy15.png" mode=""></image>
  38. <view class="nitem-font">优惠券大厅</view>
  39. </view>
  40. <view class="navbar-item" @click="navTo('/user/page/shareQrCode')">
  41. <image class="nitem-image" src="../../static/sy/sy13.png" mode=""></image>
  42. <view class="nitem-font">邀请有礼</view>
  43. </view>
  44. </view>
  45. </view>
  46. <store></store>
  47. <seckill></seckill>
  48. <view class="product-box">
  49. <view class="product-title">
  50. <view class="bb">
  51. </view>
  52. <view class="pt-title">猜你喜欢</view>
  53. <view class="bb">
  54. </view>
  55. </view>
  56. <view class="hotgoods">
  57. <view class="hotgoods-item" v-for="item in firstList" :key="item.id" @click="navToDetailPage(item)">
  58. <!-- <view class="yuezhuan">
  59. <image src="../../static/icon/yz.png"></image>
  60. <view>
  61. <view >约赚</view>
  62. <view>¥{{ item.recommend }}</view>
  63. </view>
  64. </view> -->
  65. <view class="image-wrapper">
  66. <image class="image" :src="item.image" mode="scaleToFill"></image>
  67. </view>
  68. <view class="hotgoods-box">
  69. <view class="title clamp2">{{ item.store_name }}</view>
  70. <view class="titlee">{{ item.store_name }}</view>
  71. </view>
  72. <view class="hot-price">
  73. <!-- <view class="hotPrice-box">会员价</view> -->
  74. <view class="price">
  75. <text class="font-size-sm">¥</text>
  76. {{ item.price * 1 }}
  77. </view>
  78. <view class="yuanPrice">原价{{ item.price }}</view>
  79. </view>
  80. </view>
  81. </view>
  82. </view>
  83. <!-- <u-tabbar activeColor="#434A54" v-model="current" :list="tabbar" :mid-button="true"></u-tabbar> -->
  84. </view>
  85. </template>
  86. <script>
  87. // #ifdef H5
  88. import jWeixin from "@/plugin/jweixin-module/index.js";
  89. // #endif
  90. import {
  91. shareFun
  92. } from '@/utils/wxAuthorized.js'
  93. import {
  94. lookSubpoints,
  95. lookOneself
  96. } from '../../api/user.js';
  97. import seckill from '../../components/seckill/seckill.vue';
  98. import store from '../../components/store/store.vue';
  99. import {
  100. loadIndexs,
  101. getVip,
  102. mer
  103. } from '@/api/index.js';
  104. import {
  105. getUserInfo,
  106. spread
  107. } from '@/api/user.js';
  108. import {
  109. setCoupons
  110. } from '@/api/functionalUnit.js';
  111. import {
  112. getBargainList
  113. } from '@/api/product.js';
  114. import {
  115. interceptor
  116. } from '@/utils/loginUtils';
  117. import {
  118. mapState,
  119. mapMutations
  120. } from 'vuex';
  121. import {
  122. tabbar
  123. } from '@/utils/tabbar.js';
  124. // #ifdef H5
  125. import {
  126. weixindata,
  127. shareLoad
  128. } from '@/utils/wxAuthorized';
  129. // #endif
  130. export default {
  131. components: {
  132. seckill,
  133. store
  134. },
  135. data() {
  136. return {
  137. // isDa:true,
  138. tabbar: tabbar,
  139. current: 0,
  140. shareShow: false, //分享海报
  141. pageProportion: 0, //保存页面基于750宽度的比例
  142. swiperHeight: 0,
  143. checkid: 0,
  144. titleNViewBackground: '',
  145. longitude: 0, //经度
  146. latitude: 0, //纬度
  147. swiperCurrent: 0,
  148. swiperLength: 0,
  149. carouselList: [], //轮播列表
  150. bastList: [], //会员礼包
  151. shoplist: [], //商店列表
  152. page: 1,
  153. limit: 5,
  154. vipList: [], //vip商品
  155. firstList: [],
  156. };
  157. },
  158. computed: {
  159. ...mapState(['loginInterceptor', 'baseURL']),
  160. ...mapState('user', ['hasLogin', 'userInfo'])
  161. },
  162. onLoad: function(option) {
  163. // #ifdef MP-WEIXIN
  164. wx.showShareMenu({
  165. withShareTicket:true,
  166. menus:["shareAppMessage","shareTimeline"]
  167. })
  168. //#endif
  169. if (option.spread) {
  170. console.log(option.spread, "邀请人2")
  171. uni.setStorageSync('puid', option.spread)
  172. }
  173. if (option.mer_id) {
  174. console.log(option.mer_id, "商户id")
  175. uni.setStorageSync('mid', option.mer_id)
  176. }
  177. // #ifdef H5
  178. this.IndexShare();
  179. //#endif
  180. },
  181. // #ifdef MP-WEIXIN
  182. onShareAppMessage(res) {
  183. console.log(888888)
  184. let path = 'spread=' + this.userInfo.uid;
  185. return {
  186. title: this.userInfo.nickname + '邀请您进入玲卿加', //分享的名称
  187. path:'pages/index/index?' + path,
  188. imageUrl: "https://hy.liuniu946.com/index/logo.jpg",
  189. }
  190. console.log('pages/index/index?' + path, '分享数据');
  191. },
  192. //分享到朋友圈
  193. onShareTimeline(res) {
  194. let path = 'spread=' + this.userInfo.uid;
  195. return {
  196. title: this.userInfo.nickname + '邀请您进入玲卿加', //分享的名称
  197. path: 'pages/index/index?' + path,
  198. imageUrl: "https://hy.liuniu946.com/index/logo.jpg"
  199. }
  200. },
  201. //#endif
  202. onShow: function() {
  203. let uid = uni.getStorageSync('sid');
  204. if (uid) {
  205. spread({
  206. puid: uid
  207. }).then(res => {
  208. console.log(res);
  209. })
  210. }
  211. let mid=uni.getStorageSync('mid')
  212. console.log(mid,'9090')
  213. if(mid){
  214. mer({
  215. mid:mid
  216. }).then(e => {
  217. });
  218. }
  219. getVip({
  220. page: 1,
  221. limit: 3,
  222. is_vip: 3
  223. }).then(res => {
  224. this.vipList = res.data
  225. res.data.forEach(e => {
  226. e.isVip = e.store_type ? "3" : "0"
  227. })
  228. console.log(res.data, 'vip商品');
  229. })
  230. this.loadData();
  231. this.getBargainList();
  232. },
  233. //下拉刷新
  234. onPullDownRefresh() {
  235. this.loadData();
  236. },
  237. // #ifndef MP
  238. // 监听导航栏输入框点击事件
  239. onNavigationBarSearchInputClicked(e) {
  240. //跳转到搜索页面
  241. this.clickSearch();
  242. },
  243. //点击导航栏 buttons 时触发
  244. onNavigationBarButtonTap(e) {
  245. const index = e.index;
  246. if (index === 0) {
  247. this.$api.msg('点击了扫描');
  248. } else if (index === 1) {
  249. // #ifdef APP-PLUS
  250. const pages = getCurrentPages();
  251. const page = pages[pages.length - 1];
  252. const currentWebview = page.$getAppWebview();
  253. currentWebview.hideTitleNViewButtonRedDot({
  254. index
  255. });
  256. // #endif
  257. uni.navigateTo({
  258. url: '/user/page/notice'
  259. });
  260. }
  261. },
  262. // #endif
  263. methods: {
  264. ...mapMutations(['setLat', 'setLon']),
  265. // #ifdef H5
  266. IndexShare() {
  267. let obj = this;
  268. let pages = getCurrentPages();
  269. // 获取当前页面
  270. let page = pages[pages.length - 1];
  271. let path = '#/' + page.route + '?';
  272. // 保存传值
  273. for (let i in page.options) {
  274. path += i + '=' + page.options[i] + '&';
  275. }
  276. console.log(obj.Path);
  277. // 保存邀请人
  278. path += 'spread=' + this.userInfo.uid;
  279. let data = {
  280. link: this.baseURL + '/index/' + path,
  281. title: this.userInfo.nickname + '邀请您进入玲卿加',
  282. desc: '欢迎加入玲卿加',
  283. imgUrl: 'https://hy.liuniu946.com/index/logo.jpg'
  284. };
  285. console.log(data, '分享数据');
  286. shareLoad(data);
  287. },
  288. // #endif
  289. getaddress() {
  290. console.log('dizhi+++++++++++');
  291. let obj = this;
  292. weixindata().then(wxOjb => {
  293. console.log(wxOjb, '获取微信');
  294. wxOjb.getLocation({
  295. type: 'gcj02',
  296. success: res => {
  297. console.log(res, 123456);
  298. obj.setLat(res.latitude);
  299. obj.setLon(res.longitude);
  300. },
  301. fail: err => {
  302. console.log(err, 'shi+++++++++++++++');
  303. openMap().then(e => {
  304. this.getaddress();
  305. });
  306. }
  307. });
  308. });
  309. },
  310. //砍价商品推荐详情页
  311. navToDetailPages(item) {
  312. let id = item.product_id;
  313. //let type = 2;
  314. uni.navigateTo({
  315. url: '/pages/product/product?id=' + id
  316. });
  317. },
  318. navTo(url) {
  319. if (url == '') {
  320. this.$api.msg('暂未开通,敬请期待');
  321. } else {
  322. uni.navigateTo({
  323. url
  324. });
  325. }
  326. },
  327. openSubscribe: function(e) {
  328. let page = e;
  329. // #ifndef MP
  330. uni.navigateTo({
  331. url: page
  332. });
  333. // #endif
  334. // #ifdef MP
  335. uni.showLoading({
  336. title: '正在加载'
  337. });
  338. openBargainSubscribe()
  339. .then(res => {
  340. uni.hideLoading();
  341. uni.navigateTo({
  342. url: page
  343. });
  344. })
  345. .catch(err => {
  346. uni.hideLoading();
  347. });
  348. // #endif
  349. },
  350. getBargainList() {
  351. let that = this;
  352. getBargainList({
  353. page: that.page,
  354. limit: that.limit
  355. })
  356. .then(function(res) {
  357. // that.$set(that, 'bargainlist', res.data.slice(0, 2));
  358. })
  359. .catch(res => {
  360. console.log(res, 'getBargainList');
  361. });
  362. },
  363. Mask() {
  364. this.MaskShow = false;
  365. this.shareShow = true;
  366. uni.setStorage({
  367. key: 'FirstEntry',
  368. data: true,
  369. success: function() {
  370. console.log(uni.getStorageSync('FirstEntry'), 'Mask');
  371. }
  372. });
  373. },
  374. Toshare() {
  375. if (this.userInfo == '') {
  376. getUserInfo({})
  377. .then(({
  378. data
  379. }) => {
  380. this.setUserInfo(data);
  381. this.userInfo = data;
  382. })
  383. .catch(e => {});
  384. } else {
  385. this.shareShow = false;
  386. uni.navigateTo({
  387. url: '/user/page/shareQrCode?spread=' + this.userInfo.uid
  388. });
  389. }
  390. },
  391. Tocancel() {
  392. this.shareShow = false;
  393. },
  394. // 监听切换事件
  395. listChange(e) {
  396. this.checkid = e.detail.current;
  397. },
  398. // 點擊搜索框
  399. clickSearch() {
  400. uni.navigateTo({
  401. url: '/pages/product/search'
  402. });
  403. },
  404. // 点击触发领取优惠券
  405. setCoupons(item) {
  406. // 判断是否已经领取了优惠券
  407. let obj = this;
  408. uni.showModal({
  409. title: '领取提示',
  410. content: '是否领取优惠券',
  411. success(e) {
  412. if (e.confirm) {
  413. setCoupons({
  414. couponId: item.id
  415. }).then(e => {
  416. item.is_use = true;
  417. uni.showToast({
  418. title: '领取成功',
  419. type: 'top',
  420. duration: 2000
  421. });
  422. });
  423. }
  424. }
  425. });
  426. },
  427. //商品种类切换
  428. change(item) {
  429. let id = item;
  430. this.checkid = id;
  431. if (this.checkid == 1) {
  432. // console.log(1);
  433. this.detail = this.selected_detail;
  434. } else if (this.checkid == 2) {
  435. // console.log(2);
  436. this.detail = this.new_product;
  437. } else {
  438. this.detail = this.cheap_good;
  439. }
  440. },
  441. // 监听图片加载完成
  442. onImageError(key, index) {
  443. this[key][index].image = '/static/error/errorImage.jpg';
  444. },
  445. // 请求载入数据
  446. async loadData() {
  447. loadIndexs({})
  448. .then(({
  449. data
  450. }) => {
  451. let goods = data.info;
  452. console.log(goods, '商品信息');
  453. this.carouselList = data.banner;
  454. this.swiperLength = this.carouselList.length;
  455. this.bastList = data.giftInfo; //会员礼包
  456. data.info.firstList.forEach(e => {
  457. e.isVip = e.store_type ? "3" : "0"
  458. })
  459. this.firstList = data.info.firstList //首页商品
  460. uni.stopPullDownRefresh();
  461. console.log(data,'0000000000000')
  462. })
  463. .catch(e => {
  464. uni.stopPullDownRefresh();
  465. });
  466. },
  467. //轮播图切换修改背景色
  468. swiperChange(e) {
  469. const index = e.detail.current;
  470. this.swiperCurrent = index;
  471. this.titleNViewBackground = this.carouselList[index].background;
  472. },
  473. //详情页
  474. navToDetailPage(item) {
  475. let id = item.id;
  476. uni.navigateTo({
  477. url: '/pages/product/product?id=' + id + '&isVip=' + 0
  478. });
  479. },
  480. // 轮播图跳转
  481. bannerNavToUrl(item) {
  482. // #ifdef H5
  483. console.log(item.wap_url.indexOf('http'), 'banner');
  484. if (item.wap_url.indexOf('http') >= 0) {
  485. window.location.href = item.wap_url;
  486. }
  487. // #endif
  488. //测试数据没有写id,用title代替
  489. uni.navigateTo({
  490. url: item.wap_url
  491. });
  492. }
  493. }
  494. };
  495. </script>
  496. <style lang="scss">
  497. page {
  498. background: #EEEFEE;
  499. }
  500. .yuezhuan{
  501. text-align: center;
  502. z-index: 99;
  503. position: absolute;
  504. text-align: center;
  505. width:40%;
  506. }
  507. .yuezhuan image{
  508. margin-top: -12rpx;
  509. float: right;
  510. width: 120rpx;
  511. height: 120rpx;
  512. }
  513. .yuezhuan>view{
  514. width: 60rpx;
  515. top: 5rpx;
  516. height: 40rpx;
  517. text-align: center !important;
  518. font-size: 22rpx;
  519. color: #AD0B04;
  520. margin-left: 206rpx;
  521. position: absolute;
  522. }
  523. .carousel-section {
  524. position: relative;
  525. /* #ifdef H5 */
  526. padding-top: 10px;
  527. /* #endif */
  528. .bg {
  529. position: absolute;
  530. top: 0;
  531. left: 0;
  532. width: 750rpx;
  533. height: 378rpx;
  534. image {
  535. width: 100%;
  536. height: 100%;
  537. }
  538. }
  539. .titleNview-placing {
  540. height: var(--status-bar-height);
  541. box-sizing: content-box;
  542. }
  543. .search {
  544. margin-bottom: 12rpx;
  545. background-color: #F75022;
  546. justify-content: flex-start;
  547. padding: 10rpx 32rpx 20rpx;
  548. align-items: center;
  549. .address {
  550. width: 32rpx;
  551. height: 38rpx;
  552. }
  553. .shop-name {
  554. height: 38rpx;
  555. position: relative;
  556. top: -4rpx;
  557. z-index: 100;
  558. font-size: 30rpx;
  559. font-family: PingFang SC;
  560. font-weight: 500;
  561. padding-left: 10rpx;
  562. }
  563. .shop-jt {
  564. margin-left: 8rpx;
  565. width: 16rpx;
  566. height: 10rpx;
  567. }
  568. .input-box {
  569. margin-left: 10rpx;
  570. position: relative;
  571. z-index: 99;
  572. width: 710rpx;
  573. height: 60rpx;
  574. background: #EEEEEE;
  575. border-radius: 30rpx;
  576. .input-content {
  577. position: relative;
  578. z-index: 11;
  579. border-radius: 99rpx;
  580. flex-grow: 1;
  581. padding: 5rpx 30rpx;
  582. background: #EEEEEE;
  583. .iconsearch {
  584. font-size: 50rpx;
  585. color: #CBCBCB;
  586. }
  587. .input {
  588. margin-left: 19rpx;
  589. flex-grow: 1;
  590. color: #CBCBCB;
  591. input {
  592. font-size: 28rpx;
  593. color: #CBCBCB;
  594. }
  595. }
  596. }
  597. .input-button {
  598. padding-left: 20rpx;
  599. font-size: $font-base;
  600. height: 100%;
  601. }
  602. }
  603. }
  604. }
  605. .carousel {
  606. position: relative;
  607. z-index: 3;
  608. width: 100%;
  609. height: 360rpx;
  610. .carousel-item {
  611. width: 100%;
  612. height: 100%;
  613. padding: 0 28rpx;
  614. overflow: hidden;
  615. }
  616. image {
  617. width: 100%;
  618. height: 100%;
  619. border-radius: $border-radius-sm;
  620. }
  621. }
  622. .navbar {
  623. position: relative;
  624. z-index: 2;
  625. padding: 0 50rpx;
  626. margin-top: -200rpx;
  627. width: 750rpx;
  628. height: 420rpx;
  629. background: #ffffff;
  630. border-radius: 40rpx;
  631. .navbar-box {
  632. padding-top: 250rpx;
  633. .navbar-item {
  634. display: flex;
  635. flex-direction: column;
  636. align-items: center;
  637. width: 20%;
  638. .nitem-image {
  639. width: 90rpx;
  640. height: 90rpx;
  641. }
  642. .nitem-font {
  643. margin-top: 22rpx;
  644. font-size: 26rpx;
  645. font-family: PingFang SC;
  646. font-weight: 500;
  647. color: #000000;
  648. }
  649. }
  650. }
  651. }
  652. .jx {
  653. background: #fff;
  654. width: 750rpx;
  655. }
  656. .jx-box {
  657. background: #fff;
  658. display: flex;
  659. flex-direction: column;
  660. align-items: center;
  661. width: 750rpx;
  662. .jx-box-title {
  663. margin: 50rpx 0;
  664. width: 610rpx;
  665. height: 30rpx;
  666. image {
  667. width: 100%;
  668. height: 100%;
  669. }
  670. }
  671. .jx-box-img {
  672. width: 750rpx;
  673. height: 220rpx;
  674. image {
  675. width: 100%;
  676. height: 100%;
  677. }
  678. }
  679. }
  680. .cai {
  681. display: flex;
  682. justify-content: center;
  683. align-items: center;
  684. padding-bottom: 20rpx;
  685. font-size: 28rpx;
  686. font-weight: 500;
  687. color: #999999;
  688. }
  689. .jx-box-content {
  690. display: flex;
  691. .content-left {
  692. margin: 20rpx 15rpx;
  693. width: 236rpx;
  694. height: 236rpx;
  695. background: #E2E2E2;
  696. border-radius: 10rpx;
  697. image {
  698. width: 100%;
  699. height: 100%;
  700. }
  701. }
  702. .content-right {
  703. display: flex;
  704. flex-direction: column;
  705. justify-content: space-around;
  706. .shop-name {
  707. width: 382rpx;
  708. font-size: 32rpx;
  709. font-weight: bold;
  710. color: #333333;
  711. overflow: hidden;
  712. text-overflow: ellipsis;
  713. display: -webkit-box;
  714. -webkit-box-orient: vertical;
  715. -webkit-line-clamp: 2;
  716. }
  717. .shop-content {
  718. width: 455rpx;
  719. display: flex;
  720. justify-content: space-between;
  721. .shop-content-left {
  722. display: flex;
  723. flex-direction: column;
  724. .price-box {
  725. display: flex;
  726. align-items: center;
  727. .yuan-price {
  728. font-size: 26rpx;
  729. font-weight: 500;
  730. text-decoration: line-through;
  731. color: #999999;
  732. }
  733. image {
  734. margin: 0 10rpx;
  735. width: 16rpx;
  736. height: 18rpx;
  737. }
  738. .j-price {
  739. font-size: 24rpx;
  740. font-weight: bold;
  741. color: #B59467;
  742. }
  743. }
  744. .price-x {
  745. font-size: 36rpx;
  746. font-weight: bold;
  747. color: #FF4C4C;
  748. }
  749. }
  750. .shop-content-right {
  751. margin-top: 20rpx;
  752. align-items: center;
  753. text-align: center;
  754. width: 137rpx;
  755. height: 52rpx;
  756. font-size: 26rpx;
  757. font-weight: 500;
  758. color: #fff;
  759. background: #f75022;
  760. border-radius: 26rpx;
  761. line-height: 52rpx;
  762. }
  763. }
  764. }
  765. }
  766. .product-box {
  767. margin-top: 20rpx;
  768. background: #ffffff;
  769. padding: 26rpx 30rpx 20rpx;
  770. .product-title {
  771. display: flex;
  772. align-items: center;
  773. justify-content: center;
  774. .pt-image {
  775. width: 36rpx;
  776. height: 36rpx;
  777. }
  778. .bb {
  779. width: 120rpx;
  780. height: 1rpx;
  781. background: #989898;
  782. }
  783. .pt-title {
  784. margin: 0 28rpx;
  785. font-size: 30rpx;
  786. font-weight: 500;
  787. color: #363636;
  788. }
  789. .pt-tip {
  790. margin-left: 16rpx;
  791. font-size: 20rpx;
  792. font-family: PingFang SC;
  793. font-weight: bold;
  794. color: #95a0b1;
  795. }
  796. }
  797. .hotgoods {
  798. margin-top: 38rpx;
  799. width: 100%;
  800. display: flex;
  801. flex-wrap: wrap;
  802. padding: 0 0 30rpx;
  803. .hotgoods-item {
  804. width: 44%;
  805. background: #FFFFFF;
  806. margin: 20rpx;
  807. box-shadow: 0px 0px 20px 0px rgba(50, 50, 52, 0.06);
  808. border-radius: 10px;
  809. .image-wrapper {
  810. width: 100%;
  811. height: 330rpx;
  812. border-radius: 3px;
  813. overflow: hidden;
  814. position: relative;
  815. .image-bg {
  816. position: absolute;
  817. top: 0;
  818. left: 0;
  819. right: 0;
  820. bottom: 0;
  821. width: 100%;
  822. height: 100%;
  823. opacity: 1;
  824. border-radius: 12rpx 12rpx 0 0;
  825. z-index: 2;
  826. }
  827. .image {
  828. width: 100%;
  829. height: 100%;
  830. opacity: 1;
  831. border-radius: 12rpx 12rpx 0 0;
  832. }
  833. }
  834. .title {
  835. margin-top: 20rpx;
  836. font-size: 28rpx;
  837. font-family: PingFang SC;
  838. font-weight: 500;
  839. color: #333333;
  840. }
  841. .hotgoods-box {
  842. height: 100rpx;
  843. }
  844. .titlee {
  845. margin-left: 15rpx;
  846. font-size: 26rpx;
  847. font-weight: 500;
  848. color: #666666;
  849. white-space: nowrap;
  850. overflow: hidden;
  851. text-overflow: ellipsis;
  852. }
  853. .hot-price {
  854. display: flex;
  855. justify-content: flex-start;
  856. align-items: center;
  857. padding: 14rpx 0 30rpx;
  858. .hotPrice-box {
  859. width: 70rpx;
  860. height: 28rpx;
  861. background: linear-gradient(90deg, #c79a4c, #f9df7f);
  862. border-radius: 5rpx;
  863. text-align: center;
  864. line-height: 28rpx;
  865. font-size: 20rpx;
  866. font-weight: 400;
  867. color: #ffffff;
  868. }
  869. .price {
  870. margin-left: 10rpx;
  871. font-size: 36rpx;
  872. color: #ff0000;
  873. font-weight: 500;
  874. }
  875. .yuanPrice {
  876. margin-left: 10rpx;
  877. font-size: 20rpx;
  878. font-family: PingFang SC;
  879. font-weight: 500;
  880. text-decoration: line-through;
  881. color: #999999;
  882. }
  883. .cart-icon {
  884. image {
  885. width: 44rpx;
  886. height: 44rpx;
  887. }
  888. }
  889. }
  890. }
  891. }
  892. }
  893. .shop {
  894. margin-top: 20rpx;
  895. background: #ffffff;
  896. padding: 0 12rpx;
  897. .shop-title {
  898. padding: 30rpx 0 20rpx;
  899. display: flex;
  900. align-items: center;
  901. border-bottom: 1px solid #e3e6e7;
  902. .shop-item {
  903. width: 25%;
  904. display: flex;
  905. align-items: center;
  906. justify-content: center;
  907. .sitem-font {
  908. font-size: 26rpx;
  909. font-family: PingFang SC;
  910. font-weight: bold;
  911. color: #333333;
  912. }
  913. .jt-down {
  914. width: 10rpx;
  915. height: 8rpx;
  916. margin-left: 12rpx;
  917. }
  918. }
  919. }
  920. }
  921. .shop-main {
  922. padding: 32rpx 18rpx 0 12rpx;
  923. align-items: flex-start;
  924. justify-content: flex-start;
  925. .main-left {
  926. width: 180rpx;
  927. height: 180rpx;
  928. border-radius: 10rpx;
  929. }
  930. .main-right {
  931. width: 500rpx;
  932. justify-content: space-between;
  933. align-items: flex-start;
  934. margin-left: 20rpx;
  935. padding: 13rpx 0 35rpx;
  936. border-bottom: 1px solid #eaeced;
  937. .shopm-info {
  938. max-width: 60%;
  939. line-height: 1;
  940. .shopm-title {
  941. display: flex;
  942. justify-content: flex-start;
  943. .shopmt-font {
  944. font-size: 34rpx;
  945. font-family: PingFang SC;
  946. font-weight: bold;
  947. color: #333333;
  948. }
  949. .shopmt-good {
  950. margin-left: 6rpx;
  951. width: 30rpx;
  952. height: 30rpx;
  953. border: 1px solid #ff4c4c;
  954. border-radius: 5rpx;
  955. font-size: 20rpx;
  956. font-family: PingFang SC;
  957. font-weight: 500;
  958. color: #ff4c4c;
  959. text-align: center;
  960. line-height: 30rpx;
  961. }
  962. }
  963. .address {
  964. margin-top: 16rpx;
  965. font-size: 24rpx;
  966. font-family: PingFang SC;
  967. font-weight: 500;
  968. color: #666666;
  969. }
  970. .shopmt-tip {
  971. position: relative;
  972. display: inline-block;
  973. flex-grow: 0;
  974. margin-top: 52rpx;
  975. padding: 8rpx;
  976. background: #fcf3f0;
  977. border-radius: 16rpx 16rpx 16rpx 0px;
  978. font-size: 20rpx;
  979. font-family: PingFang SC;
  980. font-weight: 500;
  981. color: #ff440d;
  982. }
  983. }
  984. .right {
  985. height: 100%;
  986. margin-top: 5rpx;
  987. display: flex;
  988. flex-direction: column;
  989. .mright-top {
  990. display: flex;
  991. justify-content: flex-end;
  992. align-items: center;
  993. .mrt-image {
  994. width: 20rpx;
  995. height: 28rpx;
  996. }
  997. .mrt-font {
  998. margin-left: 8rpx;
  999. font-size: 22rpx;
  1000. font-family: PingFang SC;
  1001. font-weight: 500;
  1002. color: #666666;
  1003. }
  1004. }
  1005. .mright-bottom {
  1006. margin-top: 80rpx;
  1007. display: flex;
  1008. justify-content: flex-end;
  1009. .mrb-item {
  1010. width: 46rpx;
  1011. height: 46rpx;
  1012. margin-left: 14rpx;
  1013. }
  1014. }
  1015. }
  1016. }
  1017. }
  1018. </style>