Authored by yyq

template

No preview for this file type
<template name="addressEditer">
<view class="edit-wrap">
<view class="edit-row">
<text class="left-cell">收货人</text>
<input data-name="consignee" class="right-cell" placeholder="姓名" maxlength="20" bindinput="onInputChanged" value="{{consignee}}"/>
</view>
<view class="edit-row">
<text class="left-cell">手机号码</text>
<input type="number" data-name="mobile" class="right-cell" placeholder="手机号码" maxlength="18" bindinput="onInputChanged" value="{{mobile}}"/>
</view>
<view class="edit-row" bindtap="chooseArea">
<text class="left-cell">选择地区</text>
<input class="right-cell" disabled="disabled" placeholder="地区信息" value="{{area}}"/>
</view>
<view class="edit-row">
<text class="left-cell">详细地址</text>
<input data-name="address" class="right-cell" placeholder="详细街道地址" maxlength="50" bindinput="onInputChanged" value="{{address}}"/>
</view>
</view>
<button class="option-btn save-btn" catchtap="saveAddr">确认</button>
<button wx:if="{{address_id}}" class="option-btn delete-btn" data-key="{{index}}" data-id="{{address_id}}" catchtap="deleteAddr">删除地址</button>
<view class="aaa">{{editeAddressPage}}</view>
<view wx:if="{{areaPicker}}" class="picker-mask" catchtap="hideAreaPicker"></view>
<picker-view wx:if="{{areaPicker}}" class="picker-view" indicator-style="height: 50px;" style="width: 100%; height: 300px;" value="{{areaValue}}" bindchange="areaPickerChange">
<picker-view-column data-type="provice1">
<view wx:for="{{pickerProvice}}" wx:key="unique" class="picker-item">
<text class="picker-text">{{item.caption}}</text>
</view>
</picker-view-column>
<picker-view-column>
<view wx:for="{{pickerCity}}" wx:key="unique" class="picker-item">
<text class="picker-text">{{item.caption}}</text>
</view>
</picker-view-column>
<picker-view-column>
<view wx:for="{{pickerArea}}" wx:key="unique" class="picker-item">
<text class="picker-text">{{item.caption}}</text>
</view>
</picker-view-column>
</picker-view>
</template>
... ...
.edit-wrap {
background-color: #fff;
padding-left: 30rpx;
margin-bottom: 50rpx;
}
.edit-wrap .edit-row {
border-bottom: 1rpx solid #e0e0e0;
padding: 10rpx 0;
}
.edit-wrap .edit-row:last-child {
border-bottom: 0;
}
.edit-wrap .edit-row .left-cell,
.edit-wrap .edit-row .right-cell {
height: 80rpx;
line-height: 80rpx;
display: inline-block;
vertical-align: middle;
}
.edit-wrap .edit-row .right-cell {
float: right;
width: 540rpx;
margin-right: 30rpx;
}
.option-btn {
height: 80rpx;
line-height: 80rpx;
margin: 20rpx 30rpx;
color: #fff;
background-color: #444;
}
.option-btn.delete-btn {
background-color: #aaa;
}
.picker-mask {
position: fixed;
left: 0;
right: 0;
top: 0;
bottom: 0;
z-index: 10;
}
.picker-view {
position: fixed;
left: 0;
bottom: 0;
z-index: 20;
}
.picker-view .picker-item {
line-height: 92rpx;
text-align: center;
}
.picker-view .picker-text {
max-width: 60%;
margin: 0 auto;
display: block;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
... ...
No preview for this file type
<template name="orderItem">
<view class="order" data-order_code="{{item.order_code}}" bindtap="navToOrderDetail">
<view class="header">
订单编号:{{item.order_code}}
<view class="order-status">{{item.status_str}}</view>
</view>
<view class="order-goods">
<block wx:for="{{item.order_goods}}" wx:for-item="good" wx:key="product_id">
<view class="order-good" data-id="">
<view class="thumb-wrap">
<image class="thumb" src="{{good.goods_image}}"></image>
<image wx:if="{{good.goods_type=='gift' || good.goods_type=='price_gift'}}"class='productTag' src="{{good.goods_type=='gift'?'images/zp-lab@2x.png':'images/jjg-lab@2x.png'}}"></image>
</view>
<view class="deps">
<view class="name row">{{good.product_name}}</view>
<view class="row">
<view class="color">
颜色:{{good.color_name}}
</view>
<view class="size">
尺码:{{good.size_name}}
</view>
</view>
<view class="row price-wrap">
<view class="price">
¥{{good.real_pay_price}}
</view>
<view wx:if="{{good.sales_price}}" class="count" style='text-decoration:line-through;'>
¥{{good.sales_price}}
</view>
<view class="count">
× {{good.buy_number}}
</view>
</view>
</view>
<block wx:if="{{good.expect_arrival_time}}">
<text class="order-tip" >上市期:{{good.expect_arrival_time}}</text>
</block>
</view>
</block>
</view>
<view class="footer">
共{{item.buy_total}}件商品 实付
<view class="sum-cost">¥{{item.amount}}</view>
(含运费¥{{item.shipping_cost}})
</view>
<view wx:if="{{item.attribute == 9}}" class="order-opt" style='font-size:28rpx;color:#444444'>*此订单只能在APP端操作</view>
<view wx:elif="{{item.links.length > 0}}" class="order-opt">
<block wx:if="{{item.counter_flag == 'Y' && item.is_cancel != 'Y' && item.pay_lefttime > 0}}">
<view class="counterView">
<image class="timeIcon" src='../../../static/images/shijian@3x.png'></image>
<text class="counter">剩余 {{item.time_left}}</text>
</view>
</block>
<block wx:for="{{item.links}}" wx:for-item="link" wx:key="order_code">
<block wx:if="{{link == 'closeOrder'}}">
<view class="btn" formType="submit" type="default" size="{{defaultSize}}" plain='true'
catchtap="cancelOrder" data-code="{{item.order_code}}">取消订单</view>
</block>
<block wx:if="{{link == 'buyNow'}}">
<view class="btn pay" catchtap="payNow" data-code="{{item.order_code}}"
data-amount="{{item.amount}}">立即付款
</view>
</block>
<block wx:if="{{link == 'delOrder'}}">
<view class="btn cancel" catchtap="delOrder" data-code="{{item.order_code}}">删除订单</view>
</block>
<block wx:if="{{link == 'getExpress'}}">
<view class="btn cancel" catchtap="expressDetail" data-code="{{item.order_code}}">查看物流</view>
</block>
<block wx:if="{{link == 'confirm'}}">
<view class="button pay" catchtap="confirmReceive" data-code="{{item.order_code}}">确认收货
</view>
</block>
<block wx:if="{{link == 'refundApply'}}">
<view class="button cancel" catchtap="refundOrder" data-code="{{item.order_code}}">申请退款
</view>
</block>
</block>
</view>
</view>
</template>
... ...
.order:last-child {
margin-bottom: 0;
}
.order {
position: relative;
display: block;
background: #fff;
margin-bottom: 20rpx;
border-top: 1rpx solid #e0e0e0;
border-bottom: 1rpx solid #e0e0e0;
}
.order .header {
border-bottom: 1rpx solid #e0e0e0;
}
.order .footer, .order .header {
height: 91rpx;
line-height: 90rpx;
font-size: 28rpx;
padding: 0 28rpx;
color: #444444;
}
.order .order-status {
float: right;
font-family: PingFang-SC-Medium;
font-size: 28rpx;
color: #D0021B;
letter-spacing: -0.39px;
}
.order-good {
position: relative;
margin: 18rpx 0;
margin-left: 30.6rpx;
height: 144rpx;
border-bottom: 1rpx solid #e0e0e0;
font-size: 23.4rpx;
}
.order-tip {
font-size: 25.2rpx;
margin-left: 15rpx;
color: red;
margin-top: 10rpx;
}
.order-good:last-child {
border-bottom: none;
margin-bottom: 0rpx;
}
.order-good .thumb-wrap {
position: relative;
float: left;
width: 100rpx;
height: 132rpx;
top: -9rpx;
}
.productTag{
width: 100%;
height: 20rpx;
bottom: 0;
left: 0;
position: absolute;
}
.order-good .thumb {
width: 100%;
height: 100%;
}
image {
display: block;
margin: 0 auto;
max-width: 100%;
border: 0;
}
.order-good .deps {
margin-left: 121.5rpx;
}
.order-good .name {
max-width: 70%;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
font-family: PingFang-SC-Regular;
font-size: 28rpx;
color: #444;
letter-spacing: -0.4rpx;
line-height: 34rpx;
min-height: 68rpx;
}
.order-good .row:nth-child(2) {
height: 40.5rpx;
line-height: 40.5rpx;
width: 90%;
}
.order-good .row .color {
display: inline-block;
max-width: 200rpx;
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
vertical-align: bottom;
font-family: PingFang-SC-Regular;
font-size: 24rpx;
color: #B0B0B0;
letter-spacing: -0.34rpx;
}
.order-good .row .size {
display: inline-block;
vertical-align: bottom;
padding-left: 20rpx;
font-family: PingFang-SC-Regular;
font-size: 24rpx;
color: #B0B0B0;
letter-spacing: -0.34rpx;
}
.order-good .color, .order-good .size {
color: #b6b6b6;
}
.order-good .price-wrap {
position: absolute;
top: 0rpx;
right: 27rpx;
text-align: right;
}
.order-good .price {
color: #d0021b;
}
.order-good .count {
display: block;
text-align: right;
font-family: PingFang-SC-Regular;
font-size: 24rpx;
color: #B0B0B0;
letter-spacing: -0.34rpx;
margin-top: 40rpx;
}
.order .footer {
text-align: right;
border-top: 1rpx solid #e0e0e0;
}
.order .sum-cost {
color: #e01;
margin-left: 4.5rpx;
display: inline-block;
}
.order .order-opt {
padding: 27rpx 0;
padding-right: 27rpx;
border-top: 1rpx solid #e0e0e0;
text-align: right;
margin-right: 20rpx;
display: flex;
flex-direction:row;
justify-content:flex-end;
}
.order .order-opt .counterView{
position: absolute;
left: 33rpx;
height: 108rpx;
bottom: 0rpx;
display: flex;
flex-direction:row;
align-items: center;
}
.order .order-opt .counterView .timeIcon{
height: 24rpx;
width: 24rpx;
}
.order .order-opt .counterView .counter{
margin-left: 10rpx;
font-size: 24rpx;
text-align: center;
}
.order .order-opt .btn {
display: inline-block;
height: 60rpx;
line-height: 60rpx;
width: 140rpx;
font-size: 25rpx;
text-align: center;
border: 1rpx solid #444444;
color: #444444;
border-radius: 4rpx;
}
.button {
height: 54rpx;
line-height: 54rpx;
width: 130rpx;
padding-left: 1rpx;
padding-right: 1rpx;
font-size: 25rpx;
text-align: center;
margin-right: 1rpx;
}
a {
outline: none;
color: #444444;
text-decoration: none;
}
.order .order-opt .pay {
background: #d0021b;
color: #fff;
border: none;
font-size: 25rpx;
margin-left: 20rpx;
line-height: 58rpx;
border: 1rpx solid #d0021b;
}
\ No newline at end of file
... ...
<template name="reason">
<view wx:if="{{showReason}}" id="reason-picker" class="reason-picker" catchtap="hidePicker">
<picker-view class="picker-view" value="{{reasonValue}}" bindchange="reasonChange" indicator-style="height: 50rpx;">
<picker-view-column>
<view wx:for="{{reason}}" wx:key="unique" class="addr-item">{{item.reason}}</view>
</picker-view-column>
</picker-view>
<view class="picker-option" bindtap="reasonSure">确定</view>
</view>
</template>
... ...
.reason-picker {
position: fixed;
top: 0;
bottom: 0;
left: 0;
right: 0;
z-index: 1000;
}
.reason-picker:after {
content: '';
width: 100%;
height: 100%;
background-color: #333;
filter: alpha(opacity=30);
opacity: 0.3;
position: absolute;
top:0;
left:0;
z-index: -1;
}
.reason-picker .picker-view{
width: 100%;
height: 400rpx;
background-color: white;
position: absolute;
bottom: 0;
left: 0;
text-align: center;
z-index: 0;
}
.reason-picker .picker-option {
height: 80rpx;
line-height: 80rpx;
color: #444;
background-color: white;
padding: 0 30rpx;
font-size: 28rpx;
position: absolute;
bottom: 320rpx;
right: 0;
z-index: 1;
}
... ...