<import src="/wxParse/wxParse.wxml" />
<view class="page">
    <view class="page-hd">
        <!-- <image class="goods-img" mode="widthFix" src="/img/demo/goods.png"></image> -->
        <image class="goods-img" mode="widthFix" src="{{detail.photo}}"></image>
        <view class="goods-info">
            <view class="goods-name">{{detail.name}}</view>
            <view class="space-bt">
                <view>快递费：免邮费 广东广州</view>
                <view>总销量{{detail.sell_num}}笔</view>
            </view>
            <view class="price">
                <text class="unit">￥</text>{{unitPrice}}</view>
            <view class="remind">卖家承诺</view>
            <view class="remind-item">
                <image class="icon-yes" src="/img/icon-yes.png"></image>假一赔十
            </view>
        </view>
    </view>
    <view class="page-bd">
        <view class="details">
            <view class="details-hd">商品详情</view>
            <view class="details-bd">
                <!-- <image class="g" mode="widthFix" src="/img/demo/goods-detail.png" style="width: 100%;display: block;"></image> -->
                <template is="wxParse" data="{{wxParseData:article.nodes}}" />
            </view>
        </view>
    </view>
    <view class="page-ft">
        <view class="booking">
            <view class="input-item space-between">
                <view class="label">数量</view>
                <view class="input-content">
                    <view class="num-counter">
                        <view class="minus" catchtap="minusAmount">-</view>
                        <text class="input-num">{{amount}}</text>
                        <view class="plus" catchtap="addAmount">+</view>
                    </view>
                </view>
            </view>
            <view class="input-item">
                <view class="label">姓名</view>
                <view class="input-content">
                    <input type="text" class="input-text" bindinput="_handleInput" data-name="name" placeholder="您的称呼" />
                </view>
            </view>
            <view class="input-item">
                <view class="label">电话</view>
                <view class="input-content">
                    <input type="number" class="input-text" bindinput="_handleInput" data-name="phone" placeholder="您的手机号码" />
                </view>
            </view>
            <view class="input-item ">
                <view class="label ">地址</view>
                <view class="input-content">
                    <input type="text" class="input-text" bindinput="_handleInput" data-name="address" placeholder="寄送地址" />
                </view>
            </view>
        </view>
        <view class="total">
            <view class="total-price"><text class="unit">￥</text><text class="red">{{unitPrice*amount}}元</text></view>
            <view class="btn-cart" bindtap="toCart">加入购物车</view>
            <view class="btn-pay" bindtap="toPay">立即支付</view>
        </view>
    </view>
</view>