using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Microsoft.EntityFrameworkCore;

namespace Strata.Code.DataAccess.Models;

[Table("SpreadHistory", Schema = "fp")]
public partial class SpreadHistory
{
    [Key]
    [Column("SpreadHistoryGUID")]
    public Guid SpreadHistoryGuid { get; set; }

    [Column(TypeName = "datetime")]
    public DateTime Date { get; set; }

    [Column("AuthorGUID")]
    public Guid AuthorGuid { get; set; }

    public string AuthorFullName { get; set; } = null!;

    public byte[]? ExcelFile { get; set; }

    [InverseProperty("SpreadHistory")]
    public virtual ICollection<BenefitsSpread> BenefitsSpreads { get; set; } = new List<BenefitsSpread>();

    [InverseProperty("SpreadHistory")]
    public virtual ICollection<ChargeVolumeSpread> ChargeVolumeSpreads { get; set; } = new List<ChargeVolumeSpread>();

    [InverseProperty("SpreadHistory")]
    public virtual ICollection<GeneralLedgerSpread> GeneralLedgerSpreads { get; set; } = new List<GeneralLedgerSpread>();

    [InverseProperty("SpreadHistory")]
    public virtual ICollection<ProviderCompensationSpread> ProviderCompensationSpreads { get; set; } = new List<ProviderCompensationSpread>();

    [InverseProperty("SpreadHistory")]
    public virtual ICollection<ServiceLineEncounterSpread> ServiceLineEncounterSpreads { get; set; } = new List<ServiceLineEncounterSpread>();

    [InverseProperty("SpreadHistory")]
    public virtual ICollection<StaffingSpread> StaffingSpreads { get; set; } = new List<StaffingSpread>();

    [InverseProperty("SpreadHistory")]
    public virtual ICollection<StatisticsSpread> StatisticsSpreads { get; set; } = new List<StatisticsSpread>();
}
