HRIdentityDBContextModelSnapshot.cs 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749
  1. // <auto-generated />
  2. using System;
  3. using MTWorkHR.Identity.DBContext;
  4. using Microsoft.EntityFrameworkCore;
  5. using Microsoft.EntityFrameworkCore.Infrastructure;
  6. using Microsoft.EntityFrameworkCore.Metadata;
  7. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  8. #nullable disable
  9. namespace MTWorkHR.Identity.Migrations
  10. {
  11. [DbContext(typeof(HRIdentityDBContext))]
  12. partial class HRIdentityDBContextModelSnapshot : ModelSnapshot
  13. {
  14. protected override void BuildModel(ModelBuilder modelBuilder)
  15. {
  16. #pragma warning disable 612, 618
  17. modelBuilder
  18. .HasAnnotation("ProductVersion", "8.0.1")
  19. .HasAnnotation("Relational:MaxIdentifierLength", 128);
  20. SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
  21. modelBuilder.Entity("ApplicationRoleApplicationUser", b =>
  22. {
  23. b.Property<string>("UserRolesId")
  24. .HasColumnType("nvarchar(450)");
  25. b.Property<string>("UsersId")
  26. .HasColumnType("nvarchar(450)");
  27. b.HasKey("UserRolesId", "UsersId");
  28. b.HasIndex("UsersId");
  29. b.ToTable("ApplicationRoleApplicationUser");
  30. });
  31. modelBuilder.Entity("MTWorkHR.Core.Entities.Base.AttachmentType", b =>
  32. {
  33. b.Property<long>("Id")
  34. .ValueGeneratedOnAdd()
  35. .HasColumnType("bigint")
  36. .HasColumnOrder(0);
  37. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  38. b.Property<bool>("IsRequired")
  39. .HasColumnType("bit");
  40. b.Property<string>("NameAr")
  41. .IsRequired()
  42. .HasMaxLength(250)
  43. .HasColumnType("nvarchar(250)");
  44. b.Property<string>("NameEn")
  45. .IsRequired()
  46. .HasMaxLength(250)
  47. .HasColumnType("nvarchar(250)");
  48. b.HasKey("Id");
  49. b.ToTable("AttachmentTypes");
  50. b.HasData(
  51. new
  52. {
  53. Id = 1L,
  54. IsRequired = false,
  55. NameAr = "السيرة الذاتية",
  56. NameEn = "CV"
  57. },
  58. new
  59. {
  60. Id = 2L,
  61. IsRequired = false,
  62. NameAr = "الهوية",
  63. NameEn = "Identification"
  64. });
  65. });
  66. modelBuilder.Entity("MTWorkHR.Identity.Entities.ApplicationRole", b =>
  67. {
  68. b.Property<string>("Id")
  69. .HasColumnType("nvarchar(450)");
  70. b.Property<string>("ConcurrencyStamp")
  71. .IsConcurrencyToken()
  72. .HasColumnType("nvarchar(max)");
  73. b.Property<DateTime>("CreateDate")
  74. .HasColumnType("datetime2");
  75. b.Property<string>("CreateUser")
  76. .HasColumnType("nvarchar(max)");
  77. b.Property<string>("DeleteUserId")
  78. .HasColumnType("nvarchar(max)");
  79. b.Property<bool?>("IsAdmin")
  80. .HasColumnType("bit");
  81. b.Property<bool>("IsDeleted")
  82. .HasColumnType("bit");
  83. b.Property<string>("Name")
  84. .HasMaxLength(256)
  85. .HasColumnType("nvarchar(256)");
  86. b.Property<string>("NormalizedName")
  87. .HasMaxLength(256)
  88. .HasColumnType("nvarchar(256)");
  89. b.Property<DateTime?>("UpdateDate")
  90. .HasColumnType("datetime2");
  91. b.Property<string>("UpdateUser")
  92. .HasColumnType("nvarchar(max)");
  93. b.HasKey("Id");
  94. b.HasIndex("NormalizedName")
  95. .IsUnique()
  96. .HasDatabaseName("RoleNameIndex")
  97. .HasFilter("[NormalizedName] IS NOT NULL");
  98. b.ToTable("AspNetRoles", (string)null);
  99. b.HasData(
  100. new
  101. {
  102. Id = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A",
  103. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  104. IsAdmin = true,
  105. IsDeleted = false,
  106. Name = "Admin",
  107. NormalizedName = "ADMIN"
  108. },
  109. new
  110. {
  111. Id = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E",
  112. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  113. IsAdmin = false,
  114. IsDeleted = false,
  115. Name = "Employee",
  116. NormalizedName = "EMPLOYEE"
  117. });
  118. });
  119. modelBuilder.Entity("MTWorkHR.Identity.Entities.ApplicationUser", b =>
  120. {
  121. b.Property<string>("Id")
  122. .HasColumnType("nvarchar(450)");
  123. b.Property<int>("AccessFailedCount")
  124. .HasColumnType("int");
  125. b.Property<string>("ConcurrencyStamp")
  126. .IsConcurrencyToken()
  127. .HasColumnType("nvarchar(max)");
  128. b.Property<string>("CreateUser")
  129. .HasColumnType("nvarchar(max)");
  130. b.Property<string>("DeleteUserId")
  131. .HasColumnType("nvarchar(max)");
  132. b.Property<string>("Email")
  133. .HasMaxLength(256)
  134. .HasColumnType("nvarchar(256)");
  135. b.Property<bool>("EmailConfirmed")
  136. .HasColumnType("bit");
  137. b.Property<string>("FavoriteName")
  138. .HasColumnType("nvarchar(max)");
  139. b.Property<string>("FirstName")
  140. .IsRequired()
  141. .HasColumnType("nvarchar(max)");
  142. b.Property<decimal?>("IncomeTaxValue")
  143. .HasColumnType("decimal(18,2)");
  144. b.Property<bool>("IsDeleted")
  145. .HasColumnType("bit");
  146. b.Property<bool>("IsStopped")
  147. .HasColumnType("bit");
  148. b.Property<string>("JobTitle")
  149. .HasColumnType("nvarchar(max)");
  150. b.Property<string>("LastName")
  151. .IsRequired()
  152. .HasColumnType("nvarchar(max)");
  153. b.Property<bool>("LockoutEnabled")
  154. .HasColumnType("bit");
  155. b.Property<DateTimeOffset?>("LockoutEnd")
  156. .HasColumnType("datetimeoffset");
  157. b.Property<string>("ManagerId")
  158. .HasColumnType("nvarchar(450)");
  159. b.Property<string>("NormalizedEmail")
  160. .HasMaxLength(256)
  161. .HasColumnType("nvarchar(256)");
  162. b.Property<string>("NormalizedUserName")
  163. .HasMaxLength(256)
  164. .HasColumnType("nvarchar(256)");
  165. b.Property<string>("PassportNumber")
  166. .IsRequired()
  167. .HasColumnType("nvarchar(max)");
  168. b.Property<string>("PasswordHash")
  169. .HasColumnType("nvarchar(max)");
  170. b.Property<string>("PhoneNumber")
  171. .HasColumnType("nvarchar(max)");
  172. b.Property<bool>("PhoneNumberConfirmed")
  173. .HasColumnType("bit");
  174. b.Property<int?>("QualificationId")
  175. .HasColumnType("int");
  176. b.Property<string>("SecurityStamp")
  177. .HasColumnType("nvarchar(max)");
  178. b.Property<decimal?>("TaxNumber")
  179. .HasColumnType("decimal(18,2)");
  180. b.Property<bool>("TwoFactorEnabled")
  181. .HasColumnType("bit");
  182. b.Property<string>("University")
  183. .HasColumnType("nvarchar(max)");
  184. b.Property<string>("UpdateUser")
  185. .HasColumnType("nvarchar(max)");
  186. b.Property<string>("UserName")
  187. .HasMaxLength(256)
  188. .HasColumnType("nvarchar(256)");
  189. b.Property<int>("UserType")
  190. .HasColumnType("int");
  191. b.HasKey("Id");
  192. b.HasIndex("ManagerId");
  193. b.HasIndex("NormalizedEmail")
  194. .HasDatabaseName("EmailIndex");
  195. b.HasIndex("NormalizedUserName")
  196. .IsUnique()
  197. .HasDatabaseName("UserNameIndex")
  198. .HasFilter("[NormalizedUserName] IS NOT NULL");
  199. b.ToTable("AspNetUsers", (string)null);
  200. b.HasData(
  201. new
  202. {
  203. Id = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  204. AccessFailedCount = 0,
  205. ConcurrencyStamp = "7cc87689-9eab-4280-b8e3-1834080783a5",
  206. Email = "a@b.com",
  207. EmailConfirmed = true,
  208. FirstName = "Zinab",
  209. IncomeTaxValue = 1m,
  210. IsDeleted = false,
  211. IsStopped = false,
  212. LastName = "Elgendy",
  213. LockoutEnabled = false,
  214. NormalizedEmail = "A@B.COM",
  215. NormalizedUserName = "ADMIN",
  216. PassportNumber = "1234567",
  217. PasswordHash = "AQAAAAIAAYagAAAAEPg+ASbciPFxtyxQq8Wx5ilBUQ0RbAoITXXkOQm1PzC5BzySX0sn/wUmOjBKPDGV9w==",
  218. PhoneNumber = "1234567890",
  219. PhoneNumberConfirmed = true,
  220. QualificationId = 1,
  221. SecurityStamp = "49bb16c3-4704-4c60-908d-dc8506950acc",
  222. TaxNumber = 111m,
  223. TwoFactorEnabled = false,
  224. UserName = "Admin",
  225. UserType = 1
  226. },
  227. new
  228. {
  229. Id = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  230. AccessFailedCount = 0,
  231. ConcurrencyStamp = "4af7b4cf-802a-455b-b598-997e167745b3",
  232. Email = "ali@b.com",
  233. EmailConfirmed = true,
  234. FirstName = "Ali",
  235. IncomeTaxValue = 100m,
  236. IsDeleted = false,
  237. IsStopped = false,
  238. LastName = "Farok",
  239. LockoutEnabled = false,
  240. NormalizedEmail = "ALI@B.COM",
  241. NormalizedUserName = "ALI",
  242. PassportNumber = "7654321001010",
  243. PasswordHash = "AQAAAAIAAYagAAAAEI3QJkcZjCH4Y8Db4rEgL8Mmll5oCvYcWiXZjQSN9bGW4SMcjHe3ZPMnkN/l9DmJeQ==",
  244. PhoneNumber = "1234567890",
  245. PhoneNumberConfirmed = true,
  246. QualificationId = 1,
  247. SecurityStamp = "62549056-1b9d-46d4-84f8-adea3e4d8b68",
  248. TaxNumber = 222m,
  249. TwoFactorEnabled = false,
  250. UserName = "ali",
  251. UserType = 1
  252. });
  253. });
  254. modelBuilder.Entity("MTWorkHR.Identity.Entities.Permission", b =>
  255. {
  256. b.Property<long>("Id")
  257. .ValueGeneratedOnAdd()
  258. .HasColumnType("bigint")
  259. .HasColumnOrder(0);
  260. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  261. b.Property<string>("CategoryName")
  262. .IsRequired()
  263. .HasMaxLength(150)
  264. .HasColumnType("nvarchar(150)");
  265. b.Property<string>("Desc")
  266. .IsRequired()
  267. .HasMaxLength(250)
  268. .HasColumnType("nvarchar(250)");
  269. b.Property<string>("Name")
  270. .IsRequired()
  271. .HasMaxLength(250)
  272. .HasColumnType("nvarchar(250)");
  273. b.Property<bool>("Show")
  274. .HasColumnType("bit");
  275. b.HasKey("Id");
  276. b.ToTable("Permissions");
  277. });
  278. modelBuilder.Entity("MTWorkHR.Identity.Entities.RolePermission", b =>
  279. {
  280. b.Property<long>("Id")
  281. .ValueGeneratedOnAdd()
  282. .HasColumnType("bigint")
  283. .HasColumnOrder(0);
  284. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  285. b.Property<long>("PermissionId")
  286. .HasColumnType("bigint");
  287. b.Property<string>("PermissionName")
  288. .IsRequired()
  289. .HasColumnType("nvarchar(max)");
  290. b.Property<string>("RoleId")
  291. .IsRequired()
  292. .HasColumnType("nvarchar(450)");
  293. b.HasKey("Id");
  294. b.HasIndex("PermissionId");
  295. b.HasIndex("RoleId");
  296. b.ToTable("RolePermissions");
  297. });
  298. modelBuilder.Entity("MTWorkHR.Identity.Entities.UserAddress", b =>
  299. {
  300. b.Property<long>("Id")
  301. .ValueGeneratedOnAdd()
  302. .HasColumnType("bigint")
  303. .HasColumnOrder(0);
  304. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  305. b.Property<string>("AddressDesc")
  306. .IsRequired()
  307. .HasColumnType("nvarchar(max)");
  308. b.Property<string>("City")
  309. .IsRequired()
  310. .HasColumnType("nvarchar(max)");
  311. b.Property<int>("CountryId")
  312. .HasColumnType("int");
  313. b.Property<DateTime>("CreateDate")
  314. .HasColumnType("datetime2")
  315. .HasColumnOrder(3);
  316. b.Property<string>("CreateUser")
  317. .HasMaxLength(450)
  318. .HasColumnType("nvarchar(450)")
  319. .HasColumnOrder(1);
  320. b.Property<string>("PostalCode")
  321. .IsRequired()
  322. .HasColumnType("nvarchar(max)");
  323. b.Property<DateTime?>("UpdateDate")
  324. .HasColumnType("datetime2")
  325. .HasColumnOrder(4);
  326. b.Property<string>("UpdateUser")
  327. .HasMaxLength(450)
  328. .HasColumnType("nvarchar(450)")
  329. .HasColumnOrder(2);
  330. b.Property<string>("UserId")
  331. .IsRequired()
  332. .HasColumnType("nvarchar(450)");
  333. b.HasKey("Id");
  334. b.HasIndex("UserId")
  335. .IsUnique();
  336. b.ToTable("UserAddress");
  337. });
  338. modelBuilder.Entity("MTWorkHR.Identity.Entities.UserAttachment", b =>
  339. {
  340. b.Property<long>("Id")
  341. .ValueGeneratedOnAdd()
  342. .HasColumnType("bigint")
  343. .HasColumnOrder(0);
  344. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  345. b.Property<long>("AttachmentTypeId")
  346. .HasColumnType("bigint");
  347. b.Property<DateTime>("CreateDate")
  348. .HasColumnType("datetime2")
  349. .HasColumnOrder(3);
  350. b.Property<string>("CreateUser")
  351. .HasMaxLength(450)
  352. .HasColumnType("nvarchar(450)")
  353. .HasColumnOrder(1);
  354. b.Property<string>("FileName")
  355. .IsRequired()
  356. .HasMaxLength(250)
  357. .HasColumnType("nvarchar(250)");
  358. b.Property<string>("OriginalName")
  359. .IsRequired()
  360. .HasMaxLength(250)
  361. .HasColumnType("nvarchar(250)");
  362. b.Property<DateTime?>("UpdateDate")
  363. .HasColumnType("datetime2")
  364. .HasColumnOrder(4);
  365. b.Property<string>("UpdateUser")
  366. .HasMaxLength(450)
  367. .HasColumnType("nvarchar(450)")
  368. .HasColumnOrder(2);
  369. b.Property<string>("UserId")
  370. .IsRequired()
  371. .HasColumnType("nvarchar(450)");
  372. b.HasKey("Id");
  373. b.HasIndex("AttachmentTypeId");
  374. b.HasIndex("UserId");
  375. b.ToTable("UserAttachments");
  376. });
  377. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  378. {
  379. b.Property<int>("Id")
  380. .ValueGeneratedOnAdd()
  381. .HasColumnType("int");
  382. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  383. b.Property<string>("ClaimType")
  384. .HasColumnType("nvarchar(max)");
  385. b.Property<string>("ClaimValue")
  386. .HasColumnType("nvarchar(max)");
  387. b.Property<string>("RoleId")
  388. .IsRequired()
  389. .HasColumnType("nvarchar(450)");
  390. b.HasKey("Id");
  391. b.HasIndex("RoleId");
  392. b.ToTable("AspNetRoleClaims", (string)null);
  393. });
  394. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  395. {
  396. b.Property<int>("Id")
  397. .ValueGeneratedOnAdd()
  398. .HasColumnType("int");
  399. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  400. b.Property<string>("ClaimType")
  401. .HasColumnType("nvarchar(max)");
  402. b.Property<string>("ClaimValue")
  403. .HasColumnType("nvarchar(max)");
  404. b.Property<string>("UserId")
  405. .IsRequired()
  406. .HasColumnType("nvarchar(450)");
  407. b.HasKey("Id");
  408. b.HasIndex("UserId");
  409. b.ToTable("AspNetUserClaims", (string)null);
  410. });
  411. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  412. {
  413. b.Property<string>("LoginProvider")
  414. .HasColumnType("nvarchar(450)");
  415. b.Property<string>("ProviderKey")
  416. .HasColumnType("nvarchar(450)");
  417. b.Property<string>("ProviderDisplayName")
  418. .HasColumnType("nvarchar(max)");
  419. b.Property<string>("UserId")
  420. .IsRequired()
  421. .HasColumnType("nvarchar(450)");
  422. b.HasKey("LoginProvider", "ProviderKey");
  423. b.HasIndex("UserId");
  424. b.ToTable("AspNetUserLogins", (string)null);
  425. });
  426. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  427. {
  428. b.Property<string>("UserId")
  429. .HasColumnType("nvarchar(450)");
  430. b.Property<string>("RoleId")
  431. .HasColumnType("nvarchar(450)");
  432. b.HasKey("UserId", "RoleId");
  433. b.HasIndex("RoleId");
  434. b.ToTable("AspNetUserRoles", (string)null);
  435. b.HasData(
  436. new
  437. {
  438. UserId = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  439. RoleId = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A"
  440. },
  441. new
  442. {
  443. UserId = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  444. RoleId = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E"
  445. });
  446. });
  447. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  448. {
  449. b.Property<string>("UserId")
  450. .HasColumnType("nvarchar(450)");
  451. b.Property<string>("LoginProvider")
  452. .HasColumnType("nvarchar(450)");
  453. b.Property<string>("Name")
  454. .HasColumnType("nvarchar(450)");
  455. b.Property<string>("Value")
  456. .HasColumnType("nvarchar(max)");
  457. b.HasKey("UserId", "LoginProvider", "Name");
  458. b.ToTable("AspNetUserTokens", (string)null);
  459. });
  460. modelBuilder.Entity("ApplicationRoleApplicationUser", b =>
  461. {
  462. b.HasOne("MTWorkHR.Identity.Entities.ApplicationRole", null)
  463. .WithMany()
  464. .HasForeignKey("UserRolesId")
  465. .OnDelete(DeleteBehavior.Cascade)
  466. .IsRequired();
  467. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", null)
  468. .WithMany()
  469. .HasForeignKey("UsersId")
  470. .OnDelete(DeleteBehavior.Cascade)
  471. .IsRequired();
  472. });
  473. modelBuilder.Entity("MTWorkHR.Identity.Entities.ApplicationUser", b =>
  474. {
  475. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", "Manager")
  476. .WithMany()
  477. .HasForeignKey("ManagerId");
  478. b.Navigation("Manager");
  479. });
  480. modelBuilder.Entity("MTWorkHR.Identity.Entities.RolePermission", b =>
  481. {
  482. b.HasOne("MTWorkHR.Identity.Entities.Permission", "Permission")
  483. .WithMany()
  484. .HasForeignKey("PermissionId")
  485. .OnDelete(DeleteBehavior.Cascade)
  486. .IsRequired();
  487. b.HasOne("MTWorkHR.Identity.Entities.ApplicationRole", "Role")
  488. .WithMany("RolePermissions")
  489. .HasForeignKey("RoleId")
  490. .OnDelete(DeleteBehavior.Cascade)
  491. .IsRequired();
  492. b.Navigation("Permission");
  493. b.Navigation("Role");
  494. });
  495. modelBuilder.Entity("MTWorkHR.Identity.Entities.UserAddress", b =>
  496. {
  497. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", "User")
  498. .WithOne("UserAddress")
  499. .HasForeignKey("MTWorkHR.Identity.Entities.UserAddress", "UserId")
  500. .OnDelete(DeleteBehavior.Cascade)
  501. .IsRequired();
  502. b.Navigation("User");
  503. });
  504. modelBuilder.Entity("MTWorkHR.Identity.Entities.UserAttachment", b =>
  505. {
  506. b.HasOne("MTWorkHR.Core.Entities.Base.AttachmentType", "AttachmentType")
  507. .WithMany()
  508. .HasForeignKey("AttachmentTypeId")
  509. .OnDelete(DeleteBehavior.Cascade)
  510. .IsRequired();
  511. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", "User")
  512. .WithMany("UserAttachments")
  513. .HasForeignKey("UserId")
  514. .OnDelete(DeleteBehavior.Cascade)
  515. .IsRequired();
  516. b.Navigation("AttachmentType");
  517. b.Navigation("User");
  518. });
  519. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  520. {
  521. b.HasOne("MTWorkHR.Identity.Entities.ApplicationRole", null)
  522. .WithMany()
  523. .HasForeignKey("RoleId")
  524. .OnDelete(DeleteBehavior.Cascade)
  525. .IsRequired();
  526. });
  527. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  528. {
  529. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", null)
  530. .WithMany()
  531. .HasForeignKey("UserId")
  532. .OnDelete(DeleteBehavior.Cascade)
  533. .IsRequired();
  534. });
  535. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  536. {
  537. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", null)
  538. .WithMany()
  539. .HasForeignKey("UserId")
  540. .OnDelete(DeleteBehavior.Cascade)
  541. .IsRequired();
  542. });
  543. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  544. {
  545. b.HasOne("MTWorkHR.Identity.Entities.ApplicationRole", null)
  546. .WithMany()
  547. .HasForeignKey("RoleId")
  548. .OnDelete(DeleteBehavior.Cascade)
  549. .IsRequired();
  550. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", null)
  551. .WithMany()
  552. .HasForeignKey("UserId")
  553. .OnDelete(DeleteBehavior.Cascade)
  554. .IsRequired();
  555. });
  556. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  557. {
  558. b.HasOne("MTWorkHR.Identity.Entities.ApplicationUser", null)
  559. .WithMany()
  560. .HasForeignKey("UserId")
  561. .OnDelete(DeleteBehavior.Cascade)
  562. .IsRequired();
  563. });
  564. modelBuilder.Entity("MTWorkHR.Identity.Entities.ApplicationRole", b =>
  565. {
  566. b.Navigation("RolePermissions");
  567. });
  568. modelBuilder.Entity("MTWorkHR.Identity.Entities.ApplicationUser", b =>
  569. {
  570. b.Navigation("UserAddress")
  571. .IsRequired();
  572. b.Navigation("UserAttachments");
  573. });
  574. #pragma warning restore 612, 618
  575. }
  576. }
  577. }