|
@@ -45,6 +45,12 @@
|
|
style="width: 100px"
|
|
style="width: 100px"
|
|
type="number"
|
|
type="number"
|
|
:min="0"
|
|
:min="0"
|
|
|
|
+ :onkeyup="
|
|
|
|
+ (search.value =
|
|
|
|
+ Number(String(search.value).replace(/\D/g, '')) == 0
|
|
|
|
+ ? ''
|
|
|
|
+ : Number(String(search.value).replace(/\D/g, '')))
|
|
|
|
+ "
|
|
@keyup.enter="getList"
|
|
@keyup.enter="getList"
|
|
/>
|
|
/>
|
|
<a-select
|
|
<a-select
|
|
@@ -66,6 +72,7 @@
|
|
size="small"
|
|
size="small"
|
|
style="width: 240px"
|
|
style="width: 240px"
|
|
value-format="YYYY-MM"
|
|
value-format="YYYY-MM"
|
|
|
|
+ :clearable="false"
|
|
>
|
|
>
|
|
</el-date-picker>
|
|
</el-date-picker>
|
|
<el-date-picker
|
|
<el-date-picker
|
|
@@ -79,6 +86,7 @@
|
|
size="small"
|
|
size="small"
|
|
style="width: 240px"
|
|
style="width: 240px"
|
|
value-format="YYYY-MM-DD"
|
|
value-format="YYYY-MM-DD"
|
|
|
|
+ :clearable="false"
|
|
>
|
|
>
|
|
</el-date-picker>
|
|
</el-date-picker>
|
|
</div>
|
|
</div>
|
|
@@ -180,6 +188,10 @@ const PerformanceDetial = defineComponent({
|
|
end_date: this.search.date_arr ? this.search.date_arr[1] : "",
|
|
end_date: this.search.date_arr ? this.search.date_arr[1] : "",
|
|
...this.search,
|
|
...this.search,
|
|
};
|
|
};
|
|
|
|
+ if(sorter) {
|
|
|
|
+ if(sorter.order === 'descend') param.back_amount_order = 2
|
|
|
|
+ if(sorter.order === "ascend") param.back_amount_order = 1
|
|
|
|
+ }
|
|
delete param.date_arr;
|
|
delete param.date_arr;
|
|
console.log("请求参数", param);
|
|
console.log("请求参数", param);
|
|
let { data } = await getStuffPerformance({
|
|
let { data } = await getStuffPerformance({
|
|
@@ -257,37 +269,6 @@ const PerformanceDetial = defineComponent({
|
|
});
|
|
});
|
|
console.log("渲染");
|
|
console.log("渲染");
|
|
linePlot.render();
|
|
linePlot.render();
|
|
- // fetch(
|
|
|
|
- // "https://gw.alipayobjects.com/os/bmw-prod/e00d52f4-2fa6-47ee-a0d7-105dd95bde20.json"
|
|
|
|
- // )
|
|
|
|
- // .then((res: any) => res.json())
|
|
|
|
- // .then((data: any) => {
|
|
|
|
- // console.log("CHART DATA:", data);
|
|
|
|
- // const linePlot = new Line("chart-container", {
|
|
|
|
- // data,
|
|
|
|
- // xField: "year",
|
|
|
|
- // yField: "gdp",
|
|
|
|
- // seriesField: "name",
|
|
|
|
- // yAxis: {
|
|
|
|
- // label: {
|
|
|
|
- // formatter: (v: any) => `${(v / 10e8).toFixed(1)} B`,
|
|
|
|
- // },
|
|
|
|
- // },
|
|
|
|
- // legend: {
|
|
|
|
- // position: "top",
|
|
|
|
- // },
|
|
|
|
- // smooth: true,
|
|
|
|
- // // @TODO 后续会换一种动画方式
|
|
|
|
- // animation: {
|
|
|
|
- // appear: {
|
|
|
|
- // animation: "path-in",
|
|
|
|
- // duration: 3000,
|
|
|
|
- // },
|
|
|
|
- // },
|
|
|
|
- // });
|
|
|
|
-
|
|
|
|
- // linePlot.render();
|
|
|
|
- // });
|
|
|
|
},
|
|
},
|
|
// 工具函数:获取最近日期
|
|
// 工具函数:获取最近日期
|
|
getDateRange(dateNow: any, intervalDays: any, bolPastTime: any) {
|
|
getDateRange(dateNow: any, intervalDays: any, bolPastTime: any) {
|
|
@@ -366,9 +347,8 @@ const PerformanceDetial = defineComponent({
|
|
if(item.dataIndex === 'cash_withdrawal_amount') withdrawalIndex = index
|
|
if(item.dataIndex === 'cash_withdrawal_amount') withdrawalIndex = index
|
|
if(item.dataIndex === 'user_charge_amount_sum') chargeIndex = index+2
|
|
if(item.dataIndex === 'user_charge_amount_sum') chargeIndex = index+2
|
|
})
|
|
})
|
|
- // 选择按月查询 1.自然日从0加起-默认展示M+0、M+1、M+2 \ 2.24小时-从1加起-默认展示M+1、M+2
|
|
|
|
|
|
+ // 选择按月查询 1.自然日从0加起-默认展示M+0、M+1、M+2 \ 2.24小时-从1加起-默认展示M+0、M+1
|
|
if(this.search.type === 'month') { // 按月查询
|
|
if(this.search.type === 'month') { // 按月查询
|
|
- if(this.search.model === 'natural') { // 自然日
|
|
|
|
if(!this.search.value) {// 默认 未输入自定义月数
|
|
if(!this.search.value) {// 默认 未输入自定义月数
|
|
for(let i = 0; i< 3; i++) {
|
|
for(let i = 0; i< 3; i++) {
|
|
this.columns.splice(withdrawalIndex+(i+1), 0,{
|
|
this.columns.splice(withdrawalIndex+(i+1), 0,{
|
|
@@ -424,63 +404,7 @@ const PerformanceDetial = defineComponent({
|
|
})
|
|
})
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- } else { // 24小时
|
|
|
|
- if(!this.search.value) { // 未输入月数 默认
|
|
|
|
- for(let i =0; i< 3; i++) {
|
|
|
|
- this.columns.splice(withdrawalIndex+(i+1), 0,{
|
|
|
|
- title: '提现(元)M+'+ (i+1),
|
|
|
|
- dataIndex: 'cash_withdrawal',
|
|
|
|
- width: 150,
|
|
|
|
- customRender: ({ text, record }) => {
|
|
|
|
- return (<div style="color:gray;font-size:13px">
|
|
|
|
- <p style="color:black;font-size:14px">{ text[i].amount }</p>
|
|
|
|
- <p>累计提现: { text[i].accruing_amount }</p>
|
|
|
|
- <p>回本率: { text[i].back_rate }</p>
|
|
|
|
- </div>)
|
|
|
|
- },
|
|
|
|
- })
|
|
|
|
- this.columns.splice(chargeIndex+(i*2), 0,{
|
|
|
|
- title: '用户充值(元)M+'+ (i+1),
|
|
|
|
- dataIndex: 'user_charge',
|
|
|
|
- width: 150,
|
|
|
|
- customRender: ({ text, record }) => {
|
|
|
|
- return (<div style="color:gray;font-size:13px">
|
|
|
|
- <p style="color:black;font-size:14px">{ text[i].amount }</p>
|
|
|
|
- <p>累计提现: { text[i].accruing_amount }</p>
|
|
|
|
- <p>回本率: { text[i].back_rate }</p>
|
|
|
|
- </div>)
|
|
|
|
- },
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- } else { // 自定义月数
|
|
|
|
- for(let i = 0; i< this.search.value; i++) {
|
|
|
|
- this.columns.splice(withdrawalIndex+(i+1), 0,{
|
|
|
|
- title: '提现(元)M+'+ (i+1),
|
|
|
|
- dataIndex: 'cash_withdrawal',
|
|
|
|
- width: 150,
|
|
|
|
- customRender: ({ text, record }) => {
|
|
|
|
- return (<div style="color:gray;font-size:13px">
|
|
|
|
- <p style="color:black;font-size:14px">{ text[i].amount }</p>
|
|
|
|
- <p>累计提现: { text[i].accruing_amount }</p>
|
|
|
|
- <p>回本率: { text[i].back_rate }</p>
|
|
|
|
- </div>)
|
|
|
|
- },
|
|
|
|
- })
|
|
|
|
- this.columns.splice(chargeIndex+(i*2), 0,{
|
|
|
|
- title: '用户充值(元)M+'+(i+1),
|
|
|
|
- dataIndex: 'user_charge',
|
|
|
|
- width: 150,
|
|
|
|
- customRender: ({ text, record }) => {
|
|
|
|
- return (<div style="color:gray;font-size:13px">
|
|
|
|
- <p style="color:black;font-size:14px">{ text[i].amount }</p>
|
|
|
|
- <p>累计提现: { text[i].accruing_amount }</p>
|
|
|
|
- <p>回本率: { text[i].back_rate }</p>
|
|
|
|
- </div>)
|
|
|
|
- },
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
|
|
+
|
|
} else { // 选择按日查询 1.自然日从0加起-默认展示T+0、T+2、T+6、T+14、T+29 \ 2.24小时-从1加起-默认展示T+0、T+2、T+6、T+14、T+29
|
|
} else { // 选择按日查询 1.自然日从0加起-默认展示T+0、T+2、T+6、T+14、T+29 \ 2.24小时-从1加起-默认展示T+0、T+2、T+6、T+14、T+29
|
|
if(!this.search.value) {// 默认 未输入自定义月数
|
|
if(!this.search.value) {// 默认 未输入自定义月数
|
|
for(let i = 0; i< 5; i++) {
|
|
for(let i = 0; i< 5; i++) {
|