productGroup.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934
  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. obj.goodsStore = obj.productValue[str].stock;
  334. // if (obj.goodsType == 2) {
  335. // obj.goodsStore = obj.productValue[str].quota;
  336. // } else {
  337. // obj.goodsStore = obj.productValue[str].product_stock;
  338. // }
  339. } else {
  340. (obj.buys_show = false), (obj.buys_shows = true);
  341. }
  342. },
  343. // 立即购买
  344. buy(item) {
  345. let obj = this;
  346. /* obj.toggleSpec();
  347. this.specClass='show',
  348. console.log(obj.list.productValue.默认.unique)
  349. console.log(obj.chooseGoodsNumber,'chooseGoodsNumber')
  350. return */
  351. // 创建传值对象
  352. console.log(obj.list.productValue);
  353. console.log(obj.list);
  354. let data = {
  355. // cartNum: obj.goodsNumber, //商品数量
  356. cartNum: obj.chooseGoodsNumber, //商品数量
  357. uniqueId: obj.uniqueId, //商品标签
  358. new: 1, //商品是否新增加到购物车1为不加入0为加入
  359. mer_id: obj.shopId,
  360. combinationId: obj.goodsid, //拼团编号
  361. productId: obj.goodsObjact.product_id, //商品编号
  362. };
  363. this.specClass = 'none';
  364. cartAdd(data)
  365. .then(function(e) {
  366. let da = e.data;
  367. console.log(e);
  368. if (obj.type == 1) {
  369. // 跳转到支付页
  370. uni.navigateTo({
  371. url: '/pages/order/createOrder?id=' + da.cartId + '&goodsType=' + obj.goodsType
  372. });
  373. }
  374. if (obj.type == 2) {
  375. obj.$api.msg('成功加入购物车');
  376. obj.toggleSpec();
  377. }
  378. })
  379. .catch(e => {
  380. console.log(e);
  381. });
  382. },
  383. // 去开团
  384. ToKaiTuan(item) {
  385. let id = item.id;
  386. uni.navigateTo({
  387. url: '/pages/product/productGroup?id=' + id
  388. });
  389. },
  390. // 跳转页面
  391. navTo(url) {
  392. uni.navigateTo({
  393. url
  394. });
  395. },
  396. // 查看更多
  397. clickMore() {
  398. this.showlist = this.pinkTlist;
  399. console.log(this.showlist, 22);
  400. this.more = false;
  401. },
  402. //去拼团
  403. groupBooking(item) {
  404. uni.navigateTo({
  405. url: '/pages/groupBooking/groupdetails?id=' + item
  406. });
  407. },
  408. // 获取拼团商品详情
  409. groupGoods() {
  410. let obj = this;
  411. // // 大家还在拼
  412. // nowPinkLst({}).then(({data}) => {
  413. // this.recommendedlist = data;
  414. // })
  415. groupGoods({}, this.goodsid).then(function({
  416. data
  417. }) {
  418. let goods = data.storeInfo;
  419. obj.goodsObjact = goods;
  420. console.log(obj.goodsObjact, 88)
  421. console.log(Array.isArray(data.productValue), 99)
  422. if(Array.isArray(data.productValue) != true){
  423. obj.many = 2;
  424. obj.specList = data.productAttr;//保存产品属性
  425. obj.productValue = data.productValue; //保存属性值
  426. obj.specSelected = []; //初始化默认选择对象
  427. for (let i = 0; i < obj.specList.length; i++) {
  428. // 设置默认数据
  429. let attrValue = obj.specList[i].attr_value[0];
  430. attrValue.check = true;
  431. obj.specSelected.push(attrValue.attr);
  432. }
  433. let str = obj.specSelected.join(',');
  434. console.log(str,'str')
  435. // 设置默认值
  436. obj.actionPrice = obj.productValue[str].price;
  437. obj.goodsNumberMax = obj.productValue[str].stock;
  438. obj.actionImage = obj.productValue[str].image;
  439. obj.uniqueId = obj.productValue[str].unique;
  440. obj.goodsStore = obj.productValue[str].quota;
  441. }else{
  442. obj.many = 1;
  443. }
  444. console.log(obj.many,'obj.many')
  445. if (obj.goodsObjact.description != null) {
  446. obj.description = obj.goodsObjact.description.replace(/\<img/gi, '<img class="rich-img"');
  447. }
  448. obj.imgList = goods.images; //保存轮播图
  449. obj.actionPrice = goods.price; //保存默认选中商品价格
  450. obj.actionImage = goods.image_base; //保存默认选中商品图片
  451. obj.goodsNumberMax = 1; //保存默认选中最大可购买商品数量
  452. if (obj.goodsObjact.pink_type == 'AA团') {
  453. obj.pink_type = 1;
  454. } else {
  455. obj.pink_type = 2;
  456. }
  457. obj.pinkTlist = data.pink;
  458. obj.showlist = obj.pinkTlist.slice(0, 2);
  459. if (obj.pinkTlist.length <= 2) {
  460. obj.more = false;
  461. }
  462. // 保存结束时间
  463. obj.seckillObj.stopTime = goods.stop_time * 1000;
  464. // 获取当前时间
  465. let acitonTime = new Date();
  466. // 判断当前时间是否大于结束时间
  467. if (acitonTime.getTime() > obj.seckillObj.stopTime) {
  468. // 当前秒杀时间已经结束
  469. obj.seckillObj.stop = true;
  470. } else {
  471. // 计算倒计时
  472. let time = timeComputed(obj.seckillObj.stopTime)
  473. // 倒计时数据保存
  474. obj.seckillObj = {
  475. stopTime: goods.stop_time * 1000, //结束时间
  476. stop: false, //是否结束
  477. stopTimeD: time.day, //天
  478. stopTimeH: time.hours, //小时
  479. stopTimeM: time.minutes, //分钟
  480. stopTimeS: time.seconds, //秒钟
  481. upTime: (new Date()).getTime()
  482. }
  483. }
  484. });
  485. },
  486. // 立即购买
  487. openPinkT(item) {
  488. let obj = this;
  489. obj.type = item;
  490. // 创建传值对象
  491. let data = {
  492. cartNum: obj.goodsNumber, //商品数量
  493. new: 1, //商品是否新增加到购物车1为不加入0为加入
  494. combinationId: obj.goodsid,
  495. productId: obj.goodsObjact.product_id
  496. };
  497. cartAdd(data)
  498. .then(function(e) {
  499. let da = e.data;
  500. if (obj.type == 1) {
  501. // 跳转到支付页
  502. uni.navigateTo({
  503. url: '/pages/order/createOrder?id=' + da.cartId+'&goodsType=2'
  504. });
  505. }
  506. })
  507. .catch(e => {
  508. console.log(e);
  509. });
  510. },
  511. specOPne(item) {
  512. let obj = this;
  513. obj.specClass = 'show';
  514. console.log(obj.specClass,'this.specClass')
  515. },
  516. //规格弹窗开关
  517. toggleSpec(str) {
  518. if (this.specClass === 'show') {
  519. this.specClass = 'hide';
  520. setTimeout(() => {
  521. this.specClass = 'none';
  522. }, 250);
  523. } else if (this.specClass === 'none') {
  524. this.specClass = 'show';
  525. }
  526. // 判断是否为数字
  527. if (typeof str == 'number') {
  528. // 保存当前购买类型
  529. this.type = str;
  530. }
  531. },
  532. // 阻止触发上级事件
  533. stopPrevent() {}
  534. }
  535. };
  536. </script>
  537. <style lang="scss">
  538. /* 弹出层 */
  539. .popup {
  540. position: fixed;
  541. left: 0;
  542. top: 0;
  543. right: 0;
  544. bottom: 0;
  545. z-index: 99;
  546. &.show {
  547. display: block;
  548. .mask {
  549. animation: showPopup 0.2s linear both;
  550. }
  551. .layer {
  552. animation: showLayer 0.2s linear both;
  553. }
  554. }
  555. &.hide {
  556. .mask {
  557. animation: hidePopup 0.2s linear both;
  558. }
  559. .layer {
  560. animation: hideLayer 0.2s linear both;
  561. }
  562. }
  563. &.none {
  564. display: none;
  565. }
  566. .mask {
  567. position: fixed;
  568. top: 0;
  569. width: 100%;
  570. height: 100%;
  571. z-index: 1;
  572. background-color: rgba(0, 0, 0, 0.4);
  573. }
  574. .layer {
  575. position: fixed;
  576. z-index: 99;
  577. bottom: 0;
  578. width: 100%;
  579. min-height: 35vh;
  580. border-radius: 10rpx 10rpx 0 0;
  581. background-color: #fff;
  582. .btn {
  583. height: 66rpx;
  584. line-height: 66rpx;
  585. border-radius: 100rpx;
  586. background: $uni-color-primary;
  587. font-size: $font-base + 2rpx;
  588. color: #fff;
  589. margin: 30rpx auto 20rpx;
  590. }
  591. }
  592. @keyframes showPopup {
  593. 0% {
  594. opacity: 0;
  595. }
  596. 100% {
  597. opacity: 1;
  598. }
  599. }
  600. @keyframes hidePopup {
  601. 0% {
  602. opacity: 1;
  603. }
  604. 100% {
  605. opacity: 0;
  606. }
  607. }
  608. @keyframes showLayer {
  609. 0% {
  610. transform: translateY(120%);
  611. }
  612. 100% {
  613. transform: translateY(0%);
  614. }
  615. }
  616. @keyframes hideLayer {
  617. 0% {
  618. transform: translateY(0);
  619. }
  620. 100% {
  621. transform: translateY(120%);
  622. }
  623. }
  624. }
  625. /* 规格选择弹窗 */
  626. .attr-content {
  627. padding: 25rpx 30rpx;
  628. .a-t {
  629. display: flex;
  630. image {
  631. width: 170rpx;
  632. height: 170rpx;
  633. flex-shrink: 0;
  634. border-radius: 8rpx;
  635. }
  636. .right {
  637. display: flex;
  638. flex-direction: column;
  639. padding-left: 24rpx;
  640. font-size: $font-sm + 2rpx;
  641. color: $font-color-base;
  642. line-height: 42rpx;
  643. width: 75%;
  644. .price {
  645. font-size: $font-lg;
  646. color: $uni-color-primary;
  647. margin: 10rpx 0rpx;
  648. }
  649. .name {
  650. font-size: 32rpx;
  651. color: $font-color-dark;
  652. height: 50rpx;
  653. overflow: hidden;
  654. text-overflow: ellipsis;
  655. white-space: nowrap;
  656. display: block;
  657. }
  658. .selected-text {
  659. margin-right: 10rpx;
  660. }
  661. }
  662. }
  663. .attr-list {
  664. display: flex;
  665. flex-direction: column;
  666. font-size: $font-base + 2rpx;
  667. color: $font-color-base;
  668. padding-top: 30rpx;
  669. padding-left: 10rpx;
  670. }
  671. .item-list {
  672. padding: 20rpx 0 0;
  673. display: flex;
  674. flex-wrap: wrap;
  675. text {
  676. display: flex;
  677. align-items: center;
  678. justify-content: center;
  679. background: #eee;
  680. margin-right: 20rpx;
  681. margin-bottom: 20rpx;
  682. border-radius: 100rpx;
  683. min-width: 60rpx;
  684. height: 60rpx;
  685. padding: 0 20rpx;
  686. font-size: $font-base;
  687. color: $font-color-dark;
  688. }
  689. .selected {
  690. background: #ddffdf;
  691. color: $uni-color-primary;
  692. }
  693. }
  694. }
  695. //默认商品底部高度
  696. .goodsBottom {
  697. height: 160rpx;
  698. }
  699. page {
  700. background: #f0f0f0;
  701. }
  702. //秒杀、拼团底部高度
  703. .contentBottomHeight {
  704. height: 110rpx;
  705. // background-color: #FFFFFF;
  706. }
  707. //默认商品底部高度
  708. .goodsBottom {
  709. height: 160rpx;
  710. }
  711. /deep/ .iconenter {
  712. font-size: $font-base + 2rpx;
  713. color: #888;
  714. }
  715. /deep/ .con_image {
  716. width: 130rpx;
  717. height: 130rpx;
  718. display: inline-block;
  719. padding: 15rpx;
  720. image {
  721. width: 100%;
  722. height: 100%;
  723. }
  724. }
  725. /* 商品详情中限制图片大小 */
  726. /deep/ .rich-img {
  727. width: 100% !important;
  728. height: auto;
  729. }
  730. .pinklistbox {
  731. background: #ffffff;
  732. margin-top: 25rpx;
  733. overflow: hidden;
  734. }
  735. .pink_num {
  736. background: -webkit-linear-gradient(left, #fdf5f6, #fbebf6);
  737. padding: 15rpx 25rpx;
  738. font-size: 26rpx;
  739. color: #dd524d;
  740. }
  741. .pint {
  742. background: -webkit-linear-gradient(left, #ff1f4f, #ff0409);
  743. padding: 10rpx 25rpx;
  744. color: #ffffff;
  745. font-size: 24rpx;
  746. border-radius: 25rpx;
  747. .iconenter {
  748. font-size: 15px;
  749. color: #ffffff;
  750. }
  751. }
  752. .pinklist {
  753. padding: 0rpx 25rpx;
  754. padding-top: 45rpx !important;
  755. }
  756. .pinklist_list {
  757. margin-bottom: 10rpx;
  758. }
  759. .pink_img {
  760. width: 100rpx;
  761. height: 100rpx;
  762. image {
  763. width: 100%;
  764. height: 100%;
  765. border-radius: 100%;
  766. }
  767. }
  768. .pink_people {
  769. font-size: 28rpx;
  770. text {
  771. color: #dd524d;
  772. }
  773. }
  774. .pink_time {
  775. font-size: 26rpx;
  776. color: #909399;
  777. }
  778. .pink_name {
  779. width: 200rpx;
  780. overflow: hidden;
  781. white-space: nowrap;
  782. text-overflow: ellipsis;
  783. padding-left: 10rpx;
  784. // background: #FC2A3F;
  785. // height: 50rpx;
  786. }
  787. .More {
  788. width: 100%;
  789. line-height: 2;
  790. background-color: #fc2a3f;
  791. font-size: $font-lg;
  792. margin: 0 auto;
  793. text-align: center;
  794. color: #ffffff;
  795. // border-radius: 50rpx;
  796. }
  797. .ping-plan {
  798. background-color: #FFFFFF;
  799. padding: 25rpx 35rpx;
  800. border-top: 15rpx solid #F3F3F4;
  801. border-bottom: 15rpx solid #F3F3F4;
  802. }
  803. .participate-7 {
  804. color: #000000;
  805. font-size: 29rpx;
  806. font-weight: 500;
  807. padding-bottom: 25rpx;
  808. .participate-7-1 {
  809. .word {
  810. color: #ff0a1a;
  811. }
  812. .word1 {
  813. font-size: 25rpx;
  814. color: #989aa0;
  815. }
  816. image {
  817. width: 10rpx;
  818. height: 20rpx;
  819. margin-left: 15rpx;
  820. }
  821. }
  822. }
  823. //左右顶格加上下居中
  824. .flex-between-center {
  825. display: flex;
  826. justify-content: space-between;
  827. align-items: center;
  828. }
  829. .participate-8 {
  830. image {
  831. width: 26rpx;
  832. height: 12rpx;
  833. }
  834. .participate-8-1 {
  835. text-align: center;
  836. .img1 {
  837. width: 43rpx;
  838. height: 50rpx;
  839. }
  840. .img2 {
  841. width: 43rpx;
  842. height: 42rpx;
  843. }
  844. .img3 {
  845. width: 60rpx;
  846. height: 46rpx;
  847. }
  848. .word-1 {
  849. font-size: 23rpx;
  850. color: #000000;
  851. line-height: 34rpx;
  852. }
  853. .word-2 {
  854. font-size: 21rpx;
  855. color: #91949B;
  856. line-height: 34rpx;
  857. }
  858. }
  859. }
  860. </style>