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

20230221101523_AddedDeletedFieldToFileEntity.Designer.cs 44KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227
  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("20230221101523_AddedDeletedFieldToFileEntity")]
  14. partial class AddedDeletedFieldToFileEntity
  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>("Gender")
  102. .IsRequired()
  103. .HasColumnType("nvarchar(max)");
  104. b.Property<string>("GithubLink")
  105. .HasColumnType("nvarchar(max)");
  106. b.Property<string>("LastName")
  107. .IsRequired()
  108. .HasMaxLength(128)
  109. .HasColumnType("nvarchar(128)");
  110. b.Property<string>("LinkedlnLink")
  111. .HasColumnType("nvarchar(max)");
  112. b.Property<string>("PhoneNumber")
  113. .IsRequired()
  114. .HasMaxLength(30)
  115. .HasColumnType("nvarchar(30)");
  116. b.Property<string>("Position")
  117. .IsRequired()
  118. .HasMaxLength(128)
  119. .HasColumnType("nvarchar(128)");
  120. b.Property<string>("ProfessionalQualification")
  121. .IsRequired()
  122. .HasMaxLength(128)
  123. .HasColumnType("nvarchar(128)");
  124. b.Property<string>("TypeOfEmployment")
  125. .IsRequired()
  126. .HasColumnType("nvarchar(max)");
  127. b.HasKey("ApplicantId");
  128. b.ToTable("Applicants");
  129. });
  130. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.AppRole", b =>
  131. {
  132. b.Property<int>("Id")
  133. .ValueGeneratedOnAdd()
  134. .HasColumnType("int");
  135. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  136. b.Property<string>("ConcurrencyStamp")
  137. .IsConcurrencyToken()
  138. .HasColumnType("nvarchar(max)");
  139. b.Property<string>("Name")
  140. .HasMaxLength(256)
  141. .HasColumnType("nvarchar(256)");
  142. b.Property<string>("NormalizedName")
  143. .HasMaxLength(256)
  144. .HasColumnType("nvarchar(256)");
  145. b.HasKey("Id");
  146. b.HasIndex("NormalizedName")
  147. .IsUnique()
  148. .HasDatabaseName("RoleNameIndex")
  149. .HasFilter("[NormalizedName] IS NOT NULL");
  150. b.ToTable("AspNetRoles", (string)null);
  151. });
  152. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Category", b =>
  153. {
  154. b.Property<int>("Id")
  155. .ValueGeneratedOnAdd()
  156. .HasColumnType("int");
  157. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  158. b.Property<string>("Name")
  159. .IsRequired()
  160. .HasColumnType("nvarchar(max)");
  161. b.HasKey("Id");
  162. b.ToTable("Categories");
  163. });
  164. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Comment", b =>
  165. {
  166. b.Property<int>("Id")
  167. .ValueGeneratedOnAdd()
  168. .HasColumnType("int");
  169. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  170. b.Property<int>("ApplicantId")
  171. .HasColumnType("int");
  172. b.Property<string>("Content")
  173. .IsRequired()
  174. .HasMaxLength(1024)
  175. .HasColumnType("nvarchar(1024)");
  176. b.Property<DateTime>("DateOfSending")
  177. .HasColumnType("datetime2");
  178. b.Property<int>("UserId")
  179. .HasColumnType("int");
  180. b.HasKey("Id");
  181. b.HasIndex("ApplicantId");
  182. b.HasIndex("UserId");
  183. b.ToTable("Comments");
  184. });
  185. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.FileEntity", b =>
  186. {
  187. b.Property<int>("Id")
  188. .ValueGeneratedOnAdd()
  189. .HasColumnType("int");
  190. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  191. b.Property<int>("CategoryId")
  192. .HasColumnType("int");
  193. b.Property<bool>("Deleted")
  194. .HasColumnType("bit");
  195. b.Property<Guid>("DocumentId")
  196. .HasColumnType("uniqueidentifier");
  197. b.Property<string>("Title")
  198. .IsRequired()
  199. .HasColumnType("nvarchar(max)");
  200. b.HasKey("Id");
  201. b.HasIndex("CategoryId");
  202. b.ToTable("Files");
  203. });
  204. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.InsuranceCompany", b =>
  205. {
  206. b.Property<long>("Id")
  207. .ValueGeneratedOnAdd()
  208. .HasColumnType("bigint");
  209. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  210. b.Property<string>("City")
  211. .IsRequired()
  212. .HasColumnType("nvarchar(max)");
  213. b.Property<string>("Country")
  214. .IsRequired()
  215. .HasColumnType("nvarchar(max)");
  216. b.Property<DateTime>("CreatedAtUtc")
  217. .HasColumnType("datetime2");
  218. b.Property<DateTime?>("DeletedAtUtc")
  219. .HasColumnType("datetime2");
  220. b.Property<string>("Fax")
  221. .IsRequired()
  222. .HasColumnType("nvarchar(max)");
  223. b.Property<string>("LegalAddress")
  224. .IsRequired()
  225. .HasColumnType("nvarchar(max)");
  226. b.Property<string>("LegalEmail")
  227. .IsRequired()
  228. .HasColumnType("nvarchar(max)");
  229. b.Property<string>("Name")
  230. .IsRequired()
  231. .HasColumnType("nvarchar(max)");
  232. b.Property<string>("PhoneNumber")
  233. .IsRequired()
  234. .HasColumnType("nvarchar(max)");
  235. b.Property<string>("PostalCode")
  236. .IsRequired()
  237. .HasColumnType("nvarchar(max)");
  238. b.Property<DateTime?>("UpdatedAtUtc")
  239. .HasColumnType("datetime2");
  240. b.HasKey("Id");
  241. b.ToTable("InsuranceCompanies");
  242. });
  243. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.InsurancePolicy", b =>
  244. {
  245. b.Property<long>("Id")
  246. .ValueGeneratedOnAdd()
  247. .HasColumnType("bigint");
  248. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  249. b.Property<DateTime>("CreatedAtUtc")
  250. .HasColumnType("datetime2");
  251. b.Property<DateTime?>("DeletedAtUtc")
  252. .HasColumnType("datetime2");
  253. b.Property<DateTime>("EndDate")
  254. .HasColumnType("datetime2");
  255. b.Property<long>("InsurerId")
  256. .HasColumnType("bigint");
  257. b.Property<decimal>("Premium")
  258. .HasColumnType("decimal(18,2)");
  259. b.Property<DateTime>("StartDate")
  260. .HasColumnType("datetime2");
  261. b.Property<string>("Type")
  262. .IsRequired()
  263. .HasColumnType("nvarchar(max)");
  264. b.Property<DateTime?>("UpdatedAtUtc")
  265. .HasColumnType("datetime2");
  266. b.HasKey("Id");
  267. b.HasIndex("InsurerId");
  268. b.ToTable("InsurancePolicies");
  269. });
  270. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Insurer", b =>
  271. {
  272. b.Property<long>("Id")
  273. .ValueGeneratedOnAdd()
  274. .HasColumnType("bigint");
  275. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  276. b.Property<string>("Address")
  277. .IsRequired()
  278. .HasColumnType("nvarchar(max)");
  279. b.Property<string>("City")
  280. .IsRequired()
  281. .HasColumnType("nvarchar(max)");
  282. b.Property<string>("Country")
  283. .IsRequired()
  284. .HasColumnType("nvarchar(max)");
  285. b.Property<DateTime>("CreatedAtUtc")
  286. .HasColumnType("datetime2");
  287. b.Property<DateTime>("DateOfBirth")
  288. .HasColumnType("datetime2");
  289. b.Property<DateTime?>("DeletedAtUtc")
  290. .HasColumnType("datetime2");
  291. b.Property<string>("Email")
  292. .IsRequired()
  293. .HasColumnType("nvarchar(max)");
  294. b.Property<string>("FirstName")
  295. .IsRequired()
  296. .HasColumnType("nvarchar(max)");
  297. b.Property<long>("InsuranceCompanyId")
  298. .HasColumnType("bigint");
  299. b.Property<string>("LastName")
  300. .IsRequired()
  301. .HasColumnType("nvarchar(max)");
  302. b.Property<string>("PhoneNumber")
  303. .IsRequired()
  304. .HasColumnType("nvarchar(max)");
  305. b.Property<string>("PostalCode")
  306. .IsRequired()
  307. .HasColumnType("nvarchar(max)");
  308. b.Property<DateTime?>("UpdatedAtUtc")
  309. .HasColumnType("datetime2");
  310. b.HasKey("Id");
  311. b.HasIndex("InsuranceCompanyId");
  312. b.ToTable("Insurers");
  313. });
  314. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Pattern", b =>
  315. {
  316. b.Property<int>("Id")
  317. .ValueGeneratedOnAdd()
  318. .HasColumnType("int");
  319. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  320. b.Property<DateTime>("CreatedAt")
  321. .HasColumnType("datetime2");
  322. b.Property<string>("Message")
  323. .IsRequired()
  324. .HasColumnType("nvarchar(max)");
  325. b.Property<int>("SelectionLevelId")
  326. .HasColumnType("int");
  327. b.Property<string>("Title")
  328. .IsRequired()
  329. .HasColumnType("nvarchar(max)");
  330. b.HasKey("Id");
  331. b.HasIndex("SelectionLevelId");
  332. b.ToTable("Patterns");
  333. });
  334. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.RefreshToken", b =>
  335. {
  336. b.Property<int>("Id")
  337. .ValueGeneratedOnAdd()
  338. .HasColumnType("int");
  339. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  340. b.Property<DateTime>("CreationDate")
  341. .HasColumnType("datetime2");
  342. b.Property<DateTime>("ExpiryDate")
  343. .HasColumnType("datetime2");
  344. b.Property<bool>("Invalidated")
  345. .HasColumnType("bit");
  346. b.Property<string>("JwtId")
  347. .IsRequired()
  348. .HasColumnType("nvarchar(max)");
  349. b.Property<string>("Token")
  350. .IsRequired()
  351. .HasColumnType("nvarchar(max)");
  352. b.Property<bool>("Used")
  353. .HasColumnType("bit");
  354. b.Property<int>("UserId")
  355. .HasColumnType("int");
  356. b.HasKey("Id");
  357. b.HasIndex("UserId");
  358. b.ToTable("RefreshTokens");
  359. });
  360. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.SelectionLevel", b =>
  361. {
  362. b.Property<int>("Id")
  363. .ValueGeneratedOnAdd()
  364. .HasColumnType("int");
  365. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  366. b.Property<string>("Name")
  367. .IsRequired()
  368. .HasColumnType("nvarchar(max)");
  369. b.HasKey("Id");
  370. b.ToTable("SelectionLevels");
  371. b.HasData(
  372. new
  373. {
  374. Id = 1,
  375. Name = "HR intervju"
  376. },
  377. new
  378. {
  379. Id = 2,
  380. Name = "Screening test"
  381. },
  382. new
  383. {
  384. Id = 3,
  385. Name = "Tehnicki intervju"
  386. },
  387. new
  388. {
  389. Id = 4,
  390. Name = "Konacna odluka"
  391. });
  392. });
  393. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.SelectionProcess", b =>
  394. {
  395. b.Property<int>("Id")
  396. .ValueGeneratedOnAdd()
  397. .HasColumnType("int");
  398. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  399. b.Property<int>("ApplicantId")
  400. .HasColumnType("int");
  401. b.Property<string>("Comment")
  402. .HasColumnType("nvarchar(max)");
  403. b.Property<DateTime?>("Date")
  404. .HasColumnType("datetime2");
  405. b.Property<string>("Link")
  406. .HasColumnType("nvarchar(max)");
  407. b.Property<string>("Name")
  408. .IsRequired()
  409. .HasColumnType("nvarchar(max)");
  410. b.Property<int?>("SchedulerId")
  411. .HasColumnType("int");
  412. b.Property<int>("SelectionLevelId")
  413. .HasColumnType("int");
  414. b.Property<string>("Status")
  415. .IsRequired()
  416. .HasColumnType("nvarchar(max)");
  417. b.HasKey("Id");
  418. b.HasIndex("ApplicantId");
  419. b.HasIndex("SchedulerId");
  420. b.HasIndex("SelectionLevelId");
  421. b.ToTable("SelectionProcesses");
  422. });
  423. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Tag", b =>
  424. {
  425. b.Property<int>("Id")
  426. .ValueGeneratedOnAdd()
  427. .HasColumnType("int");
  428. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  429. b.Property<string>("Name")
  430. .IsRequired()
  431. .HasColumnType("nvarchar(max)");
  432. b.HasKey("Id");
  433. b.ToTable("Tags");
  434. });
  435. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Technology", b =>
  436. {
  437. b.Property<int>("TechnologyId")
  438. .ValueGeneratedOnAdd()
  439. .HasColumnType("int");
  440. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("TechnologyId"), 1L, 1);
  441. b.Property<string>("Name")
  442. .IsRequired()
  443. .HasMaxLength(128)
  444. .HasColumnType("nvarchar(128)");
  445. b.Property<string>("TechnologyType")
  446. .IsRequired()
  447. .HasColumnType("nvarchar(max)");
  448. b.HasKey("TechnologyId");
  449. b.ToTable("Technologies");
  450. });
  451. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.TechnologyApplicant", b =>
  452. {
  453. b.Property<int>("Id")
  454. .ValueGeneratedOnAdd()
  455. .HasColumnType("int");
  456. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  457. b.Property<int>("ApplicantId")
  458. .HasColumnType("int");
  459. b.Property<int>("TechnologyId")
  460. .HasColumnType("int");
  461. b.HasKey("Id");
  462. b.HasIndex("ApplicantId");
  463. b.HasIndex("TechnologyId");
  464. b.ToTable("ApplicantTechnologies");
  465. });
  466. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.User", b =>
  467. {
  468. b.Property<int>("Id")
  469. .ValueGeneratedOnAdd()
  470. .HasColumnType("int");
  471. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  472. b.Property<int>("AccessFailedCount")
  473. .HasColumnType("int");
  474. b.Property<string>("ConcurrencyStamp")
  475. .IsConcurrencyToken()
  476. .HasColumnType("nvarchar(max)");
  477. b.Property<string>("Email")
  478. .HasMaxLength(256)
  479. .HasColumnType("nvarchar(256)");
  480. b.Property<bool>("EmailConfirmed")
  481. .HasColumnType("bit");
  482. b.Property<string>("FirstName")
  483. .IsRequired()
  484. .HasColumnType("nvarchar(max)");
  485. b.Property<bool?>("IsEnabled")
  486. .ValueGeneratedOnAdd()
  487. .HasColumnType("bit")
  488. .HasDefaultValue(true);
  489. b.Property<string>("LastName")
  490. .IsRequired()
  491. .HasColumnType("nvarchar(max)");
  492. b.Property<string>("LinkedIn")
  493. .HasColumnType("nvarchar(max)");
  494. b.Property<bool>("LockoutEnabled")
  495. .HasColumnType("bit");
  496. b.Property<DateTimeOffset?>("LockoutEnd")
  497. .HasColumnType("datetimeoffset");
  498. b.Property<string>("NormalizedEmail")
  499. .HasMaxLength(256)
  500. .HasColumnType("nvarchar(256)");
  501. b.Property<string>("NormalizedUserName")
  502. .HasMaxLength(256)
  503. .HasColumnType("nvarchar(256)");
  504. b.Property<string>("PasswordHash")
  505. .HasColumnType("nvarchar(max)");
  506. b.Property<string>("PhoneNumber")
  507. .HasColumnType("nvarchar(max)");
  508. b.Property<bool>("PhoneNumberConfirmed")
  509. .HasColumnType("bit");
  510. b.Property<string>("Position")
  511. .HasColumnType("nvarchar(max)");
  512. b.Property<string>("SecurityStamp")
  513. .HasColumnType("nvarchar(max)");
  514. b.Property<bool>("TwoFactorEnabled")
  515. .HasColumnType("bit");
  516. b.Property<string>("UserName")
  517. .HasMaxLength(256)
  518. .HasColumnType("nvarchar(256)");
  519. b.HasKey("Id");
  520. b.HasIndex("NormalizedEmail")
  521. .HasDatabaseName("EmailIndex");
  522. b.HasIndex("NormalizedUserName")
  523. .IsUnique()
  524. .HasDatabaseName("UserNameIndex")
  525. .HasFilter("[NormalizedUserName] IS NOT NULL");
  526. b.ToTable("AspNetUsers", (string)null);
  527. });
  528. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.UserCategories", b =>
  529. {
  530. b.Property<int>("Id")
  531. .ValueGeneratedOnAdd()
  532. .HasColumnType("int");
  533. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  534. b.Property<int>("CategoryId")
  535. .HasColumnType("int");
  536. b.Property<int>("UserId")
  537. .HasColumnType("int");
  538. b.HasKey("Id");
  539. b.HasIndex("CategoryId");
  540. b.HasIndex("UserId");
  541. b.ToTable("UserCategories");
  542. });
  543. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.WebhookDefinition", b =>
  544. {
  545. b.Property<long>("Id")
  546. .ValueGeneratedOnAdd()
  547. .HasColumnType("bigint");
  548. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  549. b.Property<DateTime>("CreatedAtUtc")
  550. .HasColumnType("datetime2");
  551. b.Property<DateTime?>("DeletedAtUtc")
  552. .HasColumnType("datetime2");
  553. b.Property<string>("Description")
  554. .IsRequired()
  555. .HasColumnType("nvarchar(max)");
  556. b.Property<string>("DisplayName")
  557. .IsRequired()
  558. .HasMaxLength(100)
  559. .HasColumnType("nvarchar(100)");
  560. b.Property<string>("Name")
  561. .IsRequired()
  562. .HasMaxLength(100)
  563. .HasColumnType("nvarchar(100)");
  564. b.Property<DateTime?>("UpdatedAtUtc")
  565. .HasColumnType("datetime2");
  566. b.HasKey("Id");
  567. b.ToTable("WebhookDefinitions");
  568. });
  569. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.WebhookSubscription", b =>
  570. {
  571. b.Property<long>("Id")
  572. .ValueGeneratedOnAdd()
  573. .HasColumnType("bigint");
  574. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"), 1L, 1);
  575. b.Property<DateTime>("CreatedAtUtc")
  576. .HasColumnType("datetime2");
  577. b.Property<DateTime?>("DeletedAtUtc")
  578. .HasColumnType("datetime2");
  579. b.Property<bool>("IsActive")
  580. .HasColumnType("bit");
  581. b.Property<DateTime?>("UpdatedAtUtc")
  582. .HasColumnType("datetime2");
  583. b.Property<long>("WebhookDefinitionId")
  584. .HasColumnType("bigint");
  585. b.Property<string>("WebhookURL")
  586. .IsRequired()
  587. .HasColumnType("nvarchar(max)");
  588. b.HasKey("Id");
  589. b.HasIndex("WebhookDefinitionId");
  590. b.ToTable("WebhookSubscriptions");
  591. });
  592. modelBuilder.Entity("FileEntityTag", b =>
  593. {
  594. b.Property<int>("FilesId")
  595. .HasColumnType("int");
  596. b.Property<int>("TagsId")
  597. .HasColumnType("int");
  598. b.HasKey("FilesId", "TagsId");
  599. b.HasIndex("TagsId");
  600. b.ToTable("FileEntityTag");
  601. });
  602. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<int>", b =>
  603. {
  604. b.Property<int>("Id")
  605. .ValueGeneratedOnAdd()
  606. .HasColumnType("int");
  607. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  608. b.Property<string>("ClaimType")
  609. .HasColumnType("nvarchar(max)");
  610. b.Property<string>("ClaimValue")
  611. .HasColumnType("nvarchar(max)");
  612. b.Property<int>("RoleId")
  613. .HasColumnType("int");
  614. b.HasKey("Id");
  615. b.HasIndex("RoleId");
  616. b.ToTable("AspNetRoleClaims", (string)null);
  617. });
  618. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<int>", b =>
  619. {
  620. b.Property<int>("Id")
  621. .ValueGeneratedOnAdd()
  622. .HasColumnType("int");
  623. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"), 1L, 1);
  624. b.Property<string>("ClaimType")
  625. .HasColumnType("nvarchar(max)");
  626. b.Property<string>("ClaimValue")
  627. .HasColumnType("nvarchar(max)");
  628. b.Property<int>("UserId")
  629. .HasColumnType("int");
  630. b.HasKey("Id");
  631. b.HasIndex("UserId");
  632. b.ToTable("AspNetUserClaims", (string)null);
  633. });
  634. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<int>", b =>
  635. {
  636. b.Property<string>("LoginProvider")
  637. .HasColumnType("nvarchar(450)");
  638. b.Property<string>("ProviderKey")
  639. .HasColumnType("nvarchar(450)");
  640. b.Property<string>("ProviderDisplayName")
  641. .HasColumnType("nvarchar(max)");
  642. b.Property<int>("UserId")
  643. .HasColumnType("int");
  644. b.HasKey("LoginProvider", "ProviderKey");
  645. b.HasIndex("UserId");
  646. b.ToTable("AspNetUserLogins", (string)null);
  647. });
  648. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<int>", b =>
  649. {
  650. b.Property<int>("UserId")
  651. .HasColumnType("int");
  652. b.Property<int>("RoleId")
  653. .HasColumnType("int");
  654. b.HasKey("UserId", "RoleId");
  655. b.HasIndex("RoleId");
  656. b.ToTable("AspNetUserRoles", (string)null);
  657. });
  658. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<int>", b =>
  659. {
  660. b.Property<int>("UserId")
  661. .HasColumnType("int");
  662. b.Property<string>("LoginProvider")
  663. .HasColumnType("nvarchar(450)");
  664. b.Property<string>("Name")
  665. .HasColumnType("nvarchar(450)");
  666. b.Property<string>("Value")
  667. .HasColumnType("nvarchar(max)");
  668. b.HasKey("UserId", "LoginProvider", "Name");
  669. b.ToTable("AspNetUserTokens", (string)null);
  670. });
  671. modelBuilder.Entity("AdApplicant", b =>
  672. {
  673. b.HasOne("Diligent.WebAPI.Data.Entities.Ad", null)
  674. .WithMany()
  675. .HasForeignKey("AdsId")
  676. .OnDelete(DeleteBehavior.Cascade)
  677. .IsRequired();
  678. b.HasOne("Diligent.WebAPI.Data.Entities.Applicant", null)
  679. .WithMany()
  680. .HasForeignKey("ApplicantsApplicantId")
  681. .OnDelete(DeleteBehavior.Cascade)
  682. .IsRequired();
  683. });
  684. modelBuilder.Entity("AdTechnology", b =>
  685. {
  686. b.HasOne("Diligent.WebAPI.Data.Entities.Ad", null)
  687. .WithMany()
  688. .HasForeignKey("AdsId")
  689. .OnDelete(DeleteBehavior.Cascade)
  690. .IsRequired();
  691. b.HasOne("Diligent.WebAPI.Data.Entities.Technology", null)
  692. .WithMany()
  693. .HasForeignKey("TechnologiesTechnologyId")
  694. .OnDelete(DeleteBehavior.Cascade)
  695. .IsRequired();
  696. });
  697. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Comment", b =>
  698. {
  699. b.HasOne("Diligent.WebAPI.Data.Entities.Applicant", "Applicant")
  700. .WithMany("Comments")
  701. .HasForeignKey("ApplicantId")
  702. .OnDelete(DeleteBehavior.Cascade)
  703. .IsRequired();
  704. b.HasOne("Diligent.WebAPI.Data.Entities.User", "User")
  705. .WithMany("Comments")
  706. .HasForeignKey("UserId")
  707. .OnDelete(DeleteBehavior.Cascade)
  708. .IsRequired();
  709. b.Navigation("Applicant");
  710. b.Navigation("User");
  711. });
  712. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.FileEntity", b =>
  713. {
  714. b.HasOne("Diligent.WebAPI.Data.Entities.Category", "Category")
  715. .WithMany("Files")
  716. .HasForeignKey("CategoryId")
  717. .OnDelete(DeleteBehavior.Cascade)
  718. .IsRequired();
  719. b.Navigation("Category");
  720. });
  721. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.InsurancePolicy", b =>
  722. {
  723. b.HasOne("Diligent.WebAPI.Data.Entities.Insurer", "Insurer")
  724. .WithMany()
  725. .HasForeignKey("InsurerId")
  726. .OnDelete(DeleteBehavior.Cascade)
  727. .IsRequired();
  728. b.Navigation("Insurer");
  729. });
  730. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Insurer", b =>
  731. {
  732. b.HasOne("Diligent.WebAPI.Data.Entities.InsuranceCompany", "InsuranceCompany")
  733. .WithMany()
  734. .HasForeignKey("InsuranceCompanyId")
  735. .OnDelete(DeleteBehavior.Cascade)
  736. .IsRequired();
  737. b.Navigation("InsuranceCompany");
  738. });
  739. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Pattern", b =>
  740. {
  741. b.HasOne("Diligent.WebAPI.Data.Entities.SelectionLevel", "SelectionLevel")
  742. .WithMany()
  743. .HasForeignKey("SelectionLevelId")
  744. .OnDelete(DeleteBehavior.Cascade)
  745. .IsRequired();
  746. b.Navigation("SelectionLevel");
  747. });
  748. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.RefreshToken", b =>
  749. {
  750. b.HasOne("Diligent.WebAPI.Data.Entities.User", "User")
  751. .WithMany()
  752. .HasForeignKey("UserId")
  753. .OnDelete(DeleteBehavior.Cascade)
  754. .IsRequired();
  755. b.Navigation("User");
  756. });
  757. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.SelectionProcess", b =>
  758. {
  759. b.HasOne("Diligent.WebAPI.Data.Entities.Applicant", "Applicant")
  760. .WithMany("SelectionProcesses")
  761. .HasForeignKey("ApplicantId")
  762. .OnDelete(DeleteBehavior.Cascade)
  763. .IsRequired();
  764. b.HasOne("Diligent.WebAPI.Data.Entities.User", "Scheduler")
  765. .WithMany("Processes")
  766. .HasForeignKey("SchedulerId")
  767. .OnDelete(DeleteBehavior.SetNull);
  768. b.HasOne("Diligent.WebAPI.Data.Entities.SelectionLevel", "SelectionLevel")
  769. .WithMany("SelectionProcesses")
  770. .HasForeignKey("SelectionLevelId")
  771. .OnDelete(DeleteBehavior.Cascade)
  772. .IsRequired();
  773. b.Navigation("Applicant");
  774. b.Navigation("Scheduler");
  775. b.Navigation("SelectionLevel");
  776. });
  777. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.TechnologyApplicant", b =>
  778. {
  779. b.HasOne("Diligent.WebAPI.Data.Entities.Applicant", "Applicant")
  780. .WithMany("TechnologyApplicants")
  781. .HasForeignKey("ApplicantId")
  782. .OnDelete(DeleteBehavior.Cascade)
  783. .IsRequired();
  784. b.HasOne("Diligent.WebAPI.Data.Entities.Technology", "Technology")
  785. .WithMany("TechnologyApplicants")
  786. .HasForeignKey("TechnologyId")
  787. .OnDelete(DeleteBehavior.Cascade)
  788. .IsRequired();
  789. b.Navigation("Applicant");
  790. b.Navigation("Technology");
  791. });
  792. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.UserCategories", b =>
  793. {
  794. b.HasOne("Diligent.WebAPI.Data.Entities.Category", null)
  795. .WithMany("UserCategories")
  796. .HasForeignKey("CategoryId")
  797. .OnDelete(DeleteBehavior.Cascade)
  798. .IsRequired();
  799. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  800. .WithMany("UserCategories")
  801. .HasForeignKey("UserId")
  802. .OnDelete(DeleteBehavior.Cascade)
  803. .IsRequired();
  804. });
  805. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.WebhookSubscription", b =>
  806. {
  807. b.HasOne("Diligent.WebAPI.Data.Entities.WebhookDefinition", "WebhookDefinition")
  808. .WithMany()
  809. .HasForeignKey("WebhookDefinitionId")
  810. .OnDelete(DeleteBehavior.Cascade)
  811. .IsRequired();
  812. b.Navigation("WebhookDefinition");
  813. });
  814. modelBuilder.Entity("FileEntityTag", b =>
  815. {
  816. b.HasOne("Diligent.WebAPI.Data.Entities.FileEntity", null)
  817. .WithMany()
  818. .HasForeignKey("FilesId")
  819. .OnDelete(DeleteBehavior.Cascade)
  820. .IsRequired();
  821. b.HasOne("Diligent.WebAPI.Data.Entities.Tag", null)
  822. .WithMany()
  823. .HasForeignKey("TagsId")
  824. .OnDelete(DeleteBehavior.Cascade)
  825. .IsRequired();
  826. });
  827. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<int>", b =>
  828. {
  829. b.HasOne("Diligent.WebAPI.Data.Entities.AppRole", null)
  830. .WithMany()
  831. .HasForeignKey("RoleId")
  832. .OnDelete(DeleteBehavior.Cascade)
  833. .IsRequired();
  834. });
  835. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<int>", b =>
  836. {
  837. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  838. .WithMany()
  839. .HasForeignKey("UserId")
  840. .OnDelete(DeleteBehavior.Cascade)
  841. .IsRequired();
  842. });
  843. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<int>", b =>
  844. {
  845. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  846. .WithMany()
  847. .HasForeignKey("UserId")
  848. .OnDelete(DeleteBehavior.Cascade)
  849. .IsRequired();
  850. });
  851. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<int>", b =>
  852. {
  853. b.HasOne("Diligent.WebAPI.Data.Entities.AppRole", null)
  854. .WithMany()
  855. .HasForeignKey("RoleId")
  856. .OnDelete(DeleteBehavior.Cascade)
  857. .IsRequired();
  858. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  859. .WithMany()
  860. .HasForeignKey("UserId")
  861. .OnDelete(DeleteBehavior.Cascade)
  862. .IsRequired();
  863. });
  864. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<int>", b =>
  865. {
  866. b.HasOne("Diligent.WebAPI.Data.Entities.User", null)
  867. .WithMany()
  868. .HasForeignKey("UserId")
  869. .OnDelete(DeleteBehavior.Cascade)
  870. .IsRequired();
  871. });
  872. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Applicant", b =>
  873. {
  874. b.Navigation("Comments");
  875. b.Navigation("SelectionProcesses");
  876. b.Navigation("TechnologyApplicants");
  877. });
  878. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Category", b =>
  879. {
  880. b.Navigation("Files");
  881. b.Navigation("UserCategories");
  882. });
  883. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.SelectionLevel", b =>
  884. {
  885. b.Navigation("SelectionProcesses");
  886. });
  887. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.Technology", b =>
  888. {
  889. b.Navigation("TechnologyApplicants");
  890. });
  891. modelBuilder.Entity("Diligent.WebAPI.Data.Entities.User", b =>
  892. {
  893. b.Navigation("Comments");
  894. b.Navigation("Processes");
  895. b.Navigation("UserCategories");
  896. });
  897. #pragma warning restore 612, 618
  898. }
  899. }
  900. }