product.vue 72 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939
  1. <template>
  2. <view
  3. class="product "
  4. :style="{
  5. paddingBottom: userIdentity == 1 && userIdentity == 3 ? '0rpx' : '188rpx',
  6. paddingTop: CustomBar + 'px'
  7. }"
  8. >
  9. <custom-p
  10. v-if="isHeaderPoduct"
  11. :systeminfo="systeminfo"
  12. :navbar-data="nvabarData"
  13. :headerBtnPosi="headerBtnPosi"
  14. :headerColor="headerColor"
  15. :type="isShareType"
  16. :page="backPage"
  17. >
  18. </custom-p>
  19. <view
  20. class="product-topnav"
  21. id="topBar"
  22. v-show="isNavbarFiexd"
  23. :class="navbarFiexd"
  24. :style="{ top: CustomBar - 2 + 'px' }"
  25. >
  26. <view class="search-input">
  27. <view class="gosearch-btn" :class="navbarFiexd" @click="this.$api.navigateTo(clickPath)">
  28. <view class="search-icon"> <text class="iconfont icon-iconfonticonfontsousuo1"></text> </view>
  29. <view class="search-text">搜索商品/项目仪器</view>
  30. </view>
  31. </view>
  32. <view class="navbar">
  33. <view
  34. class="nav-item tui-skeleton-fillet"
  35. :class="{ current: tabCurrentIndex === 0 }"
  36. @click="tabClick(0)"
  37. >
  38. <text>详情</text> <text class="line"></text>
  39. </view>
  40. <view
  41. class="nav-item tui-skeleton-fillet"
  42. :class="{ current: tabCurrentIndex === 1 }"
  43. @click="tabClick(1)"
  44. >
  45. <text>服务项目</text> <text class="line"></text>
  46. </view>
  47. <view
  48. class="nav-item tui-skeleton-fillet"
  49. :class="{ current: tabCurrentIndex === 2 }"
  50. @click="tabClick(2)"
  51. v-if="product.qualificationImg"
  52. >
  53. <text>商品资质</text> <text class="line"></text>
  54. </view>
  55. <view
  56. class="nav-item tui-skeleton-fillet"
  57. :class="{ current: tabCurrentIndex === 3 }"
  58. @click="tabClick(3)"
  59. >
  60. <text>推荐</text> <text class="line"></text>
  61. </view>
  62. <view
  63. class="nav-item tui-skeleton-fillet"
  64. :class="{ current: tabCurrentIndex === 4 }"
  65. @click="tabClick(4)"
  66. v-if="product.archiveId !== 0"
  67. >
  68. <text>相关资料</text> <text class="line"></text>
  69. </view>
  70. </view>
  71. </view>
  72. <tui-skeleton
  73. v-if="skeletonShow"
  74. backgroundColor="#fafafa"
  75. borderRadius="10rpx"
  76. :isLoading="true"
  77. :loadingType="5"
  78. ></tui-skeleton>
  79. <template v-else>
  80. <view class="cart-content empty" v-if="isInvalid">
  81. <view class="empty-container">
  82. <image class="empty-container-image" :src="productNoneImage" mode="aspectFit"></image>
  83. <text class="error-text">商品已失效,去商城逛逛别的吧~</text>
  84. <view class="login-btn" @click="goIndex">去商城</view>
  85. </view>
  86. </view>
  87. <view class="container-product tui-skeleton" v-else>
  88. <view class="container-product-main">
  89. <view class="product-top">
  90. <view class="banner-section">
  91. <!-- <view class="cm-product-tags"> -->
  92. <!-- <view class="cm-product-cover" v-if="product.appletsActType === 1"
  93. >云上美博会</view
  94. > -->
  95. <view class="cm-product-type" v-if="product.productType == 2">医疗器械</view>
  96. <view class="cm-product-cover" v-if="product.appletsActType === 1"></view>
  97. <!-- </view> -->
  98. <uni-swiper-dot :info="productImage" :current="current" field="content" :mode="mode">
  99. <swiper
  100. class="banner tui-banner tui-skeleton-rect"
  101. @change="swiperChange"
  102. :duration="800"
  103. :autoplay="false"
  104. :circular="true"
  105. >
  106. <swiper-item v-for="(item, index) in productImage" :key="index" class="banner-item">
  107. <image :src="item" @click="previewImg(index)" class="product-img" />
  108. </swiper-item>
  109. </swiper>
  110. <view class="swiper__dots-box">
  111. <tui-tag
  112. padding="12rpx 24rpx"
  113. type="translucent"
  114. shape="circleLeft"
  115. size="32rpx"
  116. :scaleMultiple="0.82"
  117. originRight
  118. >
  119. {{ current + 1 }}/{{ productImage.length }}
  120. </tui-tag>
  121. </view>
  122. </uni-swiper-dot>
  123. </view>
  124. <view class="product-wrap clearfix">
  125. <view class="wrap-top" :class="goodsData.isNoneDisabled ? 'none' : ''">
  126. <view class="wrap-top-price">
  127. <cm-price
  128. v-if="isRequest"
  129. :product="product"
  130. :userIdentity="userIdentity"
  131. :shopID="shopID"
  132. :promotions="product.promotions"
  133. :ladderPriceList="ladderPriceList"
  134. />
  135. </view>
  136. <view class="p-title tui-skeleton-fillet">
  137. <view class="mclap-tag" v-if="product.beautyActFlag == '1'">美博会</view>
  138. <view class="p-title-name" :class="product.beautyActFlag == '1' ? 'indent' : ''">
  139. {{ product.name == undefined ? '' : product.name }}
  140. </view>
  141. <button open-type="share" class="p-title-share tui-share-position" @tap="onShare">
  142. <view class=""><text class="iconfont icon-fenxiang1"></text></view>
  143. <view class="">分享</view>
  144. </button>
  145. </view>
  146. <view class="wrap-label" v-if="product.tagsList.length > 0">
  147. <view
  148. class="label-a tui-skeleton-fillet"
  149. v-for="(label, index) in product.tagsList"
  150. :key="index"
  151. >{{ label }}</view
  152. >
  153. </view>
  154. <view class="product-seve" v-if="hasLogin">
  155. <text class="label">采美承诺:</text>
  156. <text class="iconfont icon-dui tui-skeleton-rect"
  157. ><text class="text">无忧退货</text></text
  158. >
  159. <text class="iconfont icon-dui tui-skeleton-rect"
  160. ><text class="text">快速退款</text></text
  161. >
  162. <text class="iconfont icon-dui tui-skeleton-rect"
  163. ><text class="text">正品保证</text></text
  164. >
  165. </view>
  166. <view
  167. class="productRemarks"
  168. v-if="product.productRemarks != '' && product.productRemarks != null"
  169. >
  170. 备注:{{ product.productRemarks }}
  171. </view>
  172. </view>
  173. </view>
  174. </view>
  175. <view class="product-item-none" v-if="goodsData.isNoneDisabled">
  176. <image class="none-image" :src="productNoneImage" mode=""></image>
  177. <view class="none-text">此商品已{{ goodsData.disabledText }},请浏览以下推荐商品~</view>
  178. </view>
  179. <!-- 选择规格 -->
  180. <view class="product-parameter" v-if="isShowButton || userIdentity === 1" @click="showPopup(3)">
  181. <text class="title">选择:</text> <text class="name">共{{ skusCount }}种规格可选</text>
  182. <text class="iconfont icon-xiayibu"></text>
  183. </view>
  184. <!-- 参数 -->
  185. <view class="product-parameter" @click="showPopup(0)" v-if="!goodsData.isNoneDisabled">
  186. <text class="title">参数:</text> <text class="name">品牌 分类...</text>
  187. <text class="iconfont icon-xiayibu"></text>
  188. </view>
  189. <!-- 配套商品 -->
  190. <view
  191. class="product-supporting"
  192. v-if="!goodsData.isNoneDisabled && isShowSupportingList && supportingList.length > 0"
  193. @click.stop="handleSupporting"
  194. >
  195. <view class="product-supporting-title">配套商品({{ supportingNum }})</view>
  196. <view class="product-supporting-list">
  197. <view
  198. class="list"
  199. v-for="(supporting, index) in supportingList"
  200. :key="index"
  201. v-if="index < 4"
  202. >
  203. <image class="list-image" :src="supporting.image" mode=""></image>
  204. </view>
  205. <text class="iconfont icon-xiayibu"></text>
  206. </view>
  207. </view>
  208. <!-- 优惠券 -->
  209. <view
  210. class="product-parameter coupon"
  211. v-if="isShowButton && productCoupon.length > 0"
  212. @click="showPopup(2)"
  213. >
  214. <text class="title">优惠券:</text>
  215. <view class="coupon">
  216. <text class="tags" v-for="(coupon, index) in productCoupon.slice(0, 3)" :key="index">
  217. 满{{ coupon.touchPrice }}减{{ coupon.couponAmount }}
  218. </text>
  219. </view>
  220. <text class="iconfont icon-xiayibu"></text>
  221. </view>
  222. <!-- 仪器培训方案 -->
  223. <view
  224. class="product-parameter"
  225. @click="showPopup(1)"
  226. v-if="product.commodityType == 2 && product.trainingMethod"
  227. >
  228. <text class="title">培训方案:</text>
  229. <text class="name">{{ product.trainingMethod == 1 ? '线上培训' : '线下培训' }}</text>
  230. <text class="iconfont icon-xiayibu"></text>
  231. </view>
  232. <!-- 供应商 -->
  233. <view class="product-supplier" @click="goSupplier">
  234. <view class="logo">
  235. <img
  236. :src="
  237. shop.logo
  238. ? shop.logo
  239. : 'https://static.caimei365.com/app/img/icon/icon-shoplogo.png'
  240. "
  241. alt=""
  242. /></view>
  243. <view class="main">
  244. <view class="name">{{ shop.name }}</view>
  245. <view class="massgs">
  246. <view class="label">满意度:</view>
  247. <view class="p-stars">
  248. <uni-stars
  249. :stars="6"
  250. :iconClass="iconClass"
  251. :iconColor="iconColor"
  252. :fontSize="36"
  253. :widthInfo="176"
  254. ></uni-stars>
  255. </view>
  256. <view class="acount">
  257. <text>{{ shop.normalNum }}</text
  258. >件商品
  259. </view>
  260. </view>
  261. </view>
  262. <view class="right" v-if="!isShowCaimeiShop"><text class="iconfont icon-xiayibu"></text></view>
  263. </view>
  264. </view>
  265. <!-- 商品详情 -->
  266. <view v-show="tabCurrentIndex !== 3">
  267. <view class="product-details product-details0">
  268. <view class="title"> <view class="title-tab">商品详情</view> </view>
  269. <view class="content tui-banner product-rich-text tui-skeleton-rect">
  270. <template v-if="!goodsData.isNoneDisabled && product.productDetail.detailInfo">
  271. <parser :html="html" :img-mode="widthFix"></parser>
  272. </template>
  273. <view class="product-rich-text-none" v-else>暂无商品信息</view>
  274. </view>
  275. </view>
  276. <!-- 服务项目 -->
  277. <view class="product-details service product-details1">
  278. <view class="title"> <view class="title-tab">服务项目</view> </view>
  279. <view
  280. class="content service"
  281. v-if="product.productDetail.orderInfo || product.productDetail.serviceInfo"
  282. >
  283. <cm-service :product="product.productDetail" v-if="isRequest"></cm-service>
  284. </view>
  285. <view class="content-none" v-else> <text>暂无服务项目</text> </view>
  286. </view>
  287. <!-- 商品资质 -->
  288. <view class="product-details qualifications product-details2" v-if="product.qualificationImg">
  289. <view class="title"><view class="title-tab">商品资质</view></view>
  290. <view class="product-details-image">
  291. <view class="product-details-table clearfix" v-if="product.qualificationNo">
  292. <view class="ladder-tr">
  293. <view class="ladder-item-td th">证书编号</view>
  294. <view class="ladder-item-td th">产品名称</view>
  295. <view class="ladder-item-td th">详情</view>
  296. </view>
  297. <view class="ladder-tr">
  298. <view class="ladder-item-td">
  299. <view class="te-text">{{ product.qualificationNo }}</view>
  300. </view>
  301. <view class="ladder-item-td">
  302. <view class="te-text">{{ product.productName }}</view>
  303. </view>
  304. <view class="ladder-item-td">
  305. <view class="te-text last">{{ product.qualificationLink }}</view>
  306. <view class="te-copy">
  307. <text class="clipboard" @click.stop="clipboard(product.qualificationLink)"
  308. >复制</text
  309. >
  310. </view>
  311. </view>
  312. </view>
  313. </view>
  314. <image
  315. class="qualificationImg-image"
  316. :src="product.qualificationImg"
  317. mode="aspectFill"
  318. @click="previewImg1(product.qualificationImg)"
  319. ></image>
  320. </view>
  321. </view>
  322. <!-- 相关推荐 -->
  323. <view class="product-details recommend product-details3">
  324. <view class="title"> <view class="title-tab">相关推荐</view> </view>
  325. <view class="content hot">
  326. <cm-recommend
  327. :query-productid="product.productId"
  328. :query-type="product.recommendType"
  329. v-if="isRequest"
  330. ></cm-recommend>
  331. </view>
  332. </view>
  333. </view>
  334. <!-- 相关资料 -->
  335. <view class="product-details recommend product-details4" v-show="tabCurrentIndex === 4">
  336. <cm-product-doc
  337. @previewImage="changePreViewImageStatus"
  338. :archiveId="product.archiveId"
  339. :userId="userId"
  340. ></cm-product-doc>
  341. </view>
  342. <!-- 优惠券 -->
  343. <tui-bottom-popup :radius="true" :show="popupShow2" @close="hidePopup(2)">
  344. <view class="tui-popup-box clearfix">
  345. <view class="title">优惠券</view>
  346. <view class="tui-popup-close" @click="hidePopup(2)">
  347. <text class="iconfont icon-iconfontguanbi"></text>
  348. </view>
  349. <view class="tui-popup-tabs">
  350. <coupon-tabs
  351. :tabs="navbar"
  352. :currentTab="currentTab > 2 ? 0 : currentTab"
  353. @change="couponChange"
  354. :itemWidth="100 / navbar.length + '%'"
  355. selectedColor="#e15616"
  356. sliderBgColor="#e15616"
  357. >
  358. </coupon-tabs>
  359. </view>
  360. <div class="tui-popup-main coupon">
  361. <scroll-view class="tui-popup-scroll" scroll-y="true">
  362. <view class="coupon-empty" v-if="isCouponEmpty">
  363. <image
  364. class="empty-container-image"
  365. :src="StaticUrl + '/icon/icon-coupon-empty@2x.png'"
  366. ></image>
  367. <text class="error-text">暂无可领的优惠券~</text>
  368. </view>
  369. <template v-else>
  370. <view
  371. v-for="(coupon, index) in productCouponList"
  372. :key="index"
  373. :id="coupon.couponId"
  374. class="coupon-list"
  375. >
  376. <view class="list-cell-le">
  377. <view class="coupon-maxMoney"
  378. ><text class="small">¥</text>{{ coupon.couponAmount }}</view
  379. >
  380. <view class="coupon-minMoney">满{{ coupon.touchPrice }}可用</view>
  381. </view>
  382. <view class="list-cell-ri">
  383. <view class="list-cell-top">
  384. <view class="list-cell-type">
  385. <view class="list-cell-tags">
  386. <template v-if="coupon.moneyCouponFlag == 1">
  387. <text class="tags" v-if="coupon.moneyCouponType == 1"
  388. >意向{{ coupon.couponType | TypeFormat }}</text
  389. >
  390. <text class="tags" v-else
  391. >定向{{ coupon.couponType | TypeFormat }}</text
  392. >
  393. </template>
  394. <template v-else>
  395. <text class="tags">{{
  396. coupon.couponType | TypeFormat
  397. }}</text>
  398. </template>
  399. </view>
  400. <view class="list-cell-texts">
  401. <text v-if="coupon.couponType == 0">
  402. {{
  403. coupon.productType && coupon.productType == 1
  404. ? '全商城商品通用'
  405. : '仅可购买指定商品'
  406. }}
  407. </text>
  408. <text v-if="coupon.couponType == 1">
  409. {{
  410. coupon.categoryType == 1
  411. ? '仅限购买产品类商品'
  412. : '仅限购买仪器类商品'
  413. }}
  414. </text>
  415. <text v-if="coupon.couponType == 3"
  416. >仅限购买店铺【{{ coupon.shopName }}】的商品</text
  417. >
  418. <text v-if="coupon.couponType == 4 || coupon.couponType == 2"
  419. >全商城商品通用</text
  420. >
  421. </view>
  422. </view>
  423. <view class="list-cell-btn">
  424. <view class="icon-used">
  425. <template v-if="coupon.couponBtnType == 0">
  426. <template v-if="coupon.couponPayWay == 2">
  427. <view class="icon-used-text"
  428. >{{ coupon.moneyCouponPrice }}采美豆</view
  429. >
  430. <view
  431. class="icon-used-btn receive"
  432. @click="toDeductCoupon(coupon)"
  433. >抵扣</view
  434. >
  435. </template>
  436. <template v-else-if="coupon.couponPayWay == 1">
  437. <view class="icon-used-text">购买</view>
  438. <view
  439. class="icon-used-btn receive"
  440. @click="toPayCoupon(coupon)"
  441. >¥{{ coupon.moneyCouponPrice }}</view
  442. >
  443. </template>
  444. <template v-else>
  445. <view
  446. class="icon-used-btn receive"
  447. @click="receiveCoupon(coupon)"
  448. >领取</view
  449. >
  450. </template>
  451. </template>
  452. <view
  453. class="icon-used-btn make"
  454. v-if="coupon.couponBtnType == 1"
  455. >已领取</view
  456. >
  457. </view>
  458. </view>
  459. </view>
  460. <view class="list-cell-time"
  461. >{{ coupon.startDate }} - {{ coupon.endDate }}</view
  462. >
  463. </view>
  464. </view>
  465. </template>
  466. </scroll-view>
  467. </div>
  468. </view>
  469. </tui-bottom-popup>
  470. <!-- 培训方案 -->
  471. <tui-bottom-popup :radius="true" :show="popupShow1" @close="hidePopup(1)">
  472. <view class="tui-popup-box clearfix">
  473. <view class="title">培训方案</view>
  474. <div class="tui-popup-main">
  475. <scroll-view class="tui-popup-scroll train" scroll-y="true">
  476. <view class="content-tr">
  477. <view class="content-td">培训方式:</view>
  478. <view class="content-th">{{
  479. product.trainingMethod == 1 ? '线上培训' : '线下培训'
  480. }}</view>
  481. </view>
  482. <view class="content-tr">
  483. <view class="content-td">培训费用:</view>
  484. <view class="content-th">{{
  485. product.trainingType == 1 ? '¥' + product.trainingFee : '售价已包含'
  486. }}</view>
  487. </view>
  488. </scroll-view>
  489. </div>
  490. <view
  491. class="tui-right-flex tui-popup-btn"
  492. :style="{ paddingBottom: isIphoneX ? '68rpx' : '.34rpx' }"
  493. >
  494. <view class="tui-flex-1"> <view class="tui-button" @click="hidePopup(1)">收起</view> </view>
  495. </view>
  496. </view>
  497. </tui-bottom-popup>
  498. <!-- 底部按钮 -->
  499. <view class="menu" v-if="isShowButton">
  500. <view class="bottom-btn" :style="{ paddingBottom: isIphoneX ? '68rpx' : '0rpx' }">
  501. <view class="bottom-le">
  502. <view class="item-bt" @click="this.$api.switchTabTo('/pages/tabBar/home/index')">
  503. <image src="../../static/icon-home-active@3x.png"></image> <text>首页</text>
  504. </view>
  505. <view class="item-bt" @click="handleCollection">
  506. <image
  507. :src="
  508. collectionType
  509. ? StaticUrl + 'icon/icon-collection@2x.png'
  510. : StaticUrl + 'icon/icon-collection-none@2x.png'
  511. "
  512. ></image>
  513. <text>{{ collectionType ? '已收藏' : '收藏' }}</text>
  514. </view>
  515. <view class="item-bt" @click="buyProductCart()">
  516. <image src="https://static.caimei365.com/app/img/icon/icon-cart-active@3x.png"></image>
  517. <text>购物车</text>
  518. <text
  519. v-if="hasLogin && bottomCartNumber > 0"
  520. class="uni-badge uni-badge-error uni-small uni-badge--small icon-num"
  521. :class="[bottomCartNumber < 10 ? 'goleft' : '']"
  522. >
  523. {{ bottomCartNumber >= 100 ? '99+' : bottomCartNumber }}
  524. </text>
  525. <view class="animation-num" :class="isAnimation ? 'animation' : 'restion'">+1</view>
  526. </view>
  527. </view>
  528. <view class="bottom-ri">
  529. <button
  530. :disabled="goodsData.disabled"
  531. class="btn btn-cart"
  532. :class="[goodsData.disabled ? 'disabled' : '']"
  533. @tap.stop="btnGetConfirm('add')"
  534. >
  535. 加入购物车
  536. </button>
  537. <button
  538. :disabled="goodsData.disabled"
  539. class="btn btn-bay"
  540. :class="[goodsData.disabled ? 'disabled' : '']"
  541. @tap.stop="btnGetConfirm('buy')"
  542. >
  543. 立即购买
  544. </button>
  545. </view>
  546. </view>
  547. </view>
  548. <!-- 侧边 -->
  549. <scroll-top :isScrollTop="isScrollTop" :bottom="200" v-show="tabCurrentIndex !== 3"></scroll-top>
  550. </view>
  551. </template>
  552. <!-- 商品参数 -->
  553. <cm-prams-popup v-if="popupShow0" :popupShow="popupShow0" :product="product"></cm-prams-popup>
  554. <!-- 选择规格弹窗 -->
  555. <cm-unit-popup
  556. v-if="popupShow3"
  557. :popupShow="popupShow3"
  558. :skuProduct="skuProduct"
  559. :type="unitPopupType"
  560. :btnType="btnType"
  561. :goodsData="goodsData"
  562. @buyConfirm="handleBuyConfirm"
  563. @skuClick="handleSkuClick"
  564. ></cm-unit-popup>
  565. <!-- 弹窗提示 -->
  566. <tui-modal
  567. :show="modal"
  568. @click="handleClick"
  569. @cancel="hideMobel"
  570. :content="contentModalText"
  571. :button="modalButton"
  572. color="#333"
  573. :size="32"
  574. shape="circle"
  575. :maskClosable="false"
  576. >
  577. </tui-modal>
  578. <!-- 商品详情可见度弹窗提醒 -->
  579. <cm-product-modal
  580. v-if="showModal"
  581. :showModal="showModal"
  582. :commodityDetailsFlag="product.commodityDetailsFlag"
  583. :isShareType="isShareType"
  584. :userIdentity="userIdentity"
  585. :firstClubType="firstClubType"
  586. />
  587. <!-- ross弹窗 -->
  588. <cmRossPopup v-if="showRossHtml" :popupShow="showRossHtml"></cmRossPopup>
  589. </view>
  590. </template>
  591. <script>
  592. import { mapState, mapMutations } from 'vuex'
  593. import customP from './components/cm-header.vue' //自定义导航
  594. import parser from '@/components/jyf-Parser/index' //富文本处理
  595. import cmPrice from './components/cm-price.vue' //价格显示
  596. import cmAttributes from './components/cm-attributes.vue' //规格信息
  597. import cmRecommend from './components/recommend' //相关推荐
  598. import cmParameter from './components/cm-parameter' //相关参数
  599. import cmService from './components/cm-service' //服务项目
  600. import cmProductDoc from './components/cm-product-doc.vue'
  601. import cmProductModal from './components/cm-product-modal.vue'
  602. import cmPramsPopup from './components/cm-prams-popup.vue'
  603. import cmUnitPopup from './components/cm-unit-popup.vue'
  604. import couponTabs from '@/components/cm-module/coupon/tui-tabs.vue'
  605. import cmRossPopup from '@/components/cm-module/cm-ross/cm-ross-popup'
  606. import authorize from '@/common/config/authorize.js'
  607. import wxLogin from '@/common/config/wxLogin.js'
  608. import { debounce } from '@/common/config/common.js'
  609. import payMixins from '@/mixins/payMixins.js'
  610. import proMixins from './mixins/proMixins.js'
  611. import cmSrsMixins from '@/mixins/cmSrsMixins.js'
  612. import thorui from '@/components/clipboard/clipboard.thorui.js'
  613. var isPreviewImg
  614. export default {
  615. mixins: [payMixins,proMixins,cmSrsMixins],
  616. components: {
  617. customP,
  618. parser,
  619. cmRecommend,
  620. cmPrice,
  621. cmAttributes,
  622. cmParameter,
  623. cmService,
  624. couponTabs,
  625. cmProductDoc,
  626. cmPramsPopup,
  627. cmUnitPopup,
  628. cmProductModal,
  629. cmRossPopup
  630. },
  631. data() {
  632. return {
  633. StaticUrl: this.$Static, //静态图片路径
  634. clickPath: '/pages/search/search',
  635. html: '',
  636. productNoneImage: 'https://static.caimei365.com/app/img/icon/icon-pnone.png',
  637. mode: 'round',
  638. iconClass: 'icon-aixin',
  639. iconColor: '#ff9100',
  640. specClass: '', // 规格弹窗css类,控制开关动画
  641. isBtnType: '',
  642. isRequest: false,
  643. isScrollTop: false,
  644. current: 0,
  645. isShareType: '',
  646. isHeaderPoduct: false,
  647. isNavbarFiexd: false,
  648. navbarFiexd: 'none',
  649. ladderPriceFlag: '',
  650. ladderPriceList: '',
  651. isInvalid: false,
  652. isEvaluate: false,
  653. isAnimation: false,
  654. skeletonShow: true,
  655. isStock: false,
  656. disabled: false,
  657. isNoneDisabled: false,
  658. tabCurrentIndex: 0,
  659. userId: 0,
  660. shopId: 0,
  661. shopID: 0,
  662. typeId: 0,
  663. vipFlag: 0,
  664. firstClubType: 0,
  665. productId: 0,
  666. skusCount: 0, // 规格种类
  667. userIdentity: 0, // 用户类型
  668. goodsData: {}, // 自定义数据
  669. shop: {}, //供应商信息
  670. product: {}, //采美
  671. productImage: [],
  672. retailPrice: 0,
  673. stock: 0,
  674. number: 0,
  675. minBuyNumber: 0,
  676. productsList: [],
  677. goodListData: [],
  678. productCoupon: [], // 优惠券
  679. productCouponList: [], // 优惠券弹窗列表
  680. headerBtnPosi: this.setHeaderBtnPosi(), // 获取设备顶部胶囊高度
  681. systeminfo: this.setSysteminfo(), // 获取设备信息
  682. windowHeight: '',
  683. headerColor: false,
  684. backPage: 1,
  685. nvabarData: {
  686. // 顶部自定义导航
  687. showCapsule: 1, // 是否显示左上角图标 1表示显示 0表示不显示
  688. title: '' // 导航栏 中间的标题
  689. },
  690. linkPath: '',
  691. CustomBar: this.CustomBar, // 顶部导航栏高度
  692. popupShow0: false, // 参数弹窗
  693. popupShow1: false, // 培训方案
  694. popupShow2: false, // 优惠券
  695. popupShow3: false, // 购买弹窗
  696. tabSelectFlag: false,
  697. sectionPropsArr: [],
  698. scrollTopArray: [],
  699. winHeight: '',
  700. isShowButton: true,
  701. isCouponEmpty: false,
  702. currentTab: 0,
  703. couponParam: {
  704. // 获取弹窗优惠券领取参数
  705. userId: 0,
  706. productId: 0,
  707. status: 1,
  708. source: 2
  709. },
  710. bottomCartNumber: 0,
  711. navbar: [{ name: '未领取', num: 0 }, { name: '已领取', num: 0 }],
  712. isPreviewImage: false,
  713. opentype: '',
  714. collectionType: false,
  715. isShowSupportingList: false,
  716. supportingList: [],
  717. supportingNum: 0, // 组合商品总数
  718. contentModalText: '', //操作文字提示语句
  719. modal: false,
  720. modalButton: [
  721. {
  722. text: '取消',
  723. type: 'gray',
  724. plain: true //是否空心
  725. },
  726. {
  727. text: '去升级',
  728. customStyle: {
  729. color: '#fff',
  730. bgColor: 'linear-gradient(90deg, #F28F31 0%, #E15616 100%)'
  731. },
  732. plain: false
  733. }
  734. ],
  735. showModal: false,
  736. isShowCaimeiShop: false,
  737. unitPopupType: 0 // 选择类型 1 点击加入购物车 立即购买 2:点击规格选择
  738. }
  739. },
  740. computed: {
  741. ...mapState(['hasLogin', 'clubType', 'identity', 'isIphoneX'])
  742. },
  743. filters: {
  744. TypeFormat(value) {
  745. switch (value) {
  746. case 0:
  747. return '活动券'
  748. break
  749. case 1:
  750. return '品类券'
  751. break
  752. case 2:
  753. return '用户专享券'
  754. break
  755. case 3:
  756. return '店铺券'
  757. break
  758. case 4:
  759. return '新用户券'
  760. break
  761. }
  762. }
  763. },
  764. watch: {
  765. isNavbarFiexd(val) {
  766. if (!this.isRequest || !val) return
  767. let timer = null
  768. clearTimeout(timer)
  769. timer = setTimeout(() => {
  770. if (this.sectionPropsArr.length > 0) return
  771. this.getSectionProps()
  772. }, 200)
  773. }
  774. },
  775. onLoad(option) {
  776. this.productId = this.couponParam.productId = this.addParams.productId = this.handleProsId = option.id //获取商品ID
  777. if (option.typeId) {
  778. this.typeId = option.typeId
  779. }
  780. this.opentype = option.open
  781. this.isShareType = option.type
  782. this.linkPath = option.path
  783. this.isHeaderPoduct = true
  784. if (option.page == 2) {
  785. this.backPage = option.page
  786. }
  787. this.getWinHeight()
  788. },
  789. onReady() {
  790. if (this.opentype == 'caimei') {
  791. // 跳转到资料详情
  792. uni.showLoading({
  793. title: '加载中'
  794. })
  795. setTimeout(() => {
  796. this.isNavbarFiexd = true
  797. this.tabClick(3)
  798. uni.hideLoading()
  799. }, 2000)
  800. }
  801. console.log('是iPhoneX', this.isIphoneX)
  802. },
  803. methods: {
  804. async initGetStotage() {
  805. // 初始化
  806. const userInfo = await this.$api.getStorage()
  807. this.userId = this.couponParam.userId = this.addParams.userId = userInfo.userId ? userInfo.userId : 0
  808. this.userIdentity = userInfo.userIdentity ? userInfo.userIdentity : 0
  809. this.vipFlag = userInfo.vipFlag ? userInfo.vipFlag : 0
  810. this.shopID = userInfo.shopId ? userInfo.shopId : 0
  811. this.firstClubType = this.clubType
  812. if (this.userIdentity == 0 || this.userIdentity == 2 || this.userIdentity == 4) {
  813. this.isShowButton = true
  814. } else {
  815. this.isShowButton = false
  816. }
  817. if (isPreviewImg) {
  818. isPreviewImg = false
  819. return
  820. } else {
  821. this.initData()
  822. }
  823. },
  824. initData() {
  825. // 初始化商品详情查询
  826. this.ProductService.QueryProductDetils({
  827. userId: this.userId,
  828. productId: this.productId,
  829. identity: this.identity,
  830. typeId: this.typeId
  831. })
  832. .then(response => {
  833. let productLabel = ''
  834. this.productImage = []
  835. this.shop = response.data.shop
  836. this.shopId = response.data.shopId
  837. this.product = this.skuProduct = response.data
  838. this.skusCount = this.product.skus.length
  839. this.addParams.skuId = this.product.skuId
  840. if (this.product.tinyTypeName) {
  841. productLabel = this.product.tinyTypeName
  842. } else if (!this.product.tinyTypeName && this.product.smallTypeName) {
  843. productLabel = this.product.smallTypeName
  844. } else {
  845. productLabel = this.product.bigTypeName
  846. }
  847. //设置统计数据标签
  848. uni.setStorageSync(
  849. 'productLabel',
  850. `${productLabel}-${this.product.brandName ? this.product.brandName : ''}`
  851. )
  852. //校验是否为ross
  853. this.checkedIsRossSet()
  854. //判断是否可以跳转供应商主页
  855. if (this.product.shopType === 2) {
  856. this.isShowCaimeiShop = true
  857. }
  858. // 判断是否显示已收藏
  859. if (this.product.userLike && this.product.userLike == 1) {
  860. this.collectionType = true
  861. } else {
  862. this.collectionType = false
  863. }
  864. //已删除/已冻结
  865. if (this.product.validFlag === 0 || this.product.validFlag == 10) {
  866. this.isInvalid = true
  867. } else if (this.product.validFlag === 9) {
  868. if (this.userIdentity == 1) {
  869. this.isInvalid = false
  870. } else {
  871. this.isInvalid = true
  872. }
  873. }
  874. this.ladderPriceFlag = this.product.ladderPriceFlag
  875. this.html = this.adaptRichTextImg(this.product)
  876. this.stock = this.product.stock
  877. this.number = this.product.minBuyNumber
  878. this.minBuyNumber = this.product.minBuyNumber
  879. //处理商品图片列表
  880. this.product.imageList.forEach(item => {
  881. this.productImage.push(item.image)
  882. })
  883. //处理阶梯价格
  884. if (this.product.ladderPriceList != null) {
  885. this.ladderPriceList = this.product.ladderPriceList
  886. }
  887. //拆分金额并转千分位格式显示
  888. if (this.product.price != null) {
  889. this.retailPrice = this.product.price.toFixed(2)
  890. }
  891. //处理下架商品和售罄商品
  892. if (this.product.validFlag == 3 || this.product.saleOutFlag === 1) {
  893. this.isNoneDisabled = true
  894. this.disabled = true
  895. } else {
  896. this.disabled = false
  897. this.isNoneDisabled = false
  898. this.goodsData.disabledText = ''
  899. }
  900. if (this.product.priceFlag == 1) {
  901. this.disabled = true
  902. } else if (this.product.priceFlag == 2) {
  903. if (this.userIdentity == 4 && this.vipFlag != 1) {
  904. this.disabled = true
  905. } else {
  906. this.disabled = false
  907. }
  908. } else if (this.product.priceFlag == 3) {
  909. if (this.userIdentity == 4) {
  910. this.disabled = true
  911. } else if (this.userIdentity == 2 && this.firstClubType != 1) {
  912. this.disabled = true
  913. } else {
  914. this.disabled = false
  915. }
  916. } else {
  917. this.disabled = false
  918. }
  919. this.goodsData.disabled = this.disabled
  920. this.goodsData.isNoneDisabled = this.isNoneDisabled
  921. if (this.product.validFlag == 3) {
  922. this.goodsData.disabledText = '下架'
  923. }
  924. if (this.product.validFlag == 10) {
  925. this.goodsData.disabledText = '停售'
  926. }
  927. if (this.product.saleOutFlag === 1) {
  928. this.goodsData.disabledText = '售罄'
  929. }
  930. console.log(this.disabled)
  931. // setTimeout(() => {
  932. // this.getSectionProps()
  933. // }, 2000)
  934. this.handleShowProductType(this.product.commodityDetailsFlag)
  935. if ((this.hasLogin && this.userIdentity == 2) || this.userIdentity == 4) {
  936. this.ProductCartNumber()
  937. }
  938. this.queryProductDetilsCoupons()
  939. this.getCommodityCombinationList()
  940. setTimeout(() => {
  941. this.skeletonShow = false
  942. this.isRequest = true
  943. }, 1000)
  944. })
  945. .catch(error => {
  946. this.$util.msg(error.msg, 2000)
  947. })
  948. },
  949. handleShowProductType(flag = '') {
  950. // 根据商品详情可见度显示弹窗 flag 1.所有人可见 2.所有机构可见 3.仅会员机构可见 4.仅医美机构可见
  951. const flagMap = {
  952. '2': true,
  953. '3': true,
  954. '4': true
  955. }
  956. if (!this.hasLogin) {
  957. this.showModal = flagMap[flag]
  958. return
  959. }
  960. if (this.vipFlag === 1) {
  961. this.showModal = false
  962. return
  963. }
  964. if (flag === 3 && this.userIdentity === 4) {
  965. this.showModal = true
  966. return
  967. }
  968. if (flag === 4 && this.userIdentity === 4) {
  969. this.showModal = true
  970. return
  971. }
  972. if (flag === 4 && this.userIdentity === 2 && this.firstClubType !== 1) {
  973. this.showModal = true
  974. return
  975. }
  976. },
  977. hideMobel1() {
  978. this.modal1 = false
  979. this.$api.navigateBack(1)
  980. },
  981. adaptRichTextImg(product) {
  982. // 商品详情
  983. let defaulHtml = '<div style="text-align: center;color:#333333;">暂无内容</div>'
  984. let html = ''
  985. if (product.productDetailChose == 1) {
  986. // 同资质机构显示商品详情
  987. html = product.productDetail ? this.$api.adaptRichTextImg(product.productDetail.detailInfo) : defaulHtml
  988. } else {
  989. if (this.hasLogin && this.userIdentity != 4) {
  990. html = product.productDetail
  991. ? this.$api.adaptRichTextImg(product.productDetail.detailInfo)
  992. : defaulHtml
  993. } else {
  994. if (product.productDetail.commonDetailInfo) {
  995. html = product.productDetail
  996. ? this.$api.adaptRichTextImg(product.productDetail.commonDetailInfo)
  997. : defaulHtml
  998. } else {
  999. html = defaulHtml
  1000. }
  1001. }
  1002. }
  1003. return html
  1004. },
  1005. getCommodityCombinationList() {
  1006. // 初始化商品详情配套商品
  1007. this.ProductService.getCommodityCombinationList({
  1008. userId: this.userId,
  1009. productId: this.productId,
  1010. source: 2,
  1011. pageNum: 1,
  1012. pageSize: 4
  1013. })
  1014. .then(response => {
  1015. const data = response.data
  1016. this.supportingList = data.results
  1017. this.supportingNum = data.totalRecord
  1018. if (this.supportingList.length > 0) {
  1019. if (!this.hasLogin || this.userIdentity == 2 || this.userIdentity == 4) {
  1020. this.isShowSupportingList = true
  1021. }
  1022. }
  1023. })
  1024. .catch(error => {
  1025. console.log('获取组合商品列表失败')
  1026. })
  1027. },
  1028. queryProductDetilsCoupons() {
  1029. // 初始化商品详情优惠券信息
  1030. this.ProductService.QueryProductDetilsCoupons(this.couponParam)
  1031. .then(response => {
  1032. this.productCoupon = response.data.list
  1033. })
  1034. .catch(error => {
  1035. console.log('获取优惠券列表失败')
  1036. })
  1037. },
  1038. queryPopupCoupons() {
  1039. // 获取弹窗优惠券列表
  1040. this.ProductService.QueryProductDetilsCoupons(this.couponParam)
  1041. .then(response => {
  1042. let data = response.data
  1043. this.navbar[0].num = data.notCouponNum
  1044. this.navbar[1].num = data.couponNum
  1045. if (data.couponList && data.couponList.length > 0) {
  1046. this.productCouponList = data.couponList
  1047. this.isCouponEmpty = false
  1048. } else {
  1049. this.isCouponEmpty = true
  1050. }
  1051. })
  1052. .catch(error => {
  1053. console.log('获取优惠券列表失败')
  1054. })
  1055. },
  1056. ProductCartNumber() {
  1057. // 获取用户购物车储量
  1058. this.ProductService.ProductCartNumber({ userId: this.userId })
  1059. .then(response => {
  1060. this.bottomCartNumber = response.data
  1061. })
  1062. .catch(error => {
  1063. console.log('获取购物车数量失败')
  1064. })
  1065. },
  1066. receiveCoupon(coupon) {
  1067. // 点击优惠券领取按钮,友盟埋点收集领取优惠券
  1068. if (process.env.NODE_ENV != 'development') {
  1069. this.$uma.trackEvent('Um_Event_productCouponReceive', {
  1070. Um_Key_PageName: '商品详情',
  1071. Um_Key_EvenName: '领取优惠券',
  1072. Um_Key_CouponId: `${coupon.couponId}`
  1073. })
  1074. }
  1075. this.ProductService.ReceiveCoupon({
  1076. userId: this.couponParam.userId,
  1077. couponId: coupon.couponId,
  1078. source: 1
  1079. })
  1080. .then(response => {
  1081. this.$util.msg('领取成功', 1500, true, 'success')
  1082. setTimeout(() => {
  1083. this.currentTab = 1
  1084. this.couponParam.status = 2
  1085. this.queryPopupCoupons()
  1086. }, 1500)
  1087. })
  1088. .catch(error => {
  1089. this.$util.msg(error.msg, 2000)
  1090. })
  1091. },
  1092. toDeductCoupon(coupon) {
  1093. // 点击采美豆抵扣优惠券
  1094. if (process.env.NODE_ENV != 'development') {
  1095. this.$uma.trackEvent('Um_Event_userCouponCollectionBuy', {
  1096. Um_Key_PageName: '领券中心',
  1097. Um_Key_EvenName: '抵扣优惠券',
  1098. Um_Key_CouponId: `${coupon.couponId}`
  1099. })
  1100. }
  1101. if (this.hasLogin) {
  1102. if (this.userIdentity === 1 || this.userIdentity === 3) {
  1103. this.$util.msg('您的身份暂不支持领取优惠券', 2000)
  1104. return
  1105. }
  1106. this.WeChatPayCouponBeans(coupon)
  1107. } else {
  1108. this.$api.navigateTo('/pages/login/login')
  1109. }
  1110. },
  1111. WeChatPayCouponBeans(coupon) {
  1112. // 采美豆抵扣优惠券
  1113. this.PayService.WeChatPayCouponBeans({
  1114. source: 1, //领取渠道 1 小程序 2 网站
  1115. userId: this.couponParam.userId,
  1116. couponId: coupon.couponId
  1117. })
  1118. .then(response => {
  1119. this.$util.msg('抵扣成功', 1500)
  1120. setTimeout(() => {
  1121. this.currentTab = 1
  1122. this.couponParam.status = 2
  1123. this.queryPopupCoupons()
  1124. }, 1500)
  1125. })
  1126. .catch(error => {
  1127. this.$util.msg(error.msg, 2000)
  1128. })
  1129. },
  1130. toPayCoupon(coupon) {
  1131. // 点击购买优惠券,友盟埋点收集购买优惠券
  1132. if (process.env.NODE_ENV != 'development') {
  1133. this.$uma.trackEvent('Um_Event_productCouponBuy', {
  1134. Um_Key_PageName: '商品详情',
  1135. Um_Key_EvenName: '购买优惠券',
  1136. Um_Key_CouponId: `${coupon.couponId}`
  1137. })
  1138. }
  1139. this.createCouponRecord(coupon)
  1140. },
  1141. createCouponRecord(coupon) {
  1142. // 生成购买优惠券记录Id
  1143. this.PayService.WeChatCouponRecord({
  1144. userId: this.userId,
  1145. couponId: coupon.couponId
  1146. })
  1147. .then(response => {
  1148. this.MiniWxPayFor(coupon, response.data.couponRecordId)
  1149. })
  1150. .catch(error => {
  1151. if (error.code == -1) {
  1152. //个人机构不能购买
  1153. this.contentModalText = '该优惠券仅限医美机构购买,请升级为医美机构后再次购买。'
  1154. this.modal = true
  1155. } else if (error.code == -2) {
  1156. //会员机构不是医美机构不能购买
  1157. this.$util.msg('该优惠券仅限医美机构购买', 2000)
  1158. }
  1159. })
  1160. },
  1161. async MiniWxPayFor(coupon, couponRecordId) {
  1162. const wechatcode = await authorize.getCode('weixin')
  1163. const params = {
  1164. userId: this.userId,
  1165. couponId: coupon.couponId,
  1166. couponRecordId: couponRecordId,
  1167. payType: 'XCX',
  1168. code: wechatcode,
  1169. source: 1 //支付来源 1 小程序 2 WWW
  1170. }
  1171. this.weChatMiniCouponWxPay(
  1172. params,
  1173. 'Um_Event_productCouponPay',
  1174. '商品详情',
  1175. '线上支付优惠券',
  1176. coupon.couponId,
  1177. this.userId
  1178. )
  1179. },
  1180. hideMobel() {
  1181. this.modal = false
  1182. },
  1183. handleClick(e) {
  1184. //个人机构跳转升级页面
  1185. if (e.index == 1) {
  1186. this.$api.navigateTo('/pages/login/apply')
  1187. }
  1188. this.modal = false
  1189. },
  1190. swiperChange(e) {
  1191. //顶部商品图片切换
  1192. const index = e.detail.current
  1193. this.current = index
  1194. },
  1195. previewImg1(url) {
  1196. let mentuzArray = []
  1197. mentuzArray.push(url)
  1198. uni.previewImage({
  1199. urls: mentuzArray,
  1200. current: 0
  1201. })
  1202. },
  1203. previewImg(index) {
  1204. //顶部商品图片预览
  1205. isPreviewImg = true
  1206. let previewUrls = this.productImage
  1207. uni.previewImage({
  1208. current: index, //图片索引
  1209. urls: previewUrls, //必须是http图片,本地图片无效
  1210. longPressActions: ''
  1211. })
  1212. },
  1213. //商品详情&&供应商信息tab切换
  1214. tabClick(index) {
  1215. // 重新标记
  1216. this.getSectionProps()
  1217. this.tabCurrentIndex = index
  1218. this.tabSelectFlag = true
  1219. let timer = null
  1220. clearTimeout(timer)
  1221. // 点击tab 300ms才执行跳转,避免出错(来回跳动)
  1222. timer = setTimeout(() => {
  1223. this.tabClickAction(index)
  1224. }, 500)
  1225. },
  1226. // 跳转执行
  1227. tabClickAction(index) {
  1228. const that = this
  1229. if (index === 3) {
  1230. return uni.pageScrollTo({
  1231. duration: 300, //过渡时间必须为0,uniapp bug,否则运行到手机会报错
  1232. scrollTop: this.sectionPropsArr[0].scrollTop
  1233. })
  1234. }
  1235. uni.pageScrollTo({
  1236. duration: 300, //过渡时间必须为0,uniapp bug,否则运行到手机会报错
  1237. scrollTop: this.sectionPropsArr[index].scrollTop,
  1238. success() {
  1239. setTimeout(() => {
  1240. that.tabSelectFlag = false
  1241. }, 300)
  1242. }
  1243. })
  1244. },
  1245. handleContact(e) {
  1246. //跳转小程序客服
  1247. console.log(e.detail.path)
  1248. console.log(e.detail.query)
  1249. },
  1250. buyProductCart() {
  1251. //底部购物车按钮点击
  1252. if (this.hasLogin) {
  1253. // 友盟埋点商品详情购物车入口点击事件
  1254. if (process.env.NODE_ENV != 'development') {
  1255. this.$uma.trackEvent('Um_Event_ProductShoppingCart', {
  1256. Um_Key_PageName: '去购物车',
  1257. Um_Key_SourcePage: '商品详情购物车入口'
  1258. })
  1259. }
  1260. this.$api.navigateTo('/pages/goods/cart')
  1261. } else {
  1262. this.$api.navigateTo('/pages/login/login?type=1')
  1263. }
  1264. },
  1265. btnGetConfirm(type) {
  1266. //加入购物车&&立即购买点击
  1267. if (this.hasLogin) {
  1268. this.btnType = type
  1269. this.popupShow3 = true
  1270. this.unitPopupType = 1
  1271. } else {
  1272. this.$api.navigateTo('/pages/login/login?type=1')
  1273. }
  1274. },
  1275. getAddProductCart() {
  1276. //增加购物车成功和toast弹窗提示成功
  1277. this.ProductService.shoppingAddCart({
  1278. productId: this.productId,
  1279. userId: this.userId,
  1280. productCount: this.number,
  1281. source: 2
  1282. })
  1283. .then(response => {
  1284. this.specClass = 'hide'
  1285. this.$util.msg('加入购物车成功', 1500, true, 'success')
  1286. this.isAnimation = true
  1287. setTimeout(() => {
  1288. this.specClass = 'none'
  1289. }, 200)
  1290. setTimeout(() => {
  1291. this.isAnimation = false
  1292. }, 2000)
  1293. this.bottomCartNumber = response.data
  1294. })
  1295. .catch(error => {
  1296. console.log('error', error.msg)
  1297. })
  1298. },
  1299. setHeaderBtnPosi() {
  1300. // 获得胶囊按钮位置信息
  1301. let headerBtnPosi = uni.getMenuButtonBoundingClientRect()
  1302. return headerBtnPosi
  1303. },
  1304. setSysteminfo() {
  1305. let systeminfo
  1306. uni.getSystemInfo({
  1307. // 获取设备信息
  1308. success: res => {
  1309. systeminfo = res
  1310. }
  1311. })
  1312. return systeminfo
  1313. },
  1314. goIndex() {
  1315. //商城首页
  1316. uni.switchTab({
  1317. url: '/pages/tabBar/home/index'
  1318. })
  1319. },
  1320. goSupplier() {
  1321. //跳供应商资料页
  1322. if (!this.isShowCaimeiShop) {
  1323. this.$api.navigateTo('/pages/supplier/user/my-shop?shopId=' + this.shopId)
  1324. }
  1325. },
  1326. discard() {
  1327. //丢弃
  1328. },
  1329. onShare(res) {
  1330. //分享转发
  1331. if (res.from === 'button') {
  1332. // 来自页面内转发按钮
  1333. }
  1334. return {
  1335. title: `${this.product.name}`,
  1336. path: `pages/goods/product?type=share&id=${this.productId}`,
  1337. imageUrl: `${this.productImage[0]}`
  1338. }
  1339. },
  1340. handleCollection() {
  1341. // 收藏
  1342. if (this.hasLogin) {
  1343. this.ProductService.getProductUserLike({
  1344. userId: this.userId,
  1345. productId: this.product.productId
  1346. })
  1347. .then(response => {
  1348. this.collectionType = !this.collectionType
  1349. this.$util.msg(response.data, 1500, true, 'success')
  1350. })
  1351. .catch(error => {
  1352. this.$util.msg(error.msg, 2000)
  1353. })
  1354. } else {
  1355. this.$api.navigateTo('/pages/login/login')
  1356. }
  1357. },
  1358. showPopup(index) {
  1359. switch (index) {
  1360. case 0:
  1361. this.popupShow0 = true
  1362. break
  1363. case 1:
  1364. this.popupShow1 = true
  1365. break
  1366. case 2:
  1367. if (this.hasLogin) {
  1368. this.queryPopupCoupons()
  1369. this.popupShow2 = true
  1370. } else {
  1371. this.$api.navigateTo('/pages/login/login')
  1372. }
  1373. break
  1374. case 3:
  1375. this.popupShow3 = true
  1376. this.unitPopupType = 2
  1377. break
  1378. }
  1379. },
  1380. hidePopup(index) {
  1381. switch (index) {
  1382. case 0:
  1383. this.popupShow0 = false
  1384. break
  1385. case 1:
  1386. this.popupShow1 = false
  1387. break
  1388. case 2:
  1389. this.popupShow2 = false
  1390. break
  1391. case 3:
  1392. this.popupShow3 = false
  1393. break
  1394. }
  1395. },
  1396. couponChange(e) {
  1397. this.currentTab = e.index
  1398. switch (this.currentTab) {
  1399. case 0:
  1400. this.couponParam.status = 1
  1401. this.queryPopupCoupons()
  1402. break
  1403. case 1:
  1404. this.couponParam.status = 2
  1405. this.queryPopupCoupons()
  1406. break
  1407. }
  1408. },
  1409. handleSupporting() {
  1410. // 跳转组合商品页面
  1411. this.$api.navigateTo(`/pages/goods/goods-supporting?productId=${this.productId}`)
  1412. },
  1413. // 获取每个tab对应区域的区间
  1414. async getSectionProps() {
  1415. const sectionPropsArr = [],
  1416. scrollTopArray = [],
  1417. className = 'product-details'
  1418. // 获取相关节点元素信息
  1419. const productMain = await this.$util.boundingClientRect(this, '.container-product-main', false)
  1420. const productDetail = await this.$util.boundingClientRect(this, '.product-details', true)
  1421. const topBar = await this.$util.boundingClientRect(this, '#topBar', false)
  1422. /*
  1423. 说明:采用累加方式来计算每一个 prdocut-details 的 scrollTop 定位
  1424. scrollTop = 上一个的scrollTop + 上一个的高度
  1425. */
  1426. productDetail.forEach((item, index) => {
  1427. // 上一个 prdocut-details 的 scrollTop 值
  1428. const prev = sectionPropsArr[index - 1]
  1429. const prevScrollTop = prev ? prev.scrollTop : productMain.height
  1430. // 上一个 prdocut-details 的高度
  1431. const add = productDetail[index - 1]
  1432. // 第一个需要减去tabs的高度
  1433. const addHeight = index === 0 ? (add ? add.height : 0) - topBar.height : add ? add.height : 0
  1434. sectionPropsArr.push({
  1435. className: `${className}-${index}`,
  1436. scrollTop: prevScrollTop + addHeight
  1437. })
  1438. // - topBar.height
  1439. })
  1440. this.sectionPropsArr = sectionPropsArr
  1441. console.log('更新tab影响区域')
  1442. },
  1443. //当滑动时也能同步激活tab
  1444. activeTab: debounce(
  1445. (top, _this) => {
  1446. const { sectionPropsArr } = _this
  1447. if (sectionPropsArr.length > 0) {
  1448. sectionPropsArr.forEach((item, index) => {
  1449. // 当前位置为开始位置, 下个起始位置为结束位置
  1450. const openInterval = (index === 0 ? 0 : item.scrollTop) - 20 // 自定义偏移
  1451. const next = sectionPropsArr[index + 1]
  1452. const closedInterval = (next ? next.scrollTop : 10000000) - 20 // 自定义偏移
  1453. if (top >= openInterval && top < closedInterval) {
  1454. _this.tabCurrentIndex = index
  1455. }
  1456. })
  1457. }
  1458. },
  1459. 100,
  1460. true
  1461. ),
  1462. debounce(fn, delay) {
  1463. let timer = null //借助闭包
  1464. return function() {
  1465. if (timer) {
  1466. clearTimeout(timer)
  1467. }
  1468. timer = setTimeout(fn, delay) // 简化写法
  1469. }
  1470. },
  1471. clipboard(data) {
  1472. thorui.getClipboardData(data, res => {
  1473. if (res) {
  1474. this.$util.msg('复制成功', 2000, true, 'success')
  1475. } else {
  1476. this.$util.msg('复制失败', 2000, true, 'none')
  1477. }
  1478. })
  1479. },
  1480. getWinHeight() {
  1481. this.winHeight = wx.getSystemInfoSync().windowHeight
  1482. },
  1483. changePreViewImageStatus(falg) {
  1484. this.isPreviewImage = falg
  1485. }
  1486. },
  1487. onPageScroll(e) {
  1488. //实时获取到滚动的值
  1489. const { scrollTop } = e
  1490. this.debounce(this.getSectionProps(), 1000)
  1491. if (!this.tabSelectFlag) {
  1492. this.activeTab(scrollTop, this)
  1493. }
  1494. if (e.scrollTop > 60) {
  1495. this.headerColor = true
  1496. this.navbarFiexd = 'fixed'
  1497. this.isNavbarFiexd = true
  1498. this.nvabarData = {
  1499. showCapsule: 1,
  1500. title: '商品详情'
  1501. }
  1502. } else {
  1503. this.headerColor = false
  1504. this.isNavbarFiexd = false
  1505. this.navbarFiexd = 'none'
  1506. this.nvabarData = {
  1507. showCapsule: 1,
  1508. title: ''
  1509. }
  1510. }
  1511. if (e.scrollTop > 700) {
  1512. this.isScrollTop = true
  1513. } else {
  1514. this.isScrollTop = false
  1515. }
  1516. },
  1517. onShareAppMessage(res) {
  1518. //分享转发
  1519. if (res.from === 'button') {
  1520. // 来自页面内转发按钮
  1521. }
  1522. return {
  1523. title: `${this.product.name}`,
  1524. path: `pages/goods/product?type=share&id=${this.productId}`,
  1525. imageUrl: `${this.productImage[0]}`
  1526. }
  1527. },
  1528. onShow() {
  1529. wxLogin.wxLoginAuthorize()
  1530. // 是否开启图片预览 true 不刷新调用接口 false刷新调用接口
  1531. if (!this.isPreviewImage) {
  1532. this.initGetStotage()
  1533. }
  1534. this.isPreviewImage = false
  1535. }
  1536. }
  1537. </script>
  1538. <style lang="scss">
  1539. page {
  1540. background-color: #ffffff;
  1541. }
  1542. .banner-section {
  1543. width: 100%;
  1544. height: 750rpx;
  1545. position: relative;
  1546. .cm-product-tags {
  1547. position: absolute;
  1548. right: 30rpx;
  1549. top: 0;
  1550. z-index: 999;
  1551. }
  1552. .cm-product-type {
  1553. width: 64rpx;
  1554. height: 64rpx;
  1555. text-align: justify;
  1556. box-sizing: border-box;
  1557. padding: 10rpx;
  1558. border-radius: 0 0 8rpx 8rpx;
  1559. background-color: #33ccbf;
  1560. font-size: $font-size-22;
  1561. color: #ffffff;
  1562. line-height: 25rpx;
  1563. position: absolute;
  1564. left: 30rpx;
  1565. top: 0;
  1566. z-index: 999;
  1567. }
  1568. .cm-product-cover {
  1569. width: 120rpx;
  1570. height: 77rpx;
  1571. line-height: 57rpx;
  1572. font-size: 24rpx;
  1573. color: #fff;
  1574. text-align: center;
  1575. background: url(https://static.caimei365.com/app/img/icon2/cm_cover_bg_app.png) no-repeat center;
  1576. background-size: 120rpx;
  1577. float: left;
  1578. position: absolute;
  1579. right: 30rpx;
  1580. top: 0;
  1581. z-index: 999;
  1582. }
  1583. }
  1584. .banner {
  1585. width: 100%;
  1586. height: 750rpx;
  1587. .product-img {
  1588. width: 750rpx;
  1589. }
  1590. image {
  1591. width: 100%;
  1592. height: 100%;
  1593. }
  1594. .banner-item {
  1595. position: relative;
  1596. }
  1597. }
  1598. .swiper__dots-box {
  1599. position: absolute;
  1600. color: #fff;
  1601. bottom: 30rpx;
  1602. right: 0;
  1603. }
  1604. .product-wrap {
  1605. width: 100%;
  1606. height: auto;
  1607. padding: 24rpx 0 0 0;
  1608. background-color: #ffffff;
  1609. border-bottom: 20rpx solid #f7f7f7;
  1610. .productRemarks {
  1611. height: 48rpx;
  1612. width: 100%;
  1613. float: left;
  1614. line-height: 48rpx;
  1615. font-size: 24rpx;
  1616. color: #999999;
  1617. text-align: left;
  1618. }
  1619. .wrap-top {
  1620. width: 702rpx;
  1621. padding: 0 24rpx;
  1622. height: auto;
  1623. float: left;
  1624. padding-bottom: 20rpx;
  1625. border-bottom: 1px solid #f8f8f8;
  1626. &.none {
  1627. .p-title {
  1628. color: #999999;
  1629. }
  1630. }
  1631. .p-title {
  1632. width: 100%;
  1633. height: auto;
  1634. float: left;
  1635. position: relative;
  1636. .p-title-name {
  1637. width: 602rpx;
  1638. height: auto;
  1639. float: left;
  1640. line-height: 48rpx;
  1641. font-size: $font-size-28;
  1642. color: $text-color;
  1643. -o-text-overflow: ellipsis;
  1644. text-overflow: ellipsis;
  1645. display: -webkit-box;
  1646. word-break: break-all;
  1647. -webkit-box-orient: vertical;
  1648. -webkit-line-clamp: 2;
  1649. overflow: hidden;
  1650. &.indent {
  1651. text-indent: 95rpx;
  1652. }
  1653. }
  1654. .mclap-tag {
  1655. display: block;
  1656. width: 84rpx;
  1657. height: 32rpx;
  1658. background-image: linear-gradient(270deg, #f9c023 0%, #f83600 100%);
  1659. border-radius: 4rpx 48rpx 4px 4px;
  1660. line-height: 32rpx;
  1661. font-size: $font-size-22;
  1662. color: #ffffff;
  1663. text-align: center;
  1664. position: absolute;
  1665. left: 0;
  1666. top: 6rpx;
  1667. }
  1668. .p-title-share {
  1669. width: 96rpx;
  1670. height: 96rpx;
  1671. position: absolute;
  1672. right: 0;
  1673. text-align: center;
  1674. color: #999999;
  1675. font-size: $font-size-24;
  1676. box-sizing: border-box;
  1677. display: block;
  1678. background: transparent;
  1679. border-radius: 0;
  1680. border: 0;
  1681. margin: 0;
  1682. padding: 8rpx 0;
  1683. z-index: 20;
  1684. .icon-fenxiang1 {
  1685. font-size: $font-size-34;
  1686. }
  1687. }
  1688. .tui-share-btn::after {
  1689. border: 0;
  1690. }
  1691. }
  1692. .wrap-main-text {
  1693. line-height: 56rpx;
  1694. color: #ff2a2a;
  1695. font-size: $font-size-26;
  1696. display: block;
  1697. float: left;
  1698. font-weight: normal;
  1699. }
  1700. .wrap-main-none {
  1701. display: block;
  1702. width: 256rpx;
  1703. height: 44rpx;
  1704. padding-left: 20rpx;
  1705. border-radius: 11rpx;
  1706. background: $btn-confirm;
  1707. float: right;
  1708. line-height: 44rpx;
  1709. color: #ffffff;
  1710. text-align: center;
  1711. font-size: $font-size-24;
  1712. }
  1713. .p-price-none {
  1714. height: 44rpx;
  1715. line-height: 44rpx;
  1716. float: left;
  1717. font-size: $font-size-24;
  1718. color: #666;
  1719. text-decoration: line-through;
  1720. margin-left: 8rpx;
  1721. }
  1722. .p-minBuy {
  1723. height: 44rpx;
  1724. line-height: 44rpx;
  1725. float: right;
  1726. padding: 0 18rpx;
  1727. border-radius: 22rpx;
  1728. background-color: #f7f7f7;
  1729. color: #7f7f7f;
  1730. font-size: 24rpx;
  1731. text-align: center;
  1732. .min-text {
  1733. margin: 0 6rpx;
  1734. }
  1735. }
  1736. .p-login {
  1737. height: 56rpx;
  1738. line-height: 56rpx;
  1739. color: $color-system;
  1740. font-size: $font-size-24;
  1741. &.grade {
  1742. .price-left {
  1743. float: left;
  1744. .none {
  1745. display: block;
  1746. font-size: $font-size-20;
  1747. line-height: 48rpx;
  1748. color: #4a4b54;
  1749. float: left;
  1750. font-weight: bold;
  1751. margin-left: 5rpx;
  1752. text {
  1753. letter-spacing: 4rpx;
  1754. font-size: $font-size-32;
  1755. }
  1756. }
  1757. }
  1758. }
  1759. .p-no {
  1760. float: left;
  1761. margin-right: 5rpx;
  1762. font-size: $font-size-28;
  1763. color: $text-color;
  1764. }
  1765. .p-login-btn {
  1766. display: block;
  1767. height: 44rpx;
  1768. padding: 0 10rpx 0 20rpx;
  1769. border-radius: 11rpx;
  1770. background: $btn-confirm;
  1771. float: right;
  1772. line-height: 44rpx;
  1773. color: #ffffff;
  1774. text-align: center;
  1775. font-size: $font-size-24;
  1776. }
  1777. }
  1778. }
  1779. .wrap-label {
  1780. float: left;
  1781. width: 85%;
  1782. box-sizing: border-box;
  1783. .label-a {
  1784. padding: 0 18rpx;
  1785. line-height: 32rpx;
  1786. font-size: $font-size-20;
  1787. color: $color-system;
  1788. text-align: center;
  1789. border-radius: 6rpx;
  1790. background: #ffe6dc;
  1791. margin: 0 20rpx 15rpx 0;
  1792. display: inline-block;
  1793. }
  1794. }
  1795. .wrap-top-price {
  1796. float: left;
  1797. width: 100%;
  1798. box-sizing: border-box;
  1799. .wrap-main-item {
  1800. width: 100%;
  1801. height: 56rpx;
  1802. .p-price {
  1803. height: 56rpx;
  1804. line-height: 56rpx;
  1805. float: left;
  1806. color: #ff2a2a;
  1807. font-weight: bold;
  1808. &.none {
  1809. text-decoration: line-through;
  1810. color: #999999;
  1811. font-weight: normal;
  1812. }
  1813. .txt {
  1814. margin: 0 2rpx;
  1815. }
  1816. .txt.sm {
  1817. font-size: $font-size-26;
  1818. }
  1819. .txt.big {
  1820. font-size: $font-size-34;
  1821. }
  1822. }
  1823. }
  1824. .floor-item-act {
  1825. height: 56rpx;
  1826. text-align: center;
  1827. box-sizing: border-box;
  1828. float: left;
  1829. padding: 10rpx 0;
  1830. margin-left: 10rpx;
  1831. }
  1832. .floor-item-btn {
  1833. float: right;
  1834. height: 40rpx;
  1835. margin-top: 8rpx;
  1836. margin-left: 10rpx;
  1837. .btn {
  1838. line-height: 40rpx;
  1839. padding: 0 20rpx;
  1840. height: 40rpx;
  1841. background: $btn-confirm;
  1842. color: #ffffff;
  1843. font-size: $font-size-20;
  1844. border-radius: 4rpx;
  1845. }
  1846. }
  1847. }
  1848. .wrap-info {
  1849. float: left;
  1850. width: 702rpx;
  1851. padding: 24rpx 24rpx 0 24rpx;
  1852. border-bottom: 1px solid #f8f8f8;
  1853. .info-viewT {
  1854. width: 100%;
  1855. min-height: 40rpx;
  1856. font-size: $font-size-28;
  1857. color: $text-color;
  1858. line-height: 40rpx;
  1859. text-align: left;
  1860. &.none {
  1861. color: #999999;
  1862. }
  1863. .info-viewL {
  1864. min-width: 350rpx;
  1865. float: left;
  1866. margin-bottom: 24rpx;
  1867. }
  1868. .info-viewR {
  1869. min-width: 352rpx;
  1870. float: left;
  1871. margin-bottom: 24rpx;
  1872. }
  1873. }
  1874. .info-viewB {
  1875. width: 100%;
  1876. height: auto;
  1877. }
  1878. .info-f {
  1879. width: 50%;
  1880. float: left;
  1881. font-size: $font-size-28;
  1882. color: $text-color;
  1883. line-height: 40rpx;
  1884. margin-bottom: 24rpx;
  1885. text-align: left;
  1886. }
  1887. }
  1888. }
  1889. .product-seve {
  1890. width: 100%;
  1891. height: 60rpx;
  1892. background-color: #ffffff;
  1893. position: relative;
  1894. display: flex;
  1895. line-height: 60rpx;
  1896. .label {
  1897. font-size: $font-size-28;
  1898. color: #333333;
  1899. }
  1900. .iconfont {
  1901. color: #fea785;
  1902. margin-right: 20rpx;
  1903. font-size: $font-size-22;
  1904. }
  1905. .text {
  1906. font-size: $font-size-22;
  1907. color: #fea785;
  1908. margin-left: 10rpx;
  1909. }
  1910. }
  1911. .product-item-none {
  1912. min-height: 348rpx;
  1913. display: flex;
  1914. flex-direction: column;
  1915. align-items: center;
  1916. border-bottom: 20rpx solid #f7f7f7;
  1917. box-sizing: border-box;
  1918. padding: 40rpx 0;
  1919. .none-image {
  1920. width: 284rpx;
  1921. height: 225rpx;
  1922. }
  1923. .none-text {
  1924. text-align: center;
  1925. font-size: $font-size-28;
  1926. color: #fea785;
  1927. line-height: 40rpx;
  1928. }
  1929. }
  1930. .product-supporting {
  1931. width: 100%;
  1932. height: 274rpx;
  1933. box-sizing: border-box;
  1934. padding: 30rpx 24rpx;
  1935. background-color: #ffffff;
  1936. border-bottom: 20rpx solid #f7f7f7;
  1937. .product-supporting-title {
  1938. width: 100%;
  1939. height: 40rpx;
  1940. text-align: left;
  1941. line-height: 40rpx;
  1942. font-size: $font-size-28;
  1943. color: #333333;
  1944. }
  1945. .product-supporting-list {
  1946. width: 100%;
  1947. height: 154rpx;
  1948. box-sizing: border-box;
  1949. padding: 13rpx 0;
  1950. position: relative;
  1951. .icon-xiayibu {
  1952. line-height: 154rpx;
  1953. display: inline-block;
  1954. position: absolute;
  1955. width: 80rpx;
  1956. top: 0;
  1957. right: 0;
  1958. color: #b2b2b2;
  1959. text-align: right;
  1960. }
  1961. .list {
  1962. width: 128rpx;
  1963. height: 128rpx;
  1964. margin-right: 24rpx;
  1965. float: left;
  1966. border: 1px solid #e1e1e1;
  1967. border-radius: 8rpx;
  1968. .list-image {
  1969. width: 100%;
  1970. height: 100%;
  1971. display: block;
  1972. border-radius: 8rpx;
  1973. }
  1974. }
  1975. }
  1976. }
  1977. .product-parameter {
  1978. width: 702rpx;
  1979. height: 90rpx;
  1980. padding: 0 24rpx;
  1981. background-color: #ffffff;
  1982. position: relative;
  1983. border-bottom: 20rpx solid #f7f7f7;
  1984. &.coupon {
  1985. .title {
  1986. color: #f94b4b;
  1987. }
  1988. .icon-xiayibu {
  1989. color: #f94b4b;
  1990. }
  1991. .coupon {
  1992. float: right;
  1993. box-sizing: border-box;
  1994. padding: 29rpx 0;
  1995. padding-right: 35rpx;
  1996. .tags {
  1997. height: 32rpx;
  1998. box-sizing: border-box;
  1999. border-radius: 8rpx;
  2000. background-color: #fff1eb;
  2001. line-height: 28rpx;
  2002. color: #f94b4b;
  2003. text-align: center;
  2004. display: inline-block;
  2005. padding: 0 10rpx;
  2006. font-size: $font-size-20;
  2007. border: 1px solid #f94b4b;
  2008. float: right;
  2009. margin: 0 6rpx;
  2010. }
  2011. }
  2012. }
  2013. .title {
  2014. line-height: 90rpx;
  2015. display: inline-block;
  2016. float: left;
  2017. font-size: $font-size-28;
  2018. color: #666666;
  2019. }
  2020. .name {
  2021. line-height: 90rpx;
  2022. display: inline-block;
  2023. float: left;
  2024. font-size: $font-size-28;
  2025. color: $text-color;
  2026. padding-right: 48rpx;
  2027. overflow: hidden;
  2028. text-overflow: ellipsis;
  2029. white-space: nowrap;
  2030. text-align: right;
  2031. }
  2032. .icon-xiayibu {
  2033. line-height: 90rpx;
  2034. display: inline-block;
  2035. position: absolute;
  2036. width: 48rpx;
  2037. top: 0;
  2038. right: 0;
  2039. color: #b2b2b2;
  2040. }
  2041. }
  2042. .product-supplier {
  2043. width: 100%;
  2044. height: 174rpx;
  2045. padding: 30rpx 24rpx;
  2046. box-sizing: border-box;
  2047. background-color: #ffffff;
  2048. position: relative;
  2049. box-sizing: border-box;
  2050. border-bottom: 20rpx solid #f7f7f7;
  2051. .logo {
  2052. width: 128rpx;
  2053. height: 92rpx;
  2054. float: left;
  2055. border: 1px solid #efefef;
  2056. border-radius: 6rpx;
  2057. image {
  2058. width: 100%;
  2059. height: 100%;
  2060. display: block;
  2061. border-radius: 6rpx;
  2062. }
  2063. }
  2064. .main {
  2065. width: 470rpx;
  2066. height: 92rpx;
  2067. float: left;
  2068. margin-left: 20rpx;
  2069. .name {
  2070. width: 100%;
  2071. line-height: 46rpx;
  2072. float: left;
  2073. font-size: $font-size-28;
  2074. color: $text-color;
  2075. float: right;
  2076. overflow: hidden;
  2077. text-overflow: ellipsis;
  2078. white-space: nowrap;
  2079. text-align: left;
  2080. }
  2081. .massgs {
  2082. width: 100%;
  2083. line-height: 46rpx;
  2084. float: left;
  2085. font-size: $font-size-24;
  2086. color: #999999;
  2087. .label {
  2088. float: left;
  2089. }
  2090. .p-stars {
  2091. float: left;
  2092. margin-left: 20rpx;
  2093. }
  2094. .acount {
  2095. float: right;
  2096. text {
  2097. color: $color-system;
  2098. }
  2099. }
  2100. }
  2101. }
  2102. .icon-xiayibu {
  2103. line-height: 154rpx;
  2104. display: inline-block;
  2105. position: absolute;
  2106. width: 48rpx;
  2107. top: 0;
  2108. right: 0;
  2109. color: #b2b2b2;
  2110. }
  2111. }
  2112. .product-details {
  2113. width: 100%;
  2114. background: #ffffff;
  2115. border-bottom: 20rpx solid #f7f7f7;
  2116. &.recommend {
  2117. background-color: #f7f7f7;
  2118. border-bottom: none;
  2119. .title {
  2120. .title-tab {
  2121. background-color: #f7f7f7;
  2122. color: $text-color;
  2123. }
  2124. }
  2125. }
  2126. .product-details-image {
  2127. width: 100%;
  2128. min-height: 856rpx;
  2129. box-sizing: border-box;
  2130. padding: 0 24rpx;
  2131. .product-details-table {
  2132. width: 100%;
  2133. min-height: 160rpx;
  2134. border: 1px solid #e1e1e1;
  2135. border-radius: 10rpx;
  2136. .ladder-tr {
  2137. display: flex;
  2138. width: 100%;
  2139. justify-content: center;
  2140. height: 80rpx;
  2141. align-items: center;
  2142. border-bottom: 1px solid #e1e1e1;
  2143. &:last-child {
  2144. border-bottom: none;
  2145. }
  2146. .ladder-item-td {
  2147. height: 80rpx;
  2148. justify-content: center;
  2149. text-align: center;
  2150. box-sizing: border-box;
  2151. padding: 10rpx;
  2152. float: left;
  2153. .te-text {
  2154. line-height: 28rpx;
  2155. font-size: $font-size-24;
  2156. text-overflow: ellipsis;
  2157. display: -webkit-box;
  2158. word-break: break-all;
  2159. -webkit-box-orient: vertical;
  2160. -webkit-line-clamp: 2;
  2161. overflow: hidden;
  2162. color: #999999;
  2163. &.last {
  2164. width: 60%;
  2165. float: left;
  2166. }
  2167. }
  2168. .te-copy {
  2169. width: 40%;
  2170. float: right;
  2171. font-size: $font-size-24;
  2172. padding-top: 10rpx;
  2173. .clipboard {
  2174. width: 84rpx;
  2175. height: 36rpx;
  2176. background: #4688fa;
  2177. text-align: center;
  2178. font-size: $font-size-24;
  2179. color: #ffffff;
  2180. border-radius: 18rpx;
  2181. line-height: 36rpx;
  2182. display: inline-block;
  2183. }
  2184. }
  2185. &.th {
  2186. display: flex;
  2187. height: 80rpx;
  2188. align-items: center;
  2189. line-height: 80rpx;
  2190. font-size: 26rpx;
  2191. color: #666;
  2192. }
  2193. &:nth-child(1) {
  2194. width: 25%;
  2195. border-right: 1px solid #e1e1e1;
  2196. }
  2197. &:nth-child(2) {
  2198. width: 35%;
  2199. border-right: 1px solid #e1e1e1;
  2200. }
  2201. &:nth-child(3) {
  2202. width: 40%;
  2203. }
  2204. }
  2205. }
  2206. }
  2207. .qualificationImg-image {
  2208. width: 100%;
  2209. height: 856rpx;
  2210. display: block;
  2211. }
  2212. }
  2213. .product-rich-text-none {
  2214. box-sizing: border-box;
  2215. padding: 0 24rpx;
  2216. text-align: left;
  2217. font-size: 24rpx;
  2218. color: #999999;
  2219. line-height: 60rpx;
  2220. &.bold {
  2221. font-weight: bold;
  2222. color: #333333;
  2223. }
  2224. }
  2225. .content-none {
  2226. width: 100%;
  2227. height: 80rpx;
  2228. line-height: 80rpx;
  2229. text-align: left;
  2230. font-size: $font-size-26;
  2231. color: #999999;
  2232. box-sizing: border-box;
  2233. padding: 0 24rpx;
  2234. }
  2235. .title {
  2236. width: 100%;
  2237. box-sizing: border-box;
  2238. padding: 0 24rpx;
  2239. .title-tab {
  2240. width: 100%;
  2241. height: 100rpx;
  2242. background: #fff;
  2243. z-index: 10;
  2244. font-size: $font-size-30;
  2245. text-align: left;
  2246. color: $text-color;
  2247. line-height: 100rpx;
  2248. font-weight: 600;
  2249. }
  2250. .title-msg {
  2251. width: 100%;
  2252. height: 236rpx;
  2253. padding: 18rpx;
  2254. background-color: rgba(225, 86, 22, 0.1);
  2255. color: $color-system;
  2256. box-sizing: border-box;
  2257. margin-bottom: 30rpx;
  2258. .tit {
  2259. line-height: 46rpx;
  2260. font-size: $font-size-24;
  2261. text-align: left;
  2262. }
  2263. .txt {
  2264. line-height: 38rpx;
  2265. font-size: $font-size-20;
  2266. text-align: justify;
  2267. }
  2268. }
  2269. }
  2270. .content {
  2271. width: 100%;
  2272. background-color: #ffffff;
  2273. }
  2274. }
  2275. .isLower {
  2276. width: 100%;
  2277. height: 116rpx;
  2278. line-height: 116rpx;
  2279. text-align: center;
  2280. color: #000000;
  2281. font-size: $font-size-32;
  2282. font-weight: bold;
  2283. }
  2284. .bottom-btn {
  2285. width: 100%;
  2286. height: 100rpx;
  2287. position: fixed;
  2288. bottom: 0;
  2289. left: 0;
  2290. background: #ffffff;
  2291. z-index: 99;
  2292. .bottom-le {
  2293. width: 300rpx;
  2294. height: 100rpx;
  2295. padding: 10rpx 20rpx 10rpx 0;
  2296. float: left;
  2297. box-sizing: border-box;
  2298. .item-bt {
  2299. width: 80rpx;
  2300. height: 100%;
  2301. margin-right: 15rpx;
  2302. display: flex;
  2303. float: left;
  2304. flex-direction: column;
  2305. align-items: center;
  2306. justify-content: center;
  2307. font-size: $font-size-22;
  2308. color: $text-color;
  2309. line-height: 34rpx;
  2310. position: relative;
  2311. .animation-num {
  2312. font-size: $font-size-32;
  2313. color: #ff2a2a;
  2314. position: absolute;
  2315. top: -12rpx;
  2316. right: 4rpx;
  2317. font-weight: bold;
  2318. }
  2319. .animation {
  2320. animation: showAmnation 2.2s ease-in-out both;
  2321. }
  2322. .restion {
  2323. animation: hideAmnation 1s ease-in-out both;
  2324. }
  2325. .icon-num {
  2326. position: absolute;
  2327. right: -12rpx;
  2328. top: -5rpx;
  2329. }
  2330. .icon-num.goleft {
  2331. right: 2rpx;
  2332. }
  2333. &:last-child {
  2334. margin-right: 0;
  2335. }
  2336. image {
  2337. width: 44rpx;
  2338. height: 44rpx;
  2339. }
  2340. button.contact-btn {
  2341. width: 100%;
  2342. height: 100%;
  2343. margin: 0;
  2344. padding: 0;
  2345. display: flex;
  2346. flex-direction: column;
  2347. align-items: center;
  2348. justify-content: center;
  2349. box-sizing: border-box;
  2350. font-size: $font-size-24;
  2351. text-align: center;
  2352. text-decoration: none;
  2353. line-height: 34rpx;
  2354. border-radius: 0;
  2355. -webkit-tap-highlight-color: transparent;
  2356. overflow: hidden;
  2357. color: $text-color;
  2358. background-color: #ffffff;
  2359. }
  2360. }
  2361. }
  2362. .bottom-ri {
  2363. width: 450rpx;
  2364. height: 100%;
  2365. float: right;
  2366. display: flex;
  2367. box-sizing: border-box;
  2368. padding: 13rpx 20rpx 13rpx 0;
  2369. .btn {
  2370. flex: 1;
  2371. width: 200rpx;
  2372. line-height: 80rpx;
  2373. text-align: center;
  2374. font-size: $font-size-24;
  2375. color: #ffffff;
  2376. }
  2377. .btn-cart {
  2378. background-color: #ffe6dc;
  2379. color: $color-system;
  2380. border-radius: 42rpx 0 0 42rpx;
  2381. }
  2382. .btn-cart.disabled {
  2383. background-color: #e1e1e1;
  2384. color: #ffffff;
  2385. }
  2386. .btn-bay {
  2387. background: linear-gradient(to right, #f28f31 0%, #e15616 100%);
  2388. border-radius: 0 42rpx 42rpx 0;
  2389. }
  2390. .btn-bay.disabled {
  2391. background: linear-gradient(135deg, rgba(242, 143, 49, 0.5) 0%, rgba(225, 86, 22, 0.5) 100%);
  2392. }
  2393. }
  2394. }
  2395. .uni-badge--small {
  2396. -webkit-transform: scale(0.8);
  2397. -ms-transform: scale(0.8);
  2398. transform: scale(0.8);
  2399. -webkit-transform-origin: center center;
  2400. -ms-transform-origin: center center;
  2401. transform-origin: center center;
  2402. }
  2403. .uni-badge {
  2404. font-family: 'Helvetica Neue', Helvetica, sans-serif;
  2405. -webkit-box-sizing: border-box;
  2406. box-sizing: border-box;
  2407. font-size: 12px;
  2408. line-height: 1;
  2409. display: inline-block;
  2410. padding: 3px 6px;
  2411. color: #333;
  2412. border-radius: 100px;
  2413. background-color: #f1f1f1;
  2414. }
  2415. .uni-badge-error {
  2416. color: #fff;
  2417. background-color: #dd524d;
  2418. }
  2419. .product-topnav {
  2420. width: 100%;
  2421. height: 174rpx;
  2422. box-sizing: border-box;
  2423. background: #ffffff;
  2424. z-index: 990;
  2425. position: fixed;
  2426. opacity: 1;
  2427. left: 0;
  2428. &.fixed {
  2429. animation: showFixedColor 0.1s ease-in-out both;
  2430. }
  2431. &.none {
  2432. animation: hideFixedColor 0.1s ease-in-out both;
  2433. }
  2434. .navbar {
  2435. width: 100%;
  2436. height: 60rpx;
  2437. box-sizing: border-box;
  2438. padding: 0 24rpx;
  2439. display: flex;
  2440. .nav-item {
  2441. display: flex;
  2442. flex: 1;
  2443. justify-content: center;
  2444. align-items: center;
  2445. height: 60rpx;
  2446. font-size: $font-size-28;
  2447. color: $text-color;
  2448. position: relative;
  2449. float: left;
  2450. position: relative;
  2451. .line {
  2452. width: 60rpx;
  2453. height: 2px;
  2454. border-radius: 1px;
  2455. background: #ffffff;
  2456. position: absolute;
  2457. bottom: 0;
  2458. left: 50%;
  2459. margin-left: -30rpx;
  2460. }
  2461. &.current {
  2462. color: $color-system;
  2463. .line {
  2464. background: $color-system;
  2465. }
  2466. }
  2467. }
  2468. }
  2469. .search-input {
  2470. width: 100%;
  2471. height: 114rpx;
  2472. padding: 24rpx;
  2473. box-sizing: border-box;
  2474. .gosearch-btn {
  2475. width: 100%;
  2476. height: 100%;
  2477. border-radius: 40rpx;
  2478. margin: 0 auto;
  2479. font-size: 26rpx;
  2480. line-height: 66rpx;
  2481. color: #b2b2b2;
  2482. position: relative;
  2483. box-sizing: border-box;
  2484. padding-left: 66rpx;
  2485. &.fixed {
  2486. background: rgba(70, 70, 70, 0.1);
  2487. }
  2488. &.none {
  2489. background: rgba(70, 70, 70, 0.1);
  2490. }
  2491. .search-icon {
  2492. width: 66rpx;
  2493. height: 66rpx;
  2494. position: absolute;
  2495. left: 0;
  2496. top: 2rpx;
  2497. text-align: center;
  2498. line-height: 66rpx;
  2499. .icon-iconfonticonfontsousuo1 {
  2500. margin: 0 6rpx;
  2501. font-size: $font-size-34;
  2502. color: #b2b2b2;
  2503. z-index: 10;
  2504. }
  2505. }
  2506. .search-text {
  2507. font-size: $font-size-24;
  2508. line-height: 66rpx;
  2509. color: #b2b2b2;
  2510. }
  2511. }
  2512. }
  2513. }
  2514. @keyframes showFixedColor {
  2515. 0% {
  2516. background: rgba(255, 255, 255, 0);
  2517. }
  2518. 50% {
  2519. background: rgba(255, 255, 255, 0.5);
  2520. }
  2521. 100% {
  2522. background: rgba(255, 255, 255, 1);
  2523. }
  2524. }
  2525. @keyframes hideFixedColor {
  2526. 0% {
  2527. background: rgba(255, 255, 255, 1);
  2528. }
  2529. 50% {
  2530. background: rgba(255, 255, 255, 0.5);
  2531. }
  2532. 100% {
  2533. background: rgba(255, 255, 255, 0);
  2534. }
  2535. }
  2536. /* 加入购物模态层*/
  2537. @keyframes showPopup {
  2538. 0% {
  2539. opacity: 0;
  2540. }
  2541. 100% {
  2542. opacity: 1;
  2543. }
  2544. }
  2545. @keyframes hidePopup {
  2546. 0% {
  2547. opacity: 1;
  2548. }
  2549. 100% {
  2550. opacity: 0;
  2551. }
  2552. }
  2553. @keyframes showLayer {
  2554. 0% {
  2555. transform: translateY(0);
  2556. }
  2557. 100% {
  2558. transform: translateY(-100%);
  2559. }
  2560. }
  2561. @keyframes hideLayer {
  2562. 0% {
  2563. transform: translateY(-100%);
  2564. }
  2565. 100% {
  2566. transform: translateY(0);
  2567. }
  2568. }
  2569. @keyframes showAmnation {
  2570. 0% {
  2571. top: -12rpx;
  2572. opacity: 0;
  2573. }
  2574. 50% {
  2575. top: -60rpx;
  2576. opacity: 1;
  2577. }
  2578. 100% {
  2579. top: -100rpx;
  2580. opacity: 0;
  2581. }
  2582. }
  2583. @keyframes hideAmnation {
  2584. 0% {
  2585. top: -100rpx;
  2586. opacity: 0;
  2587. }
  2588. 100% {
  2589. top: -12rpx;
  2590. opacity: 0;
  2591. }
  2592. }
  2593. .tui-popup-box {
  2594. position: relative;
  2595. box-sizing: border-box;
  2596. min-height: 220rpx;
  2597. padding: 40rpx 24rpx 0 24rpx;
  2598. .tui-popup-close {
  2599. width: 90rpx;
  2600. height: 90rpx;
  2601. position: absolute;
  2602. right: 0;
  2603. top: 24rpx;
  2604. line-height: 90rpx;
  2605. text-align: center;
  2606. color: #b2b2b2;
  2607. .icon-iconfontguanbi {
  2608. font-size: $font-size-40;
  2609. }
  2610. }
  2611. .title {
  2612. font-size: $font-size-34;
  2613. color: $text-color;
  2614. line-height: 88rpx;
  2615. text-align: center;
  2616. float: left;
  2617. width: 100%;
  2618. height: 88rpx;
  2619. font-weight: bold;
  2620. }
  2621. .tui-popup-main {
  2622. width: 100%;
  2623. float: left;
  2624. &.coupon {
  2625. padding-bottom: 40rpx;
  2626. .coupon-empty {
  2627. width: 100%;
  2628. height: 600rpx;
  2629. display: flex;
  2630. align-items: center;
  2631. justify-content: center;
  2632. flex-direction: column;
  2633. position: fixed;
  2634. background: $bg-color;
  2635. .empty-container-image {
  2636. width: 150rpx;
  2637. height: 150rpx;
  2638. margin-bottom: 0;
  2639. margin-top: 0;
  2640. }
  2641. .error-text {
  2642. font-size: $font-size-28;
  2643. color: #999999;
  2644. line-height: 88rpx;
  2645. }
  2646. }
  2647. }
  2648. .tui-popup-scroll {
  2649. width: 100%;
  2650. height: 600rpx;
  2651. .coupon-list {
  2652. width: 100%;
  2653. height: 200rpx;
  2654. margin-top: 24rpx;
  2655. box-sizing: border-box;
  2656. background: url(https://static.caimei365.com/app/img/icon/icon-coupon-uesb@2x.png);
  2657. background-size: cover;
  2658. &:last-child {
  2659. margin-bottom: 24rpx;
  2660. }
  2661. .list-cell-le {
  2662. width: 224rpx;
  2663. height: 100%;
  2664. box-sizing: border-box;
  2665. padding: 37rpx 0;
  2666. float: left;
  2667. .coupon-maxMoney {
  2668. width: 100%;
  2669. height: 78rpx;
  2670. line-height: 78rpx;
  2671. font-size: 56rpx;
  2672. color: #ffffff;
  2673. text-align: center;
  2674. .small {
  2675. font-size: $font-size-24;
  2676. }
  2677. }
  2678. .coupon-minMoney {
  2679. width: 100%;
  2680. height: 33rpx;
  2681. line-height: 33rpx;
  2682. font-size: $font-size-24;
  2683. color: #ffffff;
  2684. text-align: center;
  2685. }
  2686. }
  2687. .list-cell-ri {
  2688. width: 478rpx;
  2689. height: 100%;
  2690. box-sizing: border-box;
  2691. padding: 20rpx 24rpx 0 24rpx;
  2692. float: right;
  2693. .list-cell-top {
  2694. width: 100%;
  2695. height: 121rpx;
  2696. float: left;
  2697. border-bottom: 1px solid #e1e1e1;
  2698. .list-cell-type {
  2699. width: 286rpx;
  2700. height: 100%;
  2701. float: left;
  2702. .list-cell-tags {
  2703. width: 100%;
  2704. height: 32rpx;
  2705. margin-bottom: 7rpx;
  2706. .tags {
  2707. display: inline-block;
  2708. padding: 0 10rpx;
  2709. height: 32rpx;
  2710. line-height: 32rpx;
  2711. background-color: #ffdcce;
  2712. color: #f94b4b;
  2713. font-size: $font-size-20;
  2714. border-radius: 8rpx;
  2715. text-align: center;
  2716. float: left;
  2717. }
  2718. }
  2719. .list-cell-texts {
  2720. width: 100%;
  2721. height: auto;
  2722. line-height: 35rpx;
  2723. text-overflow: ellipsis;
  2724. display: -webkit-box;
  2725. word-break: break-all;
  2726. -webkit-box-orient: vertical;
  2727. -webkit-line-clamp: 2;
  2728. overflow: hidden;
  2729. font-size: 26rpx;
  2730. color: #333333;
  2731. }
  2732. }
  2733. .list-cell-btn {
  2734. width: 128rpx;
  2735. height: 100%;
  2736. float: right;
  2737. .icon-used {
  2738. width: 100%;
  2739. height: 100%;
  2740. box-sizing: border-box;
  2741. padding-top: 28rpx;
  2742. .icon-used-text {
  2743. width: 100%;
  2744. text-align: center;
  2745. line-height: 26rpx;
  2746. font-size: $font-size-20;
  2747. color: #f94b4b;
  2748. }
  2749. .icon-used-btn {
  2750. width: 128rpx;
  2751. height: 48rpx;
  2752. border-radius: 28rpx;
  2753. line-height: 48rpx;
  2754. font-size: $font-size-26;
  2755. text-align: center;
  2756. &.receive {
  2757. background-image: linear-gradient(270deg, #f94b4b 0%, #feb673 100%);
  2758. color: #ffffff;
  2759. }
  2760. &.make {
  2761. border: solid 1px #f94b4b;
  2762. color: #f94b4b;
  2763. }
  2764. }
  2765. }
  2766. }
  2767. }
  2768. .list-cell-time {
  2769. width: 100%;
  2770. height: 58rpx;
  2771. line-height: 58rpx;
  2772. text-align: left;
  2773. font-size: $font-size-20;
  2774. color: #999999;
  2775. }
  2776. }
  2777. }
  2778. &.train {
  2779. height: 240rpx;
  2780. }
  2781. .content-tr {
  2782. width: 100%;
  2783. min-height: 58rpx;
  2784. line-height: 58rpx;
  2785. display: flex;
  2786. .content-td {
  2787. display: flex;
  2788. flex: 3;
  2789. font-size: $font-size-26;
  2790. color: #999999;
  2791. line-height: 58rpx;
  2792. text-align: left;
  2793. }
  2794. .content-th {
  2795. display: flex;
  2796. flex: 7;
  2797. font-size: $font-size-26;
  2798. color: #333333;
  2799. line-height: 58rpx;
  2800. text-align: left;
  2801. padding-left: 10rpx;
  2802. }
  2803. }
  2804. }
  2805. }
  2806. .tui-shopping-main {
  2807. width: 100%;
  2808. .layer-smimg {
  2809. width: 114rpx;
  2810. height: 114rpx;
  2811. float: left;
  2812. border-radius: 10rpx;
  2813. margin-right: 24rpx;
  2814. image {
  2815. width: 114rpx;
  2816. height: 114rpx;
  2817. border-radius: 10rpx;
  2818. }
  2819. }
  2820. .layer-nunbox {
  2821. justify-content: space-between;
  2822. align-items: center;
  2823. width: 536rpx;
  2824. height: auto;
  2825. float: left;
  2826. .layer-nunbox-t {
  2827. width: 100%;
  2828. height: 44rpx;
  2829. position: relative;
  2830. display: flex;
  2831. margin-bottom: 10rpx;
  2832. .text {
  2833. font-size: $font-size-24;
  2834. line-height: 48rpx;
  2835. color: #999999;
  2836. }
  2837. .layer-nunbox-text {
  2838. line-height: 44rpx;
  2839. font-size: $font-size-28;
  2840. }
  2841. .number-box {
  2842. display: flex;
  2843. justify-content: center;
  2844. align-items: center;
  2845. border: 2rpx solid #ffe6dc;
  2846. border-radius: 30rpx;
  2847. height: 48rpx;
  2848. margin-left: 20rpx;
  2849. .iconfont {
  2850. font-size: $font-size-24;
  2851. padding: 0 18rpx;
  2852. color: #999999;
  2853. text-align: center;
  2854. line-height: 48rpx;
  2855. font-weight: bold;
  2856. background: #fef6f3;
  2857. &.icon-jianhao {
  2858. border-radius: 30rpx 0 0 30rpx;
  2859. }
  2860. &.icon-jiahao {
  2861. border-radius: 0 30rpx 30rpx 0;
  2862. }
  2863. }
  2864. .btn-input {
  2865. width: 62rpx;
  2866. height: 48rpx;
  2867. line-height: 48rpx;
  2868. background: #ffffff;
  2869. border-radius: 4rpx;
  2870. text-align: center;
  2871. font-size: $font-size-28;
  2872. }
  2873. }
  2874. .product-step {
  2875. position: absolute;
  2876. left: 45rpx;
  2877. bottom: 0;
  2878. height: 44rpx;
  2879. background: #ffffff;
  2880. }
  2881. }
  2882. .layer-nunbox-b {
  2883. width: 100%;
  2884. height: 44rpx;
  2885. margin-top: 13rpx;
  2886. }
  2887. .text {
  2888. line-height: 44rpx;
  2889. font-size: $font-size-28;
  2890. .p {
  2891. color: #ff2a2a;
  2892. }
  2893. .p:first-child {
  2894. margin-left: 30rpx;
  2895. }
  2896. .p.sm {
  2897. font-size: $font-size-24;
  2898. }
  2899. }
  2900. }
  2901. }
  2902. }
  2903. .tui-popup-btn {
  2904. width: 100%;
  2905. height: auto;
  2906. float: left;
  2907. margin-top: 24rpx;
  2908. .tui-button {
  2909. width: 100%;
  2910. height: 88rpx;
  2911. background: $btn-confirm;
  2912. line-height: 88rpx;
  2913. text-align: center;
  2914. color: #ffffff;
  2915. font-size: $font-size-28;
  2916. border-radius: 44rpx;
  2917. }
  2918. }
  2919. /*富文本样式*/
  2920. rich-text.p {
  2921. width: 702rpx !important;
  2922. padding: 0 24rpx;
  2923. text-align: justify;
  2924. }
  2925. rich-text.img {
  2926. width: 100%;
  2927. height: auto;
  2928. }
  2929. </style>