goods.wxml 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504
  1. <!-- 展示蒙层 显示推广画报 -->
  2. <view class="poster" wx:if="{{myqr_show}}">
  3. <view class="title">
  4. <text>推广文案</text>
  5. </view>
  6. <view class="ads">
  7. <view style="width:480rpx">{{myqr_ads}}</view>
  8. </view>
  9. <image src="{{myqr_url}}" mode="widthFix" style="width:480rpx" show-menu-by-longpress="true"></image>
  10. <view class="tool">
  11. <view bindtap="posterCopy" style="text-align:right">
  12. <image class="img" style="width:110rpx;height:130rpx" src="/static/images/share/p_copy.png"></image>
  13. </view>
  14. <button open-type='share' class="share-btn">
  15. <image class="img" style="width: 85rpx;height: 127rpx;" src="/static/images/share/p_wx.png"></image>
  16. </button>
  17. <view style="text-align:left">
  18. <image class="img" bindtap="goSaveQrcode" src="/static/images/share/p_save.png"></image>
  19. </view>
  20. </view>
  21. <view style="text-align:center">
  22. <image class="closeImg" bindtap="hidePoster" src="/static/images/share/close.png"></image>
  23. </view>
  24. </view>
  25. <view class="container" style="filter:brightness({{myqr_blur}}%)">
  26. <image src="/static/images/new/isnew.png" wx:if="{{goods.isNew}}" class="isNew"></image>
  27. <swiper class="goodsimgs" indicator-dots="{{goods.gallery.length>1?true:false}}"
  28. indicator-color="rgba(0, 192, 255, .2)" indicator-active-color="rgba(0, 192, 255)"autoplay="true" interval="3000" duration="1000">
  29. <swiper-item wx:for="{{goods.gallery}}" wx:key="*this">
  30. <image src="{{item}}" mode="aspectFill"></image>
  31. </swiper-item>
  32. </swiper>
  33. <!-- 分享
  34. <view class='goods_name'>
  35. <view class='goods_name_left'>{{goods.name}}</view>
  36. <view hidden="{{!canShare}}" class="goods_name_right" bindtap="shareFriendOrCircle">
  37. <image class="img" src="/static/images/share.png" />
  38. </view>
  39. </view>-->
  40. <view class="share-pop-box" hidden="{{!openShare}}">
  41. <view class="share-pop">
  42. <view class="close" bindtap="closeShare">
  43. <van-icon class="icon" name="cross" />
  44. </view>
  45. <!-- <view class='share-info'>
  46. <button class="sharebtn" open-type="share" wx:if="{{!isGroupon}}">
  47. <image class='sharebtn_image' src='/static/images/wechat.png'></image>
  48. <view class='sharebtn_text'>分享给好友</view>
  49. </button>
  50. <button class="savesharebtn" open-type="openSetting" bindopensetting="handleSetting" wx:if="{{(!isGroupon) && (!canWrite)}}">
  51. <image class='sharebtn_image' src='/static/images/friend.png'></image>
  52. <view class='sharebtn_text'>发朋友圈1</view>
  53. </button>
  54. <button class="savesharebtn" bindtap="saveShare" wx:if="{{!isGroupon && canWrite}}">
  55. <image class='sharebtn_image' src='/static/images/friend.png'></image>
  56. <view class='sharebtn_text'>发朋友圈</view>
  57. </button>
  58. </view>-->
  59. </view>
  60. </view>
  61. <view class="goods-info">
  62. <!-- 活动商品展示的样式 -->
  63. <view wx:if="{{activited}}" class="activity">
  64. <view style="display: flex;flex-direction: row;justify-content: space-between;">
  65. <view class="img">限时活动</view>
  66. <view class="activityDay">
  67. <image src="https://7a68-zhaijieshi-3guecm78383ca692-1307626841.tcb.qcloud.la/activity/clock.png"></image>
  68. <text>距离活动仅剩{{activityDay}}天</text></view>
  69. </view>
  70. <view style="display: flex;justify-content: space-between;">
  71. <view style="display: flex;">
  72. <view class="activityPrice">¥<text>{{activityPrice}}</text></view>
  73. <view class="activityCounterPrice">原价¥<text>{{goods.counterPrice}}</text></view>
  74. </view>
  75. <view class="activityTime">
  76. <view>{{activityHour}}</view><text>:</text>
  77. <view>{{activityMinute}}</view><text>:</text>
  78. <view>{{activitySecond}}</view>
  79. </view>
  80. </view>
  81. </view>
  82. <!-- <view class="retailPrice">¥<text class="checked-price">{{goods.retailPrice}}</text> </view>
  83. <view wx:if="{{goods.counterPrice!=goods.retailPrice}}" class="counterPrice">原价¥<text>{{goods.counterPrice}}</text></view> -->
  84. <!-- 非活动商品的样式 -->
  85. <view class="c">
  86. <view style="display: flex;flex-direction: column;">
  87. <view wx:if="{{!activited}}" class="price">
  88. <view class="retailPrice">¥<text class="checked-price">{{checkedSku.price}}</text> </view>
  89. <!-- wx:if="{{checkedSku.counterPrice!=checkedSku.price}}" -->
  90. <view class="counterPrice">原价¥<text>{{checkedSku.counterPrice}}</text></view>
  91. <view class="sale-num">
  92. 已售<text>{{countSalesNumber}}</text>份
  93. </view>
  94. </view>
  95. <view class="goods-name-wrapper">
  96. <view class='goods_name'>
  97. <!-- <image wx:if="{{activited}}" style="width: 79rpx;height:32rpx;margin-right: 4rpx;" src="https://7a68-zhaijieshi-3guecm78383ca692-1307626841.tcb.qcloud.la/activity/618.png"></image> -->
  98. <view class='goods_name_left'>{{goods.name}}</view>
  99. </view>
  100. <text class="desc sub-color" wx:if="{{goods.brief}}">{{goods.brief}}</text>
  101. </view>
  102. <!-- <view class="price" wx:else>
  103. <view class="retailPrice">¥<text class="checked-price">{{checkedSpecPrice}}</text><text
  104. wx:if="{{goods.type=='2'}}"> 起</text></view>
  105. <view class="memberPrice" wx:if="{{goods.memberPrice!=checkedSpecPrice}}">¥{{goods.memberPrice}}</view>
  106. <view class="member-price-tag" wx:if="{{goods.memberPrice!=checkedSpecPrice}}" bindtap="goMemberCenter">会员价</view>
  107. </view> -->
  108. </view>
  109. <!-- 分享商品 -->
  110. <!-- <view hidden="{{!canShare}}" class="goods_name_right" bindtap="shareFriendOrCircle">
  111. <image class="img" src="/static/images/share.png" />
  112. </view> -->
  113. </view>
  114. </view>
  115. <!-- <view class="section-nav section-attr" bindtap="switchAttrPop">
  116. <view class="t">{{checkedSpecText}}</view>
  117. <van-icon class="i" name="arrow" />
  118. </view> -->
  119. <!-- <view class="comments" wx:if="{{comment.count > 0}}">
  120. <view class="h">
  121. <navigator url="/pages/comment/comment?valueId={{goods.id}}&type=0">
  122. <text class="t">评价({{comment.count > 999 ? '999+' : comment.count}})</text>
  123. <view class="i">
  124. 查看全部
  125. <van-icon name="arrow" />
  126. </view>
  127. </navigator>
  128. </view>
  129. <view class="b">
  130. <view class="item" wx:for="{{comment.data}}" wx:key="id">
  131. <view class="info">
  132. <view class="user">
  133. <image src="{{item.avatar}}"></image>
  134. <text>{{item.nickname}}</text>
  135. </view>
  136. <view class="time">{{item.addTime}}</view>
  137. </view>
  138. <view class="content">
  139. {{item.content}}
  140. </view>
  141. <view class="imgs" wx:if="{{item.picList.length > 0}}">
  142. <image class="img" wx:for="{{item.picList}}" wx:key="*this" wx:for-item="iitem" src="{{iitem}} "></image>
  143. </view>
  144. <view class="customer-service" wx:if="{{item.adminContent}}">
  145. <text class="u">商家回复:</text>
  146. <text class="c">{{item.adminContent}}</text>
  147. </view>
  148. </view>
  149. </view>
  150. </view>-->
  151. <!-- <view class="goods-attr">
  152. <view class="t">商品参数</view>
  153. <view class="l">
  154. <view class="item" wx:for="{{attribute}}" wx:key="name">
  155. <text class="left">{{item.attribute}}</text>
  156. <text class="right">{{item.value}}</text>
  157. </view>
  158. </view>
  159. </view> -->
  160. <!-- 购买提醒 -->
  161. <view class="buy-toast" wx:if="{{buyToastShow}}">
  162. <image src="{{goodsBuyTime.cusHeadImg}}" mode="aspectFill" ></image>
  163. <view>{{goodsBuyTime.comment}}</view>
  164. </view>
  165. <!-- 选择规格sku -->
  166. <view class="sku-info" bindtap="showSkuPopup">
  167. <view class="sku-left">
  168. <view>已选</view>
  169. <view class="current-sku">{{checkedSku.specifications[0]}}</view>
  170. </view>
  171. <view class="sku-right">
  172. <view>可选服务</view>
  173. <van-icon name="arrow" color="#00B4FF" />
  174. </view>
  175. </view>
  176. <!-- 推荐产品 -->
  177. <view class="recommend-product" wx:if="{{recGoodsNum>0}}">
  178. <view class="recommend-title">
  179. 推荐产品({{recGoodsNum}})
  180. </view>
  181. <scroll-view scroll-x="true" class="recommend-scroll" >
  182. <view class="scroll-item-wrapper" wx:for="{{recGoodsList}}" wx:key="index">
  183. <navigator url="/pages/goods/goods?id={{item.id}}" >
  184. <view class="scroll-item" >
  185. <image src="{{item.picUrl}}" mode="aspectFill" ></image>
  186. <view class="scroll-right">
  187. <view class="recommend-name">{{item.name}}</view>
  188. <view class="recommend-price">
  189. <text>¥{{item.retailPrice}}</text>/台
  190. </view>
  191. </view>
  192. </view>
  193. </navigator>
  194. </view>
  195. </scroll-view>
  196. </view>
  197. <!-- 团购评价 -->
  198. <view class="group-evaluation">
  199. <view class="title" bindtap="goWholeEval">
  200. <view class="left">团购评价(999+条)</view>
  201. <view class="right">
  202. <view>查看全部</view>
  203. <van-icon name="arrow" color="#85868A" />
  204. </view>
  205. </view>
  206. <view class="evaluation-item" wx:for="{{goodsComment}}" wx:key="index">
  207. <view class="item-left">
  208. <view class="eval-top">
  209. <image src="{{item.cusHeadImg}}" mode="aspectFill" class="avatar"></image>
  210. <view class="name">{{item.cusName}}</view>
  211. <view class="tag">{{item.cusLabel}}</view>
  212. <view class="hp">{{item.commentType}}</view>
  213. </view>
  214. <view class="eval-content">
  215. {{item.comment}}
  216. </view>
  217. </view>
  218. <view class="item-right">
  219. <image src="{{item.commentImg}}" mode="aspectFill"></image>
  220. </view>
  221. </view>
  222. </view>
  223. <view class="detail">
  224. <import src="/lib/wxParse/wxParse.wxml" />
  225. <template is="wxParse" data="{{wxParseData:goodsDetail.nodes}}" />
  226. </view>
  227. <!-- <view class="common-problem">
  228. <view class="h">
  229. <view class="line"></view>
  230. <text class="title">常见问题</text>
  231. </view>
  232. <view class="b">
  233. <view class="item" wx:for="{{issueList}}" wx:key="id">
  234. <view class="question-box">
  235. <text class="spot"></text>
  236. <text class="question">{{item.question}}</text>
  237. </view>
  238. <view class="answer">
  239. {{item.answer}}
  240. </view>
  241. </view>
  242. </view>
  243. </view> -->
  244. <!-- 大家都在看 -->
  245. <view class="related-goods" wx:if="{{relatedGoods.length > 0}}">
  246. <view class="h">
  247. <view class="line"></view>
  248. <text class="title">大家都在看</text>
  249. </view>
  250. <view class="b">
  251. <view class="item" wx:for="{{relatedGoods}}" wx:key="id">
  252. <navigator url="/pages/goods/goods?id={{item.id}}">
  253. <image class="img" src="{{item.picUrl}}" background-size="cover"></image>
  254. <text class="name">{{item.name}}</text>
  255. <text class="price">¥{{item.retailPrice}}</text>
  256. </navigator>
  257. </view>
  258. </view>
  259. </view>
  260. </view>
  261. <!-- 规格选择界面 -->
  262. <view class="attr-pop-box" hidden="{{!openshow}}">
  263. <view class="attr-pop">
  264. <view class="close" bindtap="closeAttr">
  265. <van-icon class="icon" name="cross" />
  266. </view>
  267. </view>
  268. </view>
  269. <!-- 规格选择界面 -->
  270. <view class="attr-pop-box" hidden="{{!openAttr}}">
  271. <view class="attr-pop">
  272. <view class="close" bindtap="closeAttr">
  273. <van-icon class="icon" name="cross" />
  274. </view>
  275. <view class="img-info">
  276. <image class="img" src="{{goods.picUrl}}"></image>
  277. <view class="info">
  278. <view class="c">
  279. <view class="p">价格:¥{{checkedSpecPrice}}</view>
  280. <view class="a">{{tmpSpecText}}</view>
  281. </view>
  282. </view>
  283. </view>
  284. <!-- 规格列表 -->
  285. <view class="spec-con">
  286. <view class="spec-item" wx:for="{{specificationList}}" wx:key="name">
  287. <view class="name">{{item.name}}</view>
  288. <view class="values">
  289. <view class="value {{vitem.checked ? 'selected' : ''}}" bindtap="clickSkuValue" wx:for="{{item.valueList}}"
  290. wx:for-item="vitem" wx:key="id" data-value-id="{{vitem.id}}" data-name="{{vitem.specification}}">
  291. {{vitem.value}}</view>
  292. </view>
  293. </view>
  294. <view class="spec-item" wx:if="{{groupon.length > 0}}">
  295. <view class="name">团购立减</view>
  296. <view class="values">
  297. <view class="value {{vitem.checked ? 'selected' : ''}}" bindtap="clickGroupon" wx:for="{{groupon}}"
  298. wx:for-item="vitem" wx:key="{{vitem.id}}" data-value-id="{{vitem.id}}" data-name="{{vitem.specification}}">
  299. ¥{{vitem.discount}} ({{vitem.discountMember}}人)</view>
  300. </view>
  301. </view>
  302. <!-- 数量 -->
  303. <view class="number-item">
  304. <view class="name">数量</view>
  305. <view class="selnum">
  306. <!-- <view class="cut" bindtap="cutNumber">-</view> -->
  307. <input value="{{number}}" class="number" disabled="true" type="number" />
  308. <!-- <view class="add" bindtap="addNumber">+</view> -->
  309. </view>
  310. </view>
  311. </view>
  312. </view>
  313. </view>
  314. <!-- 联系客服
  315. <view class="contact">
  316. <contact-button style="opacity:0;position:absolute;" type="default-dark" session-from="weapp" size="36">
  317. </contact-button>
  318. </view> -->
  319. <!-- 底部按钮 -->
  320. <view class="bottom-btn" style="position:{{myqr_bottom_btn}}">
  321. <view class="l l-collect" bindtap="addCollectOrNot" wx:if="{{!isGroupon}}">
  322. <view class="collect-wrapper">
  323. <van-icon class="icon" name="star" color="#09afff" wx:if="{{collect}}" size="22px" />
  324. <van-icon class="icon" size="22px" color="#09afff" name="star-o" wx:else />
  325. <text class="jz-color collect-text">收藏</text>
  326. </view>
  327. </view>
  328. <view class="l l-kefu">
  329. <view class="service-wrapper" bindtap="goCustomerService">
  330. <view class="contact-block">
  331. <!-- <contact-button style="opacity:0;position:absolute; left:16rpx; top:0rpx;" type="default-dark"
  332. session-from="weapp" size="44">
  333. </contact-button> -->
  334. <van-icon name="service-o" color="#09afff" size="22px" />
  335. </view>
  336. <text class="jz-color">在线客服</text>
  337. </view>
  338. </view>
  339. <!-- <view class="l l-cart" wx:if="{{!isGroupon}}">
  340. <view class="box" bindtap="openCartPage">
  341. <text class="cart-count" wx:if="{{cartGoodsCount>0}}">{{cartGoodsCount}}</text>
  342. <van-icon class="icon" name="cart-o" />
  343. <text class="txt">购物车</text>
  344. </view>
  345. </view> -->
  346. <!-- <view class="r" bindtap="addToCart" wx:if="{{!soldout}}" wx:if="{{!isGroupon}}">加入购物车</view> -->
  347. <!-- <view class="r" bindtap="copyToHM">
  348. <view class="title">复制链接</view>
  349. <view class="subtitle">去盒马APP下单</view>
  350. </view> -->
  351. <!-- <view class="c" bindtap="addFast" wx:if="{{!soldout||!hasLogin}}">{{isGroupon?'参加团购':'立即预约'}}</view>
  352. <view class="n" wx:if="{{soldout}}">商品已售空</view> -->
  353. <!-- 自购&推广 分享进入有shareId不展示自购推广-->
  354. <!-- (hasLogin&&userInfo.isDis)||(hasLogin&&shareId==0)
  355. <view class="dis-order-wrapper" wx:if="{{hasLogin&&userInfo.isDis&&referee.self>0}}">
  356. <view class="self-order" bindtap="goSelfPay">
  357. <view class="buy-type">自购</view>
  358. <view>立省 {{referee.self}}元</view>
  359. </view>
  360. <view class="spread-order" bindtap="goSpread">
  361. <view class="buy-type jz-color" style="overflow: hidden;">推广</view>
  362. <view class="jz-color" style="overflow: hidden;">最高返 {{referee.share}}元</view>
  363. </view>
  364. </view>
  365. <block wx:else>
  366. <view class="c" bindtap="addFast" wx:if="{{!soldout||!hasLogin}}">{{isGroupon?'参加团购':'立即预约'}}</view>
  367. <view class="n" wx:if="{{soldout}}">商品已售空</view>
  368. </block>-->
  369. <view class="dis-order-wrapper" wx:if="{{goods.type==0||goods.type==3}}">
  370. <view class="self-order" data-type='0' bindtap="addFast">
  371. <view class="buy-type">先买后约</view>
  372. </view>
  373. <view class="spread-order" data-type='1' bindtap="addFast">
  374. <view class="buy-type jz-color" style="overflow: hidden;">立即预约</view>
  375. </view>
  376. </view>
  377. <block wx:else>
  378. <view class="c" bindtap="addFast" wx:if="{{!soldout||!hasLogin}}">立即预约</view>
  379. </block>
  380. </view>
  381. <!-- 自购提示 -->
  382. <van-overlay show="{{ selfPayShow }}">
  383. <view class="overlay-wrapper">
  384. <view class="tips-wrapper">
  385. <view class="tips-top">
  386. <view class="tips-title">立省金额说明</view>
  387. <view>立省金额会以佣金形式发放,请在引荐人中心查收哦</view>
  388. </view>
  389. <view class="notip-again">
  390. <van-checkbox value="{{selfPayChecked}}" shape="square" icon-size="20px" bind:change="onSelfPayChange"
  391. checked-color="#09afff"></van-checkbox>
  392. <text class="user-agree">我已知晓,不再提示</text>
  393. </view>
  394. <view class="tips-bottom">
  395. <view class="cancel-btn" bindtap="cancelSelfPay">取消</view>
  396. <view class="btn-devide"></view>
  397. <view class="repay-btn" bindtap="reSelfPay">继续购买</view>
  398. </view>
  399. </view>
  400. </view>
  401. </van-overlay>
  402. <!-- 推广提示 -->
  403. <van-overlay show="{{spreadPayShow }}">
  404. <view class="overlay-wrapper">
  405. <view class="tips-wrapper">
  406. <view class="tips-top">
  407. <view class="tips-title">推广佣金说明</view>
  408. <view>页面展示推广佣金为预计最高返现金额,实际金额根据购买者团队身份计算,请在引荐人中心查看实际佣金</view>
  409. </view>
  410. <view class="notip-again">
  411. <van-checkbox value="{{spreadPayChecked}}" shape="square" icon-size="20px" bind:change="onSpreadPayChange"
  412. checked-color="#09afff"></van-checkbox>
  413. <text class="user-agree">我已知晓,不再提示</text>
  414. </view>
  415. <view class="tips-bottom">
  416. <view class="cancel-btn" bindtap="cancelSpreadPay">取消</view>
  417. <view class="btn-devide"></view>
  418. <view class="repay-btn" bindtap="reSpread">继续推广</view>
  419. </view>
  420. </view>
  421. </view>
  422. </van-overlay>
  423. <!-- bind:click-overlay="onSkuClose" -->
  424. <!-- sku规格列表 -->
  425. <van-popup show="{{ chooseSkuVisible }}" round position="bottom" bind:click-overlay="onSkuClose">
  426. <view class="spu-popup">
  427. <view class="popup-good">
  428. <view class="left">
  429. <image src="{{currentSku.url}}" mode="aspectFill" ></image>
  430. <view class="spu-price">¥<text>{{currentSku.price}}</text></view>
  431. <view class="spu-price-old">¥{{currentSku.price}}</view>
  432. </view>
  433. <image src="https://jzmall.lifejingzhi.com/file/jzmall/weixin/sku-close.png" mode="aspectFill" class="sku-close" bindtap="onSkuClose" ></image>
  434. </view>
  435. <scroll-view scroll-y="true" class="sku-list-block">
  436. <view class="spu-title">
  437. 选择品类
  438. </view>
  439. <view style="padding-bottom:20rpx;">
  440. <view class="sku-item {{activeSku==item.id?'active-sku':''}}" wx:for="{{productList}}" wx:key="index" data-index="{{index}}" data-id="{{item.id}}" bindtap="selectSku">
  441. <view>
  442. {{item.specifications[0]}}
  443. </view>
  444. </view>
  445. </view>
  446. </scroll-view>
  447. <view class="sku-btn" bindtap="confSku">
  448. 确认
  449. </view>
  450. </view>
  451. </van-popup>