edit
This commit is contained in:
@ -2,7 +2,10 @@ import { Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { Router } from '@angular/router';
|
||||
import { STComponent, STColumn, STChange } from '@delon/abc/st';
|
||||
import { SFComponent, SFSchema, SFDateWidgetSchema } from '@delon/form';
|
||||
import { NzModalService } from 'ng-zorro-antd/modal';
|
||||
import { SystemStaffStaffModalComponent } from 'src/app/routes/sys-setting/components/staff-management/staff-modal/staff-modal.component';
|
||||
import { SystemService } from 'src/app/routes/sys-setting/services/system.service';
|
||||
import { SettingFinancialComponent } from './setting-financial/setting-financial.component';
|
||||
|
||||
@Component({
|
||||
selector: 'app-main-account',
|
||||
@ -53,7 +56,7 @@ export class MainAccountComponent implements OnInit {
|
||||
buttons: [
|
||||
{
|
||||
text: '财务设置',
|
||||
click: item => this.routeTo(item)
|
||||
click: item => this.settingFinanical(item)
|
||||
},
|
||||
{
|
||||
text: '合同设置',
|
||||
@ -64,7 +67,7 @@ export class MainAccountComponent implements OnInit {
|
||||
];
|
||||
reqParams = { pageIndex: 1, pageSize: 10 };
|
||||
|
||||
constructor(public service: SystemService, private router: Router) {}
|
||||
constructor(public service: SystemService, private router: Router, private nzModalService: NzModalService) {}
|
||||
|
||||
ngOnInit(): void {}
|
||||
|
||||
@ -76,6 +79,17 @@ export class MainAccountComponent implements OnInit {
|
||||
}
|
||||
}
|
||||
|
||||
settingFinanical(item: any) {
|
||||
const modal = this.nzModalService.create({
|
||||
nzContent: SettingFinancialComponent,
|
||||
nzComponentParams: item ? { i: { ...item, roleId: '1,2,3', name: '用户名', phone: 18555555555 } } : { i: { id: 0 } },
|
||||
nzFooter: null
|
||||
});
|
||||
modal.afterClose.subscribe(res => {
|
||||
this.st.load();
|
||||
});
|
||||
}
|
||||
|
||||
routeTo(item?: any) {
|
||||
this.router.navigate(['/financial-management/driver-account-detail/1']);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user