diff --git a/src/app/accounting/accounting-routing.module.ts b/src/app/accounting/accounting-routing.module.ts index 980396ba5..9085722e1 100644 --- a/src/app/accounting/accounting-routing.module.ts +++ b/src/app/accounting/accounting-routing.module.ts @@ -23,6 +23,7 @@ import { EditGlAccountComponent } from './chart-of-accounts/edit-gl-account/edit import { ClosingEntriesComponent } from './closing-entries/closing-entries.component'; import { CreateClosureComponent } from './closing-entries/create-closure/create-closure.component'; +import { ViewClosureComponent } from './closing-entries/view-closure/view-closure.component'; const routes: Routes = [ Route.withShell([ @@ -142,6 +143,11 @@ const routes: Routes = [ path: 'create', component: CreateClosureComponent, data: { title: extract('Create Accounting Closure'), breadcrumb: 'Create' } + }, + { + path: 'view/:id', + component: ViewClosureComponent, + data: { title: extract('View Accounting Closure'), routeParamBreadcrumb: 'id' } } ] } diff --git a/src/app/accounting/accounting.module.ts b/src/app/accounting/accounting.module.ts index 5a812e1ba..6279c5e93 100644 --- a/src/app/accounting/accounting.module.ts +++ b/src/app/accounting/accounting.module.ts @@ -22,6 +22,7 @@ import { ViewGlAccountComponent } from './chart-of-accounts/view-gl-account/view import { EditGlAccountComponent } from './chart-of-accounts/edit-gl-account/edit-gl-account.component'; import { ClosingEntriesComponent } from './closing-entries/closing-entries.component'; import { CreateClosureComponent } from './closing-entries/create-closure/create-closure.component'; +import { ViewClosureComponent } from './closing-entries/view-closure/view-closure.component'; @NgModule({ imports: [ @@ -48,7 +49,8 @@ import { CreateClosureComponent } from './closing-entries/create-closure/create- ViewGlAccountComponent, EditGlAccountComponent, ClosingEntriesComponent, - CreateClosureComponent + CreateClosureComponent, + ViewClosureComponent ], entryComponents: [ RevertTransactionComponent, diff --git a/src/app/accounting/accounting.service.ts b/src/app/accounting/accounting.service.ts index 0c9eff787..2a9ac90b0 100644 --- a/src/app/accounting/accounting.service.ts +++ b/src/app/accounting/accounting.service.ts @@ -129,4 +129,8 @@ export class AccountingService { return this.http.post('/glclosures', accountingClosure); } + getAccountingClosure(accountingClosureId: number) { + return this.http.get(`/glclosures/${accountingClosureId}`); + } + } diff --git a/src/app/accounting/closing-entries/closing-entries.component.html b/src/app/accounting/closing-entries/closing-entries.component.html index 7d887986e..2b5040553 100644 --- a/src/app/accounting/closing-entries/closing-entries.component.html +++ b/src/app/accounting/closing-entries/closing-entries.component.html @@ -44,7 +44,7 @@