EP-WachatApp/eaterplanet_ecommerce/pages/goods/comment.wxml

178 lines
9.0 KiB
Plaintext

<ep-navBar title="商品评价" background='#4facfe' back="{{true}}" iconTheme='white' color='#fff' bindback="handlerGobackClick"/>
<view>
<view class="goodsInfo">
<i-img class="goodsImg" defaultImage="../../images/placeholder-refund.png" height="90" iClass="img-class" loadImage="{{goods.one_image}}" width="90"></i-img>
<view class="goodsDetail">
<view class="detailTop">
<view class="detailTopInfo">
<view class="goodsName">{{goods.goodsname}}</view>
<view class="purchasing" wx:if="{{goods.one_limit_count > 0 || goods.total_limit_count > 0}}">
<text wx:if="{{goods.total_limit_count > 0}}">每人限购{{goods.total_limit_count}}份</text>
<text wx:if="{{goods.one_limit_count > 0}}"> 每单限购{{goods.one_limit_count}}份</text>
</view>
<view class="saleNum">已售{{goods.seller_count}}{{goods_sale_unit}},剩余{{goods.total}}{{goods_sale_unit}}</view>
</view>
<button class="shareBtn" hoverClass="none" openType="share">
<image class="shareImg" src="../../images/shareImg.png"></image>
</button>
</view>
<view class="detailBottom">
<view class="price">¥
<text class="salePrice">{{goods.price_front}}</text>.{{goods.price_after}}</view>
<view class="time">
<text wx:if="{{goods.over_type == 1}}">距结束</text>
<text class="endAct" wx:if="{{goods.over_type == 0}}">距开始</text>
<text class="endAct" wx:if="{{goods.over_type == 2}}">结束时间</text>
<text class="endAct" wx:if="{{goods.over_type == 2}}">{{goods.end_date}}</text>
<view class="countdown-class i-count-down">
<em wx:if="{{endtime.days > 0}}">{{endtime.days}}天</em>
<span class="item-class">{{endtime.hours}}</span>:
<span class="item-class">{{endtime.minutes}}</span>:
<span class="item-class">{{endtime.seconds}}</span>
</view>
</view>
</view>
</view>
</view>
<view class="noComments" style="height:{{containerHeight}}px" wx:if="{{showData===0}}">
<view class="noCommentsCon">
<image class="noCommentsImg" src="../../images/noData.png"></image>
<view class="noCommentsTit">暂无评论</view>
</view>
</view>
<view class="comments" wx:if="{{showData===1}}">
<view class="commentsDetail">
<view class="commentsList" wx:for="{{list}}" wx:key="id">
<i-card>
<view class="commentsListInfo" slot="content">
<view class='comment-user'>
<image src='{{item.avatar}}'></image>
<text>{{item.user_name}}</text>
</view>
<view bindlongpress="copy" bindtap="bindOpen" class="commentsCon {{item.isOpen&&item.showOpen?'doubleHidden':''}}" data-idx="{{index}}" data-val="{{item.content}}">{{item.content}}</view>
<view class="commentsOpen" wx:if="{{item.showOpen}}">
<text bindtap="bindOpen" data-idx="{{index}}">{{item.isOpen?'展开':'收起'}}</text>
<image class="commentsOpenImg {{item.isOpen?'down':''}}" src="../../images/commentsOpen.png"></image>
</view>
<view class="commentsImgCon" wx:if="{{item.images.length > 0}}">
<view class="commentsImg" wx:for="{{item.images}}" wx:for-index="idx" wx:for-item="imgItem" wx:key="index">
<i-img bindtap="preview" class="goodsImg" data-idx="{{idx}}" data-index="{{index}}" height="75" iClass="img-class" imgType="5" loadImage="{{imgItem}}" width="75"></i-img>
</view>
</view>
<view class="commentsTime">{{item.add_time}}</view>
</view>
</i-card>
</view>
<i-load-more iClass="loadMore" loading="{{loadMore}}" tip="{{tip}}"></i-load-more>
</view>
</view>
<!--底部按钮begin-->
<view class='i-fixed-bottom'>
<view class="goods-bottom-bar">
<view class="leftBtn">
<navigator hoverClass="none" openType="switchTab" url="/eaterplanet_ecommerce/pages/index/index">
<view class="bar-item back-to-index">
<image class="icon" src="{{iconArr.home}}"></image>
回首页
</view>
</navigator>
<navigator hoverClass="none" openType="switchTab" url="/eaterplanet_ecommerce/pages/order/shopCart">
<view class="bar-item shop-cart">
<view class="icon">
<image src="{{iconArr.car}}"></image>
<view class="cart-num" wx:if="{{cartNum}}">{{cartNum}}</view>
</view>
购物车
</view>
</navigator>
</view>
<view class="goodsStatus" wx:if="{{goods.total<=0}}">已抢光</view>
<view class="goodsStatus" wx:elif="{{goods.total > 0 && goods.over_type ==2}}">已结束</view>
<view class="goodsStatus" wx:elif="{{goods.grounding != 1}}">已下架</view>
<view class="goodsStatus" wx:elif="{{goods.over_type == 0}}">即将开抢</view>
<view class="goodsStatus" wx:elif="{{is_comunity_rest == 1}}">团长休息中</view>
<view class="gobuy" wx:else>
<form bindsubmit="addToCart" reportSubmit="true">
<view class="bar-item add-to-cart" style='background: {{goodsdetails_addcart_bg_color}}'>加入购物车</view>
<button class="btn" formType="submit"></button>
</form>
<form bindsubmit="submit" reportSubmit="true">
<button hidden formType="submit" id="formId"></button>
</form>
<label class="balanceBtn" for="formId">
<view bindtap="balance" class="bar-item balance" style='background: {{goodsdetails_buy_bg_color}}'>立即购买</view>
</label>
</view>
</view>
</view>
<!--底部按钮end-->
<view class="mask" bindtap='closeSku' hidden="{{!visible}}"></view>
<!---规格选择begin-->
<view bind:cancel="close" class='sku-content' scrollUp="{{true}}" hidden="{{!visible}}">
<view class="sku-card">
<view bindtap="closeSku" class="close">
<image src="../../images/icon-sku-close.png"></image>
</view>
<view class="sku-header">
<image src='{{cur_sku_arr.skuImage}}' style="width:80px;height:80px;" class='sku-img'></image>
<view class="sku-desc">
<view class="sku-title">
<span>{{cur_sku_arr.spuName}}</span>
</view>
<view class="sku-price">
<view class="sale-price">
¥
<span>{{cur_sku_arr.actPrice[0]}}</span>.{{cur_sku_arr.actPrice[1]}}
</view>
<view class="market-price">¥{{cur_sku_arr.marketPrice[0]}}.{{cur_sku_arr.marketPrice[1]}}</view>
</view>
<view class="sku-switch-on" wx:if="{{cur_sku_arr.spec}}">已选择:{{cur_sku_arr.spec}}</view>
</view>
</view>
<view class="sku-spec" wx:for="{{skuList.list}}" wx:key="id">
<view class="title">{{item.name}}</view>
<view class="spec-list">
<span bindtap="selectSku" class="{{idx==sku[index]['idx']?'on':''}}" data-disabled="{{item.canBuyNum-value<0}}" data-type="{{index}}_{{idx}}_{{value.option_value_id}}_{{value.name}}" wx:for-index="idx" data-idx="{{idx}}" wx:for="{{item.option_value}}"
wx:for-item="value">{{value.name}}</span>
</view>
</view>
<view class="sku-num-content">
<view class="title">数量</view>
<view class="i-class i-input-number i-input-number-size-{{size}}">
<view bindtap="setNum" data-type="decrease" class="i-input-number-minus {{value<=min?'i-input-number-disabled':''}}">
<image src="../../images/icon-input-reduce.png"></image>
</view>
<input bindblur="handleBlur" bindfocus="handleFocus" class="i-input-number-text {{min>=max?'i-input-number-disabled':''}}" disabled="true" type="number" value="{{sku_val}}"></input>
<view bindtap="setNum" data-type="add" class="i-input-number-plus {{value>=max?'i-input-number-disabled':''}}">
<image src="../../images/icon-input-add.png"></image>
</view>
</view>
<view class="msg" wx:if="{{skuList[current].isLimit}}">
<span wx:if="{{skuList[current].limitMemberNum>-1}}">每人限{{skuList[current].limitMemberNum}}单</span>
<span wx:if="{{skuList[current].limitOrderNum>-1}}">每单限{{skuList[current].limitOrderNum}}份</span>
<span></span>
</view>
<view class="even-num" wx:elif="{{!skuList[current].isLimit&&skuList[current].canBuyNum-value<=10&&skuList[current].canBuyNum-value>-1}}">还可以购买 {{skuList[current].canBuyNum-value}} 件</view>
</view>
<form bindsubmit="gocarfrom" report-submit="true">
<button formType="submit" class="sku-confirm" disabled='{{cur_sku_arr.stock==0 ? true : false}}'>
<view>{{cur_sku_arr.stock==0?"已抢光":"确定"}}</view>
</button>
</form>
</view>
</view>
<!---规格选择end-->
</view>
<i-new-auth needAuth="{{needAuth&&showAuthModal}}" bind:authSuccess="authSuccess" bind:cancel="authModal" needPosition="{{needPosition}}"></i-new-auth>
<i-vip-modal visible="{{showVipModal}}" imgUrl="{{pop_vipmember_buyimage}}" />