goods.wxml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324
  1. <!-- 展示蒙层 显示推广画报 -->
  2. <view class="poster" wx:if="{{myqr_show}}">
  3. <view class="title">
  4. <text>推广文案</text></view>
  5. <view class="ads">
  6. <view style="width:480rpx">{{myqr_ads}}</view>
  7. </view>
  8. <image src="{{myqr_url}}" mode="widthFix" style="width:480rpx" show-menu-by-longpress="true"></image>
  9. <view class="tool">
  10. <view bindtap="posterCopy" style="text-align:right">
  11. <image class="img" style="width:110rpx;height:130rpx" src="/static/images/share/p_copy.png"></image>
  12. </view>
  13. <button open-type='share' class="share-btn">
  14. <image class="img" style="width: 85rpx;height: 127rpx;" src="/static/images/share/p_wx.png"></image>
  15. </button>
  16. <view style="text-align:left">
  17. <image class="img" bindtap="goSaveQrcode" src="/static/images/share/p_save.png"></image>
  18. </view>
  19. </view>
  20. <view style="text-align:center">
  21. <image class="closeImg" bindtap="hidePoster" src="/static/images/share/close.png"></image>
  22. </view>
  23. </view>
  24. <view class="container" style="filter:brightness({{myqr_blur}}%)">
  25. <image src="/static/images/new/isnew.png" wx:if="{{goods.isNew}}" class="isNew"></image>
  26. <swiper class="goodsimgs" indicator-dots="true" autoplay="true" interval="3000" duration="1000">
  27. <swiper-item wx:for="{{goods.picAddress}}" wx:key="*this">
  28. <image src="{{item}}" mode="aspectFill"></image>
  29. </swiper-item>
  30. </swiper>
  31. <!-- 分享
  32. <view class='goods_name'>
  33. <view class='goods_name_left'>{{goods.name}}</view>
  34. <view hidden="{{!canShare}}" class="goods_name_right" bindtap="shareFriendOrCircle">
  35. <image class="img" src="/static/images/share.png" />
  36. </view>
  37. </view>-->
  38. <view class="share-pop-box" hidden="{{!openShare}}">
  39. <view class="share-pop">
  40. <view class="close" bindtap="closeShare">
  41. <van-icon class="icon" name="cross" />
  42. </view>
  43. </view>
  44. </view>
  45. <view class="goods-info">
  46. <view class="c">
  47. <view>
  48. <view class='goods_name'>
  49. <view class='goods_name_left'>{{goods.commodityName}}</view>
  50. </view>
  51. <!-- <text class="desc sub-color" wx:if="{{goods.commodityName}}">{{goods.commodityName}}</text> -->
  52. <view class="price" >
  53. <view class="retailPrice">商品编码:<text class="checked-price">{{goods.spuCode}}</text></view>
  54. <!-- <view class="member-price-tag spread-tag">推广优惠价</view> -->
  55. </view>
  56. <!-- <view class="price" wx:else>
  57. <view class="retailPrice">¥<text class="checked-price">{{checkedSpecPrice}}</text><text
  58. wx:if="{{goods.type=='2'}}"> 起</text></view> -->
  59. <!-- <view class="memberPrice" wx:if="{{goods.memberPrice!=checkedSpecPrice}}">¥{{goods.memberPrice}}</view> -->
  60. <!-- <view class="member-price-tag" wx:if="{{goods.memberPrice!=checkedSpecPrice}}" bindtap="goMemberCenter">会员价</view> -->
  61. <!-- </view> -->
  62. </view>
  63. <!-- 分享商品 -->
  64. <!-- <view hidden="{{!canShare}}" class="goods_name_right" bindtap="shareFriendOrCircle">
  65. <image class="img" src="/static/images/share.png" />
  66. </view> -->
  67. </view>
  68. </view>
  69. <!-- 数量和sku列表 -->
  70. <view class="sku-list">
  71. <view class="sku-title">请输入商品数量:</view>
  72. <view class="spu-number">
  73. <view class="minus" bindtap="minusNumber">-</view>
  74. <input value="{{goosNumber}}" class="goods-number" maxlength="4" type="number" placeholder="" bindinput="bindNumberInput"/>
  75. <view class="add" bindtap="addNumber" >+</view>
  76. </view>
  77. <view class="sku-title">规格选择:</view>
  78. <view >
  79. <label class="radio" wx:for="{{goods.skus}}" wx:key="index">
  80. <view class="sku-item" bindtap="skuSelect" data-id="{{item.id}}" data-stock="{{item.inHouseCount}}">
  81. <view>
  82. <radio
  83. color="#09afff" value="{{item.id}}" checked="{{currentSku==item.id?true:false}}" disabled="{{item.inHouseCount<=0}}"/>
  84. </view>
  85. <view class="sku-center"><text class="sku-name">{{item.propertyValue}}(库存:{{item.inHouseCount}} )</text></view>
  86. <view class="sku-price">
  87. 单价:¥<text>{{item.salePrice}}</text>
  88. </view>
  89. </view>
  90. </label>
  91. </view>
  92. </view>
  93. <!-- <view class="detail">
  94. <import src="/lib/wxParse/wxParse.wxml" />
  95. <template is="wxParse" data="{{wxParseData:goodsDetail.nodes}}" />
  96. </view> -->
  97. <!-- 大家都在看 -->
  98. <view class="related-goods" wx:if="{{relatedGoods.length > 0}}">
  99. <view class="h">
  100. <view class="line"></view>
  101. <text class="title">大家都在看</text>
  102. </view>
  103. <view class="b">
  104. <view class="item" wx:for="{{relatedGoods}}" wx:key="id">
  105. <navigator url="/pages/goods/goods?id={{item.id}}">
  106. <image class="img" src="{{item.picUrl}}" background-size="cover"></image>
  107. <text class="name">{{item.name}}(库存:{{item.inHouseCount}} )</text>
  108. <text class="price">¥{{item.retailPrice}}</text>
  109. </navigator>
  110. </view>
  111. </view>
  112. </view>
  113. </view>
  114. <!-- 规格选择界面 -->
  115. <view class="attr-pop-box" hidden="{{!openshow}}">
  116. <view class="attr-pop">
  117. <view class="close" bindtap="closeAttr">
  118. <van-icon class="icon" name="cross" />
  119. </view>
  120. </view>
  121. </view>
  122. <!-- 规格选择界面 -->
  123. <view class="attr-pop-box" hidden="{{!openAttr}}">
  124. <view class="attr-pop">
  125. <view class="close" bindtap="closeAttr">
  126. <van-icon class="icon" name="cross" />
  127. </view>
  128. <view class="img-info">
  129. <image class="img" src="{{goods.picUrl}}"></image>
  130. <view class="info">
  131. <view class="c">
  132. <view class="p">价格:¥{{checkedSpecPrice}}</view>
  133. <view class="a">{{tmpSpecText}}</view>
  134. </view>
  135. </view>
  136. </view>
  137. <!-- 规格列表 -->
  138. <view class="spec-con">
  139. <view class="spec-item" wx:for="{{specificationList}}" wx:key="name">
  140. <view class="name">{{item.name}}</view>
  141. <view class="values">
  142. <view class="value {{vitem.checked ? 'selected' : ''}}" bindtap="clickSkuValue" wx:for="{{item.valueList}}"
  143. wx:for-item="vitem" wx:key="id" data-value-id="{{vitem.id}}" data-name="{{vitem.specification}}">
  144. {{vitem.value}}</view>
  145. </view>
  146. </view>
  147. <view class="spec-item" wx:if="{{groupon.length > 0}}">
  148. <view class="name">团购立减</view>
  149. <view class="values">
  150. <view class="value {{vitem.checked ? 'selected' : ''}}" bindtap="clickGroupon" wx:for="{{groupon}}"
  151. wx:for-item="vitem" wx:key="{{vitem.id}}" data-value-id="{{vitem.id}}" data-name="{{vitem.specification}}">
  152. ¥{{vitem.discount}} ({{vitem.discountMember}}人)</view>
  153. </view>
  154. </view>
  155. <!-- 数量 -->
  156. <view class="number-item">
  157. <view class="name">数量</view>
  158. <view class="selnum">
  159. <!-- <view class="cut" bindtap="cutNumber">-</view> -->
  160. <input value="{{number}}" class="number" disabled="true" type="number" />
  161. <!-- <view class="add" bindtap="addNumber">+</view> -->
  162. </view>
  163. </view>
  164. </view>
  165. </view>
  166. </view>
  167. <!-- 联系客服
  168. <view class="contact">
  169. <contact-button style="opacity:0;position:absolute;" type="default-dark" session-from="weapp" size="36">
  170. </contact-button>
  171. </view> -->
  172. <!-- 底部按钮 -->
  173. <view class="bottom-btn" style="position:{{myqr_bottom_btn}}">
  174. <!-- <view class="l l-collect" bindtap="addCollectOrNot" wx:if="{{!isGroupon}}">
  175. <view class="collect-wrapper">
  176. <van-icon class="icon" name="star" color="#09afff" wx:if="{{collect}}" size="22px" />
  177. <van-icon class="icon" size="22px" color="#09afff" name="star-o" wx:else />
  178. <text class="jz-color collect-text">收藏</text>
  179. </view>
  180. </view> -->
  181. <view class="l l-kefu">
  182. <!-- bindtap="goCustomerService" -->
  183. <view class="service-wrapper" >
  184. <view class="contact-block">
  185. <van-icon name="service-o" color="#09afff" size="22px" />
  186. </view>
  187. <text class="jz-color">在线客服</text>
  188. </view>
  189. <contact-button class="csr" type="default-dark" style="opacity: 0;position: absolute;z-index: 99999; width: 100rpx;height: 84rpx;top:0;left:0" session-from="weapp" size="27">
  190. </contact-button>
  191. </view>
  192. <view class="l l-cart" bindtap="openCartPage" >
  193. <view class="collect-wrapper box">
  194. <text class="cart-count" wx:if="{{cartGoodsCount>0}}">{{cartGoodsCount}}</text>
  195. <van-icon class="icon" size="22px" color="#09afff" name="cart-o" />
  196. <text class="jz-color collect-text">购物车</text>
  197. </view>
  198. </view>
  199. <view class="c" >
  200. <view bindtap="addToCart" class="add-cart">加入购物车</view>
  201. <view bindtap="addFast" class="buy-now" >立即购买</view>
  202. </view>
  203. <!-- <view class="l l-cart" wx:if="{{!isGroupon}}">
  204. <view class="box" bindtap="openCartPage">
  205. <text class="cart-count" wx:if="{{cartGoodsCount>0}}">{{cartGoodsCount}}</text>
  206. <van-icon class="icon" name="cart-o" />
  207. <text class="txt">购物车</text>
  208. </view>
  209. </view>
  210. <view class="r" bindtap="addToCart" wx:if="{{!soldout}}" wx:if="{{!isGroupon}}">加入购物车</view> -->
  211. <!--
  212. <view class="r" bindtap="copyToHM">
  213. <view class="title">复制链接</view>
  214. <view class="subtitle">去盒马APP下单</view>
  215. </view> -->
  216. <!-- <view class="c" bindtap="addFast" wx:if="{{!soldout||!hasLogin}}">{{isGroupon?'参加团购':'立即预约'}}</view>
  217. <view class="n" wx:if="{{soldout}}">商品已售空</view> -->
  218. <!-- 自购&推广 分享进入有shareId不展示自购推广-->
  219. <!-- (hasLogin&&userInfo.isDis)||(hasLogin&&shareId==0) -->
  220. <!-- <view class="dis-order-wrapper" wx:if="{{hasLogin&&userInfo.isDis&&referee.self>0}}">
  221. <view class="self-order" bindtap="goSelfPay">
  222. <view class="buy-type">自购</view>
  223. <view>立省 {{referee.self}}元</view>
  224. </view>
  225. <view class="spread-order" bindtap="goSpread">
  226. <view class="buy-type jz-color" style="overflow: hidden;">推广</view>
  227. <view class="jz-color" style="overflow: hidden;">最高返 {{referee.share}}元</view>
  228. </view>
  229. </view>
  230. <block wx:else>
  231. <view class="c" bindtap="addFast" wx:if="{{!soldout||!hasLogin}}">{{isGroupon?'参加团购':'立即预约'}}</view>
  232. <view class="n" wx:if="{{soldout}}">商品已售空</view>
  233. </block> -->
  234. </view>
  235. <!-- 自购提示 -->
  236. <van-overlay show="{{ selfPayShow }}">
  237. <view class="overlay-wrapper">
  238. <view class="tips-wrapper">
  239. <view class="tips-top">
  240. <view class="tips-title">立省金额说明</view>
  241. <view>立省金额会以佣金形式发放,请在引荐人中心查收哦</view>
  242. </view>
  243. <view class="notip-again">
  244. <van-checkbox value="{{selfPayChecked}}" shape="square" icon-size="20px" bind:change="onSelfPayChange"
  245. checked-color="#09afff"></van-checkbox>
  246. <text class="user-agree">我已知晓,不再提示</text>
  247. </view>
  248. <view class="tips-bottom">
  249. <view class="cancel-btn" bindtap="cancelSelfPay">取消</view>
  250. <view class="btn-devide"></view>
  251. <view class="repay-btn" bindtap="reSelfPay">继续购买</view>
  252. </view>
  253. </view>
  254. </view>
  255. </van-overlay>
  256. <!-- 推广提示 -->
  257. <van-overlay show="{{spreadPayShow }}">
  258. <view class="overlay-wrapper">
  259. <view class="tips-wrapper">
  260. <view class="tips-top">
  261. <view class="tips-title">推广佣金说明</view>
  262. <view>页面展示推广佣金为预计最高返现金额,实际金额根据购买者团队身份计算,请在引荐人中心查看实际佣金</view>
  263. </view>
  264. <view class="notip-again">
  265. <van-checkbox value="{{spreadPayChecked}}" shape="square" icon-size="20px" bind:change="onSpreadPayChange"
  266. checked-color="#09afff"></van-checkbox>
  267. <text class="user-agree">我已知晓,不再提示</text>
  268. </view>
  269. <view class="tips-bottom">
  270. <view class="cancel-btn" bindtap="cancelSpreadPay">取消</view>
  271. <view class="btn-devide"></view>
  272. <view class="repay-btn" bindtap="reSpread">继续推广</view>
  273. </view>
  274. </view>
  275. </view>
  276. </van-overlay>