mirror of
https://gitee.com/dotnetchina/OpenAuth.Net.git
synced 2025-07-17 19:37:45 +08:00
28 lines
890 B
C#
28 lines
890 B
C#
using System.Data.Entity.ModelConfiguration;
|
|
using OpenAuth.Domain;
|
|
|
|
namespace OpenAuth.Repository.Models.Mapping
|
|
{
|
|
public class sysdiagramMap : EntityTypeConfiguration<sysdiagram>
|
|
{
|
|
public sysdiagramMap()
|
|
{
|
|
// Primary Key
|
|
this.HasKey(t => t.diagram_id);
|
|
|
|
// Properties
|
|
this.Property(t => t.name)
|
|
.IsRequired()
|
|
.HasMaxLength(128);
|
|
|
|
// Table & Column Mappings
|
|
this.ToTable("sysdiagrams");
|
|
this.Property(t => t.name).HasColumnName("name");
|
|
this.Property(t => t.principal_id).HasColumnName("principal_id");
|
|
this.Property(t => t.diagram_id).HasColumnName("diagram_id");
|
|
this.Property(t => t.version).HasColumnName("version");
|
|
this.Property(t => t.definition).HasColumnName("definition");
|
|
}
|
|
}
|
|
}
|