<!-- 订单tab -->
<view class="order-tab">
    <view class="order-tab-item {{stateType == 'all' ? 'active':''}}" data-state="all" bindtap="orderTab">
        全部
    </view>
    <view class="order-tab-item {{stateType == 'unpaid' ? 'active':''}}" data-state="unpaid" bindtap="orderTab">
        待支付
    </view>
    <view class="order-tab-item {{stateType == 'paid' ? 'active':''}}" data-state="paid" bindtap="orderTab">
        待发货
    </view>
    <view class="order-tab-item {{stateType == 'delive' ? 'active':''}}" data-state="delive" bindtap="orderTab">
        待收货
    </view>
    <view class="order-tab-item {{stateType == 'refunds' ? 'active':''}}" data-state="refunds" bindtap="orderTab">
        已完成 <!-- 退款 -->
    </view>
</view>
<view class="order-content" wx:if="{{orderArr != ''}}">
    <view class="order-list" wx:for="{{orderArr}}" wx:key="orderArr" wx:for-item="goods">
        <view class="order-company">
            <view class="order-company-name">
                <image class="order-logo" src="/static/mall_icon/mallDetails_user.png"></image>
                {{goods.orderid}}
                <image class="order-arrow" src="/static/mall_icon/mall_arrow.png"></image>
            </view>
            <view class="order-company-state">
                {{goods.state_text}}
            </view>
        </view>
        <view class="order-goods" wx:for="{{goods.items}}" wx:key="items">
            <image class="order-goods-img" src="{{item.cover}}" mode="aspectFill"></image>
            <view class="order-goods-text">
                <view class="nowrap-multi order-goods-name">{{item.title}}</view>
                <view class="order-goods-price">
                    <text>¥{{item.price}}</text>
                    共{{item.qty}}件
                </view>
            </view>
        </view>
        <view class="order-footer">
            <view class="order-footer-btn order-footer-btn-back" wx:if="{{goods.canPay == true}}" data-orderid="{{goods.orderid}}"
                bindtap="orderPay">立即支付</view>
            <view class="order-footer-btn" wx:if="{{goods.canCancel == true}}" data-orderid="{{goods.orderid}}"
                bindtap="orderDelete">取消订单</view>
            <navigator hover-class="none" url="/pages/mall/mall_order_data/mall_order_data?orderId={{goods.orderid}}" class="order-footer-btn">订单详情</navigator>
        </view>
    </view>
</view>

<view wx:else class="pack-center pages-hint">
    <image src="/static/images/no_list.png"></image>
    <view>暂无订单</view>
</view>