[성현모] CPMeta DB 추가

This commit is contained in:
SHM
2025-10-30 10:43:27 +09:00
parent 29ea311cd3
commit 24a2eed617
12 changed files with 551 additions and 0 deletions

View File

@ -0,0 +1,35 @@
using System;
using System.Collections.Generic;
using Microsoft.EntityFrameworkCore;
namespace SystemX.Core.DB;
public partial class CPMetaContext : DbContext
{
public CPMetaContext(DbContextOptions<CPMetaContext> options)
: base(options)
{
}
public virtual DbSet<tWbmsMetum> tWbmsMeta { get; set; }
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
modelBuilder.Entity<tWbmsMetum>(entity =>
{
entity.HasKey(e => e.cProductID).HasName("PK_cProductKey");
entity.HasIndex(e => e.cMacAddress, "UQ_cMacAddress").IsUnique();
entity.Property(e => e.cProductID).HasMaxLength(50);
entity.Property(e => e.cMacAddress).HasMaxLength(50);
entity.Property(e => e.cProductNo).HasMaxLength(50);
entity.Property(e => e.cSpareValue).HasMaxLength(200);
entity.Property(e => e.cType).HasMaxLength(20);
});
OnModelCreatingPartial(modelBuilder);
}
partial void OnModelCreatingPartial(ModelBuilder modelBuilder);
}

View File

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
namespace SystemX.Core.DB;
public partial class tWbmsMetum
{
public string cProductID { get; set; } = null!;
public string? cMacAddress { get; set; }
public string? cType { get; set; }
public string? cProductNo { get; set; }
public string? cSpareValue { get; set; }
public DateTime cDateTime { get; set; }
}