import { Component, computed, inject } from '@angular/core';
import { PartnerLicenseInfoTemplateComponent } from '../components/licenseInfo/license-info-template.component';
import { PartnerInfoStore } from '../store/main.store';

@Component({
  selector: 'partner-dashboard',
  templateUrl: './index.component.html',
  imports: [PartnerLicenseInfoTemplateComponent],
})
export class DashboardComponent {
  private readonly store = inject(PartnerInfoStore);

  readonly loading = computed(() => this.store.loading());
  readonly entity = computed(() => this.store.entity());
  readonly error = computed(() => this.store.error());

  ngOnInit() {
    this.store.getData();
  }
}
