|
|
@ -1,70 +1,78 @@ |
|
|
|
<template> |
|
|
|
<template> |
|
|
|
<a-card :bordered="false"> |
|
|
|
<a-card :bordered="false"> |
|
|
|
<div class="card-title">{{ $route.meta.title }}</div> |
|
|
|
<div class="card-title">{{ $route.meta.title }}</div> |
|
|
|
<div class="table-operator"> |
|
|
|
<div class="table-operator"> |
|
|
|
<!-- 搜索板块 --> |
|
|
|
<!-- 搜索板块 --> |
|
|
|
<a-row class="row-item-search"> |
|
|
|
<a-row class="row-item-search"> |
|
|
|
<a-form class="search-form" :form="searchForm" layout="inline" @submit="handleSearch"> |
|
|
|
<a-form class="search-form" :form="searchForm" layout="inline" @submit="handleSearch"> |
|
|
|
<a-form-item label="会员订单号"> |
|
|
|
<a-form-item label="会员订单号"> |
|
|
|
<a-input v-decorator="['search']" placeholder="请输入会员订单号" /> |
|
|
|
<a-input v-decorator="['search']" placeholder="请输入会员订单号" /> |
|
|
|
</a-form-item> |
|
|
|
</a-form-item> |
|
|
|
<a-form-item label="支付状态"> |
|
|
|
<a-form-item label="支付状态"> |
|
|
|
<a-select v-decorator="['pay_status', { initialValue: 0 }]"> |
|
|
|
<a-select v-decorator="['pay_status', { initialValue: 0 }]"> |
|
|
|
<a-select-option :value="0">全部</a-select-option> |
|
|
|
<a-select-option :value="0">全部</a-select-option> |
|
|
|
<a-select-option :value="10">待支付</a-select-option> |
|
|
|
<a-select-option :value="10">待支付</a-select-option> |
|
|
|
<a-select-option :value="20">已支付</a-select-option> |
|
|
|
<a-select-option :value="20">已支付</a-select-option> |
|
|
|
</a-select> |
|
|
|
</a-select> |
|
|
|
</a-form-item> |
|
|
|
</a-form-item> |
|
|
|
<a-form-item label="订单类型"> |
|
|
|
<a-form-item label="订单类型"> |
|
|
|
<a-select v-decorator="['order_type', { initialValue: 0 }]"> |
|
|
|
<a-select v-decorator="['order_type', { initialValue: 0 }]"> |
|
|
|
<a-select-option :value="0">全部</a-select-option> |
|
|
|
<a-select-option :value="0">全部</a-select-option> |
|
|
|
<a-select-option :value="10">会员</a-select-option> |
|
|
|
<a-select-option :value="10">会员</a-select-option> |
|
|
|
<a-select-option :value="20">分销商 </a-select-option> |
|
|
|
<a-select-option :value="20">分销商 </a-select-option> |
|
|
|
</a-select> |
|
|
|
</a-select> |
|
|
|
</a-form-item> |
|
|
|
</a-form-item> |
|
|
|
<a-form-item label="支付方式"> |
|
|
|
<a-form-item label="支付方式"> |
|
|
|
<a-select v-decorator="['pay_method', { initialValue: 0 }]"> |
|
|
|
<a-select v-decorator="['pay_method', { initialValue: 0 }]"> |
|
|
|
<a-select-option :value="0">全部</a-select-option> |
|
|
|
<a-select-option :value="0">全部</a-select-option> |
|
|
|
<a-select-option :value="'wechat'">微信支付</a-select-option> |
|
|
|
<a-select-option :value="'wechat'">微信支付</a-select-option> |
|
|
|
<a-select-option :value="'balance'">余额支付 </a-select-option> |
|
|
|
<a-select-option :value="'balance'">余额支付 </a-select-option> |
|
|
|
</a-select> |
|
|
|
<a-select-option :value="'huifu'">银联支付 </a-select-option> |
|
|
|
</a-form-item> |
|
|
|
</a-select> |
|
|
|
<a-form-item label="付款时间"> |
|
|
|
</a-form-item> |
|
|
|
<a-range-picker format="YYYY-MM-DD" style="width:220px" v-decorator="['pay_time']" /> |
|
|
|
<a-form-item label="付款时间"> |
|
|
|
</a-form-item> |
|
|
|
<a-range-picker format="YYYY-MM-DD" style="width: 220px" v-decorator="['pay_time']" /> |
|
|
|
<a-form-item class="search-btn"> |
|
|
|
</a-form-item> |
|
|
|
<a-button type="primary" icon="search" html-type="submit">搜索</a-button> |
|
|
|
<a-form-item class="search-btn"> |
|
|
|
</a-form-item> |
|
|
|
<a-button type="primary" icon="search" html-type="submit">搜索</a-button> |
|
|
|
</a-form> |
|
|
|
</a-form-item> |
|
|
|
</a-row> |
|
|
|
</a-form> |
|
|
|
</div> |
|
|
|
</a-row> |
|
|
|
<s-table ref="table" rowKey="order_id" :loading="isLoading" :columns="columns" :data="loadData" :pagination="pagination"> |
|
|
|
</div> |
|
|
|
<!-- 会员信息 --> |
|
|
|
<s-table |
|
|
|
<span slot="user" slot-scope="text"> |
|
|
|
ref="table" |
|
|
|
<UserItem :user="text" /> |
|
|
|
rowKey="order_id" |
|
|
|
</span> |
|
|
|
:loading="isLoading" |
|
|
|
<!-- 充值方式 --> |
|
|
|
:columns="columns" |
|
|
|
<span slot="order_type" slot-scope="text"> |
|
|
|
:data="loadData" |
|
|
|
<a-tag v-if="text==10">会员</a-tag> |
|
|
|
:pagination="pagination" |
|
|
|
<a-tag v-if="text==20">分销商</a-tag> |
|
|
|
> |
|
|
|
</span> |
|
|
|
<!-- 会员信息 --> |
|
|
|
<!-- 时效 --> |
|
|
|
<span slot="user" slot-scope="text"> |
|
|
|
<span slot="month" slot-scope="text"> |
|
|
|
<UserItem :user="text" /> |
|
|
|
<p class="twoline-hide">{{ text }}个月</p> |
|
|
|
</span> |
|
|
|
</span> |
|
|
|
<!-- 充值方式 --> |
|
|
|
<!-- 支付方式 --> |
|
|
|
<span slot="order_type" slot-scope="text"> |
|
|
|
<span slot="pay_method" slot-scope="text"> |
|
|
|
<a-tag v-if="text == 10">会员</a-tag> |
|
|
|
<a-tag v-if="text">{{ text=='wechat'?'微信支付':'余额支付' }}</a-tag> |
|
|
|
<a-tag v-if="text == 20">分销商</a-tag> |
|
|
|
</span> |
|
|
|
</span> |
|
|
|
<!-- 状态 --> |
|
|
|
<!-- 时效 --> |
|
|
|
<span slot="pay_status" slot-scope="text"> |
|
|
|
<span slot="month" slot-scope="text"> |
|
|
|
<a-tag :color="text == 20 ? 'green' : ''">{{ text == 20 ? '已支付' : '待支付' }}</a-tag> |
|
|
|
<p class="twoline-hide">{{ text }}个月</p> |
|
|
|
</span> |
|
|
|
</span> |
|
|
|
<span slot="pay_time" slot-scope="text"> |
|
|
|
<!-- 支付方式 --> |
|
|
|
<span>{{ text | formatDate }}</span> |
|
|
|
<span slot="pay_method" slot-scope="text"> |
|
|
|
</span> |
|
|
|
<a-tag v-if="text">{{ PaymentMethodEnum[text].name }}</a-tag> |
|
|
|
</s-table> |
|
|
|
</span> |
|
|
|
</a-card> |
|
|
|
<!-- 状态 --> |
|
|
|
|
|
|
|
<span slot="pay_status" slot-scope="text"> |
|
|
|
|
|
|
|
<a-tag :color="text == 20 ? 'green' : ''">{{ text == 20 ? '已支付' : '待支付' }}</a-tag> |
|
|
|
|
|
|
|
</span> |
|
|
|
|
|
|
|
<span slot="pay_time" slot-scope="text"> |
|
|
|
|
|
|
|
<span>{{ text | formatDate }}</span> |
|
|
|
|
|
|
|
</span> |
|
|
|
|
|
|
|
</s-table> |
|
|
|
|
|
|
|
</a-card> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
|
|
|
|
|
|
|
|
<script> |
|
|
|
<script> |
|
|
@ -72,6 +80,8 @@ import * as Api from '@/api/user/order' |
|
|
|
import { STable, UserItem } from '@/components/Table' |
|
|
|
import { STable, UserItem } from '@/components/Table' |
|
|
|
import PayStatusEnum from '@/common/enum/recharge/order/PayStatus' |
|
|
|
import PayStatusEnum from '@/common/enum/recharge/order/PayStatus' |
|
|
|
import moment from 'moment' |
|
|
|
import moment from 'moment' |
|
|
|
|
|
|
|
import { PaymentMethodEnum } from '@/common/enum/payment' |
|
|
|
|
|
|
|
import { inArray, assignment } from '@/utils/util' |
|
|
|
export default { |
|
|
|
export default { |
|
|
|
name: 'Index', |
|
|
|
name: 'Index', |
|
|
|
components: { |
|
|
|
components: { |
|
|
@ -103,19 +113,19 @@ export default { |
|
|
|
title: 'ID', |
|
|
|
title: 'ID', |
|
|
|
dataIndex: 'order_id', |
|
|
|
dataIndex: 'order_id', |
|
|
|
}, |
|
|
|
}, |
|
|
|
{ |
|
|
|
{ |
|
|
|
title: '会员信息', |
|
|
|
title: '会员信息', |
|
|
|
dataIndex: 'user', |
|
|
|
dataIndex: 'user', |
|
|
|
scopedSlots: { customRender: 'user' } |
|
|
|
scopedSlots: { customRender: 'user' }, |
|
|
|
}, |
|
|
|
}, |
|
|
|
{ |
|
|
|
{ |
|
|
|
title: '订单号', |
|
|
|
title: '订单号', |
|
|
|
dataIndex: 'order_no', |
|
|
|
dataIndex: 'order_no', |
|
|
|
}, |
|
|
|
}, |
|
|
|
{ |
|
|
|
{ |
|
|
|
title: '订单类型', |
|
|
|
title: '订单类型', |
|
|
|
dataIndex: 'order_type', |
|
|
|
dataIndex: 'order_type', |
|
|
|
scopedSlots: { customRender: 'order_type' } |
|
|
|
scopedSlots: { customRender: 'order_type' }, |
|
|
|
}, |
|
|
|
}, |
|
|
|
{ |
|
|
|
{ |
|
|
|
title: '会员时效', |
|
|
|
title: '会员时效', |
|
|
@ -156,6 +166,12 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
created() {}, |
|
|
|
created() {}, |
|
|
|
|
|
|
|
beforeCreate() { |
|
|
|
|
|
|
|
// 批量给当前实例赋值 |
|
|
|
|
|
|
|
assignment(this, { |
|
|
|
|
|
|
|
PaymentMethodEnum, |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
}, |
|
|
|
methods: { |
|
|
|
methods: { |
|
|
|
/** |
|
|
|
/** |
|
|
|
* 刷新列表 |
|
|
|
* 刷新列表 |
|
|
|