import { IResilientEntity } from 'app/resilient/resilient-base/resilient-base.model';
import { DashboardComponentType } from 'app/entities/enumerations/dashboard-component-type.model';
import { DashboardComponentChartType } from 'app/entities/enumerations/dashboard-component-chart-type.model';
import { DashboardComponentView } from 'app/entities/enumerations/dashboard-component-view.model';

import { IDashboardComponentDetail } from './dashboard-component-detail.model'; 
import { IDashboardComponentOrganization } from './dashboard-component-organization.model';

export interface IDashboardComponent extends IResilientEntity {
  code?: string | null;
  name?: string | null;
  description?: string | null;
  isActive?: boolean | null;
  isExportable?: boolean | null;
  type?: keyof typeof DashboardComponentType | null;
  view?: keyof typeof DashboardComponentView | null;
  chartType?: keyof typeof DashboardComponentChartType | null;
  dashboardComponentDetails?: IDashboardComponentDetail[] | null;
  dashboardComponentOrganizations?: IDashboardComponentOrganization[] | null;
}

export type NewDashboardComponent = Omit<IDashboardComponent, 'id'> & { id: null };
