20240313083213_attendance.Designer.cs 72 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966
  1. // <auto-generated />
  2. using System;
  3. using MTWorkHR.Infrastructure.DBContext;
  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 MTWorkHR.Infrastructure.Migrations
  11. {
  12. [DbContext(typeof(HRDataContext))]
  13. [Migration("20240313083213_attendance")]
  14. partial class attendance
  15. {
  16. /// <inheritdoc />
  17. protected override void BuildTargetModel(ModelBuilder modelBuilder)
  18. {
  19. #pragma warning disable 612, 618
  20. modelBuilder
  21. .HasAnnotation("ProductVersion", "8.0.1")
  22. .HasAnnotation("Relational:MaxIdentifierLength", 128);
  23. SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
  24. modelBuilder.Entity("ApplicationRoleApplicationUser", b =>
  25. {
  26. b.Property<string>("UserRolesId")
  27. .HasColumnType("nvarchar(450)");
  28. b.Property<string>("UsersId")
  29. .HasColumnType("nvarchar(450)");
  30. b.HasKey("UserRolesId", "UsersId");
  31. b.HasIndex("UsersId");
  32. b.ToTable("ApplicationRoleApplicationUser");
  33. });
  34. modelBuilder.Entity("MTWorkHR.Core.Entities.Attendance", b =>
  35. {
  36. b.Property<long>("Id")
  37. .ValueGeneratedOnAdd()
  38. .HasColumnType("bigint")
  39. .HasColumnOrder(0);
  40. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  41. b.Property<DateTime>("AttendanceDate")
  42. .HasColumnType("datetime2");
  43. b.Property<DateTime?>("CheckInTime")
  44. .HasColumnType("datetime2");
  45. b.Property<DateTime?>("CheckOutTime")
  46. .HasColumnType("datetime2");
  47. b.Property<DateTime>("CreateDate")
  48. .HasColumnType("datetime2")
  49. .HasColumnOrder(3);
  50. b.Property<string>("CreateUser")
  51. .HasMaxLength(450)
  52. .HasColumnType("nvarchar(450)")
  53. .HasColumnOrder(1);
  54. b.Property<string>("DeleteUserId")
  55. .HasMaxLength(450)
  56. .HasColumnType("nvarchar(450)")
  57. .HasColumnOrder(8);
  58. b.Property<bool>("IsDeleted")
  59. .HasColumnType("bit")
  60. .HasColumnOrder(7);
  61. b.Property<string>("LeaveReason")
  62. .HasMaxLength(250)
  63. .HasColumnType("nvarchar(250)");
  64. b.Property<int>("LeaveType")
  65. .HasColumnType("int");
  66. b.Property<DateTime?>("UpdateDate")
  67. .HasColumnType("datetime2")
  68. .HasColumnOrder(4);
  69. b.Property<string>("UpdateUser")
  70. .HasMaxLength(450)
  71. .HasColumnType("nvarchar(450)")
  72. .HasColumnOrder(2);
  73. b.Property<string>("UserId")
  74. .IsRequired()
  75. .HasColumnType("nvarchar(max)");
  76. b.Property<string>("UserName")
  77. .HasColumnType("nvarchar(max)");
  78. b.HasKey("Id");
  79. b.ToTable("Attendances");
  80. });
  81. modelBuilder.Entity("MTWorkHR.Core.Entities.AttendanceLog", b =>
  82. {
  83. b.Property<long>("Id")
  84. .ValueGeneratedOnAdd()
  85. .HasColumnType("bigint")
  86. .HasColumnOrder(0);
  87. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  88. b.Property<string>("Channel")
  89. .HasColumnType("nvarchar(max)");
  90. b.Property<DateTime>("CreateDate")
  91. .HasColumnType("datetime2");
  92. b.Property<string>("CreateUser")
  93. .IsRequired()
  94. .HasColumnType("nvarchar(max)");
  95. b.Property<string>("ErrorCode")
  96. .IsRequired()
  97. .HasColumnType("nvarchar(max)");
  98. b.Property<string>("ErrorDescription")
  99. .IsRequired()
  100. .HasColumnType("nvarchar(max)");
  101. b.Property<string>("InnerException")
  102. .HasColumnType("nvarchar(max)");
  103. b.Property<string>("Input")
  104. .HasColumnType("nvarchar(max)");
  105. b.Property<string>("Method")
  106. .IsRequired()
  107. .HasColumnType("nvarchar(max)");
  108. b.Property<string>("QueryString")
  109. .HasColumnType("nvarchar(max)");
  110. b.Property<string>("ServerIP")
  111. .HasColumnType("nvarchar(max)");
  112. b.Property<string>("ServiceResponseTimeInSeconds")
  113. .IsRequired()
  114. .HasColumnType("nvarchar(max)");
  115. b.Property<string>("UserIP")
  116. .HasColumnType("nvarchar(max)");
  117. b.Property<string>("userAgent")
  118. .HasColumnType("nvarchar(max)");
  119. b.HasKey("Id");
  120. b.ToTable("AttendanceLogs");
  121. });
  122. modelBuilder.Entity("MTWorkHR.Core.Entities.AuthLog", b =>
  123. {
  124. b.Property<long>("Id")
  125. .ValueGeneratedOnAdd()
  126. .HasColumnType("bigint")
  127. .HasColumnOrder(0);
  128. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  129. b.Property<string>("Channel")
  130. .HasColumnType("nvarchar(max)");
  131. b.Property<DateTime>("CreateDate")
  132. .HasColumnType("datetime2");
  133. b.Property<string>("CreateUser")
  134. .IsRequired()
  135. .HasColumnType("nvarchar(max)");
  136. b.Property<string>("ErrorCode")
  137. .IsRequired()
  138. .HasColumnType("nvarchar(max)");
  139. b.Property<string>("ErrorDescription")
  140. .IsRequired()
  141. .HasColumnType("nvarchar(max)");
  142. b.Property<string>("InnerException")
  143. .HasColumnType("nvarchar(max)");
  144. b.Property<string>("Input")
  145. .HasColumnType("nvarchar(max)");
  146. b.Property<string>("Method")
  147. .IsRequired()
  148. .HasColumnType("nvarchar(max)");
  149. b.Property<string>("QueryString")
  150. .HasColumnType("nvarchar(max)");
  151. b.Property<string>("ServerIP")
  152. .HasColumnType("nvarchar(max)");
  153. b.Property<string>("ServiceResponseTimeInSeconds")
  154. .IsRequired()
  155. .HasColumnType("nvarchar(max)");
  156. b.Property<string>("UserIP")
  157. .HasColumnType("nvarchar(max)");
  158. b.Property<string>("userAgent")
  159. .HasColumnType("nvarchar(max)");
  160. b.HasKey("Id");
  161. b.ToTable("AuthLogs");
  162. });
  163. modelBuilder.Entity("MTWorkHR.Core.Entities.Base.AttachmentType", b =>
  164. {
  165. b.Property<long>("Id")
  166. .ValueGeneratedOnAdd()
  167. .HasColumnType("bigint")
  168. .HasColumnOrder(0);
  169. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  170. b.Property<bool>("IsRequired")
  171. .HasColumnType("bit");
  172. b.Property<string>("NameAr")
  173. .IsRequired()
  174. .HasMaxLength(250)
  175. .HasColumnType("nvarchar(250)");
  176. b.Property<string>("NameEn")
  177. .IsRequired()
  178. .HasMaxLength(250)
  179. .HasColumnType("nvarchar(250)");
  180. b.HasKey("Id");
  181. b.ToTable("AttachmentTypes");
  182. b.HasData(
  183. new
  184. {
  185. Id = 1L,
  186. IsRequired = false,
  187. NameAr = "السيرة الذاتية",
  188. NameEn = "CV"
  189. },
  190. new
  191. {
  192. Id = 2L,
  193. IsRequired = false,
  194. NameAr = "الهوية",
  195. NameEn = "Identification"
  196. });
  197. });
  198. modelBuilder.Entity("MTWorkHR.Core.Entities.Company", b =>
  199. {
  200. b.Property<long>("Id")
  201. .ValueGeneratedOnAdd()
  202. .HasColumnType("bigint")
  203. .HasColumnOrder(0);
  204. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  205. b.Property<string>("CRNumber")
  206. .IsRequired()
  207. .HasColumnType("nvarchar(max)");
  208. b.Property<string>("CompanyName")
  209. .IsRequired()
  210. .HasColumnType("nvarchar(max)");
  211. b.Property<DateTime>("CreateDate")
  212. .HasColumnType("datetime2")
  213. .HasColumnOrder(3);
  214. b.Property<string>("CreateUser")
  215. .HasMaxLength(450)
  216. .HasColumnType("nvarchar(450)")
  217. .HasColumnOrder(1);
  218. b.Property<string>("DeleteUserId")
  219. .HasMaxLength(450)
  220. .HasColumnType("nvarchar(450)")
  221. .HasColumnOrder(8);
  222. b.Property<bool>("IsDeleted")
  223. .HasColumnType("bit")
  224. .HasColumnOrder(7);
  225. b.Property<int>("TaxNumber")
  226. .HasColumnType("int");
  227. b.Property<DateTime?>("UpdateDate")
  228. .HasColumnType("datetime2")
  229. .HasColumnOrder(4);
  230. b.Property<string>("UpdateUser")
  231. .HasMaxLength(450)
  232. .HasColumnType("nvarchar(450)")
  233. .HasColumnOrder(2);
  234. b.Property<long>("UserId")
  235. .HasColumnType("bigint");
  236. b.HasKey("Id");
  237. b.ToTable("Companies");
  238. });
  239. modelBuilder.Entity("MTWorkHR.Core.Entities.FileLog", b =>
  240. {
  241. b.Property<long>("Id")
  242. .ValueGeneratedOnAdd()
  243. .HasColumnType("bigint")
  244. .HasColumnOrder(0);
  245. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  246. b.Property<string>("Channel")
  247. .HasColumnType("nvarchar(max)");
  248. b.Property<DateTime>("CreateDate")
  249. .HasColumnType("datetime2");
  250. b.Property<string>("CreateUser")
  251. .IsRequired()
  252. .HasColumnType("nvarchar(max)");
  253. b.Property<string>("ErrorCode")
  254. .IsRequired()
  255. .HasColumnType("nvarchar(max)");
  256. b.Property<string>("ErrorDescription")
  257. .IsRequired()
  258. .HasColumnType("nvarchar(max)");
  259. b.Property<string>("InnerException")
  260. .HasColumnType("nvarchar(max)");
  261. b.Property<string>("Input")
  262. .HasColumnType("nvarchar(max)");
  263. b.Property<string>("Method")
  264. .IsRequired()
  265. .HasColumnType("nvarchar(max)");
  266. b.Property<string>("QueryString")
  267. .HasColumnType("nvarchar(max)");
  268. b.Property<string>("ServerIP")
  269. .HasColumnType("nvarchar(max)");
  270. b.Property<string>("ServiceResponseTimeInSeconds")
  271. .IsRequired()
  272. .HasColumnType("nvarchar(max)");
  273. b.Property<string>("UserIP")
  274. .HasColumnType("nvarchar(max)");
  275. b.Property<string>("userAgent")
  276. .HasColumnType("nvarchar(max)");
  277. b.HasKey("Id");
  278. b.ToTable("FileLogs");
  279. });
  280. modelBuilder.Entity("MTWorkHR.Core.Entities.Meeting", b =>
  281. {
  282. b.Property<long>("Id")
  283. .ValueGeneratedOnAdd()
  284. .HasColumnType("bigint")
  285. .HasColumnOrder(0);
  286. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  287. b.Property<DateTime>("CreateDate")
  288. .HasColumnType("datetime2")
  289. .HasColumnOrder(3);
  290. b.Property<string>("CreateUser")
  291. .HasMaxLength(450)
  292. .HasColumnType("nvarchar(450)")
  293. .HasColumnOrder(1);
  294. b.Property<string>("DeleteUserId")
  295. .HasMaxLength(450)
  296. .HasColumnType("nvarchar(450)")
  297. .HasColumnOrder(8);
  298. b.Property<string>("Description")
  299. .HasMaxLength(500)
  300. .HasColumnType("nvarchar(500)");
  301. b.Property<DateTime>("EndDate")
  302. .HasColumnType("datetime2");
  303. b.Property<bool>("IsDeleted")
  304. .HasColumnType("bit")
  305. .HasColumnOrder(7);
  306. b.Property<string>("Location")
  307. .HasMaxLength(250)
  308. .HasColumnType("nvarchar(250)");
  309. b.Property<string>("MeetingLink")
  310. .HasMaxLength(250)
  311. .HasColumnType("nvarchar(250)");
  312. b.Property<DateTime>("StartDate")
  313. .HasColumnType("datetime2");
  314. b.Property<string>("Title")
  315. .IsRequired()
  316. .HasMaxLength(250)
  317. .HasColumnType("nvarchar(250)");
  318. b.Property<DateTime?>("UpdateDate")
  319. .HasColumnType("datetime2")
  320. .HasColumnOrder(4);
  321. b.Property<string>("UpdateUser")
  322. .HasMaxLength(450)
  323. .HasColumnType("nvarchar(450)")
  324. .HasColumnOrder(2);
  325. b.HasKey("Id");
  326. b.ToTable("Meetings");
  327. });
  328. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingLog", b =>
  329. {
  330. b.Property<long>("Id")
  331. .ValueGeneratedOnAdd()
  332. .HasColumnType("bigint")
  333. .HasColumnOrder(0);
  334. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  335. b.Property<string>("Channel")
  336. .HasColumnType("nvarchar(max)");
  337. b.Property<DateTime>("CreateDate")
  338. .HasColumnType("datetime2");
  339. b.Property<string>("CreateUser")
  340. .IsRequired()
  341. .HasColumnType("nvarchar(max)");
  342. b.Property<string>("ErrorCode")
  343. .IsRequired()
  344. .HasColumnType("nvarchar(max)");
  345. b.Property<string>("ErrorDescription")
  346. .IsRequired()
  347. .HasColumnType("nvarchar(max)");
  348. b.Property<string>("InnerException")
  349. .HasColumnType("nvarchar(max)");
  350. b.Property<string>("Input")
  351. .HasColumnType("nvarchar(max)");
  352. b.Property<string>("Method")
  353. .IsRequired()
  354. .HasColumnType("nvarchar(max)");
  355. b.Property<string>("QueryString")
  356. .HasColumnType("nvarchar(max)");
  357. b.Property<string>("ServerIP")
  358. .HasColumnType("nvarchar(max)");
  359. b.Property<string>("ServiceResponseTimeInSeconds")
  360. .IsRequired()
  361. .HasColumnType("nvarchar(max)");
  362. b.Property<string>("UserIP")
  363. .HasColumnType("nvarchar(max)");
  364. b.Property<string>("userAgent")
  365. .HasColumnType("nvarchar(max)");
  366. b.HasKey("Id");
  367. b.ToTable("MeetingLogs");
  368. });
  369. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingUser", b =>
  370. {
  371. b.Property<long>("Id")
  372. .ValueGeneratedOnAdd()
  373. .HasColumnType("bigint")
  374. .HasColumnOrder(0);
  375. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  376. b.Property<string>("AssignedUserId")
  377. .IsRequired()
  378. .HasColumnType("nvarchar(max)");
  379. b.Property<DateTime>("CreateDate")
  380. .HasColumnType("datetime2")
  381. .HasColumnOrder(3);
  382. b.Property<string>("CreateUser")
  383. .HasMaxLength(450)
  384. .HasColumnType("nvarchar(450)")
  385. .HasColumnOrder(1);
  386. b.Property<long>("MeetingId")
  387. .HasColumnType("bigint");
  388. b.Property<DateTime?>("UpdateDate")
  389. .HasColumnType("datetime2")
  390. .HasColumnOrder(4);
  391. b.Property<string>("UpdateUser")
  392. .HasMaxLength(450)
  393. .HasColumnType("nvarchar(450)")
  394. .HasColumnOrder(2);
  395. b.HasKey("Id");
  396. b.HasIndex("MeetingId");
  397. b.ToTable("MeetingUser");
  398. });
  399. modelBuilder.Entity("MTWorkHR.Core.Entities.Permission", b =>
  400. {
  401. b.Property<long>("Id")
  402. .ValueGeneratedOnAdd()
  403. .HasColumnType("bigint")
  404. .HasColumnOrder(0);
  405. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  406. b.Property<string>("CategoryName")
  407. .IsRequired()
  408. .HasMaxLength(150)
  409. .HasColumnType("nvarchar(150)");
  410. b.Property<string>("Desc")
  411. .IsRequired()
  412. .HasMaxLength(250)
  413. .HasColumnType("nvarchar(250)");
  414. b.Property<string>("Name")
  415. .IsRequired()
  416. .HasMaxLength(250)
  417. .HasColumnType("nvarchar(250)");
  418. b.Property<bool>("Show")
  419. .HasColumnType("bit");
  420. b.HasKey("Id");
  421. b.ToTable("Permissions");
  422. });
  423. modelBuilder.Entity("MTWorkHR.Core.Entities.Project", b =>
  424. {
  425. b.Property<long>("Id")
  426. .ValueGeneratedOnAdd()
  427. .HasColumnType("bigint")
  428. .HasColumnOrder(0);
  429. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  430. b.Property<DateTime>("CreateDate")
  431. .HasColumnType("datetime2")
  432. .HasColumnOrder(3);
  433. b.Property<string>("CreateUser")
  434. .HasMaxLength(450)
  435. .HasColumnType("nvarchar(450)")
  436. .HasColumnOrder(1);
  437. b.Property<string>("DeleteUserId")
  438. .HasMaxLength(450)
  439. .HasColumnType("nvarchar(450)")
  440. .HasColumnOrder(8);
  441. b.Property<bool>("IsDeleted")
  442. .HasColumnType("bit")
  443. .HasColumnOrder(7);
  444. b.Property<string>("NameAr")
  445. .IsRequired()
  446. .HasMaxLength(250)
  447. .HasColumnType("nvarchar(250)");
  448. b.Property<string>("NameEn")
  449. .IsRequired()
  450. .HasMaxLength(250)
  451. .HasColumnType("nvarchar(250)");
  452. b.Property<DateTime?>("UpdateDate")
  453. .HasColumnType("datetime2")
  454. .HasColumnOrder(4);
  455. b.Property<string>("UpdateUser")
  456. .HasMaxLength(450)
  457. .HasColumnType("nvarchar(450)")
  458. .HasColumnOrder(2);
  459. b.HasKey("Id");
  460. b.ToTable("Projects");
  461. });
  462. modelBuilder.Entity("MTWorkHR.Core.Entities.RoleLog", b =>
  463. {
  464. b.Property<long>("Id")
  465. .ValueGeneratedOnAdd()
  466. .HasColumnType("bigint")
  467. .HasColumnOrder(0);
  468. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  469. b.Property<string>("Channel")
  470. .HasColumnType("nvarchar(max)");
  471. b.Property<DateTime>("CreateDate")
  472. .HasColumnType("datetime2");
  473. b.Property<string>("CreateUser")
  474. .IsRequired()
  475. .HasColumnType("nvarchar(max)");
  476. b.Property<string>("ErrorCode")
  477. .IsRequired()
  478. .HasColumnType("nvarchar(max)");
  479. b.Property<string>("ErrorDescription")
  480. .IsRequired()
  481. .HasColumnType("nvarchar(max)");
  482. b.Property<string>("InnerException")
  483. .HasColumnType("nvarchar(max)");
  484. b.Property<string>("Input")
  485. .HasColumnType("nvarchar(max)");
  486. b.Property<string>("Method")
  487. .IsRequired()
  488. .HasColumnType("nvarchar(max)");
  489. b.Property<string>("QueryString")
  490. .HasColumnType("nvarchar(max)");
  491. b.Property<string>("ServerIP")
  492. .HasColumnType("nvarchar(max)");
  493. b.Property<string>("ServiceResponseTimeInSeconds")
  494. .IsRequired()
  495. .HasColumnType("nvarchar(max)");
  496. b.Property<string>("UserIP")
  497. .HasColumnType("nvarchar(max)");
  498. b.Property<string>("userAgent")
  499. .HasColumnType("nvarchar(max)");
  500. b.HasKey("Id");
  501. b.ToTable("RoleLogs");
  502. });
  503. modelBuilder.Entity("MTWorkHR.Core.Entities.SettingLog", b =>
  504. {
  505. b.Property<long>("Id")
  506. .ValueGeneratedOnAdd()
  507. .HasColumnType("bigint")
  508. .HasColumnOrder(0);
  509. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  510. b.Property<string>("Channel")
  511. .HasColumnType("nvarchar(max)");
  512. b.Property<DateTime>("CreateDate")
  513. .HasColumnType("datetime2");
  514. b.Property<string>("CreateUser")
  515. .IsRequired()
  516. .HasColumnType("nvarchar(max)");
  517. b.Property<string>("ErrorCode")
  518. .IsRequired()
  519. .HasColumnType("nvarchar(max)");
  520. b.Property<string>("ErrorDescription")
  521. .IsRequired()
  522. .HasColumnType("nvarchar(max)");
  523. b.Property<string>("InnerException")
  524. .HasColumnType("nvarchar(max)");
  525. b.Property<string>("Input")
  526. .HasColumnType("nvarchar(max)");
  527. b.Property<string>("Method")
  528. .IsRequired()
  529. .HasColumnType("nvarchar(max)");
  530. b.Property<string>("QueryString")
  531. .HasColumnType("nvarchar(max)");
  532. b.Property<string>("ServerIP")
  533. .HasColumnType("nvarchar(max)");
  534. b.Property<string>("ServiceResponseTimeInSeconds")
  535. .IsRequired()
  536. .HasColumnType("nvarchar(max)");
  537. b.Property<string>("UserIP")
  538. .HasColumnType("nvarchar(max)");
  539. b.Property<string>("userAgent")
  540. .HasColumnType("nvarchar(max)");
  541. b.HasKey("Id");
  542. b.ToTable("SettingLogs");
  543. });
  544. modelBuilder.Entity("MTWorkHR.Core.Entities.Team", b =>
  545. {
  546. b.Property<long>("Id")
  547. .ValueGeneratedOnAdd()
  548. .HasColumnType("bigint")
  549. .HasColumnOrder(0);
  550. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  551. b.Property<DateTime>("CreateDate")
  552. .HasColumnType("datetime2")
  553. .HasColumnOrder(3);
  554. b.Property<string>("CreateUser")
  555. .HasMaxLength(450)
  556. .HasColumnType("nvarchar(450)")
  557. .HasColumnOrder(1);
  558. b.Property<string>("DeleteUserId")
  559. .HasMaxLength(450)
  560. .HasColumnType("nvarchar(450)")
  561. .HasColumnOrder(8);
  562. b.Property<bool>("IsDeleted")
  563. .HasColumnType("bit")
  564. .HasColumnOrder(7);
  565. b.Property<string>("NameAr")
  566. .IsRequired()
  567. .HasMaxLength(250)
  568. .HasColumnType("nvarchar(250)");
  569. b.Property<string>("NameEn")
  570. .IsRequired()
  571. .HasMaxLength(250)
  572. .HasColumnType("nvarchar(250)");
  573. b.Property<DateTime?>("UpdateDate")
  574. .HasColumnType("datetime2")
  575. .HasColumnOrder(4);
  576. b.Property<string>("UpdateUser")
  577. .HasMaxLength(450)
  578. .HasColumnType("nvarchar(450)")
  579. .HasColumnOrder(2);
  580. b.HasKey("Id");
  581. b.ToTable("Teams");
  582. });
  583. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamLog", b =>
  584. {
  585. b.Property<long>("Id")
  586. .ValueGeneratedOnAdd()
  587. .HasColumnType("bigint")
  588. .HasColumnOrder(0);
  589. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  590. b.Property<string>("Channel")
  591. .HasColumnType("nvarchar(max)");
  592. b.Property<DateTime>("CreateDate")
  593. .HasColumnType("datetime2");
  594. b.Property<string>("CreateUser")
  595. .IsRequired()
  596. .HasColumnType("nvarchar(max)");
  597. b.Property<string>("ErrorCode")
  598. .IsRequired()
  599. .HasColumnType("nvarchar(max)");
  600. b.Property<string>("ErrorDescription")
  601. .IsRequired()
  602. .HasColumnType("nvarchar(max)");
  603. b.Property<string>("InnerException")
  604. .HasColumnType("nvarchar(max)");
  605. b.Property<string>("Input")
  606. .HasColumnType("nvarchar(max)");
  607. b.Property<string>("Method")
  608. .IsRequired()
  609. .HasColumnType("nvarchar(max)");
  610. b.Property<string>("QueryString")
  611. .HasColumnType("nvarchar(max)");
  612. b.Property<string>("ServerIP")
  613. .HasColumnType("nvarchar(max)");
  614. b.Property<string>("ServiceResponseTimeInSeconds")
  615. .IsRequired()
  616. .HasColumnType("nvarchar(max)");
  617. b.Property<string>("UserIP")
  618. .HasColumnType("nvarchar(max)");
  619. b.Property<string>("userAgent")
  620. .HasColumnType("nvarchar(max)");
  621. b.HasKey("Id");
  622. b.ToTable("TeamLogs");
  623. });
  624. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamUser", b =>
  625. {
  626. b.Property<long>("Id")
  627. .ValueGeneratedOnAdd()
  628. .HasColumnType("bigint")
  629. .HasColumnOrder(0);
  630. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  631. b.Property<string>("AssignedUserId")
  632. .IsRequired()
  633. .HasColumnType("nvarchar(max)");
  634. b.Property<DateTime>("CreateDate")
  635. .HasColumnType("datetime2")
  636. .HasColumnOrder(3);
  637. b.Property<string>("CreateUser")
  638. .HasMaxLength(450)
  639. .HasColumnType("nvarchar(450)")
  640. .HasColumnOrder(1);
  641. b.Property<bool>("IsAdmin")
  642. .HasColumnType("bit");
  643. b.Property<long>("TeamId")
  644. .HasColumnType("bigint");
  645. b.Property<DateTime?>("UpdateDate")
  646. .HasColumnType("datetime2")
  647. .HasColumnOrder(4);
  648. b.Property<string>("UpdateUser")
  649. .HasMaxLength(450)
  650. .HasColumnType("nvarchar(450)")
  651. .HasColumnOrder(2);
  652. b.HasKey("Id");
  653. b.HasIndex("TeamId");
  654. b.ToTable("TeamUser");
  655. });
  656. modelBuilder.Entity("MTWorkHR.Core.Entities.UserLog", b =>
  657. {
  658. b.Property<long>("Id")
  659. .ValueGeneratedOnAdd()
  660. .HasColumnType("bigint")
  661. .HasColumnOrder(0);
  662. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  663. b.Property<string>("Channel")
  664. .HasColumnType("nvarchar(max)");
  665. b.Property<DateTime>("CreateDate")
  666. .HasColumnType("datetime2");
  667. b.Property<string>("CreateUser")
  668. .IsRequired()
  669. .HasColumnType("nvarchar(max)");
  670. b.Property<string>("ErrorCode")
  671. .IsRequired()
  672. .HasColumnType("nvarchar(max)");
  673. b.Property<string>("ErrorDescription")
  674. .IsRequired()
  675. .HasColumnType("nvarchar(max)");
  676. b.Property<string>("InnerException")
  677. .HasColumnType("nvarchar(max)");
  678. b.Property<string>("Input")
  679. .HasColumnType("nvarchar(max)");
  680. b.Property<string>("Method")
  681. .IsRequired()
  682. .HasColumnType("nvarchar(max)");
  683. b.Property<string>("QueryString")
  684. .HasColumnType("nvarchar(max)");
  685. b.Property<string>("ServerIP")
  686. .HasColumnType("nvarchar(max)");
  687. b.Property<string>("ServiceResponseTimeInSeconds")
  688. .IsRequired()
  689. .HasColumnType("nvarchar(max)");
  690. b.Property<string>("UserIP")
  691. .HasColumnType("nvarchar(max)");
  692. b.Property<string>("userAgent")
  693. .HasColumnType("nvarchar(max)");
  694. b.HasKey("Id");
  695. b.ToTable("UserLogs");
  696. });
  697. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  698. {
  699. b.Property<long>("Id")
  700. .ValueGeneratedOnAdd()
  701. .HasColumnType("bigint")
  702. .HasColumnOrder(0);
  703. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  704. b.Property<long>("AssignedUserId")
  705. .HasColumnType("bigint");
  706. b.Property<DateTime>("CreateDate")
  707. .HasColumnType("datetime2")
  708. .HasColumnOrder(3);
  709. b.Property<string>("CreateUser")
  710. .HasMaxLength(450)
  711. .HasColumnType("nvarchar(450)")
  712. .HasColumnOrder(1);
  713. b.Property<string>("DeleteUserId")
  714. .HasMaxLength(450)
  715. .HasColumnType("nvarchar(450)")
  716. .HasColumnOrder(8);
  717. b.Property<string>("Description")
  718. .IsRequired()
  719. .HasColumnType("nvarchar(max)");
  720. b.Property<DateTime>("DueDate")
  721. .HasColumnType("datetime2");
  722. b.Property<bool>("IsDeleted")
  723. .HasColumnType("bit")
  724. .HasColumnOrder(7);
  725. b.Property<int>("Priority")
  726. .HasColumnType("int");
  727. b.Property<long>("ProjectId")
  728. .HasColumnType("bigint");
  729. b.Property<long>("StatusId")
  730. .HasColumnType("bigint");
  731. b.Property<string>("Title")
  732. .IsRequired()
  733. .HasColumnType("nvarchar(max)");
  734. b.Property<DateTime?>("UpdateDate")
  735. .HasColumnType("datetime2")
  736. .HasColumnOrder(4);
  737. b.Property<string>("UpdateUser")
  738. .HasMaxLength(450)
  739. .HasColumnType("nvarchar(450)")
  740. .HasColumnOrder(2);
  741. b.HasKey("Id");
  742. b.HasIndex("ProjectId");
  743. b.HasIndex("StatusId");
  744. b.ToTable("UserTasks");
  745. });
  746. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskAttachment", b =>
  747. {
  748. b.Property<long>("Id")
  749. .ValueGeneratedOnAdd()
  750. .HasColumnType("bigint")
  751. .HasColumnOrder(0);
  752. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  753. b.Property<long>("AttachmentTypeId")
  754. .HasColumnType("bigint");
  755. b.Property<DateTime>("CreateDate")
  756. .HasColumnType("datetime2")
  757. .HasColumnOrder(3);
  758. b.Property<string>("CreateUser")
  759. .HasMaxLength(450)
  760. .HasColumnType("nvarchar(450)")
  761. .HasColumnOrder(1);
  762. b.Property<string>("FileName")
  763. .HasMaxLength(250)
  764. .HasColumnType("nvarchar(250)");
  765. b.Property<string>("OriginalName")
  766. .IsRequired()
  767. .HasMaxLength(250)
  768. .HasColumnType("nvarchar(250)");
  769. b.Property<long>("TaskId")
  770. .HasColumnType("bigint");
  771. b.Property<DateTime?>("UpdateDate")
  772. .HasColumnType("datetime2")
  773. .HasColumnOrder(4);
  774. b.Property<string>("UpdateUser")
  775. .HasMaxLength(450)
  776. .HasColumnType("nvarchar(450)")
  777. .HasColumnOrder(2);
  778. b.HasKey("Id");
  779. b.HasIndex("AttachmentTypeId");
  780. b.HasIndex("TaskId");
  781. b.ToTable("UserTaskAttachments");
  782. });
  783. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskHistory", b =>
  784. {
  785. b.Property<long>("Id")
  786. .ValueGeneratedOnAdd()
  787. .HasColumnType("bigint")
  788. .HasColumnOrder(0);
  789. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  790. b.Property<long>("AssignedToUserId")
  791. .HasColumnType("bigint");
  792. b.Property<string>("Comment")
  793. .HasMaxLength(500)
  794. .HasColumnType("nvarchar(500)");
  795. b.Property<DateTime>("CreateDate")
  796. .HasColumnType("datetime2")
  797. .HasColumnOrder(3);
  798. b.Property<string>("CreateUser")
  799. .HasMaxLength(450)
  800. .HasColumnType("nvarchar(450)")
  801. .HasColumnOrder(1);
  802. b.Property<long>("CurrentStatusId")
  803. .HasColumnType("bigint");
  804. b.Property<bool>("IsDeleted")
  805. .HasColumnType("bit");
  806. b.Property<long>("TaskId")
  807. .HasColumnType("bigint");
  808. b.Property<DateTime?>("UpdateDate")
  809. .HasColumnType("datetime2")
  810. .HasColumnOrder(4);
  811. b.Property<string>("UpdateUser")
  812. .HasMaxLength(450)
  813. .HasColumnType("nvarchar(450)")
  814. .HasColumnOrder(2);
  815. b.Property<long?>("UserTaskId")
  816. .HasColumnType("bigint");
  817. b.HasKey("Id");
  818. b.HasIndex("CurrentStatusId");
  819. b.HasIndex("UserTaskId");
  820. b.ToTable("UserTaskHistories");
  821. });
  822. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskLog", b =>
  823. {
  824. b.Property<long>("Id")
  825. .ValueGeneratedOnAdd()
  826. .HasColumnType("bigint")
  827. .HasColumnOrder(0);
  828. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  829. b.Property<string>("Channel")
  830. .HasColumnType("nvarchar(max)");
  831. b.Property<DateTime>("CreateDate")
  832. .HasColumnType("datetime2");
  833. b.Property<string>("CreateUser")
  834. .IsRequired()
  835. .HasColumnType("nvarchar(max)");
  836. b.Property<string>("ErrorCode")
  837. .IsRequired()
  838. .HasColumnType("nvarchar(max)");
  839. b.Property<string>("ErrorDescription")
  840. .IsRequired()
  841. .HasColumnType("nvarchar(max)");
  842. b.Property<string>("InnerException")
  843. .HasColumnType("nvarchar(max)");
  844. b.Property<string>("Input")
  845. .HasColumnType("nvarchar(max)");
  846. b.Property<string>("Method")
  847. .IsRequired()
  848. .HasColumnType("nvarchar(max)");
  849. b.Property<string>("QueryString")
  850. .HasColumnType("nvarchar(max)");
  851. b.Property<string>("ServerIP")
  852. .HasColumnType("nvarchar(max)");
  853. b.Property<string>("ServiceResponseTimeInSeconds")
  854. .IsRequired()
  855. .HasColumnType("nvarchar(max)");
  856. b.Property<string>("UserIP")
  857. .HasColumnType("nvarchar(max)");
  858. b.Property<string>("userAgent")
  859. .HasColumnType("nvarchar(max)");
  860. b.HasKey("Id");
  861. b.ToTable("UserTaskLogs");
  862. });
  863. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskStatus", b =>
  864. {
  865. b.Property<long>("Id")
  866. .ValueGeneratedOnAdd()
  867. .HasColumnType("bigint")
  868. .HasColumnOrder(0);
  869. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  870. b.Property<string>("NameAr")
  871. .IsRequired()
  872. .HasMaxLength(250)
  873. .HasColumnType("nvarchar(250)");
  874. b.Property<string>("NameEn")
  875. .IsRequired()
  876. .HasMaxLength(250)
  877. .HasColumnType("nvarchar(250)");
  878. b.HasKey("Id");
  879. b.ToTable("UserTaskStatuses");
  880. b.HasData(
  881. new
  882. {
  883. Id = 1L,
  884. NameAr = "جديدة",
  885. NameEn = "New"
  886. },
  887. new
  888. {
  889. Id = 2L,
  890. NameAr = "قيد العمل",
  891. NameEn = "Under progress"
  892. },
  893. new
  894. {
  895. Id = 3L,
  896. NameAr = "أغلقت",
  897. NameEn = "Closed"
  898. },
  899. new
  900. {
  901. Id = 4L,
  902. NameAr = "تمت",
  903. NameEn = "Completed"
  904. },
  905. new
  906. {
  907. Id = 5L,
  908. NameAr = "مؤجلة",
  909. NameEn = "Delayed"
  910. });
  911. });
  912. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationRole", b =>
  913. {
  914. b.Property<string>("Id")
  915. .HasColumnType("nvarchar(450)");
  916. b.Property<string>("ConcurrencyStamp")
  917. .IsConcurrencyToken()
  918. .HasColumnType("nvarchar(max)");
  919. b.Property<DateTime>("CreateDate")
  920. .HasColumnType("datetime2");
  921. b.Property<string>("CreateUser")
  922. .HasColumnType("nvarchar(max)");
  923. b.Property<string>("DeleteUserId")
  924. .HasColumnType("nvarchar(max)");
  925. b.Property<bool?>("IsAdmin")
  926. .HasColumnType("bit");
  927. b.Property<bool>("IsDeleted")
  928. .HasColumnType("bit");
  929. b.Property<string>("Name")
  930. .HasMaxLength(256)
  931. .HasColumnType("nvarchar(256)");
  932. b.Property<string>("NormalizedName")
  933. .HasMaxLength(256)
  934. .HasColumnType("nvarchar(256)");
  935. b.Property<DateTime?>("UpdateDate")
  936. .HasColumnType("datetime2");
  937. b.Property<string>("UpdateUser")
  938. .HasColumnType("nvarchar(max)");
  939. b.HasKey("Id");
  940. b.HasIndex("NormalizedName")
  941. .IsUnique()
  942. .HasDatabaseName("RoleNameIndex")
  943. .HasFilter("[NormalizedName] IS NOT NULL");
  944. b.ToTable("AspNetRoles", (string)null);
  945. b.HasData(
  946. new
  947. {
  948. Id = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A",
  949. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  950. IsAdmin = true,
  951. IsDeleted = false,
  952. Name = "Admin",
  953. NormalizedName = "ADMIN"
  954. },
  955. new
  956. {
  957. Id = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E",
  958. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  959. IsAdmin = false,
  960. IsDeleted = false,
  961. Name = "Employee",
  962. NormalizedName = "EMPLOYEE"
  963. });
  964. });
  965. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  966. {
  967. b.Property<string>("Id")
  968. .HasColumnType("nvarchar(450)");
  969. b.Property<int>("AccessFailedCount")
  970. .HasColumnType("int");
  971. b.Property<string>("ConcurrencyStamp")
  972. .IsConcurrencyToken()
  973. .HasColumnType("nvarchar(max)");
  974. b.Property<string>("CreateUser")
  975. .HasColumnType("nvarchar(max)");
  976. b.Property<string>("DeleteUserId")
  977. .HasColumnType("nvarchar(max)");
  978. b.Property<string>("Email")
  979. .HasMaxLength(256)
  980. .HasColumnType("nvarchar(256)");
  981. b.Property<bool>("EmailConfirmed")
  982. .HasColumnType("bit");
  983. b.Property<string>("FavoriteName")
  984. .HasColumnType("nvarchar(max)");
  985. b.Property<string>("FirstName")
  986. .IsRequired()
  987. .HasColumnType("nvarchar(max)");
  988. b.Property<decimal?>("IncomeTaxValue")
  989. .HasColumnType("decimal(18,2)");
  990. b.Property<bool>("IsDeleted")
  991. .HasColumnType("bit");
  992. b.Property<bool>("IsStopped")
  993. .HasColumnType("bit");
  994. b.Property<string>("JobTitle")
  995. .HasColumnType("nvarchar(max)");
  996. b.Property<string>("LastName")
  997. .IsRequired()
  998. .HasColumnType("nvarchar(max)");
  999. b.Property<bool>("LockoutEnabled")
  1000. .HasColumnType("bit");
  1001. b.Property<DateTimeOffset?>("LockoutEnd")
  1002. .HasColumnType("datetimeoffset");
  1003. b.Property<string>("ManagerId")
  1004. .HasColumnType("nvarchar(450)");
  1005. b.Property<string>("NormalizedEmail")
  1006. .HasMaxLength(256)
  1007. .HasColumnType("nvarchar(256)");
  1008. b.Property<string>("NormalizedUserName")
  1009. .HasMaxLength(256)
  1010. .HasColumnType("nvarchar(256)");
  1011. b.Property<string>("PassportNumber")
  1012. .IsRequired()
  1013. .HasColumnType("nvarchar(max)");
  1014. b.Property<string>("PasswordHash")
  1015. .HasColumnType("nvarchar(max)");
  1016. b.Property<string>("PhoneNumber")
  1017. .HasColumnType("nvarchar(max)");
  1018. b.Property<bool>("PhoneNumberConfirmed")
  1019. .HasColumnType("bit");
  1020. b.Property<int?>("QualificationId")
  1021. .HasColumnType("int");
  1022. b.Property<string>("SecurityStamp")
  1023. .HasColumnType("nvarchar(max)");
  1024. b.Property<decimal?>("TaxNumber")
  1025. .HasColumnType("decimal(18,2)");
  1026. b.Property<bool>("TwoFactorEnabled")
  1027. .HasColumnType("bit");
  1028. b.Property<string>("University")
  1029. .HasColumnType("nvarchar(max)");
  1030. b.Property<string>("UpdateUser")
  1031. .HasColumnType("nvarchar(max)");
  1032. b.Property<string>("UserName")
  1033. .HasMaxLength(256)
  1034. .HasColumnType("nvarchar(256)");
  1035. b.Property<int>("UserType")
  1036. .HasColumnType("int");
  1037. b.HasKey("Id");
  1038. b.HasIndex("ManagerId");
  1039. b.HasIndex("NormalizedEmail")
  1040. .HasDatabaseName("EmailIndex");
  1041. b.HasIndex("NormalizedUserName")
  1042. .IsUnique()
  1043. .HasDatabaseName("UserNameIndex")
  1044. .HasFilter("[NormalizedUserName] IS NOT NULL");
  1045. b.ToTable("AspNetUsers", (string)null);
  1046. b.HasData(
  1047. new
  1048. {
  1049. Id = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  1050. AccessFailedCount = 0,
  1051. ConcurrencyStamp = "7cc87689-9eab-4280-b8e3-1834080783a5",
  1052. Email = "a@b.com",
  1053. EmailConfirmed = true,
  1054. FirstName = "Zinab",
  1055. IncomeTaxValue = 1m,
  1056. IsDeleted = false,
  1057. IsStopped = false,
  1058. LastName = "Elgendy",
  1059. LockoutEnabled = false,
  1060. NormalizedEmail = "A@B.COM",
  1061. NormalizedUserName = "ADMIN",
  1062. PassportNumber = "1234567",
  1063. PasswordHash = "AQAAAAIAAYagAAAAEPg+ASbciPFxtyxQq8Wx5ilBUQ0RbAoITXXkOQm1PzC5BzySX0sn/wUmOjBKPDGV9w==",
  1064. PhoneNumber = "1234567890",
  1065. PhoneNumberConfirmed = true,
  1066. QualificationId = 1,
  1067. SecurityStamp = "49bb16c3-4704-4c60-908d-dc8506950acc",
  1068. TaxNumber = 111m,
  1069. TwoFactorEnabled = false,
  1070. UserName = "Admin",
  1071. UserType = 1
  1072. },
  1073. new
  1074. {
  1075. Id = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  1076. AccessFailedCount = 0,
  1077. ConcurrencyStamp = "4af7b4cf-802a-455b-b598-997e167745b3",
  1078. Email = "ali@b.com",
  1079. EmailConfirmed = true,
  1080. FirstName = "Ali",
  1081. IncomeTaxValue = 100m,
  1082. IsDeleted = false,
  1083. IsStopped = false,
  1084. LastName = "Farok",
  1085. LockoutEnabled = false,
  1086. NormalizedEmail = "ALI@B.COM",
  1087. NormalizedUserName = "ALI",
  1088. PassportNumber = "7654321001010",
  1089. PasswordHash = "AQAAAAIAAYagAAAAEI3QJkcZjCH4Y8Db4rEgL8Mmll5oCvYcWiXZjQSN9bGW4SMcjHe3ZPMnkN/l9DmJeQ==",
  1090. PhoneNumber = "1234567890",
  1091. PhoneNumberConfirmed = true,
  1092. QualificationId = 1,
  1093. SecurityStamp = "62549056-1b9d-46d4-84f8-adea3e4d8b68",
  1094. TaxNumber = 222m,
  1095. TwoFactorEnabled = false,
  1096. UserName = "ali",
  1097. UserType = 1
  1098. });
  1099. });
  1100. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.RolePermission", b =>
  1101. {
  1102. b.Property<long>("Id")
  1103. .ValueGeneratedOnAdd()
  1104. .HasColumnType("bigint")
  1105. .HasColumnOrder(0);
  1106. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1107. b.Property<long>("PermissionId")
  1108. .HasColumnType("bigint");
  1109. b.Property<string>("PermissionName")
  1110. .IsRequired()
  1111. .HasColumnType("nvarchar(max)");
  1112. b.Property<string>("RoleId")
  1113. .IsRequired()
  1114. .HasColumnType("nvarchar(450)");
  1115. b.HasKey("Id");
  1116. b.HasIndex("PermissionId");
  1117. b.HasIndex("RoleId");
  1118. b.ToTable("RolePermissions");
  1119. });
  1120. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAddress", b =>
  1121. {
  1122. b.Property<long>("Id")
  1123. .ValueGeneratedOnAdd()
  1124. .HasColumnType("bigint")
  1125. .HasColumnOrder(0);
  1126. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1127. b.Property<string>("AddressDesc")
  1128. .IsRequired()
  1129. .HasColumnType("nvarchar(max)");
  1130. b.Property<string>("City")
  1131. .IsRequired()
  1132. .HasColumnType("nvarchar(max)");
  1133. b.Property<int>("CountryId")
  1134. .HasColumnType("int");
  1135. b.Property<DateTime>("CreateDate")
  1136. .HasColumnType("datetime2")
  1137. .HasColumnOrder(3);
  1138. b.Property<string>("CreateUser")
  1139. .HasMaxLength(450)
  1140. .HasColumnType("nvarchar(450)")
  1141. .HasColumnOrder(1);
  1142. b.Property<string>("PostalCode")
  1143. .IsRequired()
  1144. .HasColumnType("nvarchar(max)");
  1145. b.Property<DateTime?>("UpdateDate")
  1146. .HasColumnType("datetime2")
  1147. .HasColumnOrder(4);
  1148. b.Property<string>("UpdateUser")
  1149. .HasMaxLength(450)
  1150. .HasColumnType("nvarchar(450)")
  1151. .HasColumnOrder(2);
  1152. b.Property<string>("UserId")
  1153. .IsRequired()
  1154. .HasColumnType("nvarchar(450)");
  1155. b.HasKey("Id");
  1156. b.HasIndex("UserId")
  1157. .IsUnique();
  1158. b.ToTable("UserAddress");
  1159. });
  1160. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAttachment", b =>
  1161. {
  1162. b.Property<long>("Id")
  1163. .ValueGeneratedOnAdd()
  1164. .HasColumnType("bigint")
  1165. .HasColumnOrder(0);
  1166. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1167. b.Property<long>("AttachmentTypeId")
  1168. .HasColumnType("bigint");
  1169. b.Property<DateTime>("CreateDate")
  1170. .HasColumnType("datetime2")
  1171. .HasColumnOrder(3);
  1172. b.Property<string>("CreateUser")
  1173. .HasMaxLength(450)
  1174. .HasColumnType("nvarchar(450)")
  1175. .HasColumnOrder(1);
  1176. b.Property<string>("FileName")
  1177. .IsRequired()
  1178. .HasMaxLength(250)
  1179. .HasColumnType("nvarchar(250)");
  1180. b.Property<string>("OriginalName")
  1181. .IsRequired()
  1182. .HasMaxLength(250)
  1183. .HasColumnType("nvarchar(250)");
  1184. b.Property<DateTime?>("UpdateDate")
  1185. .HasColumnType("datetime2")
  1186. .HasColumnOrder(4);
  1187. b.Property<string>("UpdateUser")
  1188. .HasMaxLength(450)
  1189. .HasColumnType("nvarchar(450)")
  1190. .HasColumnOrder(2);
  1191. b.Property<string>("UserId")
  1192. .IsRequired()
  1193. .HasColumnType("nvarchar(450)");
  1194. b.HasKey("Id");
  1195. b.HasIndex("AttachmentTypeId");
  1196. b.HasIndex("UserId");
  1197. b.ToTable("UserAttachments");
  1198. });
  1199. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  1200. {
  1201. b.Property<int>("Id")
  1202. .ValueGeneratedOnAdd()
  1203. .HasColumnType("int");
  1204. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  1205. b.Property<string>("ClaimType")
  1206. .HasColumnType("nvarchar(max)");
  1207. b.Property<string>("ClaimValue")
  1208. .HasColumnType("nvarchar(max)");
  1209. b.Property<string>("RoleId")
  1210. .IsRequired()
  1211. .HasColumnType("nvarchar(450)");
  1212. b.HasKey("Id");
  1213. b.HasIndex("RoleId");
  1214. b.ToTable("AspNetRoleClaims", (string)null);
  1215. });
  1216. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  1217. {
  1218. b.Property<int>("Id")
  1219. .ValueGeneratedOnAdd()
  1220. .HasColumnType("int");
  1221. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  1222. b.Property<string>("ClaimType")
  1223. .HasColumnType("nvarchar(max)");
  1224. b.Property<string>("ClaimValue")
  1225. .HasColumnType("nvarchar(max)");
  1226. b.Property<string>("UserId")
  1227. .IsRequired()
  1228. .HasColumnType("nvarchar(450)");
  1229. b.HasKey("Id");
  1230. b.HasIndex("UserId");
  1231. b.ToTable("AspNetUserClaims", (string)null);
  1232. });
  1233. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  1234. {
  1235. b.Property<string>("LoginProvider")
  1236. .HasColumnType("nvarchar(450)");
  1237. b.Property<string>("ProviderKey")
  1238. .HasColumnType("nvarchar(450)");
  1239. b.Property<string>("ProviderDisplayName")
  1240. .HasColumnType("nvarchar(max)");
  1241. b.Property<string>("UserId")
  1242. .IsRequired()
  1243. .HasColumnType("nvarchar(450)");
  1244. b.HasKey("LoginProvider", "ProviderKey");
  1245. b.HasIndex("UserId");
  1246. b.ToTable("AspNetUserLogins", (string)null);
  1247. });
  1248. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  1249. {
  1250. b.Property<string>("UserId")
  1251. .HasColumnType("nvarchar(450)");
  1252. b.Property<string>("RoleId")
  1253. .HasColumnType("nvarchar(450)");
  1254. b.HasKey("UserId", "RoleId");
  1255. b.HasIndex("RoleId");
  1256. b.ToTable("AspNetUserRoles", (string)null);
  1257. b.HasData(
  1258. new
  1259. {
  1260. UserId = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  1261. RoleId = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A"
  1262. },
  1263. new
  1264. {
  1265. UserId = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  1266. RoleId = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E"
  1267. });
  1268. });
  1269. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  1270. {
  1271. b.Property<string>("UserId")
  1272. .HasColumnType("nvarchar(450)");
  1273. b.Property<string>("LoginProvider")
  1274. .HasColumnType("nvarchar(450)");
  1275. b.Property<string>("Name")
  1276. .HasColumnType("nvarchar(450)");
  1277. b.Property<string>("Value")
  1278. .HasColumnType("nvarchar(max)");
  1279. b.HasKey("UserId", "LoginProvider", "Name");
  1280. b.ToTable("AspNetUserTokens", (string)null);
  1281. });
  1282. modelBuilder.Entity("ApplicationRoleApplicationUser", b =>
  1283. {
  1284. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  1285. .WithMany()
  1286. .HasForeignKey("UserRolesId")
  1287. .OnDelete(DeleteBehavior.Cascade)
  1288. .IsRequired();
  1289. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  1290. .WithMany()
  1291. .HasForeignKey("UsersId")
  1292. .OnDelete(DeleteBehavior.Cascade)
  1293. .IsRequired();
  1294. });
  1295. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingUser", b =>
  1296. {
  1297. b.HasOne("MTWorkHR.Core.Entities.Meeting", "Meeting")
  1298. .WithMany("MeetingUsers")
  1299. .HasForeignKey("MeetingId")
  1300. .OnDelete(DeleteBehavior.Cascade)
  1301. .IsRequired();
  1302. b.Navigation("Meeting");
  1303. });
  1304. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamUser", b =>
  1305. {
  1306. b.HasOne("MTWorkHR.Core.Entities.Team", "Team")
  1307. .WithMany("TeamUsers")
  1308. .HasForeignKey("TeamId")
  1309. .OnDelete(DeleteBehavior.Cascade)
  1310. .IsRequired();
  1311. b.Navigation("Team");
  1312. });
  1313. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  1314. {
  1315. b.HasOne("MTWorkHR.Core.Entities.Project", "Project")
  1316. .WithMany()
  1317. .HasForeignKey("ProjectId")
  1318. .OnDelete(DeleteBehavior.Cascade)
  1319. .IsRequired();
  1320. b.HasOne("MTWorkHR.Core.Entities.UserTaskStatus", "TaskStatus")
  1321. .WithMany()
  1322. .HasForeignKey("StatusId")
  1323. .OnDelete(DeleteBehavior.Cascade)
  1324. .IsRequired();
  1325. b.Navigation("Project");
  1326. b.Navigation("TaskStatus");
  1327. });
  1328. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskAttachment", b =>
  1329. {
  1330. b.HasOne("MTWorkHR.Core.Entities.Base.AttachmentType", "AttachmentType")
  1331. .WithMany()
  1332. .HasForeignKey("AttachmentTypeId")
  1333. .OnDelete(DeleteBehavior.Cascade)
  1334. .IsRequired();
  1335. b.HasOne("MTWorkHR.Core.Entities.UserTask", "UserTask")
  1336. .WithMany("TaskAttachments")
  1337. .HasForeignKey("TaskId")
  1338. .OnDelete(DeleteBehavior.Cascade)
  1339. .IsRequired();
  1340. b.Navigation("AttachmentType");
  1341. b.Navigation("UserTask");
  1342. });
  1343. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskHistory", b =>
  1344. {
  1345. b.HasOne("MTWorkHR.Core.Entities.UserTaskStatus", "TaskStatus")
  1346. .WithMany()
  1347. .HasForeignKey("CurrentStatusId")
  1348. .OnDelete(DeleteBehavior.Cascade)
  1349. .IsRequired();
  1350. b.HasOne("MTWorkHR.Core.Entities.UserTask", null)
  1351. .WithMany("UserTaskHistories")
  1352. .HasForeignKey("UserTaskId");
  1353. b.Navigation("TaskStatus");
  1354. });
  1355. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  1356. {
  1357. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "Manager")
  1358. .WithMany()
  1359. .HasForeignKey("ManagerId");
  1360. b.Navigation("Manager");
  1361. });
  1362. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.RolePermission", b =>
  1363. {
  1364. b.HasOne("MTWorkHR.Core.Entities.Permission", "Permission")
  1365. .WithMany()
  1366. .HasForeignKey("PermissionId")
  1367. .OnDelete(DeleteBehavior.Cascade)
  1368. .IsRequired();
  1369. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", "Role")
  1370. .WithMany("RolePermissions")
  1371. .HasForeignKey("RoleId")
  1372. .OnDelete(DeleteBehavior.Cascade)
  1373. .IsRequired();
  1374. b.Navigation("Permission");
  1375. b.Navigation("Role");
  1376. });
  1377. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAddress", b =>
  1378. {
  1379. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "User")
  1380. .WithOne("UserAddress")
  1381. .HasForeignKey("MTWorkHR.Infrastructure.Entities.UserAddress", "UserId")
  1382. .OnDelete(DeleteBehavior.Cascade)
  1383. .IsRequired();
  1384. b.Navigation("User");
  1385. });
  1386. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAttachment", b =>
  1387. {
  1388. b.HasOne("MTWorkHR.Core.Entities.Base.AttachmentType", "AttachmentType")
  1389. .WithMany()
  1390. .HasForeignKey("AttachmentTypeId")
  1391. .OnDelete(DeleteBehavior.Cascade)
  1392. .IsRequired();
  1393. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "User")
  1394. .WithMany("UserAttachments")
  1395. .HasForeignKey("UserId")
  1396. .OnDelete(DeleteBehavior.Cascade)
  1397. .IsRequired();
  1398. b.Navigation("AttachmentType");
  1399. b.Navigation("User");
  1400. });
  1401. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  1402. {
  1403. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  1404. .WithMany()
  1405. .HasForeignKey("RoleId")
  1406. .OnDelete(DeleteBehavior.Cascade)
  1407. .IsRequired();
  1408. });
  1409. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  1410. {
  1411. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  1412. .WithMany()
  1413. .HasForeignKey("UserId")
  1414. .OnDelete(DeleteBehavior.Cascade)
  1415. .IsRequired();
  1416. });
  1417. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  1418. {
  1419. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  1420. .WithMany()
  1421. .HasForeignKey("UserId")
  1422. .OnDelete(DeleteBehavior.Cascade)
  1423. .IsRequired();
  1424. });
  1425. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  1426. {
  1427. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  1428. .WithMany()
  1429. .HasForeignKey("RoleId")
  1430. .OnDelete(DeleteBehavior.Cascade)
  1431. .IsRequired();
  1432. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  1433. .WithMany()
  1434. .HasForeignKey("UserId")
  1435. .OnDelete(DeleteBehavior.Cascade)
  1436. .IsRequired();
  1437. });
  1438. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  1439. {
  1440. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  1441. .WithMany()
  1442. .HasForeignKey("UserId")
  1443. .OnDelete(DeleteBehavior.Cascade)
  1444. .IsRequired();
  1445. });
  1446. modelBuilder.Entity("MTWorkHR.Core.Entities.Meeting", b =>
  1447. {
  1448. b.Navigation("MeetingUsers");
  1449. });
  1450. modelBuilder.Entity("MTWorkHR.Core.Entities.Team", b =>
  1451. {
  1452. b.Navigation("TeamUsers");
  1453. });
  1454. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  1455. {
  1456. b.Navigation("TaskAttachments");
  1457. b.Navigation("UserTaskHistories");
  1458. });
  1459. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationRole", b =>
  1460. {
  1461. b.Navigation("RolePermissions");
  1462. });
  1463. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  1464. {
  1465. b.Navigation("UserAddress")
  1466. .IsRequired();
  1467. b.Navigation("UserAttachments");
  1468. });
  1469. #pragma warning restore 612, 618
  1470. }
  1471. }
  1472. }