Feature: Lazy loading
Lazy loaded everything TODO: The cash flow module when clicking on sub-links, it reloads the whole page, it needs to be diagnosed and fixed, this problem also exists in the other modules TODO: Rename folders and modules such as account to accounts to match the url
This commit is contained in:
@@ -4,9 +4,9 @@ import { MatDialog } from '@angular/material/dialog';
|
||||
import {ActivatedRoute, Router} from '@angular/router';
|
||||
import {BehaviorSubject, Observable} from 'rxjs';
|
||||
import {IncentiveDataSource} from './incentive-datasource';
|
||||
import {Account} from '../account/account';
|
||||
import {VoucherService} from '../journal/voucher.service';
|
||||
import {Incentive, Voucher} from '../journal/voucher';
|
||||
import {Account} from '../core/account';
|
||||
import {VoucherService} from '../core/voucher.service';
|
||||
import {Incentive, Voucher} from '../core/voucher';
|
||||
import * as moment from 'moment';
|
||||
import {AuthService} from '../auth/auth.service';
|
||||
import {ConfirmDialogComponent} from '../shared/confirm-dialog/confirm-dialog.component';
|
||||
@@ -145,7 +145,7 @@ export class IncentiveComponent implements OnInit {
|
||||
.subscribe(
|
||||
(result) => {
|
||||
this.toaster.show('Success', '');
|
||||
this.router.navigate(['/Incentive', result.id]);
|
||||
this.router.navigate(['/incentive', result.id]);
|
||||
},
|
||||
(error) => {
|
||||
this.toaster.show('Danger', error.error);
|
||||
@@ -169,7 +169,7 @@ export class IncentiveComponent implements OnInit {
|
||||
.subscribe(
|
||||
(result) => {
|
||||
this.toaster.show('Success', '');
|
||||
this.router.navigate(['/Incentive'], {replaceUrl: true});
|
||||
this.router.navigate(['/incentive'], {replaceUrl: true});
|
||||
},
|
||||
(error) => {
|
||||
this.toaster.show('Danger', error.error);
|
||||
|
||||
Reference in New Issue
Block a user