mirror of
https://github.com/akveo/ngx-admin.git
synced 2026-02-22 16:04:08 +01:00
fix(Billing): Fixing bug billing
This commit is contained in:
parent
42707efc24
commit
311885894f
9 changed files with 183 additions and 104 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import { Component, OnInit } from '@angular/core';
|
||||
import { Component, OnInit, ChangeDetectorRef } from '@angular/core';
|
||||
import { BillingList } from '../../@core/data/billing';
|
||||
import { BillingService } from './billing.service';
|
||||
import { BillingDetailComponent } from './billing-detail/billing-detail.component';
|
||||
|
|
@ -10,9 +10,11 @@ import { NbWindowService } from '@nebular/theme';
|
|||
styleUrls: ['./billing.component.scss'],
|
||||
})
|
||||
export class BillingComponent implements OnInit {
|
||||
|
||||
settings = {
|
||||
mode: 'inline',
|
||||
actions: {
|
||||
add: false,
|
||||
},
|
||||
add: {
|
||||
addButtonContent: '<i class="nb-plus"></i>',
|
||||
createButtonContent: '<i class="nb-checkmark"></i>',
|
||||
|
|
@ -45,7 +47,9 @@ export class BillingComponent implements OnInit {
|
|||
|
||||
source: BillingList[] = [];
|
||||
|
||||
constructor(private service: BillingService, private windowService: NbWindowService) {
|
||||
constructor(private service: BillingService, private windowService: NbWindowService, private changeDetectorRefs: ChangeDetectorRef) {
|
||||
console.log('masuk cons')
|
||||
this.initData();
|
||||
}
|
||||
|
||||
ngOnInit(): void {
|
||||
|
|
@ -54,7 +58,8 @@ export class BillingComponent implements OnInit {
|
|||
initData(){
|
||||
this.service.getBilling().subscribe((result) => {
|
||||
this.source = Object.assign([], result);
|
||||
console.log('test', result);
|
||||
console.log('hasil', result);
|
||||
this.changeDetectorRefs.detectChanges();
|
||||
});
|
||||
}
|
||||
onCreateConfirm(event) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue