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

DatabaseContextModelSnapshot.cs 36KB

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