| 123456789101112131415161718192021222324 |
- using Domain.Entities.Stocks;
- using Microsoft.EntityFrameworkCore;
- using Microsoft.EntityFrameworkCore.Metadata.Builders;
- namespace Infrastructure.Persistence.Configurations.Stocks;
- public sealed class ListingChangeEventConfiguration : IEntityTypeConfiguration<ListingChangeEvent>
- {
- public void Configure(EntityTypeBuilder<ListingChangeEvent> builder)
- {
- builder.ToTable(nameof(ListingChangeEvent), t => t.HasComment("SEIBro 주식 상장(유통형태 변경) 정보 (getStkListInfo) — 월 윈도우 스윕, 적용일 기준 window delete+insert"));
- builder.HasKey(x => x.ID);
- builder.HasIndex(x => new { x.Isin, x.ApliDt, x.BfaltCirclForm, x.AfaltCirclForm }).IsUnique();
- builder.HasIndex(x => x.ApliDt);
- builder.Property(x => x.IssucoCustno).HasComment("발행회사 고객번호 (ISSUCO_CUSTNO)");
- builder.Property(x => x.Isin).HasMaxLength(12).IsFixedLength().IsRequired().HasComment("종목코드 (ISIN)");
- builder.Property(x => x.ShotnIsin).HasMaxLength(12).IsRequired().HasComment("단축코드 (SHOTN_ISIN)");
- builder.Property(x => x.KorSecnNm).HasMaxLength(150).IsRequired().HasComment("종목명 (KOR_SECN_NM)");
- builder.Property(x => x.BfaltCirclForm).HasMaxLength(3).HasComment("변경전 유통형태 (BFALT_CIRCL_FORM)");
- builder.Property(x => x.AfaltCirclForm).HasMaxLength(3).HasComment("변경후 유통형태 (AFALT_CIRCL_FORM)");
- builder.Property(x => x.ApliDt).IsRequired().HasComment("변경(적용)일자 (APLI_DT)");
- }
- }
|