Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858
  1. // <auto-generated />
  2. using System;
  3. using Diligent.WebAPI.Data;
  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 Diligent.WebAPI.Data.Migrations
  10. {
  11. [DbContext(typeof(DatabaseContext))]
  12. partial class DatabaseContextModelSnapshot : ModelSnapshot
  13. {
  14. protected override void BuildModel(ModelBuilder modelBuilder)
  15. {
  16. #pragma warning disable 612, 618
  17. modelBuilder
  18. .HasAnnotation("ProductVersion", "6.0.10")
  19. .HasAnnotation("Relational:MaxIdentifierLength", 128);
  20. SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1);
  21. modelBuilder.Entity("AdTechnology", b =>
  22. {
  23. b.Property<int>("AdsId")
  24. .HasColumnType("int");
  25. b.Property<int>("TechnologiesTechnologyId")
  26. .HasColumnType("int");
  27. b.HasKey("AdsId", "TechnologiesTechnologyId");
  28. b.HasIndex("TechnologiesTechnologyId");
  29. b.ToTable("AdTechnology");
  30. });
  31. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Ad", b =>
  32. {
  33. b.Property<int>("Id")
  34. .ValueGeneratedOnAdd()
  35. .HasColumnType("int");
  36. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  37. b.Property<string>("Conditions")
  38. .IsRequired()
  39. .HasColumnType("nvarchar(max)");
  40. b.Property<DateTime>("CreatedAt")
  41. .HasColumnType("datetime2");
  42. b.Property<DateTime>("ExpiredAt")
  43. .HasColumnType("datetime2");
  44. b.Property<string>("MainLiabilities")
  45. .IsRequired()
  46. .HasColumnType("nvarchar(max)");
  47. b.Property<int>("MinimumExperience")
  48. .HasColumnType("int");
  49. b.Property<string>("Offer")
  50. .IsRequired()
  51. .HasColumnType("nvarchar(max)");
  52. b.Property<string>("Title")
  53. .IsRequired()
  54. .HasColumnType("nvarchar(max)");
  55. b.HasKey("Id");
  56. b.ToTable("Ads");
  57. });
  58. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Applicant", b =>
  59. {
  60. b.Property<int>("ApplicantId")
  61. .ValueGeneratedOnAdd()
  62. .HasColumnType("int");
  63. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("ApplicantId"), 1L, 1);
  64. b.Property<string>("ApplicationChannel")
  65. .HasColumnType("nvarchar(max)");
  66. b.Property<string>("BitBucketLink")
  67. .HasColumnType("nvarchar(max)");
  68. b.Property<string>("CV")
  69. .IsRequired()
  70. .HasColumnType("nvarchar(max)");
  71. b.Property<DateTime>("DateOfApplication")
  72. .HasColumnType("datetime2");
  73. b.Property<string>("Email")
  74. .IsRequired()
  75. .HasMaxLength(128)
  76. .HasColumnType("nvarchar(128)");
  77. b.Property<int>("Experience")
  78. .HasColumnType("int");
  79. b.Property<string>("FirstName")
  80. .IsRequired()
  81. .HasMaxLength(128)
  82. .HasColumnType("nvarchar(128)");
  83. b.Property<string>("GithubLink")
  84. .HasColumnType("nvarchar(max)");
  85. b.Property<string>("LastName")
  86. .IsRequired()
  87. .HasMaxLength(128)
  88. .HasColumnType("nvarchar(128)");
  89. b.Property<string>("LinkedlnLink")
  90. .HasColumnType("nvarchar(max)");
  91. b.Property<string>("PhoneNumber")
  92. .IsRequired()
  93. .HasMaxLength(30)
  94. .HasColumnType("nvarchar(30)");
  95. b.Property<string>("Position")
  96. .IsRequired()
  97. .HasMaxLength(128)
  98. .HasColumnType("nvarchar(128)");
  99. b.HasKey("ApplicantId");
  100. b.ToTable("Applicants");
  101. });
  102. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.AppRole", b =>
  103. {
  104. b.Property<int>("Id")
  105. .ValueGeneratedOnAdd()
  106. .HasColumnType("int");
  107. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  108. b.Property<string>("ConcurrencyStamp")
  109. .IsConcurrencyToken()
  110. .HasColumnType("nvarchar(max)");
  111. b.Property<string>("Name")
  112. .HasMaxLength(256)
  113. .HasColumnType("nvarchar(256)");
  114. b.Property<string>("NormalizedName")
  115. .HasMaxLength(256)
  116. .HasColumnType("nvarchar(256)");
  117. b.HasKey("Id");
  118. b.HasIndex("NormalizedName")
  119. .IsUnique()
  120. .HasDatabaseName("RoleNameIndex")
  121. .HasFilter("[NormalizedName] IS NOT NULL");
  122. b.ToTable("AspNetRoles", (string)null);
  123. });
  124. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Comment", b =>
  125. {
  126. b.Property<int>("Id")
  127. .ValueGeneratedOnAdd()
  128. .HasColumnType("int");
  129. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  130. b.Property<int>("ApplicantId")
  131. .HasColumnType("int");
  132. b.Property<string>("Content")
  133. .IsRequired()
  134. .HasMaxLength(1024)
  135. .HasColumnType("nvarchar(1024)");
  136. b.Property<DateTime>("DateOfSending")
  137. .HasColumnType("datetime2");
  138. b.Property<int>("UserId")
  139. .HasColumnType("int");
  140. b.HasKey("Id");
  141. b.HasIndex("ApplicantId");
  142. b.HasIndex("UserId");
  143. b.ToTable("Comments");
  144. });
  145. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.InsuranceCompany", b =>
  146. {
  147. b.Property<long>("Id")
  148. .ValueGeneratedOnAdd()
  149. .HasColumnType("bigint");
  150. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  151. b.Property<string>("City")
  152. .IsRequired()
  153. .HasColumnType("nvarchar(max)");
  154. b.Property<string>("Country")
  155. .IsRequired()
  156. .HasColumnType("nvarchar(max)");
  157. b.Property<DateTime>("CreatedAtUtc")
  158. .HasColumnType("datetime2");
  159. b.Property<DateTime?>("DeletedAtUtc")
  160. .HasColumnType("datetime2");
  161. b.Property<string>("Fax")
  162. .IsRequired()
  163. .HasColumnType("nvarchar(max)");
  164. b.Property<string>("LegalAddress")
  165. .IsRequired()
  166. .HasColumnType("nvarchar(max)");
  167. b.Property<string>("LegalEmail")
  168. .IsRequired()
  169. .HasColumnType("nvarchar(max)");
  170. b.Property<string>("Name")
  171. .IsRequired()
  172. .HasColumnType("nvarchar(max)");
  173. b.Property<string>("PhoneNumber")
  174. .IsRequired()
  175. .HasColumnType("nvarchar(max)");
  176. b.Property<string>("PostalCode")
  177. .IsRequired()
  178. .HasColumnType("nvarchar(max)");
  179. b.Property<DateTime?>("UpdatedAtUtc")
  180. .HasColumnType("datetime2");
  181. b.HasKey("Id");
  182. b.ToTable("InsuranceCompanies");
  183. });
  184. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.InsurancePolicy", b =>
  185. {
  186. b.Property<long>("Id")
  187. .ValueGeneratedOnAdd()
  188. .HasColumnType("bigint");
  189. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  190. b.Property<DateTime>("CreatedAtUtc")
  191. .HasColumnType("datetime2");
  192. b.Property<DateTime?>("DeletedAtUtc")
  193. .HasColumnType("datetime2");
  194. b.Property<DateTime>("EndDate")
  195. .HasColumnType("datetime2");
  196. b.Property<long>("InsurerId")
  197. .HasColumnType("bigint");
  198. b.Property<decimal>("Premium")
  199. .HasColumnType("decimal(18,2)");
  200. b.Property<DateTime>("StartDate")
  201. .HasColumnType("datetime2");
  202. b.Property<string>("Type")
  203. .IsRequired()
  204. .HasColumnType("nvarchar(max)");
  205. b.Property<DateTime?>("UpdatedAtUtc")
  206. .HasColumnType("datetime2");
  207. b.HasKey("Id");
  208. b.HasIndex("InsurerId");
  209. b.ToTable("InsurancePolicies");
  210. });
  211. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Insurer", b =>
  212. {
  213. b.Property<long>("Id")
  214. .ValueGeneratedOnAdd()
  215. .HasColumnType("bigint");
  216. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  217. b.Property<string>("Address")
  218. .IsRequired()
  219. .HasColumnType("nvarchar(max)");
  220. b.Property<string>("City")
  221. .IsRequired()
  222. .HasColumnType("nvarchar(max)");
  223. b.Property<string>("Country")
  224. .IsRequired()
  225. .HasColumnType("nvarchar(max)");
  226. b.Property<DateTime>("CreatedAtUtc")
  227. .HasColumnType("datetime2");
  228. b.Property<DateTime>("DateOfBirth")
  229. .HasColumnType("datetime2");
  230. b.Property<DateTime?>("DeletedAtUtc")
  231. .HasColumnType("datetime2");
  232. b.Property<string>("Email")
  233. .IsRequired()
  234. .HasColumnType("nvarchar(max)");
  235. b.Property<string>("FirstName")
  236. .IsRequired()
  237. .HasColumnType("nvarchar(max)");
  238. b.Property<long>("InsuranceCompanyId")
  239. .HasColumnType("bigint");
  240. b.Property<string>("LastName")
  241. .IsRequired()
  242. .HasColumnType("nvarchar(max)");
  243. b.Property<string>("PhoneNumber")
  244. .IsRequired()
  245. .HasColumnType("nvarchar(max)");
  246. b.Property<string>("PostalCode")
  247. .IsRequired()
  248. .HasColumnType("nvarchar(max)");
  249. b.Property<DateTime?>("UpdatedAtUtc")
  250. .HasColumnType("datetime2");
  251. b.HasKey("Id");
  252. b.HasIndex("InsuranceCompanyId");
  253. b.ToTable("Insurers");
  254. });
  255. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.RefreshToken", b =>
  256. {
  257. b.Property<int>("Id")
  258. .ValueGeneratedOnAdd()
  259. .HasColumnType("int");
  260. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  261. b.Property<DateTime>("CreationDate")
  262. .HasColumnType("datetime2");
  263. b.Property<DateTime>("ExpiryDate")
  264. .HasColumnType("datetime2");
  265. b.Property<bool>("Invalidated")
  266. .HasColumnType("bit");
  267. b.Property<string>("JwtId")
  268. .IsRequired()
  269. .HasColumnType("nvarchar(max)");
  270. b.Property<string>("Token")
  271. .IsRequired()
  272. .HasColumnType("nvarchar(max)");
  273. b.Property<bool>("Used")
  274. .HasColumnType("bit");
  275. b.Property<int>("UserId")
  276. .HasColumnType("int");
  277. b.HasKey("Id");
  278. b.HasIndex("UserId");
  279. b.ToTable("RefreshTokens");
  280. });
  281. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Technology", b =>
  282. {
  283. b.Property<int>("TechnologyId")
  284. .ValueGeneratedOnAdd()
  285. .HasColumnType("int");
  286. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("TechnologyId"), 1L, 1);
  287. b.Property<string>("Name")
  288. .IsRequired()
  289. .HasMaxLength(128)
  290. .HasColumnType("nvarchar(128)");
  291. b.HasKey("TechnologyId");
  292. b.ToTable("Technologies");
  293. });
  294. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.TechnologyApplicant", b =>
  295. {
  296. b.Property<int>("Id")
  297. .ValueGeneratedOnAdd()
  298. .HasColumnType("int");
  299. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  300. b.Property<int>("ApplicantId")
  301. .HasColumnType("int");
  302. b.Property<int>("TechnologyId")
  303. .HasColumnType("int");
  304. b.HasKey("Id");
  305. b.HasIndex("ApplicantId");
  306. b.HasIndex("TechnologyId");
  307. b.ToTable("ApplicantTechnologies");
  308. });
  309. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.User", b =>
  310. {
  311. b.Property<int>("Id")
  312. .ValueGeneratedOnAdd()
  313. .HasColumnType("int");
  314. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  315. b.Property<int>("AccessFailedCount")
  316. .HasColumnType("int");
  317. b.Property<string>("ConcurrencyStamp")
  318. .IsConcurrencyToken()
  319. .HasColumnType("nvarchar(max)");
  320. b.Property<string>("Email")
  321. .HasMaxLength(256)
  322. .HasColumnType("nvarchar(256)");
  323. b.Property<bool>("EmailConfirmed")
  324. .HasColumnType("bit");
  325. b.Property<string>("FirstName")
  326. .IsRequired()
  327. .HasColumnType("nvarchar(max)");
  328. b.Property<bool>("IsEnabled")
  329. .ValueGeneratedOnAdd()
  330. .HasColumnType("bit")
  331. .HasDefaultValue(true);
  332. b.Property<string>("LastName")
  333. .IsRequired()
  334. .HasColumnType("nvarchar(max)");
  335. b.Property<bool>("LockoutEnabled")
  336. .HasColumnType("bit");
  337. b.Property<DateTimeOffset?>("LockoutEnd")
  338. .HasColumnType("datetimeoffset");
  339. b.Property<string>("NormalizedEmail")
  340. .HasMaxLength(256)
  341. .HasColumnType("nvarchar(256)");
  342. b.Property<string>("NormalizedUserName")
  343. .HasMaxLength(256)
  344. .HasColumnType("nvarchar(256)");
  345. b.Property<string>("PasswordHash")
  346. .HasColumnType("nvarchar(max)");
  347. b.Property<string>("PasswordResetToken")
  348. .HasColumnType("nvarchar(max)");
  349. b.Property<string>("PhoneNumber")
  350. .HasColumnType("nvarchar(max)");
  351. b.Property<bool>("PhoneNumberConfirmed")
  352. .HasColumnType("bit");
  353. b.Property<string>("SecurityStamp")
  354. .HasColumnType("nvarchar(max)");
  355. b.Property<bool>("TwoFactorEnabled")
  356. .HasColumnType("bit");
  357. b.Property<string>("UserName")
  358. .HasMaxLength(256)
  359. .HasColumnType("nvarchar(256)");
  360. b.HasKey("Id");
  361. b.HasIndex("NormalizedEmail")
  362. .HasDatabaseName("EmailIndex");
  363. b.HasIndex("NormalizedUserName")
  364. .IsUnique()
  365. .HasDatabaseName("UserNameIndex")
  366. .HasFilter("[NormalizedUserName] IS NOT NULL");
  367. b.ToTable("AspNetUsers", (string)null);
  368. });
  369. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.WebhookDefinition", b =>
  370. {
  371. b.Property<long>("Id")
  372. .ValueGeneratedOnAdd()
  373. .HasColumnType("bigint");
  374. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  375. b.Property<DateTime>("CreatedAtUtc")
  376. .HasColumnType("datetime2");
  377. b.Property<DateTime?>("DeletedAtUtc")
  378. .HasColumnType("datetime2");
  379. b.Property<string>("Description")
  380. .IsRequired()
  381. .HasColumnType("nvarchar(max)");
  382. b.Property<string>("DisplayName")
  383. .IsRequired()
  384. .HasMaxLength(100)
  385. .HasColumnType("nvarchar(100)");
  386. b.Property<string>("Name")
  387. .IsRequired()
  388. .HasMaxLength(100)
  389. .HasColumnType("nvarchar(100)");
  390. b.Property<DateTime?>("UpdatedAtUtc")
  391. .HasColumnType("datetime2");
  392. b.HasKey("Id");
  393. b.ToTable("WebhookDefinitions");
  394. });
  395. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.WebhookSubscription", b =>
  396. {
  397. b.Property<long>("Id")
  398. .ValueGeneratedOnAdd()
  399. .HasColumnType("bigint");
  400. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  401. b.Property<DateTime>("CreatedAtUtc")
  402. .HasColumnType("datetime2");
  403. b.Property<DateTime?>("DeletedAtUtc")
  404. .HasColumnType("datetime2");
  405. b.Property<bool>("IsActive")
  406. .HasColumnType("bit");
  407. b.Property<DateTime?>("UpdatedAtUtc")
  408. .HasColumnType("datetime2");
  409. b.Property<long>("WebhookDefinitionId")
  410. .HasColumnType("bigint");
  411. b.Property<string>("WebhookURL")
  412. .IsRequired()
  413. .HasColumnType("nvarchar(max)");
  414. b.HasKey("Id");
  415. b.HasIndex("WebhookDefinitionId");
  416. b.ToTable("WebhookSubscriptions");
  417. });
  418. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<int>", b =>
  419. {
  420. b.Property<int>("Id")
  421. .ValueGeneratedOnAdd()
  422. .HasColumnType("int");
  423. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  424. b.Property<string>("ClaimType")
  425. .HasColumnType("nvarchar(max)");
  426. b.Property<string>("ClaimValue")
  427. .HasColumnType("nvarchar(max)");
  428. b.Property<int>("RoleId")
  429. .HasColumnType("int");
  430. b.HasKey("Id");
  431. b.HasIndex("RoleId");
  432. b.ToTable("AspNetRoleClaims", (string)null);
  433. });
  434. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<int>", b =>
  435. {
  436. b.Property<int>("Id")
  437. .ValueGeneratedOnAdd()
  438. .HasColumnType("int");
  439. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  440. b.Property<string>("ClaimType")
  441. .HasColumnType("nvarchar(max)");
  442. b.Property<string>("ClaimValue")
  443. .HasColumnType("nvarchar(max)");
  444. b.Property<int>("UserId")
  445. .HasColumnType("int");
  446. b.HasKey("Id");
  447. b.HasIndex("UserId");
  448. b.ToTable("AspNetUserClaims", (string)null);
  449. });
  450. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<int>", b =>
  451. {
  452. b.Property<string>("LoginProvider")
  453. .HasColumnType("nvarchar(450)");
  454. b.Property<string>("ProviderKey")
  455. .HasColumnType("nvarchar(450)");
  456. b.Property<string>("ProviderDisplayName")
  457. .HasColumnType("nvarchar(max)");
  458. b.Property<int>("UserId")
  459. .HasColumnType("int");
  460. b.HasKey("LoginProvider", "ProviderKey");
  461. b.HasIndex("UserId");
  462. b.ToTable("AspNetUserLogins", (string)null);
  463. });
  464. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<int>", b =>
  465. {
  466. b.Property<int>("UserId")
  467. .HasColumnType("int");
  468. b.Property<int>("RoleId")
  469. .HasColumnType("int");
  470. b.HasKey("UserId", "RoleId");
  471. b.HasIndex("RoleId");
  472. b.ToTable("AspNetUserRoles", (string)null);
  473. });
  474. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<int>", b =>
  475. {
  476. b.Property<int>("UserId")
  477. .HasColumnType("int");
  478. b.Property<string>("LoginProvider")
  479. .HasColumnType("nvarchar(450)");
  480. b.Property<string>("Name")
  481. .HasColumnType("nvarchar(450)");
  482. b.Property<string>("Value")
  483. .HasColumnType("nvarchar(max)");
  484. b.HasKey("UserId", "LoginProvider", "Name");
  485. b.ToTable("AspNetUserTokens", (string)null);
  486. });
  487. modelBuilder.Entity("AdTechnology", b =>
  488. {
  489. b.HasOne("Diligent.WebAPI.Data.Entities.Ad", null)
  490. .WithMany()
  491. .HasForeignKey("AdsId")
  492. .OnDelete(DeleteBehavior.Cascade)
  493. .IsRequired();
  494. b.HasOne("Diligent.WebAPI.Data.Entities.Technology", null)
  495. .WithMany()
  496. .HasForeignKey("TechnologiesTechnologyId")
  497. .OnDelete(DeleteBehavior.Cascade)
  498. .IsRequired();
  499. });
  500. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Comment", b =>
  501. {
  502. b.HasOne("Diligent.WebAPI.Data.Entities.Applicant", "Applicant")
  503. .WithMany("Comments")
  504. .HasForeignKey("ApplicantId")
  505. .OnDelete(DeleteBehavior.Cascade)
  506. .IsRequired();
  507. b.HasOne("Diligent.WebAPI.Data.Entities.User", "User")
  508. .WithMany("Comments")
  509. .HasForeignKey("UserId")
  510. .OnDelete(DeleteBehavior.Cascade)
  511. .IsRequired();
  512. b.Navigation("Applicant");
  513. b.Navigation("User");
  514. });
  515. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.InsurancePolicy", b =>
  516. {
  517. b.HasOne("Diligent.WebAPI.Data.Entities.Insurer", "Insurer")
  518. .WithMany()
  519. .HasForeignKey("InsurerId")
  520. .OnDelete(DeleteBehavior.Cascade)
  521. .IsRequired();
  522. b.Navigation("Insurer");
  523. });
  524. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Insurer", b =>
  525. {
  526. b.HasOne("Diligent.WebAPI.Data.Entities.InsuranceCompany", "InsuranceCompany")
  527. .WithMany()
  528. .HasForeignKey("InsuranceCompanyId")
  529. .OnDelete(DeleteBehavior.Cascade)
  530. .IsRequired();
  531. b.Navigation("InsuranceCompany");
  532. });
  533. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.RefreshToken", b =>
  534. {
  535. b.HasOne("Diligent.WebAPI.Data.Entities.User", "User")
  536. .WithMany()
  537. .HasForeignKey("UserId")
  538. .OnDelete(DeleteBehavior.Cascade)
  539. .IsRequired();
  540. b.Navigation("User");
  541. });
  542. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.TechnologyApplicant", b =>
  543. {
  544. b.HasOne("Diligent.WebAPI.Data.Entities.Applicant", "Applicant")
  545. .WithMany("TechnologyApplicants")
  546. .HasForeignKey("ApplicantId")
  547. .OnDelete(DeleteBehavior.Cascade)
  548. .IsRequired();
  549. b.HasOne("Diligent.WebAPI.Data.Entities.Technology", "Technology")
  550. .WithMany("TechnologyApplicants")
  551. .HasForeignKey("TechnologyId")
  552. .OnDelete(DeleteBehavior.Cascade)
  553. .IsRequired();
  554. b.Navigation("Applicant");
  555. b.Navigation("Technology");
  556. });
  557. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.WebhookSubscription", b =>
  558. {
  559. b.HasOne("Diligent.WebAPI.Data.Entities.WebhookDefinition", "WebhookDefinition")
  560. .WithMany()
  561. .HasForeignKey("WebhookDefinitionId")
  562. .OnDelete(DeleteBehavior.Cascade)
  563. .IsRequired();
  564. b.Navigation("WebhookDefinition");
  565. });
  566. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<int>", b =>
  567. {
  568. b.HasOne("Diligent.WebAPI.Data.Entities.AppRole", null)
  569. .WithMany()
  570. .HasForeignKey("RoleId")
  571. .OnDelete(DeleteBehavior.Cascade)
  572. .IsRequired();
  573. });
  574. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<int>", b =>
  575. {
  576. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  577. .WithMany()
  578. .HasForeignKey("UserId")
  579. .OnDelete(DeleteBehavior.Cascade)
  580. .IsRequired();
  581. });
  582. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<int>", b =>
  583. {
  584. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  585. .WithMany()
  586. .HasForeignKey("UserId")
  587. .OnDelete(DeleteBehavior.Cascade)
  588. .IsRequired();
  589. });
  590. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<int>", b =>
  591. {
  592. b.HasOne("Diligent.WebAPI.Data.Entities.AppRole", null)
  593. .WithMany()
  594. .HasForeignKey("RoleId")
  595. .OnDelete(DeleteBehavior.Cascade)
  596. .IsRequired();
  597. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  598. .WithMany()
  599. .HasForeignKey("UserId")
  600. .OnDelete(DeleteBehavior.Cascade)
  601. .IsRequired();
  602. });
  603. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<int>", b =>
  604. {
  605. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  606. .WithMany()
  607. .HasForeignKey("UserId")
  608. .OnDelete(DeleteBehavior.Cascade)
  609. .IsRequired();
  610. });
  611. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Applicant", b =>
  612. {
  613. b.Navigation("Comments");
  614. b.Navigation("TechnologyApplicants");
  615. });
  616. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Technology", b =>
  617. {
  618. b.Navigation("TechnologyApplicants");
  619. });
  620. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.User", b =>
  621. {
  622. b.Navigation("Comments");
  623. });
  624. #pragma warning restore 612, 618
  625. }
  626. }
  627. }