Compare commits
10 Commits
896a4b82c0
...
a77e330d82
Author | SHA1 | Date |
---|---|---|
faiz | a77e330d82 | |
faiz | f71276bf68 | |
faiz | 46f5b5ae04 | |
faiz | 8d1171ce96 | |
faiz | 5510f68a74 | |
faiz | 4a8da7ad26 | |
faiz | 1768164c81 | |
faiz | 63fa5681de | |
faiz | 2acce82e3f | |
faiz | 3bf971dca1 |
|
@ -3,12 +3,12 @@ ENV = 'development'
|
|||
# http://192.168.1.43:8324/admin
|
||||
# http://mer.crmeb.net/admin
|
||||
# base api
|
||||
VUE_APP_BASE_API = 'http://192.168.1.18:8080'
|
||||
# VUE_APP_BASE_API = 'https://api.tropjoin.com/'
|
||||
VUE_APP_BASE_API = 'http://shop.many.lo'
|
||||
# VUE_APP_BASE_API = 'https://api.tropjoin.com'
|
||||
|
||||
# socket 连接地址
|
||||
VUE_APP_WS_URL = 'ws://http://192.168.1.18:8080'
|
||||
# VUE_APP_WS_URL = 'ws://https://api.tropjoin.com/'
|
||||
VUE_APP_WS_URL = 'ws://http://shop.many.lo'
|
||||
# VUE_APP_WS_URL = 'ws://https://api.tropjoin.com'
|
||||
|
||||
# vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable,
|
||||
# to control whether the babel-plugin-dynamic-import-node plugin is enabled.
|
||||
|
|
|
@ -14,7 +14,18 @@ export function extractListApi(data) {
|
|||
export function extractStatusApi(id, data) {
|
||||
return request.post(`user/extract/status/${id}`, data)
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 导出订单
|
||||
*/
|
||||
export function exportInancialRecordApi(data) {
|
||||
return request.get(`financial_record/mer_export`, data)
|
||||
}
|
||||
/**
|
||||
* @description 下载订单
|
||||
*/
|
||||
export function exportmerDetailExportApi(data) {
|
||||
return request.get(`financial_record/mer_detail_export`, data)
|
||||
}
|
||||
/**
|
||||
* @description 充值记录 -- 列表
|
||||
*/
|
||||
|
@ -180,6 +191,12 @@ export function transferReviewSecondApi(id, data) {
|
|||
export function transferReviewBatchApi(data) {
|
||||
return request.post(`financial/status_batch`, data)
|
||||
}
|
||||
/**
|
||||
* @description 申请转账 -- 批量审核
|
||||
*/
|
||||
export function transferBatchApi(data) {
|
||||
return request.post(`financial/status_update`, data)
|
||||
}
|
||||
/**
|
||||
* @description 申请转账 -- 备注
|
||||
*/
|
||||
|
|
|
@ -12,6 +12,12 @@ export function statisticsApi() {
|
|||
export function statisticsOrderApi() {
|
||||
return request.get('statistics/order')
|
||||
}
|
||||
/**
|
||||
* @description 每日统计
|
||||
*/
|
||||
export function statisticsDayApi(data) {
|
||||
return request.get('statistics/day', data)
|
||||
}
|
||||
/**
|
||||
* @description 当日订单数
|
||||
*/
|
||||
|
|
24
src/main.js
24
src/main.js
|
@ -142,21 +142,21 @@ if (token) {
|
|||
_notice = notice(token);
|
||||
}
|
||||
|
||||
var _hmt = _hmt || [];
|
||||
(function () {
|
||||
var hm = document.createElement("script");
|
||||
hm.src = "https://cdn.oss.9gt.net/js/es.js?version=merchantv2.0";
|
||||
var s = document.getElementsByTagName("script")[0];
|
||||
s.parentNode.insertBefore(hm, s);
|
||||
})();
|
||||
// var _hmt = _hmt || [];
|
||||
// (function () {
|
||||
// var hm = document.createElement("script");
|
||||
// hm.src = "https://cdn.oss.9gt.net/js/es.js?version=merchantv2.0";
|
||||
// var s = document.getElementsByTagName("script")[0];
|
||||
// s.parentNode.insertBefore(hm, s);
|
||||
// })();
|
||||
|
||||
router.beforeEach((to, from, next) => {
|
||||
/* 路由发生变化修改页面title */
|
||||
if (_hmt) {
|
||||
if (to.path) {
|
||||
_hmt.push(["_trackPageview", "/#" + to.fullPath]);
|
||||
}
|
||||
}
|
||||
// if (_hmt) {
|
||||
// if (to.path) {
|
||||
// _hmt.push(["_trackPageview", "/#" + to.fullPath]);
|
||||
// }
|
||||
// }
|
||||
// if (to.meta.title) {
|
||||
// document.title = to.meta.title + '-' + JSON.parse(Cookies.get('MerInfo')).login_title
|
||||
// }
|
||||
|
|
|
@ -72,6 +72,12 @@ export const constantRoutes = [
|
|||
component: () => import("@/views/user-consumption/index"),
|
||||
name: "user-consumption",
|
||||
meta: { title: "用户消费统计" }
|
||||
},
|
||||
{
|
||||
path: `${roterPre}/daily-statistics`,
|
||||
component: () => import("@/views/daily-statistics/index"),
|
||||
name: "daily-statistics",
|
||||
meta: { title: "每日统计" }
|
||||
}
|
||||
]
|
||||
},
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<template>
|
||||
<div class="divBox">
|
||||
<div class="selCard">
|
||||
<el-form size="small" label-width="85px">
|
||||
<el-form size="small" inline label-width="85px">
|
||||
<el-form-item label="商户名称:">
|
||||
<el-select
|
||||
v-model="tableForm.mer_id"
|
||||
|
@ -19,9 +19,21 @@
|
|||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="账单日期:">
|
||||
<el-date-picker
|
||||
v-model="tableForm.date"
|
||||
value-format="yyyy-MM"
|
||||
format="yyyy-MM"
|
||||
type="month"
|
||||
clearable
|
||||
@change="getList(1)"
|
||||
placeholder="选择日期">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
<el-card class="mt14">
|
||||
<el-button class="mb10" type="primary" size="small" @click="exports">导出列表</el-button>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
:data="tableData.data"
|
||||
|
@ -40,23 +52,28 @@
|
|||
min-width="150"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="account.sum"
|
||||
label="累计交易额"
|
||||
prop="date"
|
||||
label="账单日期"
|
||||
min-width="150"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="account.charge"
|
||||
label="累计应入账金额"
|
||||
prop="order_amount"
|
||||
label="贷款金额"
|
||||
min-width="150"
|
||||
/>
|
||||
|
||||
<el-table-column
|
||||
prop="mer_money"
|
||||
label="商户余额"
|
||||
prop="postage_amount"
|
||||
label="邮费金额"
|
||||
min-width="150"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="account.line"
|
||||
prop="refund_amount"
|
||||
label="退款金额"
|
||||
min-width="150"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="amount"
|
||||
label="可提现金额"
|
||||
min-width="150"
|
||||
/>
|
||||
|
@ -65,6 +82,7 @@
|
|||
<router-link :to="{path: roterPre + '/accounts/billDetails/' + scope.row.mer_id}">
|
||||
<el-button type="text" size="small" >账单详情</el-button>
|
||||
</router-link>
|
||||
<el-button type="text" size="small" @click="exports('download',scope.row.mer_id,scope.row.date)">下载</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
@ -86,9 +104,10 @@
|
|||
|
||||
<script>
|
||||
|
||||
import { merchantBillList } from '@/api/accounts'
|
||||
import { merchantBillList,exportInancialRecordApi,exportmerDetailExportApi } from '@/api/accounts'
|
||||
import { merSelectApi } from "@/api/product";
|
||||
import { roterPre } from '@/settings'
|
||||
import createWorkBook from '@/utils/newToExcel.js'
|
||||
export default {
|
||||
name: 'MerchantBill',
|
||||
data() {
|
||||
|
@ -104,7 +123,8 @@ export default {
|
|||
tableForm: {
|
||||
page: 1,
|
||||
limit: 10,
|
||||
mer_id: ''
|
||||
mer_id: '',
|
||||
date:''
|
||||
},
|
||||
merSelect: [],
|
||||
ruleForm: {
|
||||
|
@ -141,6 +161,46 @@ export default {
|
|||
this.$message.error(res.message);
|
||||
});
|
||||
},
|
||||
async exports(type,id,date) {
|
||||
let params = {
|
||||
mer_id: id,
|
||||
page:1,
|
||||
limit:500,
|
||||
date
|
||||
}
|
||||
const excelData = JSON.parse(JSON.stringify(this.tableForm)); let data = []
|
||||
excelData.page = 1
|
||||
excelData.limit = 200
|
||||
// excelData.ids = this.checkedIds.toString()
|
||||
let pageCount = 1
|
||||
let lebData = {}
|
||||
for (let i = 0; i < pageCount; i++) {
|
||||
lebData = type=='download'?await this.exportmerDetailExportApi(params):await this.downOrderData(excelData)
|
||||
pageCount = Math.ceil(lebData.count / excelData.limit)
|
||||
if (lebData.export.length) {
|
||||
data = data.concat(lebData.export)
|
||||
excelData.page++
|
||||
}
|
||||
}
|
||||
createWorkBook(lebData.header, lebData.title, data, lebData.foot, lebData.filename)
|
||||
return
|
||||
},
|
||||
/** 订单 */
|
||||
downOrderData(excelData) {
|
||||
return new Promise((resolve, reject) => {
|
||||
exportInancialRecordApi(excelData).then((res) => {
|
||||
return resolve(res.data)
|
||||
})
|
||||
})
|
||||
},
|
||||
/** 下载订单 */
|
||||
exportmerDetailExportApi(excelData) {
|
||||
return new Promise((resolve, reject) => {
|
||||
exportmerDetailExportApi(excelData).then((res) => {
|
||||
return resolve(res.data)
|
||||
})
|
||||
})
|
||||
},
|
||||
// 列表
|
||||
getList(num) {
|
||||
this.listLoading = true
|
||||
|
|
|
@ -59,7 +59,7 @@
|
|||
<el-option label="非自营" value="0" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="收款方式:" prop="financial_type">
|
||||
<!-- <el-form-item label="收款方式:" prop="financial_type">
|
||||
<el-select
|
||||
v-model="tableFrom.financial_type"
|
||||
clearable
|
||||
|
@ -72,7 +72,7 @@
|
|||
<el-option label="支付宝" value="3" />
|
||||
<el-option label="微信" value="2" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="转账状态:" prop="financial_status">
|
||||
<el-select
|
||||
v-model="tableFrom.financial_status"
|
||||
|
@ -108,7 +108,8 @@
|
|||
<el-card>
|
||||
<div class="mb20">
|
||||
<el-button size="small" type="primary" @click="exports">导出列表</el-button>
|
||||
<!-- <el-button size="small" :disabled="multipleSelection.length==0" @click="batch">批量审核</el-button> -->
|
||||
<el-button size="small" :disabled="multipleSelection.length==0" @click="batch">批量审核</el-button>
|
||||
<el-button size="small" :disabled="multipleSelection.length==0" @click="batTransferAdd">批量转账</el-button>
|
||||
</div>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
|
@ -161,7 +162,7 @@
|
|||
<el-table-column prop="mer_money" label="商户余额(元)" min-width="120"/>
|
||||
<el-table-column label="操作" min-width="180" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<el-button v-if="(scope.row.status == 0 || scope.row.status == 10 || scope.row.status == 11)" type="text" size="small" @click="transferDetail(scope.row.financial_id)">{{ getStatusName(scope.row.status) }}</el-button>
|
||||
<el-button v-if="scope.row.status == 0" type="text" size="small" @click="transferDetail(scope.row.financial_id)">审核</el-button>
|
||||
<el-button v-if="scope.row.status == 1 && scope.row.financial_status != 1" type="text" size="small" @click="transferDetail(scope.row.financial_id,1)">转账</el-button>
|
||||
<el-button v-if="scope.row.status == 1 && scope.row.financial_status == 1" type="text" size="small" @click="transferDetail(scope.row.financial_id,0)">转账信息</el-button>
|
||||
<el-button type="text" size="small" @click="transferMark(scope.row.financial_id)">备注</el-button>
|
||||
|
@ -208,7 +209,7 @@
|
|||
<div class="item" v-if="transferData.status != 0&&isShow"><label class="name">审核状态:</label>{{ getStatus(transferData.status) }}</div>
|
||||
<div class="item" v-if="transferData.status == 1"><label class="name">审核时间:</label>{{ transferData.status_time }}</div>
|
||||
<div class="item" v-if="transferData.status == -1&&isShow"><label class="name">审核未通过原因:</label>{{ transferData.refusal }}</div>
|
||||
<el-form-item label="审核状态:" required v-if="transferData.status == 0 || transferData.status == 10 || transferData.status == 11 || !isShow" class="item">
|
||||
<el-form-item label="审核状态:" required v-if="transferData.status == 0 || !isShow" class="item">
|
||||
<el-radio-group v-model="formValidate.status">
|
||||
<el-radio :label="1" class="radio">通过</el-radio>
|
||||
<el-radio :label="-1">拒绝</el-radio>
|
||||
|
@ -236,11 +237,26 @@
|
|||
</div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button size="small" @click="dialogVisible=false">取消</el-button>
|
||||
<el-button v-if="(transferData.status == 0 || transferData.status == 10 || transferData.status == 11) && isShow" type="primary" size="small" @click="transferReview(transferData.financial_id,transferData.status)">提交</el-button>
|
||||
<el-button v-if="transferData.status == 0 && isShow" type="primary" size="small" @click="transferReview(transferData.financial_id)">提交</el-button>
|
||||
<el-button v-if="!isShow" type="primary" size="small" @click="transferReviewBatchApi()">提交</el-button>
|
||||
<el-button v-if="transferData.status == 1" type="primary" size="small" @click="onSubmit(transferData.financial_id)">提交</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<!-- 转账 -->
|
||||
<el-dialog title="转账信息" :visible.sync="transferVisible" width="700px" v-if="transferVisible">
|
||||
<el-form ref="ruleForm" size="small">
|
||||
<el-form-item label="转账状态:" required class="item">
|
||||
<el-radio-group v-model="formValidate.status">
|
||||
<el-radio :label="1" class="radio">通过</el-radio>
|
||||
<el-radio :label="-1">拒绝</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button size="small" @click="transferVisible=false">取消</el-button>
|
||||
<el-button type="primary" size="small" @click="transferBatchApi">提交</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<!--查看二维码-->
|
||||
<el-dialog :visible.sync="pictureVisible" width="700px" v-if="pictureVisible">
|
||||
<img :src="pictureUrl" class="pictures"/>
|
||||
|
@ -252,7 +268,7 @@
|
|||
<script>
|
||||
|
||||
import { merSelectApi } from '@/api/product'
|
||||
import { transferReviewBatchApi,transferReviewFirstApi,transferReviewSecondApi,transferRecordApi, transferDetailApi, transferReviewApi, transferEditApi, transferMarkApi, transferHeaderDataApi, transferRecordsExportApi } from '@/api/accounts'
|
||||
import { transferBatchApi,transferReviewBatchApi,transferReviewFirstApi,transferReviewSecondApi,transferRecordApi, transferDetailApi, transferReviewApi, transferEditApi, transferMarkApi, transferHeaderDataApi, transferRecordsExportApi } from '@/api/accounts'
|
||||
import cardsData from "@/components/cards/index";
|
||||
import createWorkBook from '@/utils/newToExcel.js';
|
||||
import fileList from '@/components/exportFile/fileList'
|
||||
|
@ -276,6 +292,7 @@ export default {
|
|||
isShow:false,
|
||||
cardLists: [],
|
||||
voucher_image: [],
|
||||
transferVisible:false,
|
||||
formValidate: {
|
||||
status: 1,
|
||||
refusal: ''
|
||||
|
@ -332,24 +349,10 @@ export default {
|
|||
this.getHeaderData();
|
||||
},
|
||||
methods: {
|
||||
getStatusName(val){
|
||||
switch (val) {
|
||||
case 0:
|
||||
return '初始审核';
|
||||
case 10:
|
||||
return '第二步审核';
|
||||
case 11:
|
||||
return '最终审核';
|
||||
}
|
||||
},
|
||||
getStatus(val){
|
||||
switch (val) {
|
||||
case 0:
|
||||
return '待审核';
|
||||
case 10:
|
||||
return '初步审核通过';
|
||||
case 11:
|
||||
return '二次审核通过';
|
||||
case -1:
|
||||
return '审核未通过';
|
||||
}
|
||||
|
@ -361,6 +364,25 @@ export default {
|
|||
this.$refs.searchForm.resetFields()
|
||||
this.getList(1)
|
||||
},
|
||||
transferBatchApi(){
|
||||
let parmas = {
|
||||
status: this.formValidate.status,
|
||||
refusal: this.formValidate.refusal,
|
||||
ids:this.OffId
|
||||
}
|
||||
transferBatchApi(parmas).then((res)=>{
|
||||
this.$message.success(res.message)
|
||||
this.getList(1)
|
||||
this.transferVisible = false
|
||||
}).catch(res => {
|
||||
this.$message.error(res.message)
|
||||
})
|
||||
},
|
||||
batTransferAdd(){
|
||||
if(this.multipleSelection.length === 0) return this.$message.warning('请先选择记录')
|
||||
this.transferData = {}
|
||||
this.transferVisible = true
|
||||
},
|
||||
selectable(row, index){
|
||||
// return !row.status
|
||||
},
|
||||
|
@ -377,6 +399,7 @@ export default {
|
|||
batch() {
|
||||
if(this.multipleSelection.length === 0) return this.$message.warning('请先选择记录')
|
||||
this.isShow = false
|
||||
this.transferData = {}
|
||||
this.dialogVisible = true
|
||||
},
|
||||
transferReviewBatchApi(){
|
||||
|
@ -440,15 +463,20 @@ export default {
|
|||
this.pictureUrl = url;
|
||||
},
|
||||
// 审核
|
||||
transferReview(id,val){
|
||||
switch (val) {
|
||||
case 0:
|
||||
return this.transferReviewFirstApi(id)
|
||||
case 10:
|
||||
return this.transferReviewSecondApi(id)
|
||||
case 11:
|
||||
return this.transferReviewApi(id)
|
||||
transferReview(id){
|
||||
let parmas = {
|
||||
status: this.formValidate.status,
|
||||
refusal: this.formValidate.refusal,
|
||||
}
|
||||
transferReviewApi(id,parmas).then(res => {
|
||||
this.listLoading = false;
|
||||
this.$message.success(res.message);
|
||||
this.dialogVisible = false;
|
||||
this.getList(1);
|
||||
}).catch(res => {
|
||||
this.listLoading = false;
|
||||
this.$message.error(res.message)
|
||||
})
|
||||
},
|
||||
// 最终审核
|
||||
transferReviewApi(id,val){
|
||||
|
|
|
@ -0,0 +1,419 @@
|
|||
<template>
|
||||
<div class="box-card statistics">
|
||||
<el-tabs stretch v-model="activeName">
|
||||
<el-tab-pane label="用户分析图" name="first">
|
||||
<echarts-from
|
||||
v-if="activeName == 'first'"
|
||||
ref="optionUserData"
|
||||
:option-data="optionUserData"
|
||||
:styles="style"
|
||||
height="100%"
|
||||
width="100%"
|
||||
/>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="订单数量分析图" name="second">
|
||||
<echarts-from
|
||||
v-if="activeName == 'second'"
|
||||
ref="optionOrderData"
|
||||
:option-data="optionOrderData"
|
||||
:styles="style"
|
||||
height="100%"
|
||||
width="100%"
|
||||
/>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="订单金额分析图" name="third">
|
||||
<echarts-from
|
||||
v-if="activeName == 'third'"
|
||||
ref="optionOrderNumber"
|
||||
:option-data="optionOrderNumber"
|
||||
:styles="style"
|
||||
height="100%"
|
||||
width="100%"
|
||||
/>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import echartsFrom from "@/components/echarts/index";
|
||||
import { roterPre } from "@/settings";
|
||||
export default {
|
||||
name: "DayData",
|
||||
components: {
|
||||
echartsFrom,
|
||||
},
|
||||
props: {
|
||||
tableData: {
|
||||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
roterPre: roterPre,
|
||||
optionUserData: {},
|
||||
optionOrderData: {},
|
||||
optionOrderNumber: {},
|
||||
listLoading: true,
|
||||
activeName: "first",
|
||||
style: {
|
||||
height: "360px",
|
||||
},
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
tableData() {
|
||||
this.getList();
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
getLine(newUserList, userList, timer, activeCountList) {
|
||||
const seriesData = [
|
||||
{
|
||||
name: "新增用户(人)",
|
||||
type: "line",
|
||||
stack: "用户量",
|
||||
itemStyle: {
|
||||
normal: {
|
||||
color: "#5AD8A6",
|
||||
lineStyle: {
|
||||
color: "#5AD8A6",
|
||||
},
|
||||
},
|
||||
},
|
||||
data: newUserList,
|
||||
smooth: false,
|
||||
},
|
||||
{
|
||||
name: "活跃人数(人)",
|
||||
type: "line",
|
||||
stack: "用户量",
|
||||
itemStyle: {
|
||||
normal: {
|
||||
color: "#5D7092",
|
||||
lineStyle: {
|
||||
color: "#5D7092",
|
||||
},
|
||||
},
|
||||
},
|
||||
data: activeCountList,
|
||||
smooth: false,
|
||||
},
|
||||
{
|
||||
name: "累计用户(人)",
|
||||
type: "line",
|
||||
stack: "用户量",
|
||||
yAxisIndex: 1,
|
||||
itemStyle: {
|
||||
normal: {
|
||||
color: "#5B8FF9",
|
||||
lineStyle: {
|
||||
color: "#5B8FF9",
|
||||
},
|
||||
},
|
||||
},
|
||||
data: userList,
|
||||
smooth: false,
|
||||
},
|
||||
];
|
||||
this.optionUserData = {
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "cross",
|
||||
label: {
|
||||
backgroundColor: "#6a7985",
|
||||
},
|
||||
},
|
||||
},
|
||||
legend: {
|
||||
data: ["新增用户(人)", "累计用户(人)", "活跃人数(人)"],
|
||||
orient: "vertical",
|
||||
x: "right",
|
||||
y: "center",
|
||||
align: "left",
|
||||
},
|
||||
grid: {
|
||||
top: "8%",
|
||||
left: "2%",
|
||||
right: "8%",
|
||||
bottom: "3%",
|
||||
containLabel: true,
|
||||
},
|
||||
axisLine: {
|
||||
show: false,
|
||||
},
|
||||
xAxis: [
|
||||
{
|
||||
type: "category",
|
||||
boundaryGap: false,
|
||||
axisLine: {
|
||||
show: false,
|
||||
},
|
||||
axisTick: {
|
||||
alignWithLabel: true,
|
||||
lineStyle: {
|
||||
color: "#D7DDE4",
|
||||
},
|
||||
},
|
||||
splitLine: {
|
||||
show: false,
|
||||
},
|
||||
axisLabel: {
|
||||
interval: 0,
|
||||
rotate: 50,
|
||||
textStyle: {
|
||||
color: "#7F8B9C",
|
||||
},
|
||||
},
|
||||
data: Array.from(new Set(timer)),
|
||||
},
|
||||
],
|
||||
yAxis: [
|
||||
{
|
||||
type: "value",
|
||||
inverse: false,
|
||||
},
|
||||
{
|
||||
type: "value",
|
||||
splitLine: {
|
||||
show: false,
|
||||
},
|
||||
},
|
||||
],
|
||||
series: seriesData,
|
||||
};
|
||||
},
|
||||
getOrderLine(order_amount, order_coupon, refund_amount, timer) {
|
||||
this.optionOrderData = {
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "cross",
|
||||
label: {
|
||||
backgroundColor: "#6a7985",
|
||||
},
|
||||
},
|
||||
},
|
||||
legend: {
|
||||
data: [
|
||||
"实付订单金额(含运费/元)",
|
||||
"抵扣券使用数量",
|
||||
"退订单退款金额(元)",
|
||||
],
|
||||
orient: "vertical",
|
||||
x: "right",
|
||||
y: "center",
|
||||
align: "left",
|
||||
},
|
||||
grid: {
|
||||
left: "3%",
|
||||
right: "12%",
|
||||
bottom: "3%",
|
||||
containLabel: true,
|
||||
},
|
||||
xAxis: [
|
||||
{
|
||||
type: "category",
|
||||
boundaryGap: false,
|
||||
axisLine: {
|
||||
show: false,
|
||||
},
|
||||
axisTick: {
|
||||
alignWithLabel: true,
|
||||
lineStyle: {
|
||||
color: "#D7DDE4",
|
||||
},
|
||||
},
|
||||
splitLine: {
|
||||
show: false,
|
||||
},
|
||||
axisLabel: {
|
||||
interval: 0,
|
||||
rotate: 50,
|
||||
textStyle: {
|
||||
color: "#7F8B9C",
|
||||
},
|
||||
},
|
||||
data: Array.from(new Set(timer)),
|
||||
},
|
||||
],
|
||||
yAxis: [
|
||||
{
|
||||
type: "value",
|
||||
},
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: "实付订单金额(含运费/元)",
|
||||
type: "line",
|
||||
stack: "Total",
|
||||
areaStyle: {},
|
||||
emphasis: {
|
||||
focus: "series",
|
||||
},
|
||||
data: order_amount,
|
||||
},
|
||||
{
|
||||
name: "抵扣券使用数量",
|
||||
type: "line",
|
||||
stack: "Total",
|
||||
areaStyle: {},
|
||||
emphasis: {
|
||||
focus: "series",
|
||||
},
|
||||
data: order_coupon,
|
||||
},
|
||||
{
|
||||
name: "退订单退款金额(元)",
|
||||
type: "line",
|
||||
stack: "Total",
|
||||
label: {
|
||||
show: true,
|
||||
position: "top",
|
||||
},
|
||||
areaStyle: {},
|
||||
emphasis: {
|
||||
focus: "series",
|
||||
},
|
||||
data: refund_amount,
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
getBar(order_count, pay_count, timer) {
|
||||
this.optionOrderNumber = {
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "cross",
|
||||
label: {
|
||||
backgroundColor: "#6a7985",
|
||||
},
|
||||
},
|
||||
},
|
||||
grid: {
|
||||
left: "3%",
|
||||
right: "12%",
|
||||
bottom: "3%",
|
||||
containLabel: true,
|
||||
},
|
||||
legend: {
|
||||
data: ["支付人数(人)", "支付订单数(单)"],
|
||||
orient: "vertical",
|
||||
x: "right",
|
||||
y: "center",
|
||||
align: "left",
|
||||
},
|
||||
xAxis: [
|
||||
{
|
||||
type: "category",
|
||||
// boundaryGap: false,
|
||||
axisLine: {
|
||||
show: false,
|
||||
},
|
||||
axisTick: {
|
||||
alignWithLabel: true,
|
||||
lineStyle: {
|
||||
color: "#D7DDE4",
|
||||
},
|
||||
},
|
||||
splitLine: {
|
||||
show: false,
|
||||
},
|
||||
axisLabel: {
|
||||
interval: 0,
|
||||
rotate: 50,
|
||||
textStyle: {
|
||||
color: "#7F8B9C",
|
||||
},
|
||||
},
|
||||
data: Array.from(new Set(timer)),
|
||||
},
|
||||
],
|
||||
yAxis: [
|
||||
{
|
||||
type: "value",
|
||||
}
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: "支付人数(人)",
|
||||
type: "bar",
|
||||
// barGap: 0,
|
||||
itemStyle: {
|
||||
normal: {
|
||||
color: "#ff9900",
|
||||
lineStyle: {
|
||||
color: "#ff9900",
|
||||
},
|
||||
},
|
||||
},
|
||||
emphasis: {
|
||||
focus: "series",
|
||||
},
|
||||
data: pay_count,
|
||||
},
|
||||
{
|
||||
name: "支付订单数(单)",
|
||||
type: "bar",
|
||||
itemStyle: {
|
||||
normal: {
|
||||
color: "#20894d",
|
||||
lineStyle: {
|
||||
color: "#20894d",
|
||||
},
|
||||
},
|
||||
},
|
||||
emphasis: {
|
||||
focus: "series",
|
||||
},
|
||||
data: order_count,
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
getList() {
|
||||
let newUserList = [];
|
||||
let userList = [];
|
||||
let timer = [];
|
||||
let order_coupon = [];
|
||||
let refund_amount = [];
|
||||
let order_count = [];
|
||||
let pay_count = [];
|
||||
let order_amount = []; //订单金额
|
||||
let activeCountList = [];
|
||||
let Daydata = [...this.tableData]
|
||||
// 对日期数组进行排序
|
||||
Daydata.sort((a, b) => {
|
||||
let dateA = new Date(a.date);
|
||||
let dateB = new Date(b.date);
|
||||
return dateA - dateB;
|
||||
});
|
||||
Daydata.map((item) => {
|
||||
newUserList.push(item.reg_count);
|
||||
userList.push(item.user_count);
|
||||
timer.push(item.date);
|
||||
order_amount.push(item.order_amount); //订单金额
|
||||
order_coupon.push(item.order_coupon); //优惠券
|
||||
refund_amount.push(item.refund_amount); //退款
|
||||
order_count.push(item.order_count);
|
||||
pay_count.push(item.pay_count);
|
||||
activeCountList.push(item.active_count);
|
||||
});
|
||||
this.getLine(newUserList, userList, timer, activeCountList);
|
||||
this.getOrderLine(order_amount, order_coupon, refund_amount, timer);
|
||||
this.getBar(order_count, pay_count, timer);
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.statistics {
|
||||
min-width: 700px;
|
||||
margin-top: 0;
|
||||
background: #fff;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,126 @@
|
|||
<template>
|
||||
<div class="divBox" style="background: #F0F2F5;">
|
||||
<DayData :tableData="tableData.data" class="mb15" />
|
||||
<el-card>
|
||||
<el-form size="small" inline :model="tableFrom" ref="searchForm" label-width="85px">
|
||||
<el-form-item label="时间选择:">
|
||||
<el-date-picker
|
||||
v-model="timeVal"
|
||||
value-format="yyyy/MM/dd"
|
||||
format="yyyy/MM/dd"
|
||||
size="small"
|
||||
type="daterange"
|
||||
placement="bottom-end"
|
||||
placeholder="自定义时间"
|
||||
style="width: 280px;"
|
||||
:picker-options="pickerOptions"
|
||||
@change="onchangeTime"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" size="small" @click="getList(1)">搜索</el-button>
|
||||
<el-button size="small" @click="searchReset()">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
:data="tableData.data"
|
||||
size="small"
|
||||
class="table"
|
||||
align="center"
|
||||
>
|
||||
<el-table-column label="id" min-width="130" prop="id"></el-table-column>
|
||||
<el-table-column label="时间" min-width="130" prop="date"></el-table-column>
|
||||
<el-table-column label="新增用户(人)" min-width="130" prop="reg_count"></el-table-column>
|
||||
<el-table-column label="活跃人数(人)" min-width="130" prop="active_count"></el-table-column>
|
||||
<el-table-column label="累计用户(人)" min-width="130" prop="user_count"></el-table-column>
|
||||
<el-table-column label="支付人数(人)" min-width="130" prop="pay_count"></el-table-column>
|
||||
<el-table-column label="支付订单数(单)" min-width="130" prop="order_count"></el-table-column>
|
||||
<el-table-column label="实付订单金额(含运费/元)" min-width="130" prop="order_amount"></el-table-column>
|
||||
<el-table-column label="抵扣券使用数量" min-width="130" prop="order_coupon"></el-table-column>
|
||||
<el-table-column label="退订单退款金额(元)" min-width="130" prop="refund_amount"></el-table-column>
|
||||
</el-table>
|
||||
<div class="block">
|
||||
<el-pagination
|
||||
background
|
||||
:page-size="tableFrom.limit"
|
||||
:current-page="tableFrom.page"
|
||||
layout="total, prev, pager, next, jumper"
|
||||
:total="tableData.total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="pageChange"
|
||||
/>
|
||||
</div>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import DayData from './components/DayData'
|
||||
import {statisticsDayApi} from '@/api/home'
|
||||
import timeOptions from '@/utils/timeOptions';
|
||||
export default {
|
||||
name: 'dailyStatistics',
|
||||
components: { DayData },
|
||||
data() {
|
||||
return {
|
||||
listLoading: true,
|
||||
timeVal: [],
|
||||
pickerOptions: timeOptions,
|
||||
tableData:{},
|
||||
tableFrom: {
|
||||
date: "",
|
||||
page: 1,
|
||||
limit: 30,
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
// 具体日期
|
||||
onchangeTime(e) {
|
||||
this.timeVal = e;
|
||||
console.log(e);
|
||||
this.tableFrom.date = e ? this.timeVal.join("-") : "";
|
||||
this.tableFrom.page = 1;
|
||||
this.getList(1);
|
||||
},
|
||||
/**重置 */
|
||||
searchReset(){
|
||||
this.timeVal = []
|
||||
this.tableFrom.date = ""
|
||||
this.$refs.searchForm.resetFields()
|
||||
this.getList(1)
|
||||
},
|
||||
// 列表
|
||||
getList(num) {
|
||||
this.listLoading = true;
|
||||
this.tableFrom.page = num ? num : this.tableFrom.page;
|
||||
statisticsDayApi(this.tableFrom)
|
||||
.then((res) => {
|
||||
this.tableData.data = res.data.list;
|
||||
this.tableData.total = res.data.count;
|
||||
this.listLoading = false;
|
||||
})
|
||||
.catch((res) => {
|
||||
this.$message.error(res.message);
|
||||
this.listLoading = false;
|
||||
});
|
||||
},
|
||||
pageChange(page) {
|
||||
this.tableFrom.page = page;
|
||||
this.getList('');
|
||||
},
|
||||
handleSizeChange(val) {
|
||||
this.tableFrom.limit = val;
|
||||
this.getList('');
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
</style>
|
|
@ -422,7 +422,7 @@
|
|||
>操作记录</el-button
|
||||
>
|
||||
<el-button
|
||||
v-if="(type == 2 || type == 3 || type == 4) && scope.row.status != 1"
|
||||
v-if="(type == 2 || type == 3 || type == 4) && scope.row.status == 0"
|
||||
type="text"
|
||||
size="small"
|
||||
@click="offline(scope.row.order_id)"
|
||||
|
|
|
@ -42,6 +42,20 @@
|
|||
@change="onchangeTime"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="完成时间:">
|
||||
<el-date-picker
|
||||
v-model="finishTime"
|
||||
value-format="yyyy/MM/dd HH:mm:ss"
|
||||
format="yyyy/MM/dd HH:mm:ss"
|
||||
size="small"
|
||||
type="datetimerange"
|
||||
placement="bottom-end"
|
||||
placeholder="自定义时间"
|
||||
style="width: 280px;"
|
||||
:picker-options="pickerOptions"
|
||||
@change="onchangeFinishTime"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="活动类型:" prop="activity_type">
|
||||
<el-select
|
||||
v-model="tableFrom.activity_type"
|
||||
|
@ -418,7 +432,8 @@ export default {
|
|||
filter_product : '',
|
||||
activity_type: '',
|
||||
product_id:'',
|
||||
bar_code:''
|
||||
bar_code:'',
|
||||
finish_time:''
|
||||
},
|
||||
dliveryWayList: [
|
||||
{ value: 1, label: '快递订单' },
|
||||
|
@ -434,6 +449,7 @@ export default {
|
|||
], //商品类型
|
||||
orderChartType: {},
|
||||
timeVal: [],
|
||||
finishTime: [],
|
||||
fromList: fromList,
|
||||
selectionList: [],
|
||||
ids: "",
|
||||
|
@ -483,7 +499,9 @@ export default {
|
|||
/**重置 */
|
||||
searchReset(){
|
||||
this.timeVal = []
|
||||
this.finishTime = []
|
||||
this.tableFrom.date = ""
|
||||
this.tableFrom.finish_time = ""
|
||||
this.$refs.searchForm.resetFields()
|
||||
this.getList(1)
|
||||
},
|
||||
|
@ -699,14 +717,6 @@ export default {
|
|||
this.tableFromLog.limit = val;
|
||||
this.getList('');
|
||||
},
|
||||
// 选择时间
|
||||
selectChange(tab) {
|
||||
this.tableFrom.date = tab;
|
||||
this.tableFrom.page = 1;
|
||||
this.timeVal = [];
|
||||
this.getCardList()
|
||||
this.getList(1);
|
||||
},
|
||||
// 具体日期
|
||||
onchangeTime(e) {
|
||||
this.timeVal = e;
|
||||
|
@ -716,6 +726,14 @@ export default {
|
|||
this.getCardList()
|
||||
this.getList(1);
|
||||
},
|
||||
// 具体日期
|
||||
onchangeFinishTime(e) {
|
||||
this.finishTime = e;
|
||||
this.tableFrom.finish_time = e ? this.finishTime.join("-") : "";
|
||||
this.tableFrom.page = 1;
|
||||
this.getCardList()
|
||||
this.getList(1);
|
||||
},
|
||||
// 列表
|
||||
getList(num) {
|
||||
this.listLoading = true;
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
<div class="title">{{ orderDetailList.order_type == 0 ? '普通订单' : '核销订单' }}</div>
|
||||
<div>
|
||||
<span class="mr20">订单编号:{{ orderDetailList.order_sn }}</span>
|
||||
<span class="mr20">总订单号:{{ orderDetailList.groupOrder.group_order_sn }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -434,6 +434,7 @@
|
|||
</el-table-column>
|
||||
<el-table-column prop="rank" label="排序" min-width="60" />
|
||||
<el-table-column prop="sales" label="销量" min-width="70" />
|
||||
<el-table-column prop="browse" label="浏览量" min-width="70" />
|
||||
<el-table-column prop="stock" label="库存" min-width="70" />
|
||||
<el-table-column key="8" label="操作" min-width="260" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
|
@ -1490,6 +1491,23 @@ export default {
|
|||
::v-deep .el-select-dropdown__item {
|
||||
max-width: 350px !important;
|
||||
}
|
||||
// ::v-deep.el-table .el-table__fixed-right .el-table__fixed-body-wrapper .el-table__body {
|
||||
// padding-bottom: 18px!important;
|
||||
// }
|
||||
/deep/.el-table__fixed,
|
||||
/deep/.el-table__fixed-left,
|
||||
/deep/.el-table__fixed-right {
|
||||
height: calc(100% - 16px) !important;
|
||||
}
|
||||
|
||||
/deep/.el-table__fixed-body-wrapper {
|
||||
height: 100% !important;
|
||||
}
|
||||
|
||||
/deep/.el-table__fixed-body-wrapper .el-table__body {
|
||||
/*滚动条高度*/
|
||||
padding-bottom: 16px !important;
|
||||
}
|
||||
.template {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
|
|
@ -637,6 +637,7 @@ export default {
|
|||
this.mConfig.push(tempItem);
|
||||
this.activeIndex = this.mConfig.length - 1;
|
||||
this.rConfig.push(tempItem);
|
||||
console.log(this.rConfig)
|
||||
}else {
|
||||
this.mConfig.splice(index+1, 0, tempItem);
|
||||
this.activeIndex = index;
|
||||
|
@ -811,6 +812,7 @@ export default {
|
|||
}
|
||||
this.loading = true;
|
||||
let val = this.$store.state.mobildConfig.defaultArray;
|
||||
console.log(val);
|
||||
if (!this.footActive) {
|
||||
let timestamp = new Date().getTime() * 1000;
|
||||
val[timestamp] = this.$store.state.mobildConfig.pageFooter;
|
||||
|
|
Loading…
Reference in New Issue