edit
This commit is contained in:
@ -1,12 +1,7 @@
|
||||
<page-header-wrapper [title]="'开票订单明细'" [logo]="logo">
|
||||
<ng-template #logo>
|
||||
<button nz-button nz-tooltip nzTooltipTitle="返回上一页" (click)="goBack()">
|
||||
<i nz-icon nzType="left" nzTheme="outline"></i>
|
||||
</button>
|
||||
</ng-template>
|
||||
<page-header-wrapper [title]="'充值记录'">
|
||||
</page-header-wrapper>
|
||||
|
||||
<nz-card>
|
||||
<!-- <nz-card>
|
||||
<nz-row [nzGutter]="16">
|
||||
<nz-col [nzXl]="7" [nzLg]="8" [nzSm]="12">
|
||||
<nz-statistic nzValue="100 笔" [nzTitle]="'累计充值订单数'"
|
||||
@ -18,7 +13,7 @@
|
||||
</nz-statistic>
|
||||
</nz-col>
|
||||
</nz-row>
|
||||
</nz-card>
|
||||
</nz-card> -->
|
||||
|
||||
<nz-card class="search-box" nzBordered>
|
||||
<div nz-row nzGutter="8">
|
||||
@ -27,11 +22,11 @@
|
||||
[ui]="{ '*': { spanLabelFixed: 90,grid: { lg: 8, md: 12, sm: 12, xs: 24 } }}" [compact]="true"
|
||||
[button]="'none'"></sf>
|
||||
</div>
|
||||
<div nz-col [nzXl]="_$expand ? 24 : 6" [nzLg]="24" [nzSm]="24" [nzXs]="24"
|
||||
<div nz-col [nzXl]="_$expand ? 24 : 6" [nzLg]="24" [nzSm]="24" [nzXs]="24" [class.expend-options]="_$expand"
|
||||
class="text-right">
|
||||
<button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)">查询</button>
|
||||
<button nz-button (click)="resetSF()">重置</button>
|
||||
<button nz-button> 导出</button>
|
||||
<button nz-button (click)="exportList()"> 导出</button>
|
||||
<button nz-button nzType="link" (click)="expandToggle()">
|
||||
{{ !_$expand ? '展开' : '收起' }}
|
||||
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
|
||||
@ -41,9 +36,9 @@
|
||||
</nz-card>
|
||||
|
||||
<nz-card class="content-box" nzBordered>
|
||||
<st #st [data]="url" [columns]="columns"
|
||||
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
|
||||
<st #st [data]="service.$mock_url" [columns]="columns"
|
||||
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams, process: beforeReq }"
|
||||
[res]="{ reName: { list: 'data.records', total: 'data.total' } }"
|
||||
[page]="{ show: true, showSize: true, pageSizes: [10, 20, 30, 50, 100, 200, 300, 500, 1000] }"
|
||||
[loading]="service.http.loading" [scroll]="{ x:'1200px',y: '300px' }" (change)="stChange($event)"></st>
|
||||
[loading]="service.http.loading" [scroll]="{ x:'1200px',y: '400px' }"></st>
|
||||
</nz-card>
|
||||
@ -15,3 +15,18 @@
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.expend-options {
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
|
||||
@media (min-width: 1200px) {
|
||||
.expend-options {
|
||||
max-width : 400px;
|
||||
position : absolute;
|
||||
right : 0;
|
||||
bottom : 25px;
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,7 +1,8 @@
|
||||
import { Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { STComponent, STColumn, STChange } from '@delon/abc/st';
|
||||
import { STComponent, STColumn, STChange, STRequestOptions } from '@delon/abc/st';
|
||||
import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form';
|
||||
import { TicketService } from 'src/app/routes/ticket-management/services/system.service';
|
||||
import { FreightAccountService } from '../../services/freight-account.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-recharge-record',
|
||||
@ -9,131 +10,25 @@ import { TicketService } from 'src/app/routes/ticket-management/services/system.
|
||||
styleUrls: ['./recharge-record.component.less']
|
||||
})
|
||||
export class RechargeRecordComponent implements OnInit {
|
||||
url = `/rule?_allow_anonymous=true`;
|
||||
@ViewChild('st', { static: true })
|
||||
st!: STComponent;
|
||||
@ViewChild('sf', { static: false })
|
||||
sf!: SFComponent;
|
||||
columns: STColumn[] = [
|
||||
{ title: '充值时间', index: 'updatedAt', type: 'date' },
|
||||
{ title: '充值单号', index: 'callNo' },
|
||||
{ title: '账户主体', index: 'callNo' },
|
||||
{ title: '账户名称', index: 'callNo' },
|
||||
{ title: '虚拟账户', index: 'callNo' },
|
||||
{ title: '账户类型', index: 'callNo' },
|
||||
{ title: '充值金额', index: 'callNo' },
|
||||
{ title: '充值方式', index: 'callNo' },
|
||||
{ title: '充值状态', index: 'callNo' },
|
||||
{ title: '银行流水号', index: 'callNo' }
|
||||
];
|
||||
searchSchema: SFSchema = {
|
||||
properties: {
|
||||
expand: {
|
||||
type: 'boolean',
|
||||
ui: {
|
||||
hidden: true
|
||||
}
|
||||
},
|
||||
orderSn2: {
|
||||
type: 'string',
|
||||
title: '充值单号',
|
||||
ui: {
|
||||
placeholder: '请输入',
|
||||
autocomplete: 'off'
|
||||
}
|
||||
},
|
||||
receiveName: {
|
||||
type: 'string',
|
||||
title: '充值状态',
|
||||
enum: [
|
||||
{ label: '全部', value: '' },
|
||||
{ label: '充值中', value: '充值中' },
|
||||
{ label: '已完成', value: '已完成' }
|
||||
],
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
change: (i: any) => {
|
||||
this.sf.value.receiveName = i;
|
||||
this.sf?.setValue('/receiveName', i);
|
||||
}
|
||||
},
|
||||
default: ''
|
||||
},
|
||||
createTime: {
|
||||
title: '充值时间',
|
||||
type: 'string',
|
||||
ui: {
|
||||
widget: 'date',
|
||||
mode: 'range',
|
||||
format: 'yyyy-MM-dd'
|
||||
} as SFDateWidgetSchema
|
||||
},
|
||||
orderSn3: {
|
||||
type: 'string',
|
||||
title: '账户名称',
|
||||
ui: {
|
||||
placeholder: '请输入',
|
||||
autocomplete: 'off',
|
||||
visibleIf: {
|
||||
expand: (value: boolean) => value
|
||||
}
|
||||
}
|
||||
},
|
||||
receiveName2: {
|
||||
type: 'string',
|
||||
title: '账户类型',
|
||||
enum: [
|
||||
{ label: '全部', value: '' },
|
||||
{ label: '个人', value: '个人' },
|
||||
{ label: '企业', value: '企业' }
|
||||
],
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
change: (i: any) => {
|
||||
this.sf.value.receiveName2 = i;
|
||||
this.sf?.setValue('/receiveName2', i);
|
||||
},
|
||||
visibleIf: {
|
||||
expand: (value: boolean) => value
|
||||
}
|
||||
},
|
||||
default: ''
|
||||
},
|
||||
receiveName4: {
|
||||
type: 'string',
|
||||
title: '账户主体',
|
||||
enum: [{ label: '全部', value: '' }],
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
change: (i: any) => {
|
||||
this.sf.value.receiveName4 = i;
|
||||
this.sf?.setValue('/receiveName4', i);
|
||||
},
|
||||
visibleIf: {
|
||||
expand: (value: boolean) => value
|
||||
}
|
||||
},
|
||||
default: ''
|
||||
}
|
||||
}
|
||||
};
|
||||
columns: STColumn[] = this.initST();
|
||||
searchSchema: SFSchema = this.initSF();
|
||||
|
||||
reqParams = {};
|
||||
_$expand = false;
|
||||
constructor(public service: TicketService) {}
|
||||
constructor(public service: FreightAccountService) {}
|
||||
|
||||
ngOnInit(): void {}
|
||||
|
||||
stChange(e: STChange): void {
|
||||
switch (e.type) {
|
||||
case 'filter':
|
||||
this.st.load();
|
||||
break;
|
||||
beforeReq = (requestOptions: STRequestOptions) => {
|
||||
if (this.sf) {
|
||||
this.reqParams = { ...this.sf.value };
|
||||
}
|
||||
}
|
||||
return requestOptions;
|
||||
};
|
||||
|
||||
goBack() {
|
||||
history.go(-1);
|
||||
@ -154,4 +49,124 @@ export class RechargeRecordComponent implements OnInit {
|
||||
this._$expand = !this._$expand;
|
||||
this.sf?.setValue('/expand', this._$expand);
|
||||
}
|
||||
|
||||
exportList() {
|
||||
this.service.downloadFile(this.service.$mock_url, { ...this.sf.value, pageIndex: this.st.pi, pageSize: this.st.ps });
|
||||
}
|
||||
|
||||
private initSF(): SFSchema {
|
||||
return {
|
||||
properties: {
|
||||
expand: {
|
||||
type: 'boolean',
|
||||
ui: {
|
||||
hidden: true
|
||||
}
|
||||
},
|
||||
orderSn2: {
|
||||
type: 'string',
|
||||
title: '充值单号',
|
||||
ui: {
|
||||
placeholder: '请输入'
|
||||
}
|
||||
},
|
||||
receiveName: {
|
||||
type: 'string',
|
||||
title: '充值状态',
|
||||
enum: [
|
||||
{ label: '全部', value: '' },
|
||||
{ label: '充值中', value: '充值中' },
|
||||
{ label: '已完成', value: '已完成' }
|
||||
],
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
change: (i: any) => {
|
||||
this.sf.value.receiveName = i;
|
||||
this.sf?.setValue('/receiveName', i);
|
||||
}
|
||||
},
|
||||
default: ''
|
||||
},
|
||||
createTime: {
|
||||
title: '充值时间',
|
||||
type: 'string',
|
||||
ui: {
|
||||
widget: 'date',
|
||||
mode: 'range',
|
||||
format: 'yyyy-MM-dd'
|
||||
} as SFDateWidgetSchema
|
||||
},
|
||||
orderSn3: {
|
||||
type: 'string',
|
||||
title: '账户名称',
|
||||
ui: {
|
||||
placeholder: '请输入',
|
||||
autocomplete: 'off',
|
||||
visibleIf: {
|
||||
expand: (value: boolean) => value
|
||||
}
|
||||
}
|
||||
},
|
||||
receiveName2: {
|
||||
type: 'string',
|
||||
title: '账户类型',
|
||||
enum: [
|
||||
{ label: '全部', value: '' },
|
||||
{ label: '货主账户', value: '货主账户' },
|
||||
{ label: '司机账户', value: '司机账户' }
|
||||
],
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
change: (i: any) => {
|
||||
this.sf.value.receiveName2 = i;
|
||||
this.sf?.setValue('/receiveName2', i);
|
||||
},
|
||||
visibleIf: {
|
||||
expand: (value: boolean) => value
|
||||
}
|
||||
},
|
||||
default: ''
|
||||
},
|
||||
page2: {
|
||||
type: 'string',
|
||||
title: '网络货运人',
|
||||
enum: [{ label: '全部', value: '全部' }],
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
visibleIf: {
|
||||
expand: (value: boolean) => value
|
||||
}
|
||||
}
|
||||
},
|
||||
orderSn23: {
|
||||
type: 'string',
|
||||
title: '银行类型',
|
||||
ui: {
|
||||
placeholder: '请输入',
|
||||
visibleIf: {
|
||||
expand: (value: boolean) => value
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private initST(): STColumn[] {
|
||||
return [
|
||||
{ title: '充值时间', index: 'updatedAt', type: 'date' },
|
||||
{ title: '充值单号', index: 'callNo' },
|
||||
{ title: '账户主体', index: 'callNo' },
|
||||
{ title: '账户名称', index: 'callNo' },
|
||||
{ title: '虚拟账户', index: 'callNo' },
|
||||
{ title: '账户类型', index: 'callNo' },
|
||||
{ title: '充值金额', index: 'callNo' },
|
||||
{ title: '充值方式', index: 'callNo' },
|
||||
{ title: '充值状态', index: 'callNo' },
|
||||
{ title: '银行流水号', index: 'callNo' }
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user