123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751 |
- using System;
- using Microsoft.EntityFrameworkCore;
- using Microsoft.EntityFrameworkCore.Metadata;
- #nullable disable
- namespace YLShipBuildLandMap.Entity
- {
- public partial class YLShipBuildLandMapContext : DbContext
- {
- public YLShipBuildLandMapContext()
- {
- }
- public YLShipBuildLandMapContext(DbContextOptions<YLShipBuildLandMapContext> options)
- : base(options)
- {
- }
- public virtual DbSet<BackBdBuildingXyAxis> BackBdBuildingXyAxis { get; set; }
- public virtual DbSet<BdBuilding> BdBuilding { get; set; }
- public virtual DbSet<BdBuildingFloor> BdBuildingFloor { get; set; }
- public virtual DbSet<BdBuildingFloorRoom> BdBuildingFloorRoom { get; set; }
- public virtual DbSet<BdBuildingXyAxis> BdBuildingXyAxis { get; set; }
- public virtual DbSet<BdDepartmentOrServicePoint> BdDepartmentOrServicePoint { get; set; }
- public virtual DbSet<BdDepartmentOrServicePointBmBuildingFloorRoom> BdDepartmentOrServicePointBmBuildingFloorRoom { get; set; }
- public virtual DbSet<SysAnnouncement> SysAnnouncement { get; set; }
- public virtual DbSet<SysAnnouncementSysRole> SysAnnouncementSysRole { get; set; }
- public virtual DbSet<SysAnnouncementSysUser> SysAnnouncementSysUser { get; set; }
- public virtual DbSet<SysApiScope> SysApiScope { get; set; }
- public virtual DbSet<SysAttachment> SysAttachment { get; set; }
- public virtual DbSet<SysDictionary> SysDictionary { get; set; }
- public virtual DbSet<SysDictionaryItem> SysDictionaryItem { get; set; }
- public virtual DbSet<SysFunctionCode> SysFunctionCode { get; set; }
- public virtual DbSet<SysLog> SysLog { get; set; }
- public virtual DbSet<SysMenu> SysMenu { get; set; }
- public virtual DbSet<SysNoticeHistory> SysNoticeHistory { get; set; }
- public virtual DbSet<SysParameter> SysParameter { get; set; }
- public virtual DbSet<SysRole> SysRole { get; set; }
- public virtual DbSet<SysRoleSysFunctionCode> SysRoleSysFunctionCode { get; set; }
- public virtual DbSet<SysSerialNumber> SysSerialNumber { get; set; }
- public virtual DbSet<SysSystem> SysSystem { get; set; }
- public virtual DbSet<SysSystemSysApiScope> SysSystemSysApiScope { get; set; }
- public virtual DbSet<SysUser> SysUser { get; set; }
- public virtual DbSet<SysUserSysRole> SysUserSysRole { get; set; }
- public virtual DbSet<数据导入> 数据导入 { get; set; }
- protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
- {
- if (!optionsBuilder.IsConfigured)
- {
- #warning To protect potentially sensitive information in your connection string, you should move it out of source code. You can avoid scaffolding the connection string by using the Name= syntax to read it from configuration - see https://go.microsoft.com/fwlink/?linkid=2131148. For more guidance on storing connection strings, see http://go.microsoft.com/fwlink/?LinkId=723263.
- optionsBuilder.UseSqlServer("Server=192.168.0.66\\sql2012;User Id=sa;Password=Bowin2023!;Database=YLShipBuildLandMap");
- }
- }
- protected override void OnModelCreating(ModelBuilder modelBuilder)
- {
- modelBuilder.HasAnnotation("Relational:Collation", "Chinese_PRC_CI_AS");
- modelBuilder.Entity<BackBdBuildingXyAxis>(entity =>
- {
- entity.HasNoKey();
- entity.ToTable("back_BD_Building_XY_Axis");
- entity.Property(e => e.BuildingId).HasColumnName("BuildingID");
- entity.Property(e => e.Xaxis)
- .HasColumnType("decimal(18, 8)")
- .HasColumnName("XAxis");
- entity.Property(e => e.XyaxisId).HasColumnName("XYAxisID");
- entity.Property(e => e.Yaxis)
- .HasColumnType("decimal(18, 8)")
- .HasColumnName("YAxis");
- });
- modelBuilder.Entity<BdBuilding>(entity =>
- {
- entity.HasKey(e => e.BuildingId)
- .HasName("PK_BD_BUILDING");
- entity.ToTable("BD_Building");
- entity.Property(e => e.BuildingId)
- .ValueGeneratedNever()
- .HasColumnName("BuildingID");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.Name).HasMaxLength(300);
- });
- modelBuilder.Entity<BdBuildingFloor>(entity =>
- {
- entity.HasKey(e => e.BuildingFloorId)
- .HasName("PK_BD_BUILDING_FLOOR");
- entity.ToTable("BD_Building_Floor");
- entity.Property(e => e.BuildingFloorId)
- .ValueGeneratedNever()
- .HasColumnName("BuildingFloorID");
- entity.Property(e => e.BuildingId).HasColumnName("BuildingID");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.Name).HasMaxLength(100);
- entity.HasOne(d => d.Building)
- .WithMany(p => p.BdBuildingFloor)
- .HasForeignKey(d => d.BuildingId)
- .HasConstraintName("FK_BM_BUILD_Floor_REFERENCE_BD_BUILD");
- });
- modelBuilder.Entity<BdBuildingFloorRoom>(entity =>
- {
- entity.HasKey(e => e.BuildingFloorRoomId)
- .HasName("PK_BD_BUILDING_FLOOR_ROOM");
- entity.ToTable("BD_Building_Floor_Room");
- entity.Property(e => e.BuildingFloorRoomId)
- .ValueGeneratedNever()
- .HasColumnName("BuildingFloorRoomID");
- entity.Property(e => e.BuildingFloorId).HasColumnName("BuildingFloorID");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.Name).HasMaxLength(100);
- entity.HasOne(d => d.BuildingFloor)
- .WithMany(p => p.BdBuildingFloorRoom)
- .HasForeignKey(d => d.BuildingFloorId)
- .HasConstraintName("FK_BM_Build_Floor_Room_REFERENCE_BM_Build_Floor");
- });
- modelBuilder.Entity<BdBuildingXyAxis>(entity =>
- {
- entity.HasKey(e => e.XyaxisId)
- .HasName("PK_BD_BUILDING_XY_AXIS");
- entity.ToTable("BD_Building_XY_Axis");
- entity.Property(e => e.XyaxisId)
- .ValueGeneratedNever()
- .HasColumnName("XYAxisID");
- entity.Property(e => e.BuildingId).HasColumnName("BuildingID");
- entity.Property(e => e.Xaxis)
- .HasColumnType("decimal(18, 8)")
- .HasColumnName("XAxis");
- entity.Property(e => e.Yaxis)
- .HasColumnType("decimal(18, 8)")
- .HasColumnName("YAxis");
- entity.HasOne(d => d.Building)
- .WithMany(p => p.BdBuildingXyAxis)
- .HasForeignKey(d => d.BuildingId)
- .HasConstraintName("FK_BD_Building_XY_Axis_REFERENCE_BD_BUILD");
- });
- modelBuilder.Entity<BdDepartmentOrServicePoint>(entity =>
- {
- entity.HasKey(e => e.DepartmentOrServicePointId)
- .HasName("PK_BD_DEPARTMENTORSERVICEPOINT");
- entity.ToTable("BD_DepartmentOrServicePoint");
- entity.Property(e => e.DepartmentOrServicePointId)
- .ValueGeneratedNever()
- .HasColumnName("DepartmentOrServicePointID");
- entity.Property(e => e.ContactType).HasMaxLength(300);
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.Name).HasMaxLength(300);
- entity.Property(e => e.OpenTime).HasMaxLength(2000);
- });
- modelBuilder.Entity<BdDepartmentOrServicePointBmBuildingFloorRoom>(entity =>
- {
- entity.HasKey(e => new { e.DepartmentOrServicePointId, e.BuildingFloorRoomId });
- entity.ToTable("BD_DepartmentOrServicePoint_BM_Building_Floor_Room");
- entity.Property(e => e.DepartmentOrServicePointId).HasColumnName("DepartmentOrServicePointID");
- entity.Property(e => e.BuildingFloorRoomId).HasColumnName("BuildingFloorRoomID");
- entity.HasOne(d => d.BuildingFloorRoom)
- .WithMany(p => p.BdDepartmentOrServicePointBmBuildingFloorRoom)
- .HasForeignKey(d => d.BuildingFloorRoomId)
- .OnDelete(DeleteBehavior.ClientSetNull)
- .HasConstraintName("FK_BD_DEPAR_REFERENCE_BD_Building_Floor_Room");
- entity.HasOne(d => d.DepartmentOrServicePoint)
- .WithMany(p => p.BdDepartmentOrServicePointBmBuildingFloorRoom)
- .HasForeignKey(d => d.DepartmentOrServicePointId)
- .OnDelete(DeleteBehavior.ClientSetNull)
- .HasConstraintName("FK_BD_DEPAR_REFERENCE_BD_DepartmentOrServicePoint");
- });
- modelBuilder.Entity<SysAnnouncement>(entity =>
- {
- entity.HasKey(e => e.AnnouncementId)
- .HasName("PK_SYS_ANNOUNCEMENT");
- entity.ToTable("Sys_Announcement");
- entity.Property(e => e.AnnouncementId)
- .ValueGeneratedNever()
- .HasColumnName("AnnouncementID");
- entity.Property(e => e.AnnouncementTypeId).HasColumnName("AnnouncementTypeID");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.EndTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.StartTime).HasColumnType("datetime");
- entity.Property(e => e.Title).HasMaxLength(100);
- entity.Property(e => e.Url)
- .HasMaxLength(1024)
- .IsUnicode(false);
- });
- modelBuilder.Entity<SysAnnouncementSysRole>(entity =>
- {
- entity.HasKey(e => new { e.AnnouncementId, e.RoleId })
- .HasName("PK_SYS_ANNOUNCEMENT_SYS_ROLE");
- entity.ToTable("Sys_Announcement_Sys_Role");
- entity.Property(e => e.AnnouncementId).HasColumnName("AnnouncementID");
- entity.Property(e => e.RoleId).HasColumnName("RoleID");
- entity.HasOne(d => d.Announcement)
- .WithMany(p => p.SysAnnouncementSysRole)
- .HasForeignKey(d => d.AnnouncementId)
- .HasConstraintName("FK_Sys_Announcement_REFERENCE_Sys_Announcement_Sys_Role");
- entity.HasOne(d => d.Role)
- .WithMany(p => p.SysAnnouncementSysRole)
- .HasForeignKey(d => d.RoleId)
- .HasConstraintName("FK_Sys_Announcement_Sys_Role_REFERENCE_SYS_ROLE");
- });
- modelBuilder.Entity<SysAnnouncementSysUser>(entity =>
- {
- entity.HasKey(e => new { e.AnnouncementId, e.UserId })
- .HasName("PK_SYS_ANNOUNCEMENT_SYS_USER");
- entity.ToTable("Sys_Announcement_Sys_User");
- entity.Property(e => e.AnnouncementId).HasColumnName("AnnouncementID");
- entity.Property(e => e.UserId).HasColumnName("UserID");
- entity.HasOne(d => d.Announcement)
- .WithMany(p => p.SysAnnouncementSysUser)
- .HasForeignKey(d => d.AnnouncementId)
- .OnDelete(DeleteBehavior.ClientSetNull)
- .HasConstraintName("FK_SYS_ANNO_REFERENCE_SYS_ANNO");
- entity.HasOne(d => d.User)
- .WithMany(p => p.SysAnnouncementSysUser)
- .HasForeignKey(d => d.UserId)
- .OnDelete(DeleteBehavior.ClientSetNull)
- .HasConstraintName("FK_SYS_ANNO_REFERENCE_SYS_USER");
- });
- modelBuilder.Entity<SysApiScope>(entity =>
- {
- entity.HasKey(e => e.ApiScopeId)
- .HasName("PK_SYS_APISCOPE");
- entity.ToTable("Sys_ApiScope");
- entity.Property(e => e.ApiScopeId)
- .HasMaxLength(64)
- .IsUnicode(false)
- .HasColumnName("ApiScopeID");
- entity.Property(e => e.Name).HasMaxLength(50);
- });
- modelBuilder.Entity<SysAttachment>(entity =>
- {
- entity.HasKey(e => e.AttachmentId)
- .HasName("PK_SYS_ATTACHMENT");
- entity.ToTable("Sys_Attachment");
- entity.Property(e => e.AttachmentId)
- .ValueGeneratedNever()
- .HasColumnName("AttachmentID");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.Name).HasMaxLength(255);
- entity.Property(e => e.ReferenceId).HasColumnName("ReferenceID");
- entity.Property(e => e.Suffix)
- .HasMaxLength(100)
- .IsUnicode(false);
- });
- modelBuilder.Entity<SysDictionary>(entity =>
- {
- entity.HasKey(e => e.DictionaryCode)
- .HasName("PK_SYS_DICTIONARY");
- entity.ToTable("Sys_Dictionary");
- entity.Property(e => e.DictionaryCode).HasMaxLength(50);
- entity.Property(e => e.Name).HasMaxLength(500);
- });
- modelBuilder.Entity<SysDictionaryItem>(entity =>
- {
- entity.HasKey(e => e.DictionaryItemId)
- .HasName("PK_SYS_DICTIONARYITEM");
- entity.ToTable("Sys_DictionaryItem");
- entity.Property(e => e.DictionaryItemId)
- .ValueGeneratedNever()
- .HasColumnName("DictionaryItemID");
- entity.Property(e => e.Code)
- .IsRequired()
- .HasMaxLength(50);
- entity.Property(e => e.DictionaryCode).HasMaxLength(50);
- entity.Property(e => e.Name).HasMaxLength(100);
- entity.HasOne(d => d.DictionaryCodeNavigation)
- .WithMany(p => p.SysDictionaryItem)
- .HasForeignKey(d => d.DictionaryCode)
- .HasConstraintName("FK_Sys_DictionaryItem_Sys_Dictionary");
- });
- modelBuilder.Entity<SysFunctionCode>(entity =>
- {
- entity.HasKey(e => e.FunctionCode)
- .HasName("PK_SYS_FUNCTIONCODE");
- entity.ToTable("Sys_FunctionCode");
- entity.Property(e => e.FunctionCode).HasMaxLength(50);
- entity.Property(e => e.FunctionName).HasMaxLength(50);
- entity.Property(e => e.ParentFunctionCode).HasMaxLength(50);
- entity.HasOne(d => d.ParentFunctionCodeNavigation)
- .WithMany(p => p.InverseParentFunctionCodeNavigation)
- .HasForeignKey(d => d.ParentFunctionCode)
- .HasConstraintName("FK_SYS_FUNC_REFERENCE_SYS_FUNC");
- });
- modelBuilder.Entity<SysLog>(entity =>
- {
- entity.HasKey(e => e.LogId)
- .HasName("PK_SYS_LOG");
- entity.ToTable("Sys_log");
- entity.Property(e => e.LogId).ValueGeneratedNever();
- entity.Property(e => e.ClientIp)
- .HasMaxLength(100)
- .IsUnicode(false);
- entity.Property(e => e.LogDescribe)
- .HasMaxLength(800)
- .IsUnicode(false);
- entity.Property(e => e.LogTime).HasColumnType("datetime");
- entity.Property(e => e.LogTitle)
- .HasMaxLength(800)
- .HasColumnName("logTitle");
- entity.Property(e => e.LogUser).HasMaxLength(100);
- });
- modelBuilder.Entity<SysMenu>(entity =>
- {
- entity.HasKey(e => e.MenuNo)
- .HasName("PK_SYS_MENU");
- entity.ToTable("Sys_Menu");
- entity.Property(e => e.MenuNo).HasMaxLength(30);
- entity.Property(e => e.FunctionCode).HasMaxLength(50);
- entity.Property(e => e.Icon).HasMaxLength(50);
- entity.Property(e => e.MenuName)
- .IsRequired()
- .HasMaxLength(60)
- .HasDefaultValueSql("('请翻译')");
- entity.Property(e => e.ParentMenuNo).HasMaxLength(30);
- entity.Property(e => e.Url)
- .HasMaxLength(500)
- .IsUnicode(false);
- entity.HasOne(d => d.FunctionCodeNavigation)
- .WithMany(p => p.SysMenu)
- .HasForeignKey(d => d.FunctionCode)
- .HasConstraintName("FK_SYS_MENU_REFERENCE_SYS_FUNC");
- entity.HasOne(d => d.ParentMenuNoNavigation)
- .WithMany(p => p.InverseParentMenuNoNavigation)
- .HasForeignKey(d => d.ParentMenuNo)
- .HasConstraintName("FK_SYS_MENU_REFERENCE_SYS_MENU");
- });
- modelBuilder.Entity<SysNoticeHistory>(entity =>
- {
- entity.HasKey(e => e.NoticeHistoryId)
- .HasName("PK_SYS_NOTICEHISTORY");
- entity.ToTable("Sys_NoticeHistory");
- entity.Property(e => e.NoticeHistoryId)
- .ValueGeneratedNever()
- .HasColumnName("NoticeHistoryID");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.DepartmentId).HasColumnName("DepartmentID");
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.NoticeTypeId).HasColumnName("NoticeTypeID");
- entity.Property(e => e.SentTime).HasColumnType("datetime");
- entity.Property(e => e.SourceId).HasColumnName("SourceID");
- entity.Property(e => e.Title).HasMaxLength(100);
- entity.Property(e => e.Url)
- .HasMaxLength(255)
- .IsUnicode(false);
- entity.Property(e => e.UserId).HasColumnName("UserID");
- entity.HasOne(d => d.User)
- .WithMany(p => p.SysNoticeHistory)
- .HasForeignKey(d => d.UserId)
- .HasConstraintName("FK_Sys_NoticeHistory_REFERENCE_SYS_USER");
- });
- modelBuilder.Entity<SysParameter>(entity =>
- {
- entity.HasKey(e => e.ParameterKey)
- .HasName("PK_SYS_PARAMETER");
- entity.ToTable("Sys_Parameter");
- entity.Property(e => e.ParameterKey)
- .HasMaxLength(50)
- .IsUnicode(false);
- });
- modelBuilder.Entity<SysRole>(entity =>
- {
- entity.HasKey(e => e.RoleId)
- .HasName("PK_SYS_ROLE");
- entity.ToTable("Sys_Role");
- entity.Property(e => e.RoleId)
- .ValueGeneratedNever()
- .HasColumnName("RoleID");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.Description).HasMaxLength(500);
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.RoleName)
- .IsRequired()
- .HasMaxLength(100);
- });
- modelBuilder.Entity<SysRoleSysFunctionCode>(entity =>
- {
- entity.HasKey(e => new { e.RoleId, e.FunctionCode })
- .HasName("PK_SYS_ROLE_SYS_FUNCTIONCODE");
- entity.ToTable("Sys_Role_Sys_FunctionCode");
- entity.Property(e => e.RoleId).HasColumnName("RoleID");
- entity.Property(e => e.FunctionCode).HasMaxLength(50);
- entity.HasOne(d => d.FunctionCodeNavigation)
- .WithMany(p => p.SysRoleSysFunctionCode)
- .HasForeignKey(d => d.FunctionCode)
- .HasConstraintName("FK_Sys_Role_Sys_FunctionCode_REFERENCE_SYS_FUNCTION");
- entity.HasOne(d => d.Role)
- .WithMany(p => p.SysRoleSysFunctionCode)
- .HasForeignKey(d => d.RoleId)
- .HasConstraintName("FK_Sys_Role_Sys_FunctionCode_REFERENCE_SYS_ROLE");
- });
- modelBuilder.Entity<SysSerialNumber>(entity =>
- {
- entity.HasKey(e => e.SerialNumberKey)
- .HasName("PK_tb_sn");
- entity.ToTable("Sys_SerialNumber");
- entity.Property(e => e.SerialNumberKey)
- .HasMaxLength(50)
- .IsUnicode(false);
- entity.Property(e => e.ResetTime).HasColumnType("datetime");
- });
- modelBuilder.Entity<SysSystem>(entity =>
- {
- entity.HasKey(e => e.SystemId)
- .HasName("PK_SYS_SYSTEM");
- entity.ToTable("Sys_System");
- entity.Property(e => e.SystemId)
- .HasMaxLength(64)
- .IsUnicode(false)
- .HasColumnName("SystemID");
- entity.Property(e => e.Secret)
- .HasMaxLength(8)
- .IsUnicode(false);
- entity.Property(e => e.SystemName).HasMaxLength(100);
- });
- modelBuilder.Entity<SysSystemSysApiScope>(entity =>
- {
- entity.HasKey(e => new { e.SystemId, e.ApiScopeId })
- .HasName("PK_SYS_SYSTEM_SYS_APISCOPE");
- entity.ToTable("Sys_System_Sys_ApiScope");
- entity.Property(e => e.SystemId)
- .HasMaxLength(64)
- .IsUnicode(false)
- .HasColumnName("SystemID");
- entity.Property(e => e.ApiScopeId)
- .HasMaxLength(64)
- .IsUnicode(false)
- .HasColumnName("ApiScopeID");
- entity.HasOne(d => d.ApiScope)
- .WithMany(p => p.SysSystemSysApiScope)
- .HasForeignKey(d => d.ApiScopeId)
- .OnDelete(DeleteBehavior.ClientSetNull)
- .HasConstraintName("FK_Sys_System_Sys_ApiScope_REFERENCE_Sys_ApiScope");
- entity.HasOne(d => d.System)
- .WithMany(p => p.SysSystemSysApiScope)
- .HasForeignKey(d => d.SystemId)
- .OnDelete(DeleteBehavior.ClientSetNull)
- .HasConstraintName("FK_Sys_System_Sys_ApiScope_REFERENCE_Sys_System");
- });
- modelBuilder.Entity<SysUser>(entity =>
- {
- entity.HasKey(e => e.UserId)
- .HasName("PK_SYS_USER");
- entity.ToTable("Sys_User");
- entity.HasIndex(e => e.LoginId, "IX_Sys_User_LoginID")
- .IsUnique();
- entity.Property(e => e.UserId)
- .ValueGeneratedNever()
- .HasColumnName("UserID");
- entity.Property(e => e.CmWorkLinkAccountDomain)
- .HasMaxLength(100)
- .HasColumnName("CmWorkLink_Account_Domain");
- entity.Property(e => e.CmWorkLinkAccountPsid)
- .HasMaxLength(100)
- .HasColumnName("CmWorkLink_Account_Psid");
- entity.Property(e => e.CmWorkLinkAccountPstel)
- .HasMaxLength(100)
- .HasColumnName("CmWorkLink_Account_Pstel");
- entity.Property(e => e.CmWorkLinkLoginTime)
- .HasColumnType("datetime")
- .HasColumnName("CmWorkLink_LoginTime");
- entity.Property(e => e.CreateTime).HasColumnType("datetime");
- entity.Property(e => e.CreateUserId).HasColumnName("CreateUserID");
- entity.Property(e => e.LoginId)
- .HasMaxLength(50)
- .IsUnicode(false)
- .HasColumnName("LoginID");
- entity.Property(e => e.ModifyTime).HasColumnType("datetime");
- entity.Property(e => e.ModifyUserId).HasColumnName("ModifyUserID");
- entity.Property(e => e.Name).HasMaxLength(50);
- entity.Property(e => e.Password)
- .HasMaxLength(50)
- .IsUnicode(false);
- entity.Property(e => e.WeChatLoginTime).HasColumnType("datetime");
- entity.Property(e => e.WeChatUserId).HasMaxLength(300);
- });
- modelBuilder.Entity<SysUserSysRole>(entity =>
- {
- entity.HasKey(e => new { e.UserId, e.RoleId })
- .HasName("PK_SYS_USER_SYS_ROLE");
- entity.ToTable("Sys_User_Sys_Role");
- entity.Property(e => e.UserId).HasColumnName("UserID");
- entity.Property(e => e.RoleId).HasColumnName("RoleID");
- entity.HasOne(d => d.Role)
- .WithMany(p => p.SysUserSysRole)
- .HasForeignKey(d => d.RoleId)
- .HasConstraintName("FK_Sys_User_Sys_Role_REFERENCE_SYS_ROLE");
- entity.HasOne(d => d.User)
- .WithMany(p => p.SysUserSysRole)
- .HasForeignKey(d => d.UserId)
- .OnDelete(DeleteBehavior.ClientSetNull)
- .HasConstraintName("FK_Sys_User_Sys_Role_REFERENCE_SYS_USER");
- });
- modelBuilder.Entity<数据导入>(entity =>
- {
- entity.HasNoKey();
- entity.Property(e => e.F9).HasMaxLength(255);
- entity.Property(e => e.为必填项)
- .HasMaxLength(255)
- .HasColumnName("*为必填项");
- entity.Property(e => e.图片).HasMaxLength(255);
- entity.Property(e => e.大楼名)
- .HasMaxLength(255)
- .HasColumnName("大楼名*");
- entity.Property(e => e.开放时间).HasMaxLength(255);
- entity.Property(e => e.房间号)
- .HasMaxLength(255)
- .HasColumnName("房间号*");
- entity.Property(e => e.楼层)
- .HasMaxLength(255)
- .HasColumnName("楼层*");
- entity.Property(e => e.简介).HasMaxLength(255);
- entity.Property(e => e.联系方式).HasMaxLength(255);
- entity.Property(e => e.部门服务点)
- .HasMaxLength(255)
- .HasColumnName("部门/服务点*");
- });
- OnModelCreatingPartial(modelBuilder);
- }
- partial void OnModelCreatingPartial(ModelBuilder modelBuilder);
- }
- }
|