init to pos domain
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
import { PageLoadingComponent } from '@/shared/components/page-loading.component';
|
||||
import { Component, computed, inject } from '@angular/core';
|
||||
import { RouterOutlet } from '@angular/router';
|
||||
import { PosStore } from '../pos.store';
|
||||
|
||||
@Component({
|
||||
selector: 'pos-layout',
|
||||
templateUrl: './layout.component.html',
|
||||
imports: [PageLoadingComponent, RouterOutlet],
|
||||
})
|
||||
export class PosLayoutComponent {
|
||||
constructor() {}
|
||||
|
||||
private readonly store = inject(PosStore);
|
||||
|
||||
readonly loading = computed(() => this.store.loading());
|
||||
readonly posInfo = computed(() => this.store.entity());
|
||||
|
||||
getData() {
|
||||
this.store.getData();
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.getData();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user