You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20221207162122_UserUpdate.Designer.cs 38KB

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