product.vue 35 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400
  1. <template>
  2. <view class="product" :style="{paddingBottom: userIdentity==1 ? '0rpx' :'188rpx'}">
  3. <custom-p v-if="isHeaderPoduct"
  4. :systeminfo='systeminfo'
  5. :navbar-data='nvabarData'
  6. :headerBtnPosi ="headerBtnPosi"
  7. :headerColor="headerColor"
  8. :type="isShareType"
  9. :page='backPage'>
  10. </custom-p>
  11. <tui-skeleton v-if="skeletonShow" backgroundColor="#fafafa" borderRadius="10rpx" :isLoading ="true" :loadingType="5"></tui-skeleton>
  12. <view class="container-product tui-skeleton">
  13. <view class="product-top">
  14. <view class="banner-section">
  15. <uni-swiper-dot :info="productImage" :current="current" field="content" :mode="mode" >
  16. <swiper class="banner tui-banner tui-skeleton-rect" circular @change="swiperChange" :duration='800' :autoplay="false" :circular="false" >
  17. <swiper-item v-for="(item, index) in productImage" :key="index" class="banner-item">
  18. <image :src="item" @click="previewImg(index)" class="product-img" />
  19. </swiper-item>
  20. </swiper>
  21. <view class="swiper__dots-box">
  22. <view v-for="(item,idx) in productImage"
  23. :key="idx"
  24. :class="[idx===current?'swiper__dots-long':'none']"
  25. :data-index="current" class="swiper__dots-item">
  26. </view>
  27. </view>
  28. </uni-swiper-dot>
  29. </view>
  30. <view class="product-wrap clearfix">
  31. <view class="wrap-top" :class="goodsData.isNoneDisabled ? 'none' : ''">
  32. <view class="p-title tui-skeleton-fillet">
  33. {{product.name == undefined ? '' : product.name}}
  34. </view>
  35. <view class="productRemarks" v-if="product.productRemarks!=''&&product.productRemarks!=null">
  36. <view class="">{{product.productRemarks}}</view>
  37. </view>
  38. <view class="wrap-top-price" v-if="!goodsData.isNoneDisabled">
  39. <view v-if="!hasLogin" class="p-login grade tui-skeleton-fillet">
  40. <text class="p-no">价格:</text>
  41. <view class="price-left" v-if="linkPath === 'activity'">
  42. <text class="none">¥<text>???</text></text>
  43. </view>
  44. <uni-stars v-else :stars="parseInt(product.price1Grade)" :font-size='36' :width-info="180"></uni-stars>
  45. <view class="p-login tui-skeleton-fillet">
  46. <text class="p-login-btn" @click.stop="navToLogin">登录查看价格<text class="iconfont icon-xiayibu" style="font-size: 22rpx;margin: 0 6rpx;"></text></text>
  47. </view>
  48. </view>
  49. <view class="cm-price" v-else>
  50. <cm-price v-if="isRequest"
  51. :product="product"
  52. :userIdentity="userIdentity"
  53. :ladderPriceList="ladderPriceList"
  54. :retailPrice="retailPrice"
  55. :smallMoney="smallMoney"
  56. :minBuyNumber="minBuyNumber"/>
  57. </view>
  58. </view>
  59. </view>
  60. <view class="attributes">
  61. <cm-attributes v-if="isRequest" :product="product" :goodsData="goodsData" />
  62. </view>
  63. </view>
  64. </view>
  65. <view class="product-supplier" @click="goSupplier">
  66. <text class="title">供应商信息</text>
  67. <text class="name">{{shop.name}}</text>
  68. <text class="iconfont icon-xiayibu"></text>
  69. </view>
  70. <view class="product-details">
  71. <!-- 头部 -->
  72. <view v-if="goodsData.isNoneDisabled" class="navbar" :class="navbarFiexd" :style="{top:headerBtnPosi.bottom + (headerBtnPosi.bottom - headerBtnPosi.height - systeminfo.statusBarHeight) +'px'}">
  73. <view class="nav-item tui-skeleton-fillet" v-for="(item,index) in disabledTabNavList" :key="index" :class="{ current: tabCurrentIndex === index }" @click="tabClick(index+2)">
  74. <text class="line"></text>
  75. <text>{{item.name}}</text>
  76. </view>
  77. </view>
  78. <view v-else class="navbar" :class="navbarFiexd" :style="{top:headerBtnPosi.bottom + (headerBtnPosi.bottom - headerBtnPosi.height - systeminfo.statusBarHeight) +'px'}">
  79. <view class="nav-item tui-skeleton-fillet" :class="{ current: tabCurrentIndex === 0 }" @click="tabClick(0)">
  80. <text>商品详情</text>
  81. <text class="line"></text>
  82. </view>
  83. <view class="nav-item tui-skeleton-fillet"
  84. :class="{ current: tabCurrentIndex === 1 }"
  85. @click="tabClick(1)"
  86. v-if="product.parametersList != ''">
  87. <text>相关参数</text>
  88. <text class="line"></text>
  89. </view>
  90. <view class="nav-item tui-skeleton-fillet"
  91. :class="{ current: tabCurrentIndex === 2 }"
  92. @click="tabClick(2)"
  93. v-if="product.productDetail.orderInfo || product.productDetail.serviceInfo">
  94. <text>服务项目</text>
  95. <text class="line"></text>
  96. </view>
  97. <view class="nav-item tui-skeleton-fillet" :class="{ current: tabCurrentIndex === 3 }" @click="tabClick(3)">
  98. <text>相关推荐</text>
  99. <text class="line"></text>
  100. </view>
  101. </view>
  102. <!-- 商品详情,相关参数,服务项目,相关推荐-->
  103. <view class="content tui-banner tui-skeleton-rect" v-if="tabCurrentIndex === 0">
  104. <parser :html="html" :img-mode="widthFix"></parser>
  105. </view>
  106. <view class="content param" v-if="tabCurrentIndex === 1">
  107. <cm-parameter :product="product" v-if="isRarameter"></cm-parameter>
  108. </view>
  109. <view class="content service" v-if="tabCurrentIndex === 2">
  110. <cm-service :product="product.productDetail" v-if="isService"></cm-service>
  111. </view>
  112. <view class="content hot" v-if="tabCurrentIndex === 3">
  113. <recommend :query-productid="product.productID" v-if="isRecommend"></recommend>
  114. </view>
  115. </view>
  116. <!-- 底部按钮 -->
  117. <view class="menu" v-if="userIdentity!=1">
  118. <view class="bottom-btn" :style="{paddingBottom :isIphoneX ? '68rpx' : '0rpx'}">
  119. <view class="bottom-le">
  120. <view class="item-bt" @click="this.$api.switchTabTo('/pages/tabBar/home/home')">
  121. <image src="../../static/icon-home-active@3x.png"></image>
  122. <text>首页</text>
  123. </view>
  124. <view class="item-bt">
  125. <!-- #ifdef MP-WEIXIN -->
  126. <button class="contact-btn" open-type="contact" @bindcontact="handleContact">
  127. <image src="../../static/severs@3x.png"></image>
  128. <text>客服</text>
  129. </button>
  130. <!-- #endif -->
  131. </view>
  132. <view class="item-bt" @click="buyProductCart()">
  133. <image src="../../static/icon-cart-active@3x.png"></image>
  134. <text>购物车</text>
  135. <text v-if="hasLogin && goodsData.cartCount>0"
  136. class="uni-badge uni-badge-error uni-small uni-badge--small icon-num"
  137. :class="[goodsData.cartCount < 10 ? 'goleft':'']">
  138. {{ goodsData.cartCount >= 100 ? '99+': goodsData.cartCount}}
  139. </text>
  140. <view class="animation-num" :class="isAnimation ? 'animation' : 'restion'">+1</view>
  141. </view>
  142. </view>
  143. <view class="bottom-ri">
  144. <button
  145. :disabled="goodsData.disabled"
  146. class="btn btn-cart"
  147. :class="[goodsData.disabled ? 'disabled':'']"
  148. @tap.stop="btnGetConfirm('add')">加入购物车</button>
  149. <button
  150. :disabled="goodsData.disabled"
  151. class="btn btn-bay"
  152. :class="[goodsData.disabled ? 'disabled':'']"
  153. @tap.stop="btnGetConfirm('buy')">立即购买</button>
  154. </view>
  155. </view>
  156. </view>
  157. <!--底部选择模态层弹窗组件 -->
  158. <view class="popup spec" :class="specClass" @touchmove.stop.prevent="discard" @tap="hideSpec">
  159. <!-- 遮罩层 -->
  160. <view class="mask"></view>
  161. <view class="layer" @tap.stop="discard" :style="{paddingBottom :isIphoneX ? '68rpx' : '36rpx',bottom:isIphoneX ?'-352rpx' : '-296rpx'}">
  162. <view class="content">
  163. <view class="layer-smimg">
  164. <image :src="product.mainImage" mode=""></image>
  165. </view>
  166. <view class="layer-nunbox">
  167. <view class="layer-nunbox-t" v-if="product.step === 2">
  168. <view class="text">*该商品只能以起订量的整数倍购买</view>
  169. </view>
  170. <view class="layer-nunbox-t">
  171. <view class="layer-nunbox-text">数量:</view>
  172. <view class="number-box">
  173. <view class="iconfont icon-jianhao" :class="[isQuantity==true?'disabled':'']" @click="changeCountSub()"></view>
  174. <input class="btn-input" type="number" v-model="number" maxlength='4' @blur="changeNumber($event)">
  175. <view class="iconfont icon-jiahao" :class="[isStock==true?'disabled':'']" @click="changeCountAdd()"></view>
  176. </view>
  177. </view>
  178. <view class="layer-nunbox-b">
  179. <view class="text">单价:
  180. <text class="p sm">¥</text>
  181. <text class="p bg">{{buyRetailPrice.toFixed(2)}}</text>
  182. </view>
  183. </view>
  184. </view>
  185. </view>
  186. <view class="btn"><view class="button" @click.stop="btnConfirm">确定</view></view>
  187. </view>
  188. </view>
  189. </view>
  190. </view>
  191. </template>
  192. <script>
  193. import { mapState,mapMutations } from 'vuex'
  194. import customP from '@/components/cm-module/headerNavbar/header-poduct' //自定义导航
  195. import cmPrice from "@/components/cm-module/productDetails/cm-price.vue" //价格显示
  196. import cmAttributes from "@/components/cm-module/productDetails/cm-attributes.vue" //规格信息
  197. import authorize from '@/common/config/authorize.js'
  198. import uniStars from '@/components/uni-stars/uni-stars.vue'
  199. import parser from "@/components/jyf-Parser/index" //富文本处理
  200. import tuiSkeleton from "@/components/tui-skeleton/tui-skeleton"
  201. import recommend from "@/components/cm-module/productDetails/recommend" //相关推荐
  202. import cmParameter from "@/components/cm-module/productDetails/cm-parameter" //相关参数
  203. import cmService from "@/components/cm-module/productDetails/cm-service" //服务项目
  204. import wxLogin from "@/common/config/wxLogin.js"
  205. import { queryProductDetils } from "@/api/product.js"
  206. import { shoppingAddCart } from "@/api/cart.js"
  207. var isPreviewImg;
  208. export default{
  209. components:{
  210. customP,
  211. parser,
  212. tuiSkeleton,
  213. recommend,
  214. cmPrice,
  215. cmAttributes,
  216. cmParameter,
  217. cmService
  218. },
  219. data(){
  220. return{
  221. html:'<div style="text-align: center;color:#333333;">暂无内容</div>',
  222. disabledTabNavList:[{name:'相关推荐'}],
  223. mode:'round',
  224. specClass: '',//规格弹窗css类,控制开关动画
  225. isBtnType:'',
  226. isRequest:false,
  227. current:0,
  228. isShareType:'',
  229. isHeaderPoduct:false,
  230. navbarFiexd:'none',
  231. ladderPriceFlag:'',
  232. ladderPriceList:'',
  233. isRecommend:false,
  234. isRarameter:true,
  235. isService:false,
  236. isEvaluate:false,
  237. isAnimation:false,
  238. skeletonShow:true,
  239. isQuantity:false,
  240. isStock:false,
  241. disabled:false,
  242. isNoneDisabled:false,
  243. tabCurrentIndex:0,
  244. userID:'',
  245. productID:0,
  246. userIdentity:'',//用户类型
  247. goodsData:{},//自定义数据
  248. shop:{},//供应商信息
  249. product:{},//采美
  250. productImage:[],
  251. retailPrice:0,
  252. buyRetailPrice:0,
  253. buyRetailPriceStep:1,
  254. stock:0,
  255. number:0,
  256. minBuyNumber:0,
  257. productsList:[],
  258. goodListData:[],
  259. headerBtnPosi: this.setHeaderBtnPosi(), //获取设备顶部胶囊高度
  260. systeminfo: this.setSysteminfo(), //获取设备信息
  261. isIphoneX:this.$store.state.isIphoneX,
  262. windowHeight: '',
  263. headerColor:false,
  264. backPage:1,
  265. nvabarData: { //顶部自定义导航
  266. showCapsule: 1, // 是否显示左上角图标 1表示显示 0表示不显示
  267. title: '' // 导航栏 中间的标题
  268. },
  269. linkPath:''
  270. }
  271. },
  272. onLoad(option) {
  273. this.productID = option.id;//获取商品ID
  274. this.isShareType = option.type
  275. this.linkPath = option.path
  276. this.isHeaderPoduct = true
  277. if(option.page == 2){
  278. this.backPage = option.page
  279. }
  280. if(this.isShareType =='share'){
  281. authorize.getSetting().then(wxResponse =>{// console.log('是否已授权',res);//0:为取消授权 1:为已授权 2:为未操作
  282. console.log(wxResponse)
  283. if(wxResponse == 1){
  284. wxLogin.wxLoginAuthorize()
  285. }else{
  286. console.log(new Date +'用户未授权微信信息')
  287. }
  288. })
  289. }
  290. },
  291. computed: {
  292. ...mapState(['hasLogin','isWxAuthorize'])
  293. },
  294. methods:{
  295. initData(){// 初始化商品详情查询
  296. queryProductDetils({userId:this.userID,productID:this.productID}).then(response =>{
  297. this.skeletonShow = false
  298. this.productImage=[];
  299. this.shop = response.data.shop
  300. this.product = response.data
  301. this.ladderPriceFlag = this.product.ladderPriceFlag;
  302. this.html = this.product.productDetail == null ? this.html : this.$api.adaptRichTextImg(this.product.productDetail.detailInfo)
  303. this.stock = this.product.stock
  304. this.buyRetailPriceStep = this.product.step
  305. this.number = this.product.minBuyNumber
  306. this.minBuyNumber = this.product.minBuyNumber
  307. //处理商品图片列表
  308. this.product.imageList.forEach(item =>{
  309. this.productImage.push(item.image);
  310. })
  311. //购物车数量
  312. this.goodsData.cartCount = this.product.productCount
  313. //处理阶梯价格
  314. if(this.product.ladderPriceList!=null){
  315. this.ladderPriceList = this.product.ladderPriceList;
  316. }
  317. //拆分金额并转千分位格式显示
  318. if(this.product.retailPrice!=null){
  319. this.retailPrice = this.product.retailPrice.toFixed(2);
  320. this.buyRetailPrice = this.product.retailPrice;
  321. }
  322. //处理下架商品和售罄商品
  323. if(this.product.validFlag =='3' || this.stock == 0 ){
  324. this.disabled = true
  325. this.isNoneDisabled = true
  326. this.tabCurrentIndex = 2;// 页面显示是默认选中第一
  327. this.isRecommend = true
  328. this.goodsData.disabledText = '下架'
  329. }else{
  330. this.disabled = false
  331. this.isNoneDisabled = false
  332. this.tabCurrentIndex = 0;// 页面显示是默认选中第三
  333. this.goodsData.disabledText = ''
  334. }
  335. if(this.product.price1TextFlag == "1"){
  336. this.disabled = true
  337. }
  338. if(this.product.price1TextFlag == "2"){
  339. if(this.userIdentity == 4){
  340. this.disabled = true
  341. }else{
  342. this.disabled = false
  343. }
  344. }
  345. this.goodsData.disabled = this.disabled
  346. this.goodsData.isNoneDisabled = this.isNoneDisabled
  347. if(this.product.validFlag =='3'){
  348. this.goodsData.disabledText = '下架'
  349. }
  350. if(this.stock == 0){
  351. this.goodsData.disabledText = '售罄'
  352. }
  353. this.isRequest = true
  354. }).catch(error =>{
  355. this.$util.msg(error.msg,2000);
  356. })
  357. },
  358. swiperChange(e) {//顶部商品图片切换
  359. const index = e.detail.current;
  360. this.current = index;
  361. },
  362. previewImg (index) {//顶部商品图片预览
  363. isPreviewImg = true
  364. let previewUrls = this.productImage
  365. uni.previewImage({
  366. current: index, //图片索引
  367. urls: previewUrls, //必须是http图片,本地图片无效
  368. longPressActions:''
  369. })
  370. },
  371. tabClick(index) {//商品详情&&供应商信息tab切换
  372. this.tabCurrentIndex = index;
  373. switch(this.tabCurrentIndex){
  374. case 1:
  375. this.isRarameter = true
  376. break;
  377. case 2:
  378. this.isService = true
  379. break;
  380. case 3:
  381. this.isRecommend = true
  382. break;
  383. }
  384. },
  385. handleContact(e){//跳转小程序客服
  386. },
  387. buyProductCart(){//底部购物车按钮点击
  388. authorize.getSetting().then(wxResponse =>{// console.log('是否已授权',res);//0:为取消授权 1:为已授权 2:为未操作
  389. if(wxResponse == 1){
  390. if(this.hasLogin){
  391. this.$api.navigateTo('/pages/goods/cart')
  392. }else{
  393. this.$api.navigateTo('/pages/login/login?type=1')
  394. }
  395. }else{
  396. this.$api.navigateTo('/pages/authorization/authorization?type=1')
  397. }
  398. })
  399. },
  400. btnGetConfirm(type){//加入购物车&&立即购买点击
  401. authorize.getSetting().then(wxResponse =>{// console.log('是否已授权',res);//0:为取消授权 1:为已授权 2:为未操作
  402. if(wxResponse == 1){
  403. if(this.hasLogin){
  404. this.showSpec(type);
  405. }else{
  406. this.$api.navigateTo('/pages/login/login?type=1')
  407. }
  408. }else{
  409. this.$api.navigateTo('/pages/authorization/authorization?type=1')
  410. }
  411. })
  412. },
  413. changeCountAdd(){//popup弹窗数量增加按钮
  414. if(this.buyRetailPriceStep == 2){
  415. this.number+=this.minBuyNumber
  416. }else{
  417. this.number++
  418. }
  419. this.processActivityPrice()
  420. },
  421. changeCountSub(){//popup弹窗数量减按钮
  422. if(this.number<=this.minBuyNumber){
  423. this.number= this.minBuyNumber
  424. this.isQuantity =true
  425. this.$util.msg(`该商品最小起订量为${this.minBuyNumber}`,2000);
  426. return
  427. }else{
  428. if(this.buyRetailPriceStep == 2){
  429. this.number-=this.minBuyNumber
  430. }else{
  431. this.number--
  432. }
  433. this.processActivityPrice()
  434. this.isQuantity =false
  435. }
  436. },
  437. changeNumber(e){
  438. let _value = e.detail.value;
  439. if(!this.$api.isNumber(_value)){
  440. this.number = this.minBuyNumber
  441. }else if(_value < this.minBuyNumber){
  442. this.$util.msg(`该商品最小起订量为${this.minBuyNumber}`,2000);
  443. this.number = this.minBuyNumber
  444. }else if( _value % this.minBuyNumber !=0 ){
  445. this.$util.msg(`购买量必须为起订量的整数倍`,2000);
  446. this.number = this.minBuyNumber
  447. }else{
  448. this.number = e.detail.value
  449. }
  450. this.processActivityPrice()
  451. },
  452. processActivityPrice(){//单独处理活动价格和阶梯价格
  453. if(this.ladderPriceFlag == '0' && this.product.actStatus == 0){
  454. this.buyRetailPrice = this.product.retailPrice
  455. }else{
  456. this.ladderPriceList.forEach((item,index)=>{
  457. if(this.number>=item.buyNum){
  458. this.buyRetailPrice = item.buyPrice
  459. }
  460. })
  461. }
  462. },
  463. showSpec(type) {//显示选择数量确认弹窗
  464. this.isBtnType = type
  465. this.specClass = 'show';
  466. },
  467. hideSpec() {//关闭选择数量确认弹窗
  468. this.specClass = 'hide';
  469. setTimeout(() => {
  470. this.specClass = 'none';
  471. }, 200);
  472. },
  473. btnConfirm() {//加入购物车&&立即购买跳转订单页并关闭弹窗
  474. if(this.isBtnType == 'add'){
  475. this.getAddProductCart()
  476. }else{
  477. this.toConfirmation()
  478. }
  479. },
  480. toConfirmation(){//跳转确认订单页面
  481. this.specClass = 'hide';
  482. let productStp ={
  483. allPrice:this.number*this.buyRetailPrice,
  484. allCount:this.number,
  485. productID:this.product.productID,
  486. productCount:this.number
  487. }
  488. this.$api.navigateTo(`/pages/user/order/create-order?type=prodcut&data=${JSON.stringify({data:productStp})}`)
  489. setTimeout(() => {
  490. this.specClass = 'none';
  491. }, 200);
  492. },
  493. getAddProductCart(){//增加购物车成功和toast弹窗提示成功
  494. shoppingAddCart({productID:this.productID,userID:this.userID,productCount:this.number}).then(response => {
  495. this.specClass = 'hide';
  496. this.$util.msg('加入购物车成功',1500,true,'success')
  497. this.isAnimation = true
  498. setTimeout(() => {this.specClass = 'none'}, 200)
  499. setTimeout(() => {this.isAnimation = false},2000)
  500. this.goodsData.cartCount = response.data;
  501. }).catch(error =>{
  502. this.$util.msg(error.msg,2000);
  503. })
  504. },
  505. navToLogin(){
  506. authorize.getSetting().then(wxResponse =>{// console.log('是否已授权',res);//0:为取消授权 1:为已授权 2:为未操作
  507. if(wxResponse == 1){
  508. this.$api.navigateTo(`/pages/login/login?type=detilType&id=${this.productID}`)
  509. }else{
  510. this.$api.navigateTo('/pages/authorization/authorization?type=1')
  511. }
  512. })
  513. },
  514. setHeaderBtnPosi(){
  515. // 获得胶囊按钮位置信息
  516. let headerBtnPosi = uni.getMenuButtonBoundingClientRect();
  517. return headerBtnPosi
  518. },
  519. setSysteminfo(){
  520. let systeminfo;
  521. uni.getSystemInfo({ // 获取设备信息
  522. success: (res) => {
  523. systeminfo = res
  524. },
  525. })
  526. return systeminfo
  527. },
  528. getOptionFn(e){
  529. this.isShareType = e.type
  530. },
  531. goSupplier(){
  532. this.$api.setStorage('supplierInfo',this.shop)
  533. this.$api.navigateTo('/pages/goods/supplier')
  534. },
  535. discard(){
  536. //丢弃
  537. }
  538. },
  539. onPageScroll(e){//实时获取到滚动的值
  540. if(e.scrollTop>50){
  541. this.headerColor = true
  542. this.nvabarData={
  543. showCapsule: 1,
  544. title: '商品详情',
  545. }
  546. }else{
  547. this.headerColor = false
  548. this.nvabarData={
  549. showCapsule: 1,
  550. title: '',
  551. }
  552. }
  553. if(e.scrollTop>700){
  554. this.navbarFiexd = 'fixed'
  555. }else{
  556. this.navbarFiexd = 'none'
  557. }
  558. },
  559. onShareAppMessage(res){//分享转发
  560. if (res.from === 'button') {
  561. // 来自页面内转发按钮
  562. }
  563. return {
  564. title: `${this.product.name}`,
  565. path: `pages/goods/product?type=share&id=${this.productID}`,
  566. imageUrl:`${this.productImage[0]}`
  567. }
  568. },
  569. onShow() {
  570. this.$api.getStorage().then((resolve) => {
  571. this.userID = resolve.userID ? resolve.userID : '';
  572. this.userIdentity = resolve.userIdentity ? resolve.userIdentity : 3
  573. if (isPreviewImg) {
  574. isPreviewImg = false;
  575. return;
  576. } else {
  577. this.initData();
  578. }
  579. }).catch(error =>{
  580. this.initData();
  581. })
  582. }
  583. }
  584. </script>
  585. <style lang="scss">
  586. page{
  587. background-color: #F7F7F7;
  588. }
  589. .productRemarks{
  590. color: #FF2A2A;
  591. font-size: 24rpx;
  592. margin-bottom: 16rp
  593. }
  594. .banner-section{
  595. width: 100%;
  596. height: 750rpx;
  597. position: relative;
  598. border-bottom: 1px solid #EBEBEB;
  599. }
  600. .banner{
  601. width: 100%;
  602. height: 750rpx;
  603. .product-img{
  604. width: 750rpx;
  605. }
  606. image {
  607. width: 100%;
  608. height: 100%;
  609. }
  610. }
  611. .swiper__dots-box{
  612. position: absolute;
  613. bottom: 24px;
  614. right: 24rpx;
  615. /* #ifndef APP-NVUE */
  616. display: flex;
  617. /* #endif */
  618. flex: 1;
  619. flex-direction: row;
  620. justify-content: center;
  621. align-items: center;
  622. height: 12rpx;
  623. padding: 10rpx;
  624. background: rgba(174,174,174,0.6);
  625. border-radius:16rpx;
  626. .swiper__dots-item{
  627. width: 12rpx;
  628. height: 12rpx;
  629. border-radius: 100%;
  630. margin: 6rpx;
  631. background: rgba(62,62,62,1);
  632. }
  633. .none{
  634. background:#FFFFFF;
  635. }
  636. .swiper__dots-long{
  637. background: rgba(62,62,62,1);
  638. transition: all 0.1s;
  639. }
  640. }
  641. .product-wrap{
  642. width: 100%;
  643. height: auto;
  644. padding: 24rpx 0 0 0;
  645. background-color: #FFFFFF;
  646. border-bottom: 20rpx solid #F7F7F7;
  647. .wrap-top{
  648. width: 702rpx;
  649. padding: 0 24rpx;
  650. height: auto;
  651. float: left;
  652. padding-bottom: 24rpx;
  653. border-bottom: 1px solid #F8F8F8;
  654. &.none{
  655. .p-title{
  656. color:#999999
  657. }
  658. }
  659. .p-title{
  660. line-height: 40rpx;
  661. font-size: $font-size-28;
  662. color: $text-color;
  663. font-weight: Bold;
  664. -o-text-overflow: ellipsis;
  665. text-overflow: ellipsis;
  666. display: -webkit-box;
  667. word-break: break-all;
  668. -webkit-box-orient: vertical;
  669. -webkit-line-clamp: 2;
  670. overflow: hidden;
  671. margin-bottom: 16rpx;
  672. }
  673. .wrap-main-pricenone{
  674. line-height: 44rpx;
  675. color: #FF2A2A;
  676. font-size: $font-size-28;
  677. font-weight: 600;
  678. }
  679. .wrap-main-text{
  680. display: block;
  681. float: left;
  682. font-weight: normal;
  683. }
  684. .wrap-main-none{
  685. display: block;
  686. width: 256rpx;
  687. height: 44rpx;
  688. padding-left: 20rpx;
  689. border-radius: 11rpx;
  690. background: $btn-confirm;
  691. float: right;
  692. line-height: 44rpx;
  693. color: #FFFFFF;
  694. text-align: center;
  695. font-size: $font-size-24;
  696. }
  697. .p-active{
  698. width: 130rpx;
  699. height: 44rpx;
  700. display: flex;
  701. align-items: center;
  702. flex-direction: row;
  703. float: left;
  704. .icon-active{
  705. width: 124rpx;
  706. height: 30rpx;
  707. display: block;
  708. }
  709. }
  710. .p-price{
  711. height: 44rpx;
  712. line-height: 44rpx;
  713. float: left;
  714. .txt{
  715. color: #FF2A2A;
  716. margin:0 2rpx;
  717. }
  718. .txt.sm{
  719. font-size: $font-size-24;
  720. }
  721. .txt.big{
  722. font-size: $font-size-32;
  723. }
  724. }
  725. .p-price-none{
  726. height: 44rpx;
  727. line-height: 44rpx;
  728. float: left;
  729. font-size: $font-size-24;
  730. color: #666;
  731. text-decoration: line-through;
  732. margin-left: 8rpx;
  733. }
  734. .p-minBuy{
  735. height: 44rpx;
  736. line-height: 44rpx;
  737. float: right;
  738. padding: 0 18rpx;
  739. border-radius: 22rpx;
  740. background-color: #EBEBEB;
  741. color: #7F7F7F;
  742. font-size: 24rpx;
  743. text-align: center;
  744. .min-text{
  745. margin: 0 6rpx;
  746. }
  747. }
  748. .p-login{
  749. height: 44rpx;
  750. line-height: 44rpx;
  751. color: $color-system;
  752. font-size: $font-size-24;
  753. &.grade{
  754. margin-bottom: 20rpx;
  755. .price-left{
  756. float: left;
  757. .none{
  758. display: block;
  759. font-size: $font-size-20;
  760. line-height: 48rpx;
  761. color: #4A4B54;
  762. float: left;
  763. font-weight: bold;
  764. margin-left: 5rpx;
  765. text{
  766. letter-spacing: 4rpx;
  767. font-size: $font-size-32;
  768. }
  769. }
  770. }
  771. }
  772. .p-no{
  773. float: left;
  774. margin-right: 5rpx;
  775. font-size: $font-size-28;
  776. }
  777. .p-login-btn{
  778. display: block;
  779. height: 44rpx;
  780. padding: 0 10rpx 0 20rpx;
  781. border-radius: 11rpx;
  782. background: $btn-confirm;
  783. float: right;
  784. line-height: 44rpx;
  785. color: #FFFFFF;
  786. text-align: center;
  787. font-size: $font-size-24;
  788. }
  789. }
  790. }
  791. .wrap-active{
  792. width: 100%;
  793. float: left;
  794. height: 80rpx;
  795. background: linear-gradient(225deg,rgba(255,143,101,1) 0%,rgba(248,79,57,1) 100%);
  796. line-height: 80rpx;
  797. font-size: $font-size-26;
  798. color: #FFFFFF;
  799. text-align: center;
  800. }
  801. .wrap-ladder{
  802. float: left;
  803. width: 702rpx;
  804. border-bottom: 1px solid #F8F8F8;
  805. .ladder-text{
  806. height: 34rpx;
  807. line-height: 34rpx;
  808. margin-bottom: 24rpx;
  809. font-size: 24rpx;
  810. color: #999999;
  811. .ladder-p{
  812. font-size: 20rpx;
  813. }
  814. }
  815. .ladder-main{
  816. width: 654rpx;
  817. height: 102rpx;
  818. padding: 24rpx;
  819. background: url(https://img.caimei365.com/group1/M00/03/95/Cmis216Sk_WASybTAAI2gyWbunM918.png);
  820. background-size: cover;
  821. border-radius: 20rpx;
  822. display: flex;
  823. .ladder-left{
  824. flex: 1.5;
  825. line-height: 51rpx;
  826. font-size: 24rpx;
  827. .ladder-b{
  828. text-align-last: justify;
  829. }
  830. }
  831. .ladder-right{
  832. height: 100%;
  833. display: flex;
  834. align-items: center;
  835. flex: 8.5;
  836. .ladder-li{
  837. height: 100%;
  838. flex: 1;
  839. display:flex;
  840. flex-flow: column;
  841. align-items: center;
  842. .ladder-a{
  843. flex: 1;
  844. height: 51rpx;
  845. line-height: 51rpx;
  846. font-size: 26rpx;
  847. text-align: justify;
  848. color: #FA6400;
  849. font-weight: bold;
  850. }
  851. }
  852. }
  853. }
  854. }
  855. .wrap-label{
  856. float: left;
  857. width: 702rpx;
  858. padding: 24rpx 24rpx 0 24rpx;
  859. border-bottom: 1px solid #F8F8F8;
  860. .label-a{
  861. padding: 0 18rpx;
  862. line-height: 40rpx;
  863. font-size: $font-size-24;
  864. color: #FFFFFF;
  865. text-align: center;
  866. border-radius: 20rpx;
  867. background:#A69DFE;
  868. margin: 0 22rpx 22rpx 0;
  869. display: inline-block;
  870. }
  871. }
  872. .wrap-info{
  873. float: left;
  874. width: 702rpx;
  875. padding: 24rpx 24rpx 0 24rpx;
  876. border-bottom: 1px solid #F8F8F8;
  877. .info-viewT{
  878. width: 100%;
  879. min-height: 40rpx;
  880. font-size: $font-size-28;
  881. color: $text-color;
  882. line-height: 40rpx;
  883. text-align: left;
  884. &.none{
  885. color: #999999;
  886. }
  887. .info-viewL{
  888. min-width: 350rpx;
  889. float: left;
  890. margin-bottom: 24rpx;
  891. }
  892. .info-viewR{
  893. min-width: 352rpx;
  894. float: left;
  895. margin-bottom: 24rpx;
  896. }
  897. }
  898. .info-viewB{
  899. width: 100%;
  900. height: auto;
  901. }
  902. .info-f{
  903. width: 50%;
  904. float: left;
  905. font-size: $font-size-28;
  906. color: $text-color;
  907. line-height: 40rpx;
  908. margin-bottom: 24rpx;
  909. text-align: left;
  910. }
  911. }
  912. .wrap-seve{
  913. float: left;
  914. width: 702rpx;
  915. padding: 0 24rpx;
  916. height: 72rpx;
  917. line-height: 72rpx;
  918. font-size: $font-size-28;
  919. color: $text-color;
  920. border-bottom: 1px solid #F8F8F8;
  921. &.none{
  922. color: #999999;
  923. .text{
  924. color: #999999;
  925. }
  926. }
  927. .iconfont{
  928. color: $color-system;
  929. margin-left: 20rpx;
  930. font-size: $font-size-24;
  931. }
  932. .text{
  933. font-size: $font-size-24;
  934. color: $text-color;
  935. margin-left: 10rpx;
  936. }
  937. }
  938. }
  939. .product-supplier{
  940. width: 702rpx;
  941. height: 88rpx;
  942. padding: 0 24rpx;
  943. background-color: #FFFFFF;
  944. margin-bottom: 24rpx;
  945. position: relative;
  946. display: flex;
  947. .title{
  948. display: flex;
  949. flex: 2;
  950. line-height: 88rpx;
  951. display: inline-block;
  952. float: left;
  953. font-size: $font-size-28;
  954. color: $text-color;
  955. }
  956. .name{
  957. display: flex;
  958. flex: 2;
  959. line-height: 88rpx;
  960. display: inline-block;
  961. float: left;
  962. font-size: $font-size-24;
  963. color: #D0D0D0;
  964. float: right;
  965. padding-right: 48rpx;
  966. overflow: hidden;
  967. text-overflow:ellipsis;
  968. white-space: nowrap;
  969. text-align: right;
  970. }
  971. .icon-xiayibu{
  972. line-height: 88rpx;
  973. display: inline-block;
  974. position: absolute;
  975. width: 48rpx;
  976. top: 0;
  977. right: 0;
  978. }
  979. }
  980. .product-details {
  981. height: 100%;
  982. background: #FFFFFF;
  983. .navbar {
  984. width: 702rpx;
  985. height: 96rpx;
  986. padding: 0 24rpx;
  987. background: #fff;
  988. z-index: 10;
  989. display: flex;
  990. border-bottom: 1px solid #F8F8F8;
  991. &.fixed{
  992. position: fixed;
  993. left: 0;
  994. }
  995. .nav-item {
  996. display: flex;
  997. flex: 1;
  998. justify-content: center;
  999. align-items: center;
  1000. height: 96rpx;
  1001. font-size: $font-size-28;
  1002. color: $text-color;
  1003. position: relative;
  1004. float: left;
  1005. position: relative;
  1006. .line{
  1007. width: 60%;
  1008. height: 2px;
  1009. border-radius: 1px;
  1010. background: #FFFFFF;
  1011. position: absolute;
  1012. bottom: 0;
  1013. left: 50%;
  1014. margin-left: -30%;
  1015. }
  1016. &.current{
  1017. color:$color-system;
  1018. .line{
  1019. background: $color-system;
  1020. }
  1021. }
  1022. }
  1023. }
  1024. .content{
  1025. width: 100%;
  1026. min-height: 750rpx;
  1027. }
  1028. }
  1029. .isLower{
  1030. width: 100%;
  1031. height: 116rpx;
  1032. line-height: 116rpx;
  1033. text-align: center;
  1034. color: #000000;
  1035. font-size: $font-size-32;
  1036. font-weight: bold;
  1037. }
  1038. .bottom-btn{
  1039. width: 100%;
  1040. height: 110rpx;
  1041. position: fixed;
  1042. bottom: 0;
  1043. left: 0;
  1044. background: #FFFFFF;
  1045. z-index: 99;
  1046. .bottom-le{
  1047. width: 302rpx;
  1048. height: 86rpx;
  1049. padding:12rpx 24rpx;
  1050. float: left;
  1051. .item-bt{
  1052. width: 86rpx;
  1053. height: 100%;
  1054. margin-right:22rpx;
  1055. display: flex;
  1056. float: left;
  1057. flex-direction: column;
  1058. align-items: center;
  1059. font-size: $font-size-24;
  1060. color: $text-color;
  1061. line-height: 34rpx;
  1062. position: relative;
  1063. .animation-num{
  1064. font-size:$font-size-32 ;
  1065. color: #FF2A2A;
  1066. position: absolute;
  1067. top: -12rpx;
  1068. right: 4rpx;
  1069. font-weight: bold;
  1070. }
  1071. .animation{
  1072. animation: showAmnation 2.2s ease-in-out both;
  1073. }
  1074. .restion{
  1075. animation: hideAmnation 1s ease-in-out both;
  1076. }
  1077. .icon-num{
  1078. position: absolute;
  1079. right:-12rpx;
  1080. top: -9rpx;
  1081. }
  1082. .icon-num.goleft{
  1083. right: 4rpx;
  1084. }
  1085. &:last-child{
  1086. margin-right: 0;
  1087. }
  1088. image {
  1089. width: 40rpx;
  1090. height: 40rpx;
  1091. margin-bottom: 8rpx;
  1092. }
  1093. button.contact-btn{
  1094. width: 100%;
  1095. height: 100%;
  1096. margin: 0;
  1097. padding: 0;
  1098. display: flex;
  1099. flex-direction: column;
  1100. align-items: center;
  1101. box-sizing: border-box;
  1102. font-size: $font-size-24;
  1103. text-align: center;
  1104. text-decoration: none;
  1105. line-height: 34rpx;
  1106. border-radius: 0;
  1107. -webkit-tap-highlight-color: transparent;
  1108. overflow: hidden;
  1109. color: $text-color;
  1110. background-color:#FFFFFF;
  1111. }
  1112. }
  1113. }
  1114. .bottom-ri{
  1115. width: 400rpx;
  1116. height: 100%;
  1117. float: right;
  1118. display: flex;
  1119. .btn{
  1120. flex: 1;
  1121. width: 200rpx;
  1122. line-height: 110rpx;
  1123. text-align: center;
  1124. font-size: $font-size-28;
  1125. color: #FFFFFF;
  1126. }
  1127. .btn-cart{
  1128. background-color: #EFAF00;
  1129. }
  1130. .btn-cart.disabled{
  1131. background-color: rgba(239, 175, 0, 0.5);
  1132. }
  1133. .btn-bay{
  1134. background:linear-gradient(135deg,rgba(242,143,49,1) 0%,rgba(225,86,22,1) 100%);
  1135. }
  1136. .btn-bay.disabled{
  1137. background-color: linear-gradient(135deg,rgba(242,143,49,0.5) 0%,rgba(225,86,22,0.5) 100%);;
  1138. }
  1139. }
  1140. }
  1141. .uni-badge--small {
  1142. -webkit-transform: scale(.8);
  1143. -ms-transform: scale(.8);
  1144. transform: scale(.8);
  1145. -webkit-transform-origin: center center;
  1146. -ms-transform-origin: center center;
  1147. transform-origin: center center;
  1148. }
  1149. .uni-badge {
  1150. font-family: 'Helvetica Neue', Helvetica, sans-serif;
  1151. -webkit-box-sizing: border-box;
  1152. box-sizing: border-box;
  1153. font-size: 12px;
  1154. line-height: 1;
  1155. display: inline-block;
  1156. padding: 3px 6px;
  1157. color: #333;
  1158. border-radius: 100px;
  1159. background-color: #f1f1f1;
  1160. }
  1161. .uni-badge-error {
  1162. color: #fff;
  1163. background-color: #dd524d;
  1164. }
  1165. /* 加入购物模态层*/
  1166. @keyframes showPopup {
  1167. 0% {
  1168. opacity: 0;
  1169. }
  1170. 100% {
  1171. opacity: 1;
  1172. }
  1173. }
  1174. @keyframes hidePopup {
  1175. 0% {
  1176. opacity: 1;
  1177. }
  1178. 100% {
  1179. opacity: 0;
  1180. }
  1181. }
  1182. @keyframes showLayer {
  1183. 0% {
  1184. transform: translateY(0);
  1185. }
  1186. 100% {
  1187. transform: translateY(-100%);
  1188. }
  1189. }
  1190. @keyframes hideLayer {
  1191. 0% {
  1192. transform: translateY(-100%);
  1193. }
  1194. 100% {
  1195. transform: translateY(0);
  1196. }
  1197. }
  1198. @keyframes showAmnation {
  1199. 0% {
  1200. top: -12rpx;
  1201. opacity: 0;
  1202. }
  1203. 50% {
  1204. top: -60rpx;
  1205. opacity: 1;
  1206. }
  1207. 100% {
  1208. top: -100rpx;
  1209. opacity: 0;
  1210. }
  1211. }
  1212. @keyframes hideAmnation {
  1213. 0% {
  1214. top: -100rpx;
  1215. opacity: 0;
  1216. }
  1217. 100% {
  1218. top: -12rpx;
  1219. opacity: 0;
  1220. }
  1221. }
  1222. .popup {
  1223. position: fixed;
  1224. top: 0;
  1225. width: 100%;
  1226. height: 100%;
  1227. z-index: 999;
  1228. display: none;
  1229. .mask{
  1230. position: fixed;
  1231. top: 0;
  1232. width: 100%;
  1233. height: 100%;
  1234. z-index: 21;
  1235. background-color: rgba(0, 0, 0, 0.6);
  1236. }
  1237. .layer {
  1238. position: fixed;
  1239. z-index: 22;
  1240. bottom: -294rpx;
  1241. width: 702rpx;
  1242. padding: 24rpx 24rpx 36rpx 24rpx;
  1243. height: 260rpx;
  1244. border-radius: 20rpx 20rpx 0 0;
  1245. background-color: #fff;
  1246. display: flex;
  1247. flex-wrap: wrap;
  1248. align-content: space-between;
  1249. .content {
  1250. width: 100%;
  1251. }
  1252. .btn {
  1253. width: 100%;
  1254. height: 88rpx;
  1255. margin-top: 20rpx;
  1256. .button {
  1257. width: 100%;
  1258. height: 88rpx;
  1259. color: #fff;
  1260. display: flex;
  1261. align-items: center;
  1262. justify-content: center;
  1263. background: $btn-confirm;
  1264. font-size: $font-size-28;
  1265. border-radius: 14rpx;
  1266. }
  1267. }
  1268. }
  1269. &.show {
  1270. display: block;
  1271. .mask{
  1272. animation: showPopup 0.2s linear both;
  1273. }
  1274. .layer {
  1275. animation: showLayer 0.2s linear both;
  1276. }
  1277. }
  1278. &.hide {
  1279. display: block;
  1280. .mask{
  1281. animation: hidePopup 0.2s linear both;
  1282. }
  1283. .layer {
  1284. animation: hideLayer 0.2s linear both;
  1285. }
  1286. }
  1287. &.none {
  1288. display: none;
  1289. }
  1290. &.service {
  1291. .row {
  1292. margin: 30upx 0;
  1293. .title {
  1294. font-size: 30upx;
  1295. margin: 10upx 0;
  1296. }
  1297. .description {
  1298. font-size: 28upx;
  1299. color: #999;
  1300. }
  1301. }
  1302. }
  1303. .layer-smimg{
  1304. width: 114rpx;
  1305. height: 114rpx;
  1306. float: left;
  1307. border-radius: 10rpx;
  1308. margin-right: 24rpx;
  1309. image{
  1310. width: 114rpx;
  1311. height: 114rpx;
  1312. border-radius: 10rpx;
  1313. }
  1314. }
  1315. .layer-nunbox{
  1316. justify-content: space-between;
  1317. align-items: center;
  1318. width: 536rpx;
  1319. height: auto;
  1320. float: left;
  1321. .layer-nunbox-t{
  1322. width: 100%;
  1323. height:44rpx;
  1324. position:relative;
  1325. display: flex;
  1326. margin-bottom: 10rpx;
  1327. .text{
  1328. font-size: $font-size-24;
  1329. line-height: 48rpx;
  1330. color: #999999;
  1331. }
  1332. .layer-nunbox-text{
  1333. line-height: 44rpx;
  1334. font-size: $font-size-28;
  1335. }
  1336. .number-box{
  1337. display: flex;
  1338. justify-content: center;
  1339. align-items: center;
  1340. .iconfont{
  1341. font-size: $font-size-32;
  1342. padding:0 20rpx;
  1343. font-size: $text-color;
  1344. }
  1345. .btn-input{
  1346. width: 62rpx;
  1347. height: 48rpx;
  1348. line-height: 48rpx;
  1349. background: #F8F8F8;
  1350. border-radius: 4rpx;
  1351. text-align: center;
  1352. font-size: $font-size-28;
  1353. }
  1354. }
  1355. .product-step{
  1356. position: absolute;
  1357. left: 45rpx;
  1358. bottom: 0;
  1359. height: 44rpx;
  1360. background: #FFFFFF;
  1361. }
  1362. }
  1363. .layer-nunbox-b{
  1364. width: 100%;
  1365. height:44rpx;
  1366. margin-top: 13rpx;
  1367. }
  1368. .text{
  1369. line-height: 44rpx;
  1370. font-size: $font-size-28;
  1371. .p{
  1372. color: #FF2A2A;
  1373. }
  1374. .p:first-child{
  1375. margin-left: 30rpx;
  1376. }
  1377. .p.sm{
  1378. font-size: $font-size-24;
  1379. }
  1380. }
  1381. }
  1382. }
  1383. /*富文本样式*/
  1384. rich-text.p{
  1385. width: 702rpx !important;
  1386. padding: 0 24rpx;
  1387. text-align: justify;
  1388. }
  1389. rich-text.img{
  1390. width: 100%;
  1391. height: auto;
  1392. }
  1393. </style>