productGroup.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933
  1. <template>
  2. <view class="container">
  3. <!-- 轮播图 -->
  4. <top-swiper :imgList="imgList"></top-swiper>
  5. <!-- 拼团倒计时 -->
  6. <group-time :goodsObjact="goodsObjact" :key='goodsObjact.product_price' :seckillObj="seckillObj"></group-time>
  7. <!-- 拼团标题 -->
  8. <group-content :goodsObjact="goodsObjact"></group-content>
  9. <!-- 拼团到货时间及优惠 -->
  10. <discounts :mark='goodsObjact.mark' :Info="goodsObjact.info" @clickCoupon="Getcoupon" :showCoupon='false'></discounts>
  11. <!-- 规格信息 -->
  12. <!-- <fresh-detail :goodsObjact="goodsObjact"></fresh-detail> -->
  13. <!-- <view class="uni-padding-wrap pinklistbox" v-if="pinkTlist.length > 0">
  14. <view class="pinklist">
  15. <view v-for="(ls, ind) in showlist">
  16. <view class="flex pinklist_list">
  17. <view class="pink_img"><image :src="ls.avatar"></image></view>
  18. <view class="pink_name">{{ ls.nickname }}</view>
  19. <view class="pink_tpl">
  20. <view class="pink_people">
  21. 还差
  22. <text>{{ ls.count }}</text>
  23. 人拼团
  24. </view>
  25. </view>
  26. <view class="pint" @click="groupBooking(ls.id)">
  27. 去拼团
  28. <text class="iconfont iconenter"></text>
  29. </view>
  30. </view>
  31. </view>
  32. </view>
  33. <view class="More" @click="clickMore" v-if="more">查看更多</view>
  34. </view> -->
  35. <!-- <view class="ping-plan">
  36. <view class="participate-7 flex-between-center">
  37. <view class="participate-7-1">
  38. <text class="word" v-if="pink_type == 1">AA团</text>
  39. <text class="word" v-else>达人团</text>
  40. <text>玩法</text>
  41. </view>
  42. <view class="participate-7-1" @click="ToRule()">
  43. <text class="word1">详细规则</text>
  44. <image src="../../../static/img/img74.png"></image>
  45. </view>
  46. </view>
  47. <view class="participate-8 flex-between-center">
  48. <view class="participate-8-1">
  49. <image class="img1" src="https://shicai.liuniu946.com/img/img76.png"></image>
  50. <view class="word-1">开团/参团</view>
  51. <view class="word-2">拼团享低价</view>
  52. </view>
  53. <image src="https://shicai.liuniu946.com/img/img75.png"></image>
  54. <view class="participate-8-1">
  55. <image class="img2" src="https://shicai.liuniu946.com/img/img77.png"></image>
  56. <view class="word-1">邀请邻里参团</view>
  57. <view class="word-2">分享优惠多</view>
  58. </view>
  59. <image src="https://shicai.liuniu946.com/img/img75.png"></image>
  60. <view class="participate-8-1">
  61. <image class="img3" src="https://shicai.liuniu946.com/img/img78.png"></image>
  62. <view class="word-1">人满发货</view>
  63. <view class="word-2">人不满退款</view>
  64. </view>
  65. </view>
  66. </view> -->
  67. <!-- 大家都在拼 达人团显示 -->
  68. <!-- <now-list v-if="pink_type == 2" :recommendedlist="recommendedlist"></now-list> -->
  69. <!-- 图文详情 -->
  70. <content-text :description="description"></content-text>
  71. <!-- 底部高度撑开 -->
  72. <view class="contentBottomHeight"></view>
  73. <!-- 底部操作菜单 -->
  74. <view >
  75. <view >
  76. <group-bottom :peoplePrize='goodsObjact.people_prize' @buy="openPinkT" @specOPne="specOPne" :seckillObj="seckillObj" :many='many'></group-bottom>
  77. </view>
  78. </view>
  79. <!-- 规格-模态层弹窗 -->
  80. <view class="popup spec" :class="specClass" @touchmove.stop.prevent="stopPrevent" @click="toggleSpec()">
  81. <!-- 遮罩层 -->
  82. <view class="mask"></view>
  83. <view class="layer attr-content" @click.stop="stopPrevent">
  84. <view class="a-t">
  85. <image :src="actionImage"></image>
  86. <view class="right">
  87. <text class="name">{{ goodsObjact.store_name }}</text>
  88. <text class="price">¥{{ actionPrice * goodsNumber }}</text>
  89. <text class="stock">库存:{{ goodsStore }}件</text>
  90. <view class="selected" v-if="specList != ''">
  91. 已选:
  92. <text class="selected-text" v-for="(sItem, sIndex) in specSelected" :key="sIndex">{{ sItem }}</text>
  93. </view>
  94. </view>
  95. </view>
  96. <view v-for="(item, index) in specList" :key="index" class="attr-list">
  97. <text>{{ item.attr_name }}</text>
  98. <view class="item-list">
  99. <text
  100. v-for="(childItem, childIndex) in item.attr_value"
  101. :key="childIndex"
  102. class="tit"
  103. :class="{ selected: childItem.check }"
  104. @click="selectSpec(childItem, item, index)"
  105. >
  106. {{ childItem.attr }}
  107. </text>
  108. </view>
  109. </view>
  110. <!-- <view class="attr-list">
  111. <text>购买数量</text>
  112. <view class="item-list">
  113. <uni-number-box class="step" :isMin="true" :value="goodsNumber" :min="1" :max="goodsNumberMax" @eventChange="numberChange"></uni-number-box>
  114. </view>
  115. </view> -->
  116. <button class="btn" @click.stop="buy" v-show="buys_show">完成</button>
  117. <button class="btn" style="background-color: #999999;" v-show="buys_shows">售罄</button>
  118. </view>
  119. </view>
  120. <!-- 返回按钮 -->
  121. <return-button></return-button>
  122. </view>
  123. </template>
  124. <script>
  125. import { nowPinkLst } from '@/api/order.js';
  126. import {
  127. goodsDetail,
  128. cartAdd,
  129. collectAdd,
  130. collectDel,
  131. seckillGoods,
  132. groupGoods
  133. } from '@/api/product.js';
  134. import {
  135. mapState
  136. } from 'vuex';
  137. import store from '@/store/index.js';
  138. import {
  139. saveUrl
  140. } from '@/utils/loginUtils.js';
  141. import {
  142. timeComputed
  143. } from '@/utils/rocessor.js';
  144. // #ifdef H5
  145. import {
  146. weixindata
  147. } from '@/utils/wxAuthorized';
  148. // #endif
  149. // 头部轮播图
  150. import topSwiper from '../common/topSwiper.vue';
  151. // 拼团倒计时
  152. import groupTime from '../common/groupTime.vue';
  153. // 拼团标题
  154. import groupContent from '../common/groupContent.vue';
  155. // 拼团到货时间及优惠
  156. import discounts from '../common/discounts.vue';
  157. // 规格信息
  158. import freshDetail from '../common/freshDetail.vue';
  159. // 图文详情
  160. import contentText from '../common/contentText.vue';
  161. // 底部按钮
  162. import groupBottom from '../common/groupBottom.vue';
  163. // 返回按钮
  164. import returnButton from '@/components/returnButton.vue';
  165. // 大家还在拼
  166. import NowList from '@/components/newlist/nowList.vue';
  167. export default {
  168. components: {
  169. topSwiper,
  170. groupTime,
  171. groupContent,
  172. discounts,
  173. freshDetail,
  174. contentText,
  175. groupBottom,
  176. returnButton,
  177. NowList
  178. },
  179. data() {
  180. return {
  181. goodsStore: 0, //选中库存
  182. specList: [],
  183. buys_show: true,
  184. buys_shows: false,
  185. specSelected: [], //选中的分类
  186. reply: '', //评论
  187. list: '', //商品详情的数据
  188. type: 1, //默认支付方式add为
  189. goodsNumber: 1, //购买数量
  190. goodsid: '', //商品id
  191. description: '', //商品描述
  192. goodsObjact: {}, //保存商品数据
  193. //图片循环
  194. imgList: [],
  195. // 对比对象
  196. actionPrice: 0, //默认选中商品价格
  197. actionImage: '', //默认选中图片
  198. good_list: '', //猜你喜欢列表
  199. goodsNumberMax: 0, //最大可购买数量
  200. many:1,//1是单规格 2是多规格
  201. // 倒计时数据保存
  202. seckillObj: {
  203. stopTime: 0, //结束时间
  204. stop: false, //是否结束
  205. stopTimeH: 0, //小时
  206. stopTimeM: 0, //分钟
  207. stopTimeS: 0, //秒钟
  208. stopTimeD: 0, //天
  209. upTime: 0 //更新组件内部组件用
  210. },
  211. // 拼团数据保存
  212. pink: {
  213. id: '', //拼团编号
  214. uid: '', //用户编号
  215. people: '', //拼团人数
  216. price: '', //拼团价格
  217. stop_time: '', //拼团结束时间
  218. nickname: '', //团长昵称
  219. avatar: '', //团长头像
  220. count: '', //拼团剩余人数
  221. h: '', //时
  222. i: '', //分
  223. s: '' //秒
  224. },
  225. userInfo: '',
  226. pinkTlist: '', //拼团数据
  227. more: true, //查看更多按钮
  228. showlist: [],
  229. pink_type: 1, //拼团类别
  230. show: false, // 是否显示底部按钮
  231. recommendedlist:[],// 大家都在拼
  232. specClass: 'none' //显示隐藏弹窗
  233. };
  234. },
  235. filters: {
  236. parseIntTo(percent) {
  237. percent = +percent * 100;
  238. if (percent % 1 === 0) {
  239. return percent;
  240. } else {
  241. percent = percent.toFixed(1);
  242. return percent;
  243. }
  244. }
  245. },
  246. async onLoad(options) {
  247. let obj = this;
  248. obj.userInfo = uni.getStorageSync('userInfo');
  249. //保存商品id
  250. this.goodsid = options.id;
  251. if (options.show) {
  252. this.show = options.show;
  253. }
  254. console.log(this.show, 5656)
  255. // 判断有无人邀请
  256. if (options.spread) {
  257. // 存储邀请人
  258. uni.setStorageSync('spread', options.spread);
  259. }
  260. saveUrl();
  261. // 家在数据
  262. this.groupGoods();
  263. return;
  264. // 注册邀请信息
  265. // #ifdef H5
  266. let bool = uni.getStorageSync('weichatBrowser') || '';
  267. if (bool) {
  268. weixindata();
  269. }
  270. // #endif
  271. },
  272. computed: {
  273. ...mapState(['weichatObj', 'baseURL', 'urlFile'])
  274. },
  275. // 分享
  276. // onShareAppMessage(options) {
  277. // // 设置菜单中的转发按钮触发转发事件时的转发内容
  278. // let pages = getCurrentPages(); //获取加载的页面
  279. // let currentPage = pages[pages.length - 1]; //获取当前页面的对象
  280. // let url = currentPage.route; //当前页面url
  281. // let item = currentPage.options; //如果要获取url中所带的参数可以查看options
  282. // let shareObj = {
  283. // title: this.goodsObjact.title + ' 价格:' + this.goodsObjact.price, // 默认是小程序的名称(可以写slogan等)
  284. // path: url + '?id=' + item.id + '&spread=' + this.userInfo.uid, // 默认是当前页面,必须是以‘/’开头的完整路径
  285. // imageUrl: this.goodsObjact.image,
  286. // success: function(res) {
  287. // // 转发成功之后的回调
  288. // if (res.errMsg == 'shareAppMessage:ok') {}
  289. // },
  290. // fail: function() {
  291. // // 转发失败之后的回调
  292. // if (res.errMsg == 'shareAppMessage:fail cancel') {
  293. // // 用户取消转发
  294. // } else if (res.errMsg == 'shareAppMessage:fail') {
  295. // // 转发失败,其中 detail message 为详细失败信息
  296. // }
  297. // }
  298. // };
  299. // return shareObj;
  300. // },
  301. methods: {
  302. // 跳转详细规则
  303. ToRule() {
  304. if( this.pink_type == 1 ) {
  305. // AA团
  306. uni.navigateTo({
  307. url: '/pages/rule/AArule'
  308. })
  309. } else {
  310. // 达人团
  311. uni.navigateTo({
  312. url: '/pages/rule/DaRrule'
  313. })
  314. }
  315. },
  316. //选择规格
  317. selectSpec(item, arr, ind) {
  318. arr.attr_value.forEach(function(e) {
  319. e.check = false;
  320. });
  321. item.check = true;
  322. let obj = this;
  323. obj.specSelected[ind] = item.attr;
  324. let str = obj.specSelected.join(',');
  325. console.log(obj.productValue[str],116)
  326. if (obj.productValue[str]) {
  327. obj.buys_show = true;
  328. obj.buys_shows = false;
  329. obj.actionPrice = obj.productValue[str].price;
  330. obj.goodsNumberMax = obj.productValue[str].stock;
  331. obj.actionImage = obj.productValue[str].image;
  332. obj.uniqueId = obj.productValue[str].unique;
  333. if (obj.goodsType == 2) {
  334. obj.goodsStore = obj.productValue[str].quota;
  335. } else {
  336. obj.goodsStore = obj.productValue[str].product_stock;
  337. }
  338. } else {
  339. (obj.buys_show = false), (obj.buys_shows = true);
  340. }
  341. },
  342. // 立即购买
  343. buy(item) {
  344. let obj = this;
  345. /* obj.toggleSpec();
  346. this.specClass='show',
  347. console.log(obj.list.productValue.默认.unique)
  348. console.log(obj.chooseGoodsNumber,'chooseGoodsNumber')
  349. return */
  350. // 创建传值对象
  351. console.log(obj.list.productValue);
  352. console.log(obj.list);
  353. let data = {
  354. // cartNum: obj.goodsNumber, //商品数量
  355. cartNum: obj.chooseGoodsNumber, //商品数量
  356. uniqueId: obj.uniqueId, //商品标签
  357. new: 1, //商品是否新增加到购物车1为不加入0为加入
  358. mer_id: obj.shopId,
  359. combinationId: obj.goodsid, //拼团编号
  360. productId: obj.goodsObjact.product_id, //商品编号
  361. };
  362. this.specClass = 'none';
  363. cartAdd(data)
  364. .then(function(e) {
  365. let da = e.data;
  366. console.log(e);
  367. if (obj.type == 1) {
  368. // 跳转到支付页
  369. uni.navigateTo({
  370. url: '/pages/order/createOrder?id=' + da.cartId + '&goodsType=' + obj.goodsType
  371. });
  372. }
  373. if (obj.type == 2) {
  374. obj.$api.msg('成功加入购物车');
  375. obj.toggleSpec();
  376. }
  377. })
  378. .catch(e => {
  379. console.log(e);
  380. });
  381. },
  382. // 去开团
  383. ToKaiTuan(item) {
  384. let id = item.id;
  385. uni.navigateTo({
  386. url: '/pages/product/productGroup?id=' + id
  387. });
  388. },
  389. // 跳转页面
  390. navTo(url) {
  391. uni.navigateTo({
  392. url
  393. });
  394. },
  395. // 查看更多
  396. clickMore() {
  397. this.showlist = this.pinkTlist;
  398. console.log(this.showlist, 22);
  399. this.more = false;
  400. },
  401. //去拼团
  402. groupBooking(item) {
  403. uni.navigateTo({
  404. url: '/pages/groupBooking/groupdetails?id=' + item
  405. });
  406. },
  407. // 获取拼团商品详情
  408. groupGoods() {
  409. let obj = this;
  410. // // 大家还在拼
  411. // nowPinkLst({}).then(({data}) => {
  412. // this.recommendedlist = data;
  413. // })
  414. groupGoods({}, this.goodsid).then(function({
  415. data
  416. }) {
  417. let goods = data.storeInfo;
  418. obj.goodsObjact = goods;
  419. console.log(obj.goodsObjact, 88)
  420. console.log(Array.isArray(data.productValue), 99)
  421. if(Array.isArray(data.productValue) != true){
  422. obj.many = 2;
  423. obj.specList = data.productAttr;//保存产品属性
  424. obj.productValue = data.productValue; //保存属性值
  425. obj.specSelected = []; //初始化默认选择对象
  426. for (let i = 0; i < obj.specList.length; i++) {
  427. // 设置默认数据
  428. let attrValue = obj.specList[i].attr_value[0];
  429. attrValue.check = true;
  430. obj.specSelected.push(attrValue.attr);
  431. }
  432. let str = obj.specSelected.join(',');
  433. console.log(str,'str')
  434. // 设置默认值
  435. obj.actionPrice = obj.productValue[str].price;
  436. obj.goodsNumberMax = obj.productValue[str].stock;
  437. obj.actionImage = obj.productValue[str].image;
  438. obj.uniqueId = obj.productValue[str].unique;
  439. obj.goodsStore = obj.productValue[str].quota;
  440. }else{
  441. obj.many = 1;
  442. }
  443. console.log(obj.many,'obj.many')
  444. if (obj.goodsObjact.description != null) {
  445. obj.description = obj.goodsObjact.description.replace(/\<img/gi, '<img class="rich-img"');
  446. }
  447. obj.imgList = goods.images; //保存轮播图
  448. obj.actionPrice = goods.price; //保存默认选中商品价格
  449. obj.actionImage = goods.image_base; //保存默认选中商品图片
  450. obj.goodsNumberMax = 1; //保存默认选中最大可购买商品数量
  451. if (obj.goodsObjact.pink_type == 'AA团') {
  452. obj.pink_type = 1;
  453. } else {
  454. obj.pink_type = 2;
  455. }
  456. obj.pinkTlist = data.pink;
  457. obj.showlist = obj.pinkTlist.slice(0, 2);
  458. if (obj.pinkTlist.length <= 2) {
  459. obj.more = false;
  460. }
  461. // 保存结束时间
  462. obj.seckillObj.stopTime = goods.stop_time * 1000;
  463. // 获取当前时间
  464. let acitonTime = new Date();
  465. // 判断当前时间是否大于结束时间
  466. if (acitonTime.getTime() > obj.seckillObj.stopTime) {
  467. // 当前秒杀时间已经结束
  468. obj.seckillObj.stop = true;
  469. } else {
  470. // 计算倒计时
  471. let time = timeComputed(obj.seckillObj.stopTime)
  472. // 倒计时数据保存
  473. obj.seckillObj = {
  474. stopTime: goods.stop_time * 1000, //结束时间
  475. stop: false, //是否结束
  476. stopTimeD: time.day, //天
  477. stopTimeH: time.hours, //小时
  478. stopTimeM: time.minutes, //分钟
  479. stopTimeS: time.seconds, //秒钟
  480. upTime: (new Date()).getTime()
  481. }
  482. }
  483. });
  484. },
  485. // 立即购买
  486. openPinkT(item) {
  487. let obj = this;
  488. obj.type = item;
  489. // 创建传值对象
  490. let data = {
  491. cartNum: obj.goodsNumber, //商品数量
  492. new: 1, //商品是否新增加到购物车1为不加入0为加入
  493. combinationId: obj.goodsid,
  494. productId: obj.goodsObjact.product_id
  495. };
  496. cartAdd(data)
  497. .then(function(e) {
  498. let da = e.data;
  499. if (obj.type == 1) {
  500. // 跳转到支付页
  501. uni.navigateTo({
  502. url: '/pages/order/createOrder?id=' + da.cartId+'&goodsType=2'
  503. });
  504. }
  505. })
  506. .catch(e => {
  507. console.log(e);
  508. });
  509. },
  510. specOPne(item) {
  511. let obj = this;
  512. obj.specClass = 'show';
  513. console.log(obj.specClass,'this.specClass')
  514. },
  515. //规格弹窗开关
  516. toggleSpec(str) {
  517. if (this.specClass === 'show') {
  518. this.specClass = 'hide';
  519. setTimeout(() => {
  520. this.specClass = 'none';
  521. }, 250);
  522. } else if (this.specClass === 'none') {
  523. this.specClass = 'show';
  524. }
  525. // 判断是否为数字
  526. if (typeof str == 'number') {
  527. // 保存当前购买类型
  528. this.type = str;
  529. }
  530. },
  531. // 阻止触发上级事件
  532. stopPrevent() {}
  533. }
  534. };
  535. </script>
  536. <style lang="scss">
  537. /* 弹出层 */
  538. .popup {
  539. position: fixed;
  540. left: 0;
  541. top: 0;
  542. right: 0;
  543. bottom: 0;
  544. z-index: 99;
  545. &.show {
  546. display: block;
  547. .mask {
  548. animation: showPopup 0.2s linear both;
  549. }
  550. .layer {
  551. animation: showLayer 0.2s linear both;
  552. }
  553. }
  554. &.hide {
  555. .mask {
  556. animation: hidePopup 0.2s linear both;
  557. }
  558. .layer {
  559. animation: hideLayer 0.2s linear both;
  560. }
  561. }
  562. &.none {
  563. display: none;
  564. }
  565. .mask {
  566. position: fixed;
  567. top: 0;
  568. width: 100%;
  569. height: 100%;
  570. z-index: 1;
  571. background-color: rgba(0, 0, 0, 0.4);
  572. }
  573. .layer {
  574. position: fixed;
  575. z-index: 99;
  576. bottom: 0;
  577. width: 100%;
  578. min-height: 35vh;
  579. border-radius: 10rpx 10rpx 0 0;
  580. background-color: #fff;
  581. .btn {
  582. height: 66rpx;
  583. line-height: 66rpx;
  584. border-radius: 100rpx;
  585. background: $uni-color-primary;
  586. font-size: $font-base + 2rpx;
  587. color: #fff;
  588. margin: 30rpx auto 20rpx;
  589. }
  590. }
  591. @keyframes showPopup {
  592. 0% {
  593. opacity: 0;
  594. }
  595. 100% {
  596. opacity: 1;
  597. }
  598. }
  599. @keyframes hidePopup {
  600. 0% {
  601. opacity: 1;
  602. }
  603. 100% {
  604. opacity: 0;
  605. }
  606. }
  607. @keyframes showLayer {
  608. 0% {
  609. transform: translateY(120%);
  610. }
  611. 100% {
  612. transform: translateY(0%);
  613. }
  614. }
  615. @keyframes hideLayer {
  616. 0% {
  617. transform: translateY(0);
  618. }
  619. 100% {
  620. transform: translateY(120%);
  621. }
  622. }
  623. }
  624. /* 规格选择弹窗 */
  625. .attr-content {
  626. padding: 25rpx 30rpx;
  627. .a-t {
  628. display: flex;
  629. image {
  630. width: 170rpx;
  631. height: 170rpx;
  632. flex-shrink: 0;
  633. border-radius: 8rpx;
  634. }
  635. .right {
  636. display: flex;
  637. flex-direction: column;
  638. padding-left: 24rpx;
  639. font-size: $font-sm + 2rpx;
  640. color: $font-color-base;
  641. line-height: 42rpx;
  642. width: 75%;
  643. .price {
  644. font-size: $font-lg;
  645. color: $uni-color-primary;
  646. margin: 10rpx 0rpx;
  647. }
  648. .name {
  649. font-size: 32rpx;
  650. color: $font-color-dark;
  651. height: 50rpx;
  652. overflow: hidden;
  653. text-overflow: ellipsis;
  654. white-space: nowrap;
  655. display: block;
  656. }
  657. .selected-text {
  658. margin-right: 10rpx;
  659. }
  660. }
  661. }
  662. .attr-list {
  663. display: flex;
  664. flex-direction: column;
  665. font-size: $font-base + 2rpx;
  666. color: $font-color-base;
  667. padding-top: 30rpx;
  668. padding-left: 10rpx;
  669. }
  670. .item-list {
  671. padding: 20rpx 0 0;
  672. display: flex;
  673. flex-wrap: wrap;
  674. text {
  675. display: flex;
  676. align-items: center;
  677. justify-content: center;
  678. background: #eee;
  679. margin-right: 20rpx;
  680. margin-bottom: 20rpx;
  681. border-radius: 100rpx;
  682. min-width: 60rpx;
  683. height: 60rpx;
  684. padding: 0 20rpx;
  685. font-size: $font-base;
  686. color: $font-color-dark;
  687. }
  688. .selected {
  689. background: #ddffdf;
  690. color: $uni-color-primary;
  691. }
  692. }
  693. }
  694. //默认商品底部高度
  695. .goodsBottom {
  696. height: 160rpx;
  697. }
  698. page {
  699. background: #f0f0f0;
  700. }
  701. //秒杀、拼团底部高度
  702. .contentBottomHeight {
  703. height: 110rpx;
  704. // background-color: #FFFFFF;
  705. }
  706. //默认商品底部高度
  707. .goodsBottom {
  708. height: 160rpx;
  709. }
  710. /deep/ .iconenter {
  711. font-size: $font-base + 2rpx;
  712. color: #888;
  713. }
  714. /deep/ .con_image {
  715. width: 130rpx;
  716. height: 130rpx;
  717. display: inline-block;
  718. padding: 15rpx;
  719. image {
  720. width: 100%;
  721. height: 100%;
  722. }
  723. }
  724. /* 商品详情中限制图片大小 */
  725. /deep/ .rich-img {
  726. width: 100% !important;
  727. height: auto;
  728. }
  729. .pinklistbox {
  730. background: #ffffff;
  731. margin-top: 25rpx;
  732. overflow: hidden;
  733. }
  734. .pink_num {
  735. background: -webkit-linear-gradient(left, #fdf5f6, #fbebf6);
  736. padding: 15rpx 25rpx;
  737. font-size: 26rpx;
  738. color: #dd524d;
  739. }
  740. .pint {
  741. background: -webkit-linear-gradient(left, #ff1f4f, #ff0409);
  742. padding: 10rpx 25rpx;
  743. color: #ffffff;
  744. font-size: 24rpx;
  745. border-radius: 25rpx;
  746. .iconenter {
  747. font-size: 15px;
  748. color: #ffffff;
  749. }
  750. }
  751. .pinklist {
  752. padding: 0rpx 25rpx;
  753. padding-top: 45rpx !important;
  754. }
  755. .pinklist_list {
  756. margin-bottom: 10rpx;
  757. }
  758. .pink_img {
  759. width: 100rpx;
  760. height: 100rpx;
  761. image {
  762. width: 100%;
  763. height: 100%;
  764. border-radius: 100%;
  765. }
  766. }
  767. .pink_people {
  768. font-size: 28rpx;
  769. text {
  770. color: #dd524d;
  771. }
  772. }
  773. .pink_time {
  774. font-size: 26rpx;
  775. color: #909399;
  776. }
  777. .pink_name {
  778. width: 200rpx;
  779. overflow: hidden;
  780. white-space: nowrap;
  781. text-overflow: ellipsis;
  782. padding-left: 10rpx;
  783. // background: #FC2A3F;
  784. // height: 50rpx;
  785. }
  786. .More {
  787. width: 100%;
  788. line-height: 2;
  789. background-color: #fc2a3f;
  790. font-size: $font-lg;
  791. margin: 0 auto;
  792. text-align: center;
  793. color: #ffffff;
  794. // border-radius: 50rpx;
  795. }
  796. .ping-plan {
  797. background-color: #FFFFFF;
  798. padding: 25rpx 35rpx;
  799. border-top: 15rpx solid #F3F3F4;
  800. border-bottom: 15rpx solid #F3F3F4;
  801. }
  802. .participate-7 {
  803. color: #000000;
  804. font-size: 29rpx;
  805. font-weight: 500;
  806. padding-bottom: 25rpx;
  807. .participate-7-1 {
  808. .word {
  809. color: #ff0a1a;
  810. }
  811. .word1 {
  812. font-size: 25rpx;
  813. color: #989aa0;
  814. }
  815. image {
  816. width: 10rpx;
  817. height: 20rpx;
  818. margin-left: 15rpx;
  819. }
  820. }
  821. }
  822. //左右顶格加上下居中
  823. .flex-between-center {
  824. display: flex;
  825. justify-content: space-between;
  826. align-items: center;
  827. }
  828. .participate-8 {
  829. image {
  830. width: 26rpx;
  831. height: 12rpx;
  832. }
  833. .participate-8-1 {
  834. text-align: center;
  835. .img1 {
  836. width: 43rpx;
  837. height: 50rpx;
  838. }
  839. .img2 {
  840. width: 43rpx;
  841. height: 42rpx;
  842. }
  843. .img3 {
  844. width: 60rpx;
  845. height: 46rpx;
  846. }
  847. .word-1 {
  848. font-size: 23rpx;
  849. color: #000000;
  850. line-height: 34rpx;
  851. }
  852. .word-2 {
  853. font-size: 21rpx;
  854. color: #91949B;
  855. line-height: 34rpx;
  856. }
  857. }
  858. }
  859. </style>