|
@@ -133,13 +133,57 @@ function columns12(): { label: string, fieldSHow?: { label: string, saveField: s
|
|
|
render: (a: string, b: any) => (<WidthEllipsis value={a} />)
|
|
|
},
|
|
|
{
|
|
|
- title: '支付状态', dataIndex: 'orderStatus', label: '订单明细', align: 'center', width: 85, default: 30,
|
|
|
+ title: '注册充值时间差',
|
|
|
+ dataIndex: 'regPayTimeDiff',
|
|
|
+ align: 'center',
|
|
|
+ width: 140,
|
|
|
+ default: 30,
|
|
|
+ render: (a: string, b: any) => {
|
|
|
+ if (b?.payTime) {
|
|
|
+ let diff = new Date(b.payTime).getTime() - new Date(b.regTime).getTime()
|
|
|
+ function secondsToDhms(seconds: any) {
|
|
|
+ const days = Math.floor(seconds / (3600 * 24));
|
|
|
+ const hours = Math.floor((seconds % (3600 * 24)) / 3600);
|
|
|
+ const minutes = Math.floor((seconds % 3600) / 60);
|
|
|
+ const remainingSeconds = seconds % 60;
|
|
|
+ return `${days ? days + "天" : ''}${hours ? hours + "小时" : ''}${minutes ? minutes + "分" : ''}${remainingSeconds ? remainingSeconds + "秒" : ''}`
|
|
|
+ }
|
|
|
+ return diff ? secondsToDhms(diff / 1000) : '--'
|
|
|
+ } else {
|
|
|
+ return '--'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '最近充值时间距今',
|
|
|
+ dataIndex: 'nowPayTimeDiff',
|
|
|
+ align: 'center',
|
|
|
+ width: 130,
|
|
|
+ default: 31,
|
|
|
+ render: (a: string, b: any) => {
|
|
|
+ if (b?.payTime) {
|
|
|
+ let diff = new Date().getTime() - new Date(b.payTime).getTime()
|
|
|
+ function secondsToDhms(seconds: any) {
|
|
|
+ const days = Math.floor(seconds / (3600 * 24));
|
|
|
+ const hours = Math.floor((seconds % (3600 * 24)) / 3600);
|
|
|
+ const minutes = Math.floor((seconds % 3600) / 60);
|
|
|
+ const remainingSeconds = seconds % 60;
|
|
|
+ return `${days ? days + "天" : ''}${hours ? hours + "小时" : ''}${minutes ? minutes + "分" : ''}${remainingSeconds ? remainingSeconds.toFixed(0) + "秒" : ''}`
|
|
|
+ }
|
|
|
+ return diff ? secondsToDhms(diff / 1000) : '--'
|
|
|
+ } else {
|
|
|
+ return '--'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '支付状态', dataIndex: 'orderStatus', label: '订单明细', align: 'center', width: 85, default: 32,
|
|
|
render: (a: string, b: any) => {
|
|
|
return PayStatus[a]
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
- title: '是否首充', dataIndex: 'isFirstRecharge', label: '订单明细', align: 'center', width: 45, default: 31,
|
|
|
+ title: '是否首充', dataIndex: 'isFirstRecharge', label: '订单明细', align: 'center', width: 45, default: 33,
|
|
|
render: (a: any) => {
|
|
|
return a == 1 ? '是' : '否'
|
|
|
}
|