|
@ -29,11 +29,11 @@ |
|
|
<text>总收入</text> |
|
|
<text>总收入</text> |
|
|
<image mode="aspectFit" src="/static/images/icon/question_mark.png" @click="showQuestionModal"></image> |
|
|
<image mode="aspectFit" src="/static/images/icon/question_mark.png" @click="showQuestionModal"></image> |
|
|
</view> |
|
|
</view> |
|
|
<view><text>¥</text>{{totalData.total || '0'}}</view> |
|
|
|
|
|
|
|
|
<view><text>¥</text>{{totalData.count_type_actual_income_amount || '0'}}</view> |
|
|
</view> |
|
|
</view> |
|
|
<view class="tts-preview"> |
|
|
<view class="tts-preview"> |
|
|
<view>线上 ¥0.00</view> |
|
|
|
|
|
<view>线下 ¥200.00</view> |
|
|
|
|
|
|
|
|
<view>线上 ¥{{totalData.online_actual_income_amount || '0'}}</view> |
|
|
|
|
|
<view>线下 ¥{{totalData.offline_actual_income_amount || '0'}}</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
<view class="tc-info-section"> |
|
|
<view class="tc-info-section"> |
|
@ -56,30 +56,34 @@ |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
<view class="td-tip">总收入</view> |
|
|
<view class="td-tip">总收入</view> |
|
|
<view class="td-price"><text>¥</text>{{pageInfo.calc.total || 0}}</view> |
|
|
|
|
|
|
|
|
<view class="td-price"><text>¥</text>{{botData.count_type_actual_income_amount || 0}}</view> |
|
|
<view class="td-detail"> |
|
|
<view class="td-detail"> |
|
|
|
|
|
|
|
|
<view> |
|
|
<view> |
|
|
<view class="td-first"> |
|
|
<view class="td-first"> |
|
|
线上 ¥1000.00 |
|
|
|
|
|
|
|
|
线上 ¥{{ botData.online_actual_income_amount || '0' }} |
|
|
</view> |
|
|
</view> |
|
|
<view> |
|
|
<view> |
|
|
<text class="margin">收款笔数 </text> ( {{pageInfo.calc.in_count || 0}} ) |
|
|
|
|
|
|
|
|
<text class="margin">收款{{ botData.online_income_num || '0' }}笔 </text> |
|
|
|
|
|
( {{ botData.online_income_amount || '0' }} ) |
|
|
</view> |
|
|
</view> |
|
|
<view> |
|
|
<view> |
|
|
<text class="margin">退款笔数 </text> ( <text class="orange"> {{pageInfo.calc.out_count || 0}} </text> ) |
|
|
|
|
|
|
|
|
<text class="margin">退款{{ botData.online_refund_num || '0' }}笔 </text> |
|
|
|
|
|
( <text class="orange"> {{ botData.online_refund_amount || '0' }} </text> ) |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
<view> |
|
|
<view> |
|
|
<view class="td-first"> |
|
|
<view class="td-first"> |
|
|
线上 ¥1000.00 |
|
|
|
|
|
|
|
|
线下 ¥{{ botData.offline_actual_income_amount || '0' }} |
|
|
</view> |
|
|
</view> |
|
|
<view> |
|
|
<view> |
|
|
<text class="margin">收款金额 </text> ( ¥{{pageInfo.calc.in_total || '0.00'}} ) |
|
|
|
|
|
|
|
|
<text class="margin">收款{{ botData.offline_income_num || '0' }}笔 </text> |
|
|
|
|
|
( ¥{{botData.offline_income_amount || '0.00'}} ) |
|
|
</view> |
|
|
</view> |
|
|
<view> |
|
|
<view> |
|
|
<text class="margin">退款金额 </text> ( <text class="orange"> ¥{{pageInfo.calc.out_total || '0.00'}} </text> ) |
|
|
|
|
|
|
|
|
<text class="margin">退款{{ botData.offline_refund_num || '0' }}笔 </text> |
|
|
|
|
|
( <text class="orange"> ¥{{ botData.offline_refund_amount || '0' }} </text> ) |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
@ -114,7 +118,10 @@ export default { |
|
|
return { |
|
|
return { |
|
|
tabID: 4, |
|
|
tabID: 4, |
|
|
timeTabIdx: 0, |
|
|
timeTabIdx: 0, |
|
|
|
|
|
|
|
|
totalData: {}, |
|
|
totalData: {}, |
|
|
|
|
|
botData: {}, |
|
|
|
|
|
|
|
|
pageInfo: { |
|
|
pageInfo: { |
|
|
calc: {} |
|
|
calc: {} |
|
|
}, |
|
|
}, |
|
@ -162,16 +169,17 @@ export default { |
|
|
7 统计品牌的某一年 |
|
|
7 统计品牌的某一年 |
|
|
*/ |
|
|
*/ |
|
|
getCountType({ tab_id = -1, time_tab_idx = -1 }){ |
|
|
getCountType({ tab_id = -1, time_tab_idx = -1 }){ |
|
|
|
|
|
console.warn(tab_id, time_tab_idx, getType(time_tab_idx) + 5); |
|
|
if(time_tab_idx == -1)return tab_id; |
|
|
if(time_tab_idx == -1)return tab_id; |
|
|
|
|
|
|
|
|
let _type = getType(time_tab_idx) || -1 |
|
|
|
|
|
|
|
|
let _type = getType(time_tab_idx) |
|
|
|
|
|
|
|
|
if(tab_id == 3&&_type != -1)return _type; |
|
|
if(tab_id == 3&&_type != -1)return _type; |
|
|
|
|
|
|
|
|
if(tab_id == 4&&_type != -1)return _type + 5; |
|
|
|
|
|
|
|
|
if(tab_id == 4&&_type != -1)return _type += 5; |
|
|
|
|
|
|
|
|
function getType(idx){ |
|
|
function getType(idx){ |
|
|
switch(idx){ |
|
|
|
|
|
|
|
|
switch(+idx){ |
|
|
case 0: |
|
|
case 0: |
|
|
return 0 |
|
|
return 0 |
|
|
case 1: |
|
|
case 1: |
|
@ -188,8 +196,8 @@ export default { |
|
|
showQuestionModal(){ |
|
|
showQuestionModal(){ |
|
|
let { totalData } = this |
|
|
let { totalData } = this |
|
|
util.showModal({ |
|
|
util.showModal({ |
|
|
title: totalData.income_record_tips || '提示', |
|
|
|
|
|
content: totalData.income_record_name || '总收入为:线上(微信支付)+ 线下的总收入(退款已删除)', |
|
|
|
|
|
|
|
|
title: totalData.income_record_name|| '提示', |
|
|
|
|
|
content: totalData.income_record_tips || '总收入为:线上(微信支付)+ 线下的总收入(退款已删除)', |
|
|
showCancel: true, |
|
|
showCancel: true, |
|
|
success: mRes => { |
|
|
success: mRes => { |
|
|
|
|
|
|
|
@ -214,17 +222,28 @@ export default { |
|
|
if(timeTabIdx == 2)_date = `${curTime.month}-01` || '' // 统一格式 |
|
|
if(timeTabIdx == 2)_date = `${curTime.month}-01` || '' // 统一格式 |
|
|
if(timeTabIdx == 3)_date = `${curTime.year}-01-01` || ''// 统一格式 |
|
|
if(timeTabIdx == 3)_date = `${curTime.year}-01-01` || ''// 统一格式 |
|
|
|
|
|
|
|
|
|
|
|
let _type = this.getCountType({ tab_id: tabID, time_tab_idx: timeTabIdx }); |
|
|
|
|
|
|
|
|
let _query = { |
|
|
let _query = { |
|
|
type: timeTabIdx + 1, |
|
|
|
|
|
date: _date, |
|
|
|
|
|
|
|
|
stadium_id: curSelectStore.id || '', |
|
|
|
|
|
count_type: _type, |
|
|
|
|
|
time_str: _date || '', |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if(timeTabIdx == 1&&(_type == 0 || _type == 5)){ |
|
|
|
|
|
_query['time_str_min'] = util.formatDate({ date: new Date().getTime() - (7*24*60*60*1000) }) |
|
|
|
|
|
_query['time_str_max'] = util.formatDate({ }) |
|
|
} |
|
|
} |
|
|
if(tabID == 3)_query.stadium_id = curSelectStore.id; |
|
|
|
|
|
// 汇总 |
|
|
// 汇总 |
|
|
this.getCountData({ |
|
|
this.getCountData({ |
|
|
stadium_id: curSelectStore.id || '', |
|
|
stadium_id: curSelectStore.id || '', |
|
|
count_type: this.getCountType({ tab_id: tabID }) |
|
|
count_type: this.getCountType({ tab_id: tabID }) |
|
|
}) |
|
|
}) |
|
|
this.getBrandInfo(_query); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.getCountData(_query); |
|
|
|
|
|
|
|
|
|
|
|
// this.getBrandInfo(_query); |
|
|
}, |
|
|
}, |
|
|
// 店铺切换 |
|
|
// 店铺切换 |
|
|
storeChange(e){ |
|
|
storeChange(e){ |
|
|