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:
Amritanshu
2019-06-12 19:34:50 +05:30
parent fea48e1a3e
commit 72044476a8
184 changed files with 786 additions and 664 deletions

View File

@ -7,7 +7,7 @@ import {ProductLedgerComponent} from './product-ledger.component';
const productLedgerRoutes: Routes = [
{
path: 'ProductLedger',
path: '',
component: ProductLedgerComponent,
canActivate: [AuthGuard],
data: {
@ -19,7 +19,7 @@ const productLedgerRoutes: Routes = [
runGuardsAndResolvers: 'always'
},
{
path: 'ProductLedger/:id',
path: ':id',
component: ProductLedgerComponent,
canActivate: [AuthGuard],
data: {

View File

@ -10,7 +10,7 @@ import * as moment from 'moment';
import {ProductLedgerDataSource} from './product-ledger-datasource';
import {ProductLedger} from './product-ledger';
import {ProductLedgerService} from './product-ledger.service';
import {Product} from '../product/product';
import {Product} from '../core/product';
import {ProductService} from '../product/product.service';
@Component({
@ -108,7 +108,7 @@ export class ProductLedgerComponent implements OnInit {
show() {
const l = this.prepareSubmit();
this.router.navigate(['ProductLedger', l.product.id], {
this.router.navigate(['product-ledger', l.product.id], {
queryParams: {
startDate: l.startDate,
finishDate: l.finishDate

View File

@ -9,7 +9,7 @@ const httpOptions = {
headers: new HttpHeaders({'Content-Type': 'application/json'})
};
const url = '/api/ProductLedger';
const url = '/api/product-ledger';
const serviceName = 'ProductLedgerService';
@Injectable({

View File

@ -1,4 +1,4 @@
import {Product} from '../product/product';
import {Product} from '../core/product';
export class ProductLedgerItem {
date: string;