product.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811
  1. <template>
  2. <view class="container">
  3. <!-- 轮播图 -->
  4. <top-swiper :imgList="imgList"></top-swiper>
  5. <!-- 标题 -->
  6. <product-content :goodsObjact="goodsObjact" :list ="list"></product-content>
  7. <view class="c-list">
  8. <view class="c-row b-b" @click="toggleSpec">
  9. <text class="tit">购买数量</text>
  10. <view class="con">
  11. <text class="selected-text">{{ goodsNumber }}</text>
  12. </view>
  13. <text class="iconfont iconenter"></text>
  14. </view>
  15. <view class="c-row b-b">
  16. <text>每购买一个送{{goodsObjact.white_integral}}红积分</text>
  17. </view>
  18. </view>
  19. <!-- 拼货时间及优惠 -->
  20. <!-- <discounts @clickCoupon="Getcoupon" :Info="goodsObjact.store_info" :showCoupon="true"></discounts> -->
  21. <!-- 猜你喜欢 -->
  22. <!-- <guess-like @Addcar='Addcar' @clickNavTo='navToDetailPage' :goodList = 'good_list||[]'></guess-like> -->
  23. <!-- 评价 -->
  24. <estimate @navTo="navTo('/pages/product/reply?id=' + goodsid)" v-if="reply" :reply="reply" :list="list">
  25. </estimate>
  26. <!-- 规格信息 -->
  27. <fresh-detail :goodsObjact="goodsObjact"></fresh-detail>
  28. <!-- 图文详情 -->
  29. <content-text :description="description"></content-text>
  30. <!-- 底部高度撑开 -->
  31. <view class="contentBottomHeight"></view>
  32. <!-- 底部操作菜单 -->
  33. <product-bottom @buy="buy" :goodsObjact="goodsObjact" :goodsid="goodsid" @specOPne="specOPne"></product-bottom>
  34. <!-- 规格-模态层弹窗 -->
  35. <view class="popup spec" :class="specClass" @touchmove.stop.prevent="stopPrevent" @click="toggleSpec">
  36. <!-- 遮罩层 -->
  37. <view class="mask"></view>
  38. <view class="layer attr-content" @click.stop="stopPrevent">
  39. <view class="a-t">
  40. <image :src="actionImage"></image>
  41. <view class="right">
  42. <view class="good-name clamp">{{ goodsObjact.store_name }}</view>
  43. <text class="price" v-if="list.integral*1>0">{{list.integral}}积分</text>
  44. <text class="price" v-else>¥{{ actionPrice }}</text>
  45. <!-- <text class="stock">库存:{{ goodsObjact.stock }}件</text> -->
  46. <!-- <view class="selected" v-if="goodsType == 0">
  47. 已选:
  48. <text class="selected-text" v-for="(sItem, sIndex) in specSelected" :key="sIndex">{{ sItem }}</text>
  49. </view> -->
  50. </view>
  51. </view>
  52. <view v-for="(item, index) in specList" :key="index" class="attr-list">
  53. <text>{{ item.attr_name }}</text>
  54. <view class="item-list">
  55. <text v-for="(childItem, childIndex) in item.attr_value" :key="childIndex" class="tit"
  56. :class="{ selected: childItem.check }" @click="selectSpec(childItem, item, index)">
  57. {{ childItem.attr }}
  58. </text>
  59. </view>
  60. </view>
  61. <view class="flex">
  62. <view>购买数量</view>
  63. <view class="item-list">
  64. <uni-number-box class="step" :isMin="true" :value="goodsNumber" :min="1" :max="goodsNumberMax"
  65. @eventChange="numberChange"></uni-number-box>
  66. </view>
  67. </view>
  68. <button class="btn" @click.stop="buy">确定</button>
  69. </view>
  70. </view>
  71. </view>
  72. </template>
  73. <script>
  74. import uniNumberBox from '@/components/uni-number-box.vue';
  75. import {
  76. goodsDetail,
  77. cartAdd
  78. } from '@/api/product.js';
  79. import {
  80. mapState
  81. } from 'vuex';
  82. import store from '@/store/index.js';
  83. import {
  84. orderData,
  85. userinfo
  86. } from '@/api/user.js';
  87. import {
  88. saveUrl
  89. } from '@/utils/loginUtils.js';
  90. // #ifdef H5
  91. import {
  92. weixindata,
  93. shareLoad
  94. } from '@/utils/wxAuthorized';
  95. // #endif
  96. // 头部轮播图
  97. import topSwiper from './common/topSwiper.vue';
  98. // 标题
  99. import productContent from './common/productContent.vue';
  100. // 到货时间及优惠
  101. import discounts from './common/discounts.vue';
  102. // 规格信息
  103. import freshDetail from './common/freshDetail.vue';
  104. // 图文详情
  105. import contentText from './common/contentText.vue';
  106. // 底部按钮
  107. import productBottom from './common/productBottom.vue';
  108. // 猜你喜欢
  109. import guessLike from './common/guessLike.vue';
  110. // 评价
  111. import estimate from './common/estimate.vue';
  112. export default {
  113. components: {
  114. uniNumberBox,
  115. guessLike,
  116. topSwiper,
  117. productContent,
  118. discounts,
  119. freshDetail,
  120. contentText,
  121. productBottom,
  122. estimate
  123. },
  124. data() {
  125. return {
  126. goodsStore: 0, //选中库存
  127. specList: [],
  128. buys_show: true,
  129. buys_shows: false,
  130. specSelected: [], //选中的分类
  131. specClass: 'none', //显示隐藏弹窗
  132. many: 1, //1是单规格 2是多规格
  133. reply: '', //评论
  134. list: '', //商品详情的数据
  135. type: 1, //默认支付方式add为
  136. goodsType: 0,
  137. goodsNumber: 1, //购买数量
  138. goodsid: '', //商品id
  139. description: '', //商品描述
  140. goodsObjact: {
  141. percent: 1
  142. }, //保存商品数据
  143. //图片循环
  144. imgList: [],
  145. // 对比对象
  146. actionPrice: 0, //默认选中商品价格
  147. actionImage: '', //默认选中图片
  148. good_list: '', //猜你喜欢列表
  149. goodsNumberMax: 0, //最大可购买数量
  150. // 倒计时数据保存
  151. seckillObj: {
  152. stopTime: 0, //结束时间
  153. stop: false, //是否结束
  154. stopTimeH: 0, //小时
  155. stopTimeM: 0, //分钟
  156. stopTimeS: 0, //秒钟
  157. stopTimeD: 0, //天
  158. upTime: 0 //更新组件内部组件用
  159. },
  160. // 拼团数据保存
  161. pink: {
  162. id: '', //拼团编号
  163. uid: '', //用户编号
  164. people: '', //拼团人数
  165. price: '', //拼团价格
  166. stop_time: '', //拼团结束时间
  167. nickname: '', //团长昵称
  168. avatar: '', //团长头像
  169. count: '', //拼团剩余人数
  170. h: '', //时
  171. i: '', //分
  172. s: '' //秒
  173. },
  174. userInfo: '',
  175. isVip: '0'
  176. };
  177. },
  178. filters: {
  179. parseIntTo(percent) {
  180. percent = +percent * 100;
  181. if (percent % 1 === 0) {
  182. return percent;
  183. } else {
  184. percent = percent.toFixed(1);
  185. return percent;
  186. }
  187. }
  188. },
  189. async onLoad(options) {
  190. let obj = this;
  191. // userinfo({})
  192. // .then(({
  193. // data
  194. // }) => {
  195. // obj.userInfo = data;
  196. // console.log(data, "123456")
  197. // })
  198. //保存商品id
  199. this.goodsid = options.id;
  200. this.goodsType = options.type;
  201. // 判断有无人邀请
  202. if (options.spread) {
  203. // 存储邀请人
  204. uni.setStorageSync('spread', options.spread);
  205. }
  206. if (options.isVip) {
  207. obj.isVip = options.isVip;
  208. }
  209. console.log(obj.isVip, 'vip');
  210. saveUrl();
  211. this.goodsDetail();
  212. // 注册邀请信息
  213. // #ifdef H5
  214. let bool = uni.getStorageSync('weichatBrowser') || '';
  215. if (bool) {
  216. weixindata();
  217. }
  218. // #endif
  219. },
  220. computed: {
  221. ...mapState(['weichatObj', 'baseURL', 'urlFile'])
  222. },
  223. // 分享
  224. // onShareAppMessage(options) {
  225. // // 设置菜单中的转发按钮触发转发事件时的转发内容
  226. // let pages = getCurrentPages(); //获取加载的页面
  227. // let currentPage = pages[pages.length - 1]; //获取当前页面的对象
  228. // let url = currentPage.route; //当前页面url
  229. // let item = currentPage.options; //如果要获取url中所带的参数可以查看options
  230. // let shareObj = {
  231. // title: this.goodsObjact.store_name,
  232. // desc: obj.goodsObjact.store_info,
  233. // path: url + '?id=' + item.id + '&spread=' + this.userInfo.uid, // 默认是当前页面,必须是以‘/’开头的完整路径
  234. // imageUrl: this.goodsObjact.image,
  235. // success: function(res) {
  236. // // 转发成功之后的回调
  237. // if (res.errMsg == 'shareAppMessage:ok') {
  238. // }
  239. // },
  240. // fail: function() {
  241. // // 转发失败之后的回调
  242. // if (res.errMsg == 'shareAppMessage:fail cancel') {
  243. // // 用户取消转发
  244. // } else if (res.errMsg == 'shareAppMessage:fail') {
  245. // // 转发失败,其中 detail message 为详细失败信息
  246. // }
  247. // }
  248. // };
  249. // return shareObj;
  250. // },
  251. methods: {
  252. //选择规格
  253. selectSpec(item, arr, ind) {
  254. arr.attr_value.forEach(function(e) {
  255. e.check = false;
  256. });
  257. item.check = true;
  258. let obj = this;
  259. obj.specSelected[ind] = item.attr;
  260. let str = obj.specSelected.join(',');
  261. // 获取当前选中的对象
  262. if (obj.productValue[str]) {
  263. obj.buys_show = true;
  264. obj.buys_shows = false;
  265. obj.actionPrice = obj.productValue[str].price;
  266. obj.goodsNumberMax = obj.productValue[str].stock;
  267. obj.actionImage = obj.productValue[str].image;
  268. obj.uniqueId = obj.productValue[str].unique;
  269. obj.goodsStore = obj.productValue[str].stock;
  270. } else {
  271. (obj.buys_show = false), (obj.buys_shows = true);
  272. }
  273. if (obj.goodsStore == 0) {
  274. obj.buys_show = false;
  275. obj.buys_shows = true;
  276. }
  277. obj.specSelected[ind] = item.attr;
  278. },
  279. // 打開彈窗
  280. specOPne(type = 1) {
  281. let obj = this;
  282. obj.specClass = 'show';
  283. obj.type = type;
  284. },
  285. //规格弹窗开关
  286. toggleSpec(str) {
  287. if (this.specClass === 'show') {
  288. this.specClass = 'hide';
  289. setTimeout(() => {
  290. this.specClass = 'none';
  291. }, 250);
  292. } else if (this.specClass === 'none') {
  293. this.specClass = 'show';
  294. }
  295. // 保存当前购买类型
  296. this.type = str;
  297. },
  298. //领取优惠券
  299. Getcoupon() {
  300. uni.navigateTo({
  301. url: '/pages/coupon/getcoupon'
  302. });
  303. },
  304. // 购买数量变化
  305. numberChange(e) {
  306. this.goodsNumber = e.number;
  307. },
  308. // #ifdef H5
  309. // 加载微信html5页面分享方法
  310. shareDate() {
  311. let obj = this;
  312. // 保存分享人id链接
  313. let url = window.location.href + '&spread=' + this.userInfo.uid;
  314. // 判断是否微信浏览器
  315. let bool = uni.getStorageSync('weichatBrowser') || '';
  316. if (bool) {
  317. // 过滤微信强制添加的链接地址
  318. url = url.replace(/[\?,&]from=singlemessage/g, '');
  319. let data = {
  320. link: url, // 分享链接
  321. imgUrl: obj.goodsObjact.image, // 分享图标
  322. desc: obj.goodsObjact.store_info,
  323. title: obj.goodsObjact.store_name,
  324. success: function(e) {
  325. console.log(e);
  326. }
  327. };
  328. console.log(data, '分享');
  329. shareLoad(data);
  330. }
  331. },
  332. // #endif
  333. //详情页
  334. navToDetailPage(item) {
  335. let id = item.id;
  336. uni.navigateTo({
  337. url: '/pages/product/product?id=' + id
  338. });
  339. },
  340. // 跳转页面
  341. navTo(url) {
  342. uni.navigateTo({
  343. url: '/pages/product/reply?id=' + this.goodsid
  344. });
  345. },
  346. //加入购物车
  347. Addcar(item) {
  348. let obj = this;
  349. cartAdd({
  350. cartNum: '1', //商品数量
  351. uniqueId: '', //商品标签
  352. new: 0, //商品是否新增加到购物车1为不加入0为加入
  353. mer_id: '',
  354. productId: item.id //商品编号
  355. })
  356. .then(function(e) {
  357. uni.showToast({
  358. title: '成功加入购物车',
  359. type: 'top',
  360. duration: 500,
  361. icon: 'none'
  362. });
  363. obj.goodsDetail();
  364. })
  365. .catch(e => {
  366. console.log(e);
  367. });
  368. },
  369. goodsDetail() {
  370. let obj = this;
  371. // 获取普通商品信息
  372. goodsDetail({}, this.goodsid).then(function({
  373. data
  374. }) {
  375. obj.list = data;
  376. console.log(data,'22222222');
  377. obj.good_list = data.good_list; //保存猜你喜欢列表
  378. obj.reply = data.reply; //保存评论列表
  379. let goods = data.storeInfo;
  380. obj.goodsObjact = goods;
  381. console.log(obj.goodsObjact,'obj.goodsObjact');
  382. if (obj.goodsObjact.description != null) {
  383. obj.description = obj.goodsObjact.description.replace(/\<img/gi, '<img class="rich-img"');
  384. } //小程序商品详情图超出屏幕问题
  385. obj.imgList = goods.slider_image; //保存轮播图
  386. obj.specList = data.productAttr; //保存分类列表
  387. if (Array.isArray(data.productValue) != true) {
  388. obj.many = 2;
  389. obj.specList = data.productAttr; //保存产品属性
  390. obj.productValue = data.productValue; //保存属性值
  391. obj.specSelected = []; //初始化默认选择对象
  392. for (let i = 0; i < obj.specList.length; i++) {
  393. // 设置默认数据
  394. let attrValue = obj.specList[i].attr_value[0];
  395. attrValue.check = true;
  396. obj.specSelected.push(attrValue.attr);
  397. }
  398. let str = obj.specSelected.join(',');
  399. console.log(str, 'str');
  400. // 设置默认值
  401. obj.actionPrice = obj.productValue[str].price;
  402. obj.goodsNumberMax = obj.productValue[str].stock;
  403. obj.actionImage = obj.productValue[str].image;
  404. obj.uniqueId = obj.productValue[str].unique;
  405. obj.goodsStore = obj.productValue[str].quota;
  406. } else {
  407. obj.many = 1;
  408. obj.productValue = data.productValue; //保存分类查询数据
  409. obj.actionPrice = goods.price; //保存默认选中商品价格
  410. obj.actionImage = goods.image_base; //保存默认选中商品图片
  411. obj.goodsNumberMax = goods.stock; //保存默认选中最大可购买商品数量
  412. }
  413. obj.shopId = data.mer_id; //保存商店id
  414. // #ifdef H5
  415. obj.shareDate();
  416. // #endif
  417. });
  418. },
  419. // #ifdef H5
  420. // 加载微信html5页面分享方法
  421. shareDate() {
  422. let obj = this;
  423. // 保存分享人id链接
  424. let url = window.location.href + '&spread=' + this.userInfo.uid;
  425. // 判断是否微信浏览器
  426. let bool = uni.getStorageSync('weichatBrowser') || '';
  427. if (bool) {
  428. // 过滤微信强制添加的链接地址
  429. url = url.replace(/[\?,&]from=singlemessage/g, '');
  430. let data = {
  431. link: url, // 分享链接
  432. imgUrl: obj.goodsObjact.image, // 分享图标
  433. desc: obj.goodsObjact.store_info,
  434. title: obj.goodsObjact.store_name,
  435. success: function(e) {
  436. console.log(e);
  437. }
  438. };
  439. shareLoad(data);
  440. }
  441. },
  442. // #endif
  443. // 立即购买
  444. buy() {
  445. let obj = this;
  446. // 创建传值对象
  447. let data = {
  448. cartNum: obj.goodsNumber, //商品数量
  449. new: 1,
  450. productId: obj.goodsid, //商品编号
  451. uniqueId: obj.uniqueId
  452. };
  453. if (obj.type == 2) {
  454. data.new = 0;
  455. }
  456. cartAdd(data)
  457. .then(function(e) {
  458. let da = e.data;
  459. if (obj.type == 1) {
  460. // 跳转到支付页
  461. uni.navigateTo({
  462. url: '/pages/order/createOrder?id=' + da.cartId
  463. });
  464. }
  465. if (obj.type == 2) {
  466. uni.showToast({
  467. title: '成功加入购物车',
  468. type: 'top',
  469. duration: 2000,
  470. icon: 'none'
  471. });
  472. obj.goodsDetail();
  473. }
  474. obj.toggleSpec();
  475. })
  476. .catch(e => {
  477. console.log(e);
  478. });
  479. },
  480. buy1() {
  481. let obj = this;
  482. let data = {
  483. cartNum: obj.goodsNumber, //商品数量
  484. new: 1,
  485. productId: obj.goodsid, //商品编号
  486. uniqueId: obj.uniqueId
  487. };
  488. if (obj.type == 2) {
  489. data.new = 0;
  490. }
  491. cartAdd(data)
  492. .then(function(e) {
  493. let da = e.data;
  494. if (obj.type == 1) {
  495. // 跳转到支付页
  496. uni.navigateTo({
  497. url: '/pages/order/createOrder?id=' + da.cartId
  498. });
  499. }
  500. if (obj.type == 2) {
  501. uni.showToast({
  502. title: '成功加入购物车',
  503. type: 'top',
  504. duration: 2000,
  505. icon: 'none'
  506. });
  507. obj.goodsDetail();
  508. }
  509. obj.toggleSpec();
  510. })
  511. .catch(e => {
  512. console.log(e);
  513. });
  514. },
  515. // 阻止触发上级事件
  516. stopPrevent() {}
  517. }
  518. };
  519. </script>
  520. <style lang="scss">
  521. /* 弹出层 */
  522. .popup {
  523. position: fixed;
  524. left: 0;
  525. top: 0;
  526. right: 0;
  527. bottom: 0;
  528. z-index: 99;
  529. &.show {
  530. display: block;
  531. .mask {
  532. animation: showPopup 0.2s linear both;
  533. }
  534. .layer {
  535. animation: showLayer 0.2s linear both;
  536. }
  537. }
  538. &.hide {
  539. .mask {
  540. animation: hidePopup 0.2s linear both;
  541. }
  542. .layer {
  543. animation: hideLayer 0.2s linear both;
  544. }
  545. }
  546. &.none {
  547. display: none;
  548. }
  549. .mask {
  550. position: fixed;
  551. top: 0;
  552. width: 100%;
  553. height: 100%;
  554. z-index: 1;
  555. background-color: rgba(0, 0, 0, 0.4);
  556. }
  557. .layer {
  558. position: fixed;
  559. z-index: 99;
  560. bottom: 0;
  561. width: 100%;
  562. min-height: 30vh;
  563. border-radius: 10rpx 10rpx 0 0;
  564. background-color: #fff;
  565. .btn {
  566. height: 66rpx;
  567. line-height: 66rpx;
  568. border-radius: 100rpx;
  569. // background: $uni-color-primary;
  570. background: #FF4C4C;
  571. font-size: $font-base + 2rpx;
  572. color: #fff;
  573. margin: 30rpx auto 20rpx;
  574. }
  575. }
  576. @keyframes showPopup {
  577. 0% {
  578. opacity: 0;
  579. }
  580. 100% {
  581. opacity: 1;
  582. }
  583. }
  584. @keyframes hidePopup {
  585. 0% {
  586. opacity: 1;
  587. }
  588. 100% {
  589. opacity: 0;
  590. }
  591. }
  592. @keyframes showLayer {
  593. 0% {
  594. transform: translateY(120%);
  595. }
  596. 100% {
  597. transform: translateY(0%);
  598. }
  599. }
  600. @keyframes hideLayer {
  601. 0% {
  602. transform: translateY(0);
  603. }
  604. 100% {
  605. transform: translateY(120%);
  606. }
  607. }
  608. }
  609. /* 规格选择弹窗 */
  610. .attr-content {
  611. padding: 10rpx 30rpx;
  612. .a-t {
  613. display: flex;
  614. image {
  615. width: 170rpx;
  616. height: 170rpx;
  617. flex-shrink: 0;
  618. border-radius: 8rpx;
  619. }
  620. .right {
  621. display: flex;
  622. flex-direction: column;
  623. padding-left: 24rpx;
  624. font-size: $font-sm + 2rpx;
  625. color: $font-color-base;
  626. line-height: 42rpx;
  627. .good-name {
  628. padding-top: 20rpx;
  629. max-width: 320rpx;
  630. font-size: 30rpx;
  631. font-family: PingFang SC;
  632. font-weight: bold;
  633. color: #1d2023;
  634. line-height: 42rpx;
  635. margin-bottom: 15rpx;
  636. }
  637. .price {
  638. font-size: 60rpx;
  639. font-family: PingFang SC;
  640. font-weight: bold;
  641. color: #ff6f0f;
  642. // font-size: $font-lg;
  643. // color: $uni-color-primary;
  644. // margin-bottom: 10rpx;
  645. }
  646. .selected-text {
  647. margin-right: 10rpx;
  648. }
  649. }
  650. }
  651. .attr-list {
  652. display: flex;
  653. flex-direction: column;
  654. font-size: $font-base + 2rpx;
  655. color: $font-color-base;
  656. padding-top: 30rpx;
  657. padding-left: 10rpx;
  658. }
  659. .item-list {
  660. padding: 20rpx 0 0;
  661. display: flex;
  662. flex-wrap: wrap;
  663. .tit {
  664. display: flex;
  665. align-items: center;
  666. justify-content: center;
  667. background: #eee;
  668. // margin-left: 10rpx;
  669. margin-right: 20rpx;
  670. margin-bottom: 20rpx;
  671. border-radius: 100rpx;
  672. min-width: 60rpx;
  673. height: 60rpx;
  674. padding: 0 20rpx;
  675. font-size: $font-base;
  676. color: $font-color-dark;
  677. }
  678. .selected {
  679. background: #FCEFF1;
  680. border: 1px solid #EF041F;
  681. color: #EF041F;
  682. }
  683. }
  684. }
  685. //默认商品底部高度
  686. .goodsBottom {
  687. height: 160rpx;
  688. }
  689. page {
  690. background: #f0f0f0;
  691. }
  692. //秒杀、拼团底部高度
  693. .contentBottomHeight {
  694. height: 110rpx;
  695. }
  696. //默认商品底部高度
  697. .goodsBottom {
  698. height: 160rpx;
  699. }
  700. /deep/ .iconenter {
  701. font-size: $font-base + 2rpx;
  702. color: #888;
  703. }
  704. /deep/ .con_image {
  705. width: 130rpx;
  706. height: 130rpx;
  707. display: inline-block;
  708. padding: 15rpx;
  709. image {
  710. width: 100%;
  711. height: 100%;
  712. }
  713. }
  714. /* 商品详情中限制图片大小 */
  715. /deep/ .rich-img {
  716. width: 100% !important;
  717. height: auto;
  718. }
  719. .c-list {
  720. margin-top: 20rpx;
  721. font-size: $font-sm + 2rpx;
  722. color: $font-color-base;
  723. background: #fff;
  724. .c-row {
  725. display: flex;
  726. align-items: center;
  727. padding: 20rpx 30rpx;
  728. position: relative;
  729. }
  730. .tit {
  731. width: 140rpx;
  732. }
  733. .con {
  734. flex: 1;
  735. color: $font-color-dark;
  736. .selected-text {
  737. margin-right: 10rpx;
  738. }
  739. }
  740. .bz-list {
  741. height: 40rpx;
  742. font-size: $font-sm + 2rpx;
  743. color: $font-color-dark;
  744. text {
  745. display: inline-block;
  746. margin-right: 30rpx;
  747. }
  748. }
  749. .con-list {
  750. flex: 1;
  751. display: flex;
  752. flex-direction: column;
  753. color: $font-color-dark;
  754. line-height: 40rpx;
  755. }
  756. .red {
  757. color: $uni-color-primary;
  758. }
  759. }
  760. </style>