master
parent
c720f088cf
commit
8239264290
@ -0,0 +1,17 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
export function getList(params){
|
||||
return request({
|
||||
method:'get',
|
||||
url:'/api/merchant/balance/get-list',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function balance(params){
|
||||
return request({
|
||||
method:'get',
|
||||
url:'/api/merchant/balance',
|
||||
params
|
||||
})
|
||||
}
|
||||
@ -0,0 +1,17 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
export function getList(params){
|
||||
return request({
|
||||
method:'get',
|
||||
url:'/api/merchant/order/get-list',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function itemAction(params){
|
||||
return request({
|
||||
method:'get',
|
||||
url:'/api/merchant/order/item-action',
|
||||
params
|
||||
})
|
||||
}
|
||||
@ -0,0 +1,90 @@
|
||||
<template>
|
||||
<div>
|
||||
<div >
|
||||
<div ref="lxHeader">
|
||||
<LxHeader icon="md-apps" text="财务管理" style="margin-bottom: 10px; border: 0px; margin-top: 15px">
|
||||
<div slot="content"></div>
|
||||
<slot>
|
||||
<div style="display: flex;align-items: center;">
|
||||
|
||||
<template v-for="(val,key) in balance">
|
||||
<el-card shadow="hover" style="margin-right: 10px">
|
||||
<div style="display: flex;flex-direction: column;justify-content: center;">
|
||||
<div style="font-weight: 600">
|
||||
{{ balanceFormat(key) }}
|
||||
</div>
|
||||
<div style="text-align: center;">
|
||||
{{ val }}
|
||||
</div>
|
||||
</div>
|
||||
</el-card>
|
||||
</template>
|
||||
</div>
|
||||
</slot>
|
||||
</LxHeader>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<xy-table :table-item="table" :list="data">
|
||||
<template v-slot:btns><div></div></template>
|
||||
</xy-table>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import LxHeader from '@/components/LxHeader/index.vue'
|
||||
|
||||
import {getList,balance} from '@/api/finance'
|
||||
export default {
|
||||
components: {
|
||||
LxHeader
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
select:{
|
||||
page:1,
|
||||
rows:10,
|
||||
},
|
||||
balance:{},
|
||||
data:[],
|
||||
table:[
|
||||
|
||||
]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
async getBalance(){
|
||||
let res = await balance()
|
||||
console.log(res)
|
||||
this.balance = res
|
||||
},
|
||||
|
||||
async getList(){
|
||||
let res = await getList(this.select)
|
||||
console.log(res)
|
||||
this.data = res.data
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
balanceFormat(){
|
||||
return function(key){
|
||||
let map = new Map([
|
||||
['balance','余额'],
|
||||
['fees','充值'],
|
||||
['recharges','退款'],
|
||||
['refunds','佣金']
|
||||
])
|
||||
return map.get(key)
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.getList()
|
||||
this.getBalance()
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
</style>
|
||||
@ -0,0 +1,116 @@
|
||||
<template>
|
||||
<div>
|
||||
<div >
|
||||
<div ref="lxHeader">
|
||||
<LxHeader icon="md-apps" text="订单管理" style="margin-bottom: 10px; border: 0px; margin-top: 15px">
|
||||
<div slot="content"></div>
|
||||
<slot>
|
||||
<div style="display: flex;align-items: center;">
|
||||
<div style="margin-right: 10px;">是否包含历史记录</div>
|
||||
|
||||
<el-switch v-model="select.show_history" :active-value="1" :inactive-value="0"></el-switch>
|
||||
|
||||
<Button type="primary" @click="getList" style="margin-left: 10px">查询</Button>
|
||||
</div>
|
||||
</slot>
|
||||
</LxHeader>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<xy-table :table-item="table" :list="data">
|
||||
<template v-slot:btns><div></div></template>
|
||||
</xy-table>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import LxHeader from '@/components/LxHeader/index.vue'
|
||||
|
||||
import {getList} from '@/api/order'
|
||||
export default {
|
||||
components: {
|
||||
LxHeader
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
select:{
|
||||
page:1,
|
||||
rows:10,
|
||||
show_history:0
|
||||
},
|
||||
data:[],
|
||||
table:[
|
||||
{
|
||||
label:'客户姓名',
|
||||
sortable:false,
|
||||
prop:'member_name',
|
||||
width:160
|
||||
},
|
||||
{
|
||||
label:'客户电话',
|
||||
sortable:false,
|
||||
prop:'member_phone',
|
||||
width: 200
|
||||
},
|
||||
{
|
||||
label:'预产期',
|
||||
sortable:false,
|
||||
prop:'member_due_date',
|
||||
width: 180
|
||||
},
|
||||
{
|
||||
label:'产品类型',
|
||||
sortable:false,
|
||||
prop:'product_type.name',
|
||||
width: 180
|
||||
},
|
||||
{
|
||||
label:'状态',
|
||||
sortable:false,
|
||||
prop:'state_name',
|
||||
width:120
|
||||
},
|
||||
{
|
||||
label:'操作',
|
||||
sortable:false,
|
||||
align:'left',
|
||||
customFn:row => {
|
||||
let map = new Map([
|
||||
['follow_by_merchant','el-icon-s-comment'],
|
||||
['accept_by_merchant','el-icon-s-promotion'],
|
||||
['return_by_merchant','el-icon-refresh-left'],
|
||||
['confirm_by_merchant','el-icon-check'],
|
||||
['mark_cancel_by_merchant','el-icon-circle-close'],
|
||||
['finish_by_merchant','el-icon-edit-outline']
|
||||
])
|
||||
let btns = []
|
||||
if(typeof row?.merchant_actions == 'object'){
|
||||
for(let key in row.merchant_actions){
|
||||
btns.push(
|
||||
<el-button size="mini" type="primary" icon={map.get(key)} plain>{row.merchant_actions[key]}</el-button>
|
||||
)
|
||||
}
|
||||
}
|
||||
return btns
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
async getList(){
|
||||
let res = await getList(this.select)
|
||||
console.log(res)
|
||||
this.data = res.data
|
||||
}
|
||||
},
|
||||
computed: {},
|
||||
mounted() {
|
||||
this.getList()
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
</style>
|
||||
Loading…
Reference in new issue