20240708143314_altrUserTask.Designer.cs 123 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361
  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("20240708143314_altrUserTask")]
  14. partial class altrUserTask
  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<long>("CompanyId")
  48. .HasColumnType("bigint");
  49. b.Property<DateTime>("CreateDate")
  50. .HasColumnType("datetime2")
  51. .HasColumnOrder(3);
  52. b.Property<string>("CreateUser")
  53. .HasMaxLength(450)
  54. .HasColumnType("nvarchar(450)")
  55. .HasColumnOrder(1);
  56. b.Property<string>("DeleteUserId")
  57. .HasMaxLength(450)
  58. .HasColumnType("nvarchar(450)")
  59. .HasColumnOrder(8);
  60. b.Property<bool>("IsDeleted")
  61. .HasColumnType("bit")
  62. .HasColumnOrder(7);
  63. b.Property<string>("LeaveReason")
  64. .HasMaxLength(250)
  65. .HasColumnType("nvarchar(250)");
  66. b.Property<int>("LeaveType")
  67. .HasColumnType("int");
  68. b.Property<DateTime?>("UpdateDate")
  69. .HasColumnType("datetime2")
  70. .HasColumnOrder(4);
  71. b.Property<string>("UpdateUser")
  72. .HasMaxLength(450)
  73. .HasColumnType("nvarchar(450)")
  74. .HasColumnOrder(2);
  75. b.Property<string>("UserId")
  76. .IsRequired()
  77. .HasColumnType("nvarchar(max)");
  78. b.Property<string>("UserName")
  79. .HasColumnType("nvarchar(max)");
  80. b.HasKey("Id");
  81. b.HasIndex("CompanyId");
  82. b.ToTable("Attendances");
  83. });
  84. modelBuilder.Entity("MTWorkHR.Core.Entities.AttendanceLog", b =>
  85. {
  86. b.Property<long>("Id")
  87. .ValueGeneratedOnAdd()
  88. .HasColumnType("bigint")
  89. .HasColumnOrder(0);
  90. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  91. b.Property<string>("Channel")
  92. .HasColumnType("nvarchar(max)");
  93. b.Property<DateTime>("CreateDate")
  94. .HasColumnType("datetime2");
  95. b.Property<string>("CreateUser")
  96. .IsRequired()
  97. .HasColumnType("nvarchar(max)");
  98. b.Property<string>("ErrorCode")
  99. .IsRequired()
  100. .HasColumnType("nvarchar(max)");
  101. b.Property<string>("ErrorDescription")
  102. .IsRequired()
  103. .HasColumnType("nvarchar(max)");
  104. b.Property<string>("InnerException")
  105. .HasColumnType("nvarchar(max)");
  106. b.Property<string>("Input")
  107. .HasColumnType("nvarchar(max)");
  108. b.Property<string>("Method")
  109. .IsRequired()
  110. .HasColumnType("nvarchar(max)");
  111. b.Property<string>("QueryString")
  112. .HasColumnType("nvarchar(max)");
  113. b.Property<string>("ServerIP")
  114. .HasColumnType("nvarchar(max)");
  115. b.Property<string>("ServiceResponseTimeInSeconds")
  116. .IsRequired()
  117. .HasColumnType("nvarchar(max)");
  118. b.Property<string>("UserIP")
  119. .HasColumnType("nvarchar(max)");
  120. b.Property<string>("userAgent")
  121. .HasColumnType("nvarchar(max)");
  122. b.HasKey("Id");
  123. b.ToTable("AttendanceLogs");
  124. });
  125. modelBuilder.Entity("MTWorkHR.Core.Entities.AuthLog", b =>
  126. {
  127. b.Property<long>("Id")
  128. .ValueGeneratedOnAdd()
  129. .HasColumnType("bigint")
  130. .HasColumnOrder(0);
  131. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  132. b.Property<string>("Channel")
  133. .HasColumnType("nvarchar(max)");
  134. b.Property<DateTime>("CreateDate")
  135. .HasColumnType("datetime2");
  136. b.Property<string>("CreateUser")
  137. .IsRequired()
  138. .HasColumnType("nvarchar(max)");
  139. b.Property<string>("ErrorCode")
  140. .IsRequired()
  141. .HasColumnType("nvarchar(max)");
  142. b.Property<string>("ErrorDescription")
  143. .IsRequired()
  144. .HasColumnType("nvarchar(max)");
  145. b.Property<string>("InnerException")
  146. .HasColumnType("nvarchar(max)");
  147. b.Property<string>("Input")
  148. .HasColumnType("nvarchar(max)");
  149. b.Property<string>("Method")
  150. .IsRequired()
  151. .HasColumnType("nvarchar(max)");
  152. b.Property<string>("QueryString")
  153. .HasColumnType("nvarchar(max)");
  154. b.Property<string>("ServerIP")
  155. .HasColumnType("nvarchar(max)");
  156. b.Property<string>("ServiceResponseTimeInSeconds")
  157. .IsRequired()
  158. .HasColumnType("nvarchar(max)");
  159. b.Property<string>("UserIP")
  160. .HasColumnType("nvarchar(max)");
  161. b.Property<string>("userAgent")
  162. .HasColumnType("nvarchar(max)");
  163. b.HasKey("Id");
  164. b.ToTable("AuthLogs");
  165. });
  166. modelBuilder.Entity("MTWorkHR.Core.Entities.Base.AttachmentType", b =>
  167. {
  168. b.Property<long>("Id")
  169. .ValueGeneratedOnAdd()
  170. .HasColumnType("bigint")
  171. .HasColumnOrder(0);
  172. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  173. b.Property<bool>("IsRequired")
  174. .HasColumnType("bit");
  175. b.Property<string>("NameAr")
  176. .IsRequired()
  177. .HasMaxLength(250)
  178. .HasColumnType("nvarchar(250)");
  179. b.Property<string>("NameEn")
  180. .IsRequired()
  181. .HasMaxLength(250)
  182. .HasColumnType("nvarchar(250)");
  183. b.HasKey("Id");
  184. b.ToTable("AttachmentTypes");
  185. b.HasData(
  186. new
  187. {
  188. Id = 1L,
  189. IsRequired = false,
  190. NameAr = "السيرة الذاتية",
  191. NameEn = "CV"
  192. },
  193. new
  194. {
  195. Id = 2L,
  196. IsRequired = false,
  197. NameAr = "جواز السفر",
  198. NameEn = "Passport"
  199. },
  200. new
  201. {
  202. Id = 3L,
  203. IsRequired = false,
  204. NameAr = "شهادة التعليم",
  205. NameEn = "Education Certification"
  206. },
  207. new
  208. {
  209. Id = 4L,
  210. IsRequired = false,
  211. NameAr = "شهادة الخبرة",
  212. NameEn = "Experience Certification"
  213. },
  214. new
  215. {
  216. Id = 5L,
  217. IsRequired = false,
  218. NameAr = "شهادة الاحتراف",
  219. NameEn = "Professional Certification"
  220. },
  221. new
  222. {
  223. Id = 6L,
  224. IsRequired = false,
  225. NameAr = "التسجيل التجارى",
  226. NameEn = "Commercial Regestration"
  227. },
  228. new
  229. {
  230. Id = 7L,
  231. IsRequired = false,
  232. NameAr = "البطاقة الضريبية",
  233. NameEn = "Tax Declaration"
  234. },
  235. new
  236. {
  237. Id = 8L,
  238. IsRequired = false,
  239. NameAr = "الهوية",
  240. NameEn = "Identification"
  241. },
  242. new
  243. {
  244. Id = 9L,
  245. IsRequired = false,
  246. NameAr = "الصورة",
  247. NameEn = "Image"
  248. });
  249. });
  250. modelBuilder.Entity("MTWorkHR.Core.Entities.City", b =>
  251. {
  252. b.Property<long>("Id")
  253. .ValueGeneratedOnAdd()
  254. .HasColumnType("bigint")
  255. .HasColumnOrder(0);
  256. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  257. b.Property<string>("Code")
  258. .IsRequired()
  259. .HasColumnType("nvarchar(max)");
  260. b.Property<long>("CountryId")
  261. .HasColumnType("bigint");
  262. b.Property<string>("NameAr")
  263. .IsRequired()
  264. .HasMaxLength(250)
  265. .HasColumnType("nvarchar(250)");
  266. b.Property<string>("NameEn")
  267. .IsRequired()
  268. .HasMaxLength(250)
  269. .HasColumnType("nvarchar(250)");
  270. b.Property<string>("NameFr")
  271. .IsRequired()
  272. .HasColumnType("nvarchar(max)");
  273. b.HasKey("Id");
  274. b.HasIndex("CountryId");
  275. b.ToTable("Cities");
  276. });
  277. modelBuilder.Entity("MTWorkHR.Core.Entities.Company", b =>
  278. {
  279. b.Property<long>("Id")
  280. .ValueGeneratedOnAdd()
  281. .HasColumnType("bigint")
  282. .HasColumnOrder(0);
  283. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  284. b.Property<string>("CRNumber")
  285. .IsRequired()
  286. .HasColumnType("nvarchar(max)");
  287. b.Property<string>("CompanyName")
  288. .IsRequired()
  289. .HasColumnType("nvarchar(max)");
  290. b.Property<DateTime>("CreateDate")
  291. .HasColumnType("datetime2")
  292. .HasColumnOrder(3);
  293. b.Property<string>("CreateUser")
  294. .HasMaxLength(450)
  295. .HasColumnType("nvarchar(450)")
  296. .HasColumnOrder(1);
  297. b.Property<string>("DeleteUserId")
  298. .HasMaxLength(450)
  299. .HasColumnType("nvarchar(450)")
  300. .HasColumnOrder(8);
  301. b.Property<bool>("IsDeleted")
  302. .HasColumnType("bit")
  303. .HasColumnOrder(7);
  304. b.Property<int>("TaxNumber")
  305. .HasColumnType("int");
  306. b.Property<DateTime?>("UpdateDate")
  307. .HasColumnType("datetime2")
  308. .HasColumnOrder(4);
  309. b.Property<string>("UpdateUser")
  310. .HasMaxLength(450)
  311. .HasColumnType("nvarchar(450)")
  312. .HasColumnOrder(2);
  313. b.Property<string>("UserId")
  314. .IsRequired()
  315. .HasColumnType("nvarchar(max)");
  316. b.HasKey("Id");
  317. b.ToTable("Companies");
  318. });
  319. modelBuilder.Entity("MTWorkHR.Core.Entities.CountryLookup", b =>
  320. {
  321. b.Property<long>("Id")
  322. .ValueGeneratedOnAdd()
  323. .HasColumnType("bigint")
  324. .HasColumnOrder(0);
  325. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  326. b.Property<string>("Code")
  327. .IsRequired()
  328. .HasColumnType("nvarchar(max)");
  329. b.Property<string>("NameAr")
  330. .IsRequired()
  331. .HasMaxLength(250)
  332. .HasColumnType("nvarchar(250)");
  333. b.Property<string>("NameEn")
  334. .IsRequired()
  335. .HasMaxLength(250)
  336. .HasColumnType("nvarchar(250)");
  337. b.Property<string>("NameFr")
  338. .IsRequired()
  339. .HasColumnType("nvarchar(max)");
  340. b.HasKey("Id");
  341. b.ToTable("CountryLookups");
  342. });
  343. modelBuilder.Entity("MTWorkHR.Core.Entities.FileLog", b =>
  344. {
  345. b.Property<long>("Id")
  346. .ValueGeneratedOnAdd()
  347. .HasColumnType("bigint")
  348. .HasColumnOrder(0);
  349. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  350. b.Property<string>("Channel")
  351. .HasColumnType("nvarchar(max)");
  352. b.Property<DateTime>("CreateDate")
  353. .HasColumnType("datetime2");
  354. b.Property<string>("CreateUser")
  355. .IsRequired()
  356. .HasColumnType("nvarchar(max)");
  357. b.Property<string>("ErrorCode")
  358. .IsRequired()
  359. .HasColumnType("nvarchar(max)");
  360. b.Property<string>("ErrorDescription")
  361. .IsRequired()
  362. .HasColumnType("nvarchar(max)");
  363. b.Property<string>("InnerException")
  364. .HasColumnType("nvarchar(max)");
  365. b.Property<string>("Input")
  366. .HasColumnType("nvarchar(max)");
  367. b.Property<string>("Method")
  368. .IsRequired()
  369. .HasColumnType("nvarchar(max)");
  370. b.Property<string>("QueryString")
  371. .HasColumnType("nvarchar(max)");
  372. b.Property<string>("ServerIP")
  373. .HasColumnType("nvarchar(max)");
  374. b.Property<string>("ServiceResponseTimeInSeconds")
  375. .IsRequired()
  376. .HasColumnType("nvarchar(max)");
  377. b.Property<string>("UserIP")
  378. .HasColumnType("nvarchar(max)");
  379. b.Property<string>("userAgent")
  380. .HasColumnType("nvarchar(max)");
  381. b.HasKey("Id");
  382. b.ToTable("FileLogs");
  383. });
  384. modelBuilder.Entity("MTWorkHR.Core.Entities.Industry", b =>
  385. {
  386. b.Property<long>("Id")
  387. .ValueGeneratedOnAdd()
  388. .HasColumnType("bigint")
  389. .HasColumnOrder(0);
  390. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  391. b.Property<string>("NameAr")
  392. .IsRequired()
  393. .HasMaxLength(250)
  394. .HasColumnType("nvarchar(250)");
  395. b.Property<string>("NameEn")
  396. .IsRequired()
  397. .HasMaxLength(250)
  398. .HasColumnType("nvarchar(250)");
  399. b.HasKey("Id");
  400. b.ToTable("Industries");
  401. b.HasData(
  402. new
  403. {
  404. Id = 1L,
  405. NameAr = "صناعة الطيران والفضاء",
  406. NameEn = "Aerospace industry"
  407. },
  408. new
  409. {
  410. Id = 2L,
  411. NameAr = "صناعة الزراعة",
  412. NameEn = "Agricultural industry"
  413. },
  414. new
  415. {
  416. Id = 3L,
  417. NameAr = "صناعة السيارات",
  418. NameEn = "Automotive industry"
  419. },
  420. new
  421. {
  422. Id = 4L,
  423. NameAr = "صناعة المعادن الأساسية",
  424. NameEn = "Basic metal"
  425. },
  426. new
  427. {
  428. Id = 5L,
  429. NameAr = "صناعة الكيماويات",
  430. NameEn = "Chemical industry"
  431. },
  432. new
  433. {
  434. Id = 6L,
  435. NameAr = "صناعة الحواسيب",
  436. NameEn = "Computer industry"
  437. },
  438. new
  439. {
  440. Id = 7L,
  441. NameAr = "صناعة البناء",
  442. NameEn = "Construction industry"
  443. },
  444. new
  445. {
  446. Id = 8L,
  447. NameAr = "صناعة الإبداعية",
  448. NameEn = "Creative industry"
  449. },
  450. new
  451. {
  452. Id = 9L,
  453. NameAr = "صناعة الثقافة",
  454. NameEn = "Cultural industry"
  455. },
  456. new
  457. {
  458. Id = 10L,
  459. NameAr = "صناعة الدفاع",
  460. NameEn = "Defense industry"
  461. },
  462. new
  463. {
  464. Id = 11L,
  465. NameAr = "صناعة التعليم",
  466. NameEn = "Education industry"
  467. },
  468. new
  469. {
  470. Id = 12L,
  471. NameAr = "صناعة الطاقة الكهربائية",
  472. NameEn = "Electric power"
  473. },
  474. new
  475. {
  476. Id = 13L,
  477. NameAr = "صناعة الإلكترونيات",
  478. NameEn = "Electronics industry"
  479. },
  480. new
  481. {
  482. Id = 14L,
  483. NameAr = "صناعة الطاقة",
  484. NameEn = "Energy industry"
  485. },
  486. new
  487. {
  488. Id = 15L,
  489. NameAr = "صناعة الهندسة",
  490. NameEn = "Engineering industry"
  491. },
  492. new
  493. {
  494. Id = 16L,
  495. NameAr = "صناعة الترفيه",
  496. NameEn = "Entertainment industry"
  497. },
  498. new
  499. {
  500. Id = 17L,
  501. NameAr = "صناعة الزراعة",
  502. NameEn = "Farming industry"
  503. },
  504. new
  505. {
  506. Id = 18L,
  507. NameAr = "صناعة الموضة",
  508. NameEn = "Fashion industry"
  509. },
  510. new
  511. {
  512. Id = 19L,
  513. NameAr = "صناعة السينما",
  514. NameEn = "Film industry"
  515. },
  516. new
  517. {
  518. Id = 20L,
  519. NameAr = "صناعة الخدمات المالية",
  520. NameEn = "Financial services"
  521. },
  522. new
  523. {
  524. Id = 21L,
  525. NameAr = "صناعة الصيد",
  526. NameEn = "Fishing industry"
  527. },
  528. new
  529. {
  530. Id = 22L,
  531. NameAr = "صناعة الأغذية",
  532. NameEn = "Food industry"
  533. },
  534. new
  535. {
  536. Id = 23L,
  537. NameAr = "صناعة الغابات",
  538. NameEn = "Forestry industry"
  539. },
  540. new
  541. {
  542. Id = 24L,
  543. NameAr = "صناعة القمار",
  544. NameEn = "Gambling industry"
  545. },
  546. new
  547. {
  548. Id = 25L,
  549. NameAr = "صناعة الغاز",
  550. NameEn = "Gas industry"
  551. },
  552. new
  553. {
  554. Id = 26L,
  555. NameAr = "صناعة البيئة",
  556. NameEn = "Green industry"
  557. },
  558. new
  559. {
  560. Id = 27L,
  561. NameAr = "صناعة الخدمات الصحية",
  562. NameEn = "Health services industry"
  563. },
  564. new
  565. {
  566. Id = 28L,
  567. NameAr = "صناعة الضيافة",
  568. NameEn = "Hospitality industry"
  569. },
  570. new
  571. {
  572. Id = 29L,
  573. NameAr = "صناعة الفنادق",
  574. NameEn = "Hotels industry"
  575. },
  576. new
  577. {
  578. Id = 30L,
  579. NameAr = "صناعة الروبوتات الصناعية",
  580. NameEn = "Industrial robot"
  581. },
  582. new
  583. {
  584. Id = 31L,
  585. NameAr = "صناعة المعلومات",
  586. NameEn = "Information industry"
  587. },
  588. new
  589. {
  590. Id = 32L,
  591. NameAr = "صناعة تكنولوجيا المعلومات",
  592. NameEn = "Information technology"
  593. },
  594. new
  595. {
  596. Id = 33L,
  597. NameAr = "صناعة البنية التحتية",
  598. NameEn = "Infrastructure industry"
  599. },
  600. new
  601. {
  602. Id = 34L,
  603. NameAr = "صناعة التأمين",
  604. NameEn = "Insurance industry"
  605. },
  606. new
  607. {
  608. Id = 35L,
  609. NameAr = "صناعة الترفيه",
  610. NameEn = "Leisure industry"
  611. },
  612. new
  613. {
  614. Id = 36L,
  615. NameAr = "صناعة التكنولوجيا المنخفضة",
  616. NameEn = "Low technology"
  617. },
  618. new
  619. {
  620. Id = 37L,
  621. NameAr = "صناعة التصنيع",
  622. NameEn = "Manufacturing industry"
  623. },
  624. new
  625. {
  626. Id = 38L,
  627. NameAr = "صناعة اللحوم",
  628. NameEn = "Meat industry"
  629. },
  630. new
  631. {
  632. Id = 39L,
  633. NameAr = "صناعة الإعلام",
  634. NameEn = "Media industry"
  635. },
  636. new
  637. {
  638. Id = 40L,
  639. NameAr = "صناعة التجارة",
  640. NameEn = "Merchandising industry"
  641. },
  642. new
  643. {
  644. Id = 41L,
  645. NameAr = "صناعة التعدين",
  646. NameEn = "Mining industry"
  647. },
  648. new
  649. {
  650. Id = 42L,
  651. NameAr = "صناعة الموسيقى",
  652. NameEn = "Music industry"
  653. },
  654. new
  655. {
  656. Id = 43L,
  657. NameAr = "صناعة وسائل الإعلام",
  658. NameEn = "News media"
  659. },
  660. new
  661. {
  662. Id = 44L,
  663. NameAr = "صناعة النفط والغاز",
  664. NameEn = "Oil and gas industry"
  665. },
  666. new
  667. {
  668. Id = 45L,
  669. NameAr = "صناعة الأدوية",
  670. NameEn = "Pharmaceutical industry"
  671. },
  672. new
  673. {
  674. Id = 46L,
  675. NameAr = "صناعة المهنية",
  676. NameEn = "Professional industry"
  677. },
  678. new
  679. {
  680. Id = 47L,
  681. NameAr = "صناعة النشر",
  682. NameEn = "Publishing industry"
  683. },
  684. new
  685. {
  686. Id = 48L,
  687. NameAr = "صناعة الورق واللب",
  688. NameEn = "Pulp and paper industry"
  689. },
  690. new
  691. {
  692. Id = 49L,
  693. NameAr = "صناعة السكك الحديدية",
  694. NameEn = "Railway industry"
  695. },
  696. new
  697. {
  698. Id = 50L,
  699. NameAr = "الانشاءات",
  700. NameEn = "Real estate"
  701. });
  702. });
  703. modelBuilder.Entity("MTWorkHR.Core.Entities.JobTitle", b =>
  704. {
  705. b.Property<long>("Id")
  706. .ValueGeneratedOnAdd()
  707. .HasColumnType("bigint")
  708. .HasColumnOrder(0);
  709. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  710. b.Property<string>("NameAr")
  711. .IsRequired()
  712. .HasMaxLength(250)
  713. .HasColumnType("nvarchar(250)");
  714. b.Property<string>("NameEn")
  715. .IsRequired()
  716. .HasMaxLength(250)
  717. .HasColumnType("nvarchar(250)");
  718. b.HasKey("Id");
  719. b.ToTable("JobTitles");
  720. b.HasData(
  721. new
  722. {
  723. Id = 1L,
  724. NameAr = "مساعد ادارى",
  725. NameEn = "Administrative Assistant"
  726. },
  727. new
  728. {
  729. Id = 2L,
  730. NameAr = "موظف استقبال",
  731. NameEn = "Receptionist"
  732. },
  733. new
  734. {
  735. Id = 3L,
  736. NameAr = "مدير مكتب",
  737. NameEn = "Office Manager"
  738. },
  739. new
  740. {
  741. Id = 4L,
  742. NameAr = "مدقق محتوى",
  743. NameEn = "Auditing Clerk"
  744. },
  745. new
  746. {
  747. Id = 5L,
  748. NameAr = "محاسب",
  749. NameEn = "Bookkeeper"
  750. },
  751. new
  752. {
  753. Id = 6L,
  754. NameAr = "مدير تنفيذى",
  755. NameEn = "Account Executive"
  756. },
  757. new
  758. {
  759. Id = 7L,
  760. NameAr = "مدير فرع",
  761. NameEn = "Branch Manager"
  762. },
  763. new
  764. {
  765. Id = 8L,
  766. NameAr = "مدير",
  767. NameEn = "Business Manager"
  768. },
  769. new
  770. {
  771. Id = 9L,
  772. NameAr = "مسؤول الجودة",
  773. NameEn = "Quality Control Coordinator"
  774. },
  775. new
  776. {
  777. Id = 10L,
  778. NameAr = "مدير ادارى",
  779. NameEn = "Administrative Manager"
  780. },
  781. new
  782. {
  783. Id = 11L,
  784. NameAr = "الرئيس التنفيذي",
  785. NameEn = "Chief Executive Officer"
  786. },
  787. new
  788. {
  789. Id = 12L,
  790. NameAr = "محلل",
  791. NameEn = "Business Analyst"
  792. },
  793. new
  794. {
  795. Id = 13L,
  796. NameAr = "مدير المخاطر",
  797. NameEn = "Risk Manager"
  798. },
  799. new
  800. {
  801. Id = 14L,
  802. NameAr = "موارد بشرية",
  803. NameEn = "Human Resources"
  804. },
  805. new
  806. {
  807. Id = 15L,
  808. NameAr = "مساعد مكتب",
  809. NameEn = "Office Assistant"
  810. },
  811. new
  812. {
  813. Id = 16L,
  814. NameAr = "السكرتارية",
  815. NameEn = "Secretary"
  816. },
  817. new
  818. {
  819. Id = 17L,
  820. NameAr = "موظف مكتب",
  821. NameEn = "Office Clerk"
  822. },
  823. new
  824. {
  825. Id = 18L,
  826. NameAr = "جامع الحسابات",
  827. NameEn = "Account Collector"
  828. },
  829. new
  830. {
  831. Id = 19L,
  832. NameAr = "أخصائي إداري",
  833. NameEn = "Administrative Specialist"
  834. },
  835. new
  836. {
  837. Id = 20L,
  838. NameAr = "مساعد تنفيذي",
  839. NameEn = "Executive Assistant"
  840. },
  841. new
  842. {
  843. Id = 21L,
  844. NameAr = "مسؤل البرنامج",
  845. NameEn = "Program Administrator"
  846. },
  847. new
  848. {
  849. Id = 22L,
  850. NameAr = "مدير البرنامج",
  851. NameEn = "Program Manager"
  852. },
  853. new
  854. {
  855. Id = 23L,
  856. NameAr = "محلل إداري",
  857. NameEn = "Administrative Analyst"
  858. },
  859. new
  860. {
  861. Id = 24L,
  862. NameAr = "مدخل بيانات",
  863. NameEn = "Data Entry"
  864. });
  865. });
  866. modelBuilder.Entity("MTWorkHR.Core.Entities.LeaveType", b =>
  867. {
  868. b.Property<long>("Id")
  869. .ValueGeneratedOnAdd()
  870. .HasColumnType("bigint")
  871. .HasColumnOrder(0);
  872. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  873. b.Property<int>("DefaultDays")
  874. .HasColumnType("int");
  875. b.Property<string>("NameAr")
  876. .IsRequired()
  877. .HasColumnType("nvarchar(max)");
  878. b.Property<string>("NameEn")
  879. .IsRequired()
  880. .HasColumnType("nvarchar(max)");
  881. b.HasKey("Id");
  882. b.ToTable("LeaveTypes");
  883. b.HasData(
  884. new
  885. {
  886. Id = 1L,
  887. DefaultDays = 21,
  888. NameAr = "أجازة سنوية",
  889. NameEn = "Annual Leave"
  890. },
  891. new
  892. {
  893. Id = 2L,
  894. DefaultDays = 15,
  895. NameAr = "أجازة مرضية",
  896. NameEn = "Sick Leave"
  897. },
  898. new
  899. {
  900. Id = 3L,
  901. DefaultDays = 20,
  902. NameAr = "أجازة زواج",
  903. NameEn = "Marriage Leave"
  904. },
  905. new
  906. {
  907. Id = 4L,
  908. DefaultDays = 10,
  909. NameAr = "أجازة وضع",
  910. NameEn = "Paternity leave"
  911. },
  912. new
  913. {
  914. Id = 5L,
  915. DefaultDays = 10,
  916. NameAr = "أجازة طارئة",
  917. NameEn = "Emergency leave"
  918. });
  919. });
  920. modelBuilder.Entity("MTWorkHR.Core.Entities.LoginOTP", b =>
  921. {
  922. b.Property<long>("Id")
  923. .ValueGeneratedOnAdd()
  924. .HasColumnType("bigint")
  925. .HasColumnOrder(0);
  926. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  927. b.Property<DateTime>("CreateDate")
  928. .HasColumnType("datetime2");
  929. b.Property<DateTime>("ExpireDate")
  930. .HasColumnType("datetime2");
  931. b.Property<string>("OTP")
  932. .IsRequired()
  933. .HasColumnType("nvarchar(max)");
  934. b.Property<string>("UserId")
  935. .IsRequired()
  936. .HasColumnType("nvarchar(max)");
  937. b.HasKey("Id");
  938. b.ToTable("LoginOTPs");
  939. });
  940. modelBuilder.Entity("MTWorkHR.Core.Entities.Meeting", b =>
  941. {
  942. b.Property<long>("Id")
  943. .ValueGeneratedOnAdd()
  944. .HasColumnType("bigint")
  945. .HasColumnOrder(0);
  946. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  947. b.Property<long>("CompanyId")
  948. .HasColumnType("bigint");
  949. b.Property<DateTime>("CreateDate")
  950. .HasColumnType("datetime2")
  951. .HasColumnOrder(3);
  952. b.Property<string>("CreateUser")
  953. .HasMaxLength(450)
  954. .HasColumnType("nvarchar(450)")
  955. .HasColumnOrder(1);
  956. b.Property<string>("DeleteUserId")
  957. .HasMaxLength(450)
  958. .HasColumnType("nvarchar(450)")
  959. .HasColumnOrder(8);
  960. b.Property<string>("Description")
  961. .HasMaxLength(500)
  962. .HasColumnType("nvarchar(500)");
  963. b.Property<string>("EndTime")
  964. .IsRequired()
  965. .HasColumnType("nvarchar(max)");
  966. b.Property<bool>("IsDeleted")
  967. .HasColumnType("bit")
  968. .HasColumnOrder(7);
  969. b.Property<string>("Location")
  970. .HasMaxLength(250)
  971. .HasColumnType("nvarchar(250)");
  972. b.Property<DateTime>("MeetingDate")
  973. .HasColumnType("datetime2");
  974. b.Property<string>("MeetingLink")
  975. .HasMaxLength(250)
  976. .HasColumnType("nvarchar(250)");
  977. b.Property<int>("RepeatId")
  978. .HasColumnType("int");
  979. b.Property<string>("StartTime")
  980. .IsRequired()
  981. .HasColumnType("nvarchar(max)");
  982. b.Property<string>("Title")
  983. .IsRequired()
  984. .HasMaxLength(250)
  985. .HasColumnType("nvarchar(250)");
  986. b.Property<DateTime?>("UpdateDate")
  987. .HasColumnType("datetime2")
  988. .HasColumnOrder(4);
  989. b.Property<string>("UpdateUser")
  990. .HasMaxLength(450)
  991. .HasColumnType("nvarchar(450)")
  992. .HasColumnOrder(2);
  993. b.HasKey("Id");
  994. b.HasIndex("CompanyId");
  995. b.ToTable("Meetings");
  996. });
  997. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingLog", b =>
  998. {
  999. b.Property<long>("Id")
  1000. .ValueGeneratedOnAdd()
  1001. .HasColumnType("bigint")
  1002. .HasColumnOrder(0);
  1003. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1004. b.Property<string>("Channel")
  1005. .HasColumnType("nvarchar(max)");
  1006. b.Property<DateTime>("CreateDate")
  1007. .HasColumnType("datetime2");
  1008. b.Property<string>("CreateUser")
  1009. .IsRequired()
  1010. .HasColumnType("nvarchar(max)");
  1011. b.Property<string>("ErrorCode")
  1012. .IsRequired()
  1013. .HasColumnType("nvarchar(max)");
  1014. b.Property<string>("ErrorDescription")
  1015. .IsRequired()
  1016. .HasColumnType("nvarchar(max)");
  1017. b.Property<string>("InnerException")
  1018. .HasColumnType("nvarchar(max)");
  1019. b.Property<string>("Input")
  1020. .HasColumnType("nvarchar(max)");
  1021. b.Property<string>("Method")
  1022. .IsRequired()
  1023. .HasColumnType("nvarchar(max)");
  1024. b.Property<string>("QueryString")
  1025. .HasColumnType("nvarchar(max)");
  1026. b.Property<string>("ServerIP")
  1027. .HasColumnType("nvarchar(max)");
  1028. b.Property<string>("ServiceResponseTimeInSeconds")
  1029. .IsRequired()
  1030. .HasColumnType("nvarchar(max)");
  1031. b.Property<string>("UserIP")
  1032. .HasColumnType("nvarchar(max)");
  1033. b.Property<string>("userAgent")
  1034. .HasColumnType("nvarchar(max)");
  1035. b.HasKey("Id");
  1036. b.ToTable("MeetingLogs");
  1037. });
  1038. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingUser", b =>
  1039. {
  1040. b.Property<long>("Id")
  1041. .ValueGeneratedOnAdd()
  1042. .HasColumnType("bigint")
  1043. .HasColumnOrder(0);
  1044. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1045. b.Property<string>("AssignedUserId")
  1046. .IsRequired()
  1047. .HasColumnType("nvarchar(max)");
  1048. b.Property<string>("AssignedUserName")
  1049. .IsRequired()
  1050. .HasColumnType("nvarchar(max)");
  1051. b.Property<DateTime>("CreateDate")
  1052. .HasColumnType("datetime2")
  1053. .HasColumnOrder(3);
  1054. b.Property<string>("CreateUser")
  1055. .HasMaxLength(450)
  1056. .HasColumnType("nvarchar(450)")
  1057. .HasColumnOrder(1);
  1058. b.Property<long>("MeetingId")
  1059. .HasColumnType("bigint");
  1060. b.Property<DateTime?>("UpdateDate")
  1061. .HasColumnType("datetime2")
  1062. .HasColumnOrder(4);
  1063. b.Property<string>("UpdateUser")
  1064. .HasMaxLength(450)
  1065. .HasColumnType("nvarchar(450)")
  1066. .HasColumnOrder(2);
  1067. b.HasKey("Id");
  1068. b.HasIndex("MeetingId");
  1069. b.ToTable("MeetingUser");
  1070. });
  1071. modelBuilder.Entity("MTWorkHR.Core.Entities.OrderAllocation", b =>
  1072. {
  1073. b.Property<long>("Id")
  1074. .ValueGeneratedOnAdd()
  1075. .HasColumnType("bigint")
  1076. .HasColumnOrder(0);
  1077. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1078. b.Property<long>("CompanyId")
  1079. .HasColumnType("bigint");
  1080. b.Property<DateTime>("CreateDate")
  1081. .HasColumnType("datetime2")
  1082. .HasColumnOrder(3);
  1083. b.Property<string>("CreateUser")
  1084. .HasMaxLength(450)
  1085. .HasColumnType("nvarchar(450)")
  1086. .HasColumnOrder(1);
  1087. b.Property<string>("EmployeeId")
  1088. .IsRequired()
  1089. .HasColumnType("nvarchar(max)");
  1090. b.Property<long?>("LeaveTypeId")
  1091. .HasColumnType("bigint");
  1092. b.Property<int>("NumberOfDays")
  1093. .HasColumnType("int");
  1094. b.Property<long>("OrderTypeId")
  1095. .HasColumnType("bigint");
  1096. b.Property<int>("Period")
  1097. .HasColumnType("int");
  1098. b.Property<DateTime?>("UpdateDate")
  1099. .HasColumnType("datetime2")
  1100. .HasColumnOrder(4);
  1101. b.Property<string>("UpdateUser")
  1102. .HasMaxLength(450)
  1103. .HasColumnType("nvarchar(450)")
  1104. .HasColumnOrder(2);
  1105. b.HasKey("Id");
  1106. b.HasIndex("CompanyId");
  1107. b.HasIndex("LeaveTypeId");
  1108. b.HasIndex("OrderTypeId");
  1109. b.ToTable("OrderAllocations");
  1110. });
  1111. modelBuilder.Entity("MTWorkHR.Core.Entities.OrderType", b =>
  1112. {
  1113. b.Property<long>("Id")
  1114. .ValueGeneratedOnAdd()
  1115. .HasColumnType("bigint")
  1116. .HasColumnOrder(0);
  1117. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1118. b.Property<int>("DefaultDays")
  1119. .HasColumnType("int");
  1120. b.Property<string>("NameAr")
  1121. .IsRequired()
  1122. .HasColumnType("nvarchar(max)");
  1123. b.Property<string>("NameEn")
  1124. .IsRequired()
  1125. .HasColumnType("nvarchar(max)");
  1126. b.HasKey("Id");
  1127. b.ToTable("OrderTypes");
  1128. b.HasData(
  1129. new
  1130. {
  1131. Id = 1L,
  1132. DefaultDays = 2,
  1133. NameAr = "إذن",
  1134. NameEn = "Leave"
  1135. },
  1136. new
  1137. {
  1138. Id = 2L,
  1139. DefaultDays = 15,
  1140. NameAr = "طبية",
  1141. NameEn = "Medical"
  1142. },
  1143. new
  1144. {
  1145. Id = 3L,
  1146. DefaultDays = 20,
  1147. NameAr = "وقت إضافي",
  1148. NameEn = "Overtime"
  1149. },
  1150. new
  1151. {
  1152. Id = 4L,
  1153. DefaultDays = 0,
  1154. NameAr = "رحلة عمل",
  1155. NameEn = "Business trip"
  1156. },
  1157. new
  1158. {
  1159. Id = 5L,
  1160. DefaultDays = 0,
  1161. NameAr = "دورة تدريبية",
  1162. NameEn = "Course"
  1163. });
  1164. });
  1165. modelBuilder.Entity("MTWorkHR.Core.Entities.Permission", b =>
  1166. {
  1167. b.Property<long>("Id")
  1168. .ValueGeneratedOnAdd()
  1169. .HasColumnType("bigint")
  1170. .HasColumnOrder(0);
  1171. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1172. b.Property<string>("CategoryName")
  1173. .IsRequired()
  1174. .HasMaxLength(150)
  1175. .HasColumnType("nvarchar(150)");
  1176. b.Property<string>("Desc")
  1177. .IsRequired()
  1178. .HasMaxLength(250)
  1179. .HasColumnType("nvarchar(250)");
  1180. b.Property<string>("Name")
  1181. .IsRequired()
  1182. .HasMaxLength(250)
  1183. .HasColumnType("nvarchar(250)");
  1184. b.Property<bool>("Show")
  1185. .HasColumnType("bit");
  1186. b.HasKey("Id");
  1187. b.ToTable("Permissions");
  1188. b.HasData(
  1189. new
  1190. {
  1191. Id = 1L,
  1192. CategoryName = "User",
  1193. Desc = "Project",
  1194. Name = "Project",
  1195. Show = true
  1196. },
  1197. new
  1198. {
  1199. Id = 2L,
  1200. CategoryName = "User",
  1201. Desc = "Project.Create",
  1202. Name = "Project.Create",
  1203. Show = false
  1204. },
  1205. new
  1206. {
  1207. Id = 3L,
  1208. CategoryName = "User",
  1209. Desc = "Project.Update",
  1210. Name = "Project.Update",
  1211. Show = false
  1212. },
  1213. new
  1214. {
  1215. Id = 4L,
  1216. CategoryName = "User",
  1217. Desc = "Project.Delete",
  1218. Name = "Project.Delete",
  1219. Show = false
  1220. },
  1221. new
  1222. {
  1223. Id = 5L,
  1224. CategoryName = "User",
  1225. Desc = "Meeting",
  1226. Name = "Meeting",
  1227. Show = true
  1228. },
  1229. new
  1230. {
  1231. Id = 6L,
  1232. CategoryName = "User",
  1233. Desc = "Meeting.Create",
  1234. Name = "Meeting.Create",
  1235. Show = false
  1236. },
  1237. new
  1238. {
  1239. Id = 7L,
  1240. CategoryName = "User",
  1241. Desc = "Meeting.Update",
  1242. Name = "Meeting.Update",
  1243. Show = false
  1244. },
  1245. new
  1246. {
  1247. Id = 8L,
  1248. CategoryName = "User",
  1249. Desc = "Meeting.Delete",
  1250. Name = "Meeting.Delete",
  1251. Show = false
  1252. },
  1253. new
  1254. {
  1255. Id = 9L,
  1256. CategoryName = "User",
  1257. Desc = "Team",
  1258. Name = "Team",
  1259. Show = true
  1260. },
  1261. new
  1262. {
  1263. Id = 10L,
  1264. CategoryName = "User",
  1265. Desc = "Team.Create",
  1266. Name = "Team.Create",
  1267. Show = false
  1268. },
  1269. new
  1270. {
  1271. Id = 11L,
  1272. CategoryName = "User",
  1273. Desc = "Team.Update",
  1274. Name = "Team.Update",
  1275. Show = false
  1276. },
  1277. new
  1278. {
  1279. Id = 12L,
  1280. CategoryName = "User",
  1281. Desc = "Team.Delete",
  1282. Name = "Team.Delete",
  1283. Show = false
  1284. },
  1285. new
  1286. {
  1287. Id = 13L,
  1288. CategoryName = "Sales",
  1289. Desc = "UserTask",
  1290. Name = "UserTask",
  1291. Show = true
  1292. },
  1293. new
  1294. {
  1295. Id = 14L,
  1296. CategoryName = "Sales",
  1297. Desc = "UserTask.Create",
  1298. Name = "UserTask.Create",
  1299. Show = false
  1300. },
  1301. new
  1302. {
  1303. Id = 15L,
  1304. CategoryName = "Sales",
  1305. Desc = "UserTask.Update",
  1306. Name = "UserTask.Update",
  1307. Show = false
  1308. },
  1309. new
  1310. {
  1311. Id = 16L,
  1312. CategoryName = "User",
  1313. Desc = "UserTask.Delete",
  1314. Name = "UserTask.Delete",
  1315. Show = false
  1316. },
  1317. new
  1318. {
  1319. Id = 17L,
  1320. CategoryName = "User",
  1321. Desc = "Company",
  1322. Name = "Company",
  1323. Show = true
  1324. },
  1325. new
  1326. {
  1327. Id = 18L,
  1328. CategoryName = "User",
  1329. Desc = "Company.Create",
  1330. Name = "Company.Create",
  1331. Show = false
  1332. },
  1333. new
  1334. {
  1335. Id = 19L,
  1336. CategoryName = "User",
  1337. Desc = "Company.Update",
  1338. Name = "Company.Update",
  1339. Show = false
  1340. },
  1341. new
  1342. {
  1343. Id = 20L,
  1344. CategoryName = "User",
  1345. Desc = "Company.Delete",
  1346. Name = "Company.Delete",
  1347. Show = false
  1348. },
  1349. new
  1350. {
  1351. Id = 21L,
  1352. CategoryName = "Adminstration",
  1353. Desc = "User",
  1354. Name = "User",
  1355. Show = true
  1356. },
  1357. new
  1358. {
  1359. Id = 22L,
  1360. CategoryName = "Adminstration",
  1361. Desc = "User.Create",
  1362. Name = "User.Create",
  1363. Show = false
  1364. },
  1365. new
  1366. {
  1367. Id = 23L,
  1368. CategoryName = "Adminstration",
  1369. Desc = "User.Update",
  1370. Name = "User.Update",
  1371. Show = false
  1372. },
  1373. new
  1374. {
  1375. Id = 24L,
  1376. CategoryName = "Adminstration",
  1377. Desc = "User.Delete",
  1378. Name = "User.Delete",
  1379. Show = false
  1380. },
  1381. new
  1382. {
  1383. Id = 25L,
  1384. CategoryName = "Adminstration",
  1385. Desc = "Role",
  1386. Name = "Role",
  1387. Show = true
  1388. },
  1389. new
  1390. {
  1391. Id = 26L,
  1392. CategoryName = "Adminstration",
  1393. Desc = "Role.Create",
  1394. Name = "Role.Create",
  1395. Show = false
  1396. },
  1397. new
  1398. {
  1399. Id = 27L,
  1400. CategoryName = "Adminstration",
  1401. Desc = "Role.Update",
  1402. Name = "Role.Update",
  1403. Show = false
  1404. },
  1405. new
  1406. {
  1407. Id = 28L,
  1408. CategoryName = "Adminstration",
  1409. Desc = "Role.Delete",
  1410. Name = "Role.Delete",
  1411. Show = false
  1412. });
  1413. });
  1414. modelBuilder.Entity("MTWorkHR.Core.Entities.Project", b =>
  1415. {
  1416. b.Property<long>("Id")
  1417. .ValueGeneratedOnAdd()
  1418. .HasColumnType("bigint")
  1419. .HasColumnOrder(0);
  1420. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1421. b.Property<long>("CompanyId")
  1422. .HasColumnType("bigint");
  1423. b.Property<DateTime>("CreateDate")
  1424. .HasColumnType("datetime2")
  1425. .HasColumnOrder(3);
  1426. b.Property<string>("CreateUser")
  1427. .HasMaxLength(450)
  1428. .HasColumnType("nvarchar(450)")
  1429. .HasColumnOrder(1);
  1430. b.Property<string>("DeleteUserId")
  1431. .HasMaxLength(450)
  1432. .HasColumnType("nvarchar(450)")
  1433. .HasColumnOrder(8);
  1434. b.Property<bool>("IsDeleted")
  1435. .HasColumnType("bit")
  1436. .HasColumnOrder(7);
  1437. b.Property<string>("NameAr")
  1438. .IsRequired()
  1439. .HasMaxLength(250)
  1440. .HasColumnType("nvarchar(250)");
  1441. b.Property<string>("NameEn")
  1442. .IsRequired()
  1443. .HasMaxLength(250)
  1444. .HasColumnType("nvarchar(250)");
  1445. b.Property<DateTime?>("UpdateDate")
  1446. .HasColumnType("datetime2")
  1447. .HasColumnOrder(4);
  1448. b.Property<string>("UpdateUser")
  1449. .HasMaxLength(450)
  1450. .HasColumnType("nvarchar(450)")
  1451. .HasColumnOrder(2);
  1452. b.HasKey("Id");
  1453. b.HasIndex("CompanyId");
  1454. b.ToTable("Projects");
  1455. });
  1456. modelBuilder.Entity("MTWorkHR.Core.Entities.Qualification", b =>
  1457. {
  1458. b.Property<long>("Id")
  1459. .ValueGeneratedOnAdd()
  1460. .HasColumnType("bigint")
  1461. .HasColumnOrder(0);
  1462. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1463. b.Property<string>("NameAr")
  1464. .IsRequired()
  1465. .HasMaxLength(250)
  1466. .HasColumnType("nvarchar(250)");
  1467. b.Property<string>("NameEn")
  1468. .IsRequired()
  1469. .HasMaxLength(250)
  1470. .HasColumnType("nvarchar(250)");
  1471. b.HasKey("Id");
  1472. b.ToTable("Qualifications");
  1473. b.HasData(
  1474. new
  1475. {
  1476. Id = 1L,
  1477. NameAr = "بكالوريوس",
  1478. NameEn = "BSC"
  1479. },
  1480. new
  1481. {
  1482. Id = 2L,
  1483. NameAr = "درجة الماجيستير",
  1484. NameEn = "Master"
  1485. },
  1486. new
  1487. {
  1488. Id = 3L,
  1489. NameAr = "درحة الدكتوراه",
  1490. NameEn = "Doctor"
  1491. });
  1492. });
  1493. modelBuilder.Entity("MTWorkHR.Core.Entities.RoleLog", b =>
  1494. {
  1495. b.Property<long>("Id")
  1496. .ValueGeneratedOnAdd()
  1497. .HasColumnType("bigint")
  1498. .HasColumnOrder(0);
  1499. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1500. b.Property<string>("Channel")
  1501. .HasColumnType("nvarchar(max)");
  1502. b.Property<DateTime>("CreateDate")
  1503. .HasColumnType("datetime2");
  1504. b.Property<string>("CreateUser")
  1505. .IsRequired()
  1506. .HasColumnType("nvarchar(max)");
  1507. b.Property<string>("ErrorCode")
  1508. .IsRequired()
  1509. .HasColumnType("nvarchar(max)");
  1510. b.Property<string>("ErrorDescription")
  1511. .IsRequired()
  1512. .HasColumnType("nvarchar(max)");
  1513. b.Property<string>("InnerException")
  1514. .HasColumnType("nvarchar(max)");
  1515. b.Property<string>("Input")
  1516. .HasColumnType("nvarchar(max)");
  1517. b.Property<string>("Method")
  1518. .IsRequired()
  1519. .HasColumnType("nvarchar(max)");
  1520. b.Property<string>("QueryString")
  1521. .HasColumnType("nvarchar(max)");
  1522. b.Property<string>("ServerIP")
  1523. .HasColumnType("nvarchar(max)");
  1524. b.Property<string>("ServiceResponseTimeInSeconds")
  1525. .IsRequired()
  1526. .HasColumnType("nvarchar(max)");
  1527. b.Property<string>("UserIP")
  1528. .HasColumnType("nvarchar(max)");
  1529. b.Property<string>("userAgent")
  1530. .HasColumnType("nvarchar(max)");
  1531. b.HasKey("Id");
  1532. b.ToTable("RoleLogs");
  1533. });
  1534. modelBuilder.Entity("MTWorkHR.Core.Entities.SettingLog", b =>
  1535. {
  1536. b.Property<long>("Id")
  1537. .ValueGeneratedOnAdd()
  1538. .HasColumnType("bigint")
  1539. .HasColumnOrder(0);
  1540. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1541. b.Property<string>("Channel")
  1542. .HasColumnType("nvarchar(max)");
  1543. b.Property<DateTime>("CreateDate")
  1544. .HasColumnType("datetime2");
  1545. b.Property<string>("CreateUser")
  1546. .IsRequired()
  1547. .HasColumnType("nvarchar(max)");
  1548. b.Property<string>("ErrorCode")
  1549. .IsRequired()
  1550. .HasColumnType("nvarchar(max)");
  1551. b.Property<string>("ErrorDescription")
  1552. .IsRequired()
  1553. .HasColumnType("nvarchar(max)");
  1554. b.Property<string>("InnerException")
  1555. .HasColumnType("nvarchar(max)");
  1556. b.Property<string>("Input")
  1557. .HasColumnType("nvarchar(max)");
  1558. b.Property<string>("Method")
  1559. .IsRequired()
  1560. .HasColumnType("nvarchar(max)");
  1561. b.Property<string>("QueryString")
  1562. .HasColumnType("nvarchar(max)");
  1563. b.Property<string>("ServerIP")
  1564. .HasColumnType("nvarchar(max)");
  1565. b.Property<string>("ServiceResponseTimeInSeconds")
  1566. .IsRequired()
  1567. .HasColumnType("nvarchar(max)");
  1568. b.Property<string>("UserIP")
  1569. .HasColumnType("nvarchar(max)");
  1570. b.Property<string>("userAgent")
  1571. .HasColumnType("nvarchar(max)");
  1572. b.HasKey("Id");
  1573. b.ToTable("SettingLogs");
  1574. });
  1575. modelBuilder.Entity("MTWorkHR.Core.Entities.Team", b =>
  1576. {
  1577. b.Property<long>("Id")
  1578. .ValueGeneratedOnAdd()
  1579. .HasColumnType("bigint")
  1580. .HasColumnOrder(0);
  1581. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1582. b.Property<long>("CompanyId")
  1583. .HasColumnType("bigint");
  1584. b.Property<DateTime>("CreateDate")
  1585. .HasColumnType("datetime2")
  1586. .HasColumnOrder(3);
  1587. b.Property<string>("CreateUser")
  1588. .HasMaxLength(450)
  1589. .HasColumnType("nvarchar(450)")
  1590. .HasColumnOrder(1);
  1591. b.Property<string>("DeleteUserId")
  1592. .HasMaxLength(450)
  1593. .HasColumnType("nvarchar(450)")
  1594. .HasColumnOrder(8);
  1595. b.Property<bool>("IsDeleted")
  1596. .HasColumnType("bit")
  1597. .HasColumnOrder(7);
  1598. b.Property<string>("NameAr")
  1599. .IsRequired()
  1600. .HasMaxLength(250)
  1601. .HasColumnType("nvarchar(250)");
  1602. b.Property<string>("NameEn")
  1603. .IsRequired()
  1604. .HasMaxLength(250)
  1605. .HasColumnType("nvarchar(250)");
  1606. b.Property<DateTime?>("UpdateDate")
  1607. .HasColumnType("datetime2")
  1608. .HasColumnOrder(4);
  1609. b.Property<string>("UpdateUser")
  1610. .HasMaxLength(450)
  1611. .HasColumnType("nvarchar(450)")
  1612. .HasColumnOrder(2);
  1613. b.HasKey("Id");
  1614. b.HasIndex("CompanyId");
  1615. b.ToTable("Teams");
  1616. });
  1617. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamLog", b =>
  1618. {
  1619. b.Property<long>("Id")
  1620. .ValueGeneratedOnAdd()
  1621. .HasColumnType("bigint")
  1622. .HasColumnOrder(0);
  1623. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1624. b.Property<string>("Channel")
  1625. .HasColumnType("nvarchar(max)");
  1626. b.Property<DateTime>("CreateDate")
  1627. .HasColumnType("datetime2");
  1628. b.Property<string>("CreateUser")
  1629. .IsRequired()
  1630. .HasColumnType("nvarchar(max)");
  1631. b.Property<string>("ErrorCode")
  1632. .IsRequired()
  1633. .HasColumnType("nvarchar(max)");
  1634. b.Property<string>("ErrorDescription")
  1635. .IsRequired()
  1636. .HasColumnType("nvarchar(max)");
  1637. b.Property<string>("InnerException")
  1638. .HasColumnType("nvarchar(max)");
  1639. b.Property<string>("Input")
  1640. .HasColumnType("nvarchar(max)");
  1641. b.Property<string>("Method")
  1642. .IsRequired()
  1643. .HasColumnType("nvarchar(max)");
  1644. b.Property<string>("QueryString")
  1645. .HasColumnType("nvarchar(max)");
  1646. b.Property<string>("ServerIP")
  1647. .HasColumnType("nvarchar(max)");
  1648. b.Property<string>("ServiceResponseTimeInSeconds")
  1649. .IsRequired()
  1650. .HasColumnType("nvarchar(max)");
  1651. b.Property<string>("UserIP")
  1652. .HasColumnType("nvarchar(max)");
  1653. b.Property<string>("userAgent")
  1654. .HasColumnType("nvarchar(max)");
  1655. b.HasKey("Id");
  1656. b.ToTable("TeamLogs");
  1657. });
  1658. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamUser", b =>
  1659. {
  1660. b.Property<long>("Id")
  1661. .ValueGeneratedOnAdd()
  1662. .HasColumnType("bigint")
  1663. .HasColumnOrder(0);
  1664. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1665. b.Property<string>("AssignedUserId")
  1666. .IsRequired()
  1667. .HasColumnType("nvarchar(max)");
  1668. b.Property<string>("AssignedUserName")
  1669. .IsRequired()
  1670. .HasColumnType("nvarchar(max)");
  1671. b.Property<DateTime>("CreateDate")
  1672. .HasColumnType("datetime2")
  1673. .HasColumnOrder(3);
  1674. b.Property<string>("CreateUser")
  1675. .HasMaxLength(450)
  1676. .HasColumnType("nvarchar(450)")
  1677. .HasColumnOrder(1);
  1678. b.Property<bool>("IsAdmin")
  1679. .HasColumnType("bit");
  1680. b.Property<long>("TeamId")
  1681. .HasColumnType("bigint");
  1682. b.Property<DateTime?>("UpdateDate")
  1683. .HasColumnType("datetime2")
  1684. .HasColumnOrder(4);
  1685. b.Property<string>("UpdateUser")
  1686. .HasMaxLength(450)
  1687. .HasColumnType("nvarchar(450)")
  1688. .HasColumnOrder(2);
  1689. b.HasKey("Id");
  1690. b.HasIndex("TeamId");
  1691. b.ToTable("TeamUser");
  1692. });
  1693. modelBuilder.Entity("MTWorkHR.Core.Entities.University", b =>
  1694. {
  1695. b.Property<long>("Id")
  1696. .ValueGeneratedOnAdd()
  1697. .HasColumnType("bigint")
  1698. .HasColumnOrder(0);
  1699. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1700. b.Property<string>("NameAr")
  1701. .IsRequired()
  1702. .HasMaxLength(250)
  1703. .HasColumnType("nvarchar(250)");
  1704. b.Property<string>("NameEn")
  1705. .IsRequired()
  1706. .HasMaxLength(250)
  1707. .HasColumnType("nvarchar(250)");
  1708. b.HasKey("Id");
  1709. b.ToTable("Universities");
  1710. b.HasData(
  1711. new
  1712. {
  1713. Id = 1L,
  1714. NameAr = "جامعة الملك فهد",
  1715. NameEn = "Fahd Univ"
  1716. },
  1717. new
  1718. {
  1719. Id = 2L,
  1720. NameAr = "جامعة الرياض",
  1721. NameEn = "Riydh Univ"
  1722. },
  1723. new
  1724. {
  1725. Id = 3L,
  1726. NameAr = "جامعة جدة",
  1727. NameEn = "Geda Univ"
  1728. });
  1729. });
  1730. modelBuilder.Entity("MTWorkHR.Core.Entities.User.OrderRequest", b =>
  1731. {
  1732. b.Property<long>("Id")
  1733. .ValueGeneratedOnAdd()
  1734. .HasColumnType("bigint")
  1735. .HasColumnOrder(0);
  1736. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1737. b.Property<int?>("CityId")
  1738. .HasColumnType("int");
  1739. b.Property<long>("CompanyId")
  1740. .HasColumnType("bigint");
  1741. b.Property<int?>("CountryId")
  1742. .HasColumnType("int");
  1743. b.Property<DateTime>("CreateDate")
  1744. .HasColumnType("datetime2")
  1745. .HasColumnOrder(3);
  1746. b.Property<string>("CreateUser")
  1747. .HasMaxLength(450)
  1748. .HasColumnType("nvarchar(450)")
  1749. .HasColumnOrder(1);
  1750. b.Property<string>("DeleteUserId")
  1751. .HasMaxLength(450)
  1752. .HasColumnType("nvarchar(450)")
  1753. .HasColumnOrder(8);
  1754. b.Property<DateTime?>("EndDate")
  1755. .HasColumnType("datetime2");
  1756. b.Property<bool>("IsDeleted")
  1757. .HasColumnType("bit")
  1758. .HasColumnOrder(7);
  1759. b.Property<long?>("LeaveTypeId")
  1760. .HasColumnType("bigint");
  1761. b.Property<int?>("OrderStatus")
  1762. .HasColumnType("int");
  1763. b.Property<long>("OrderTypeId")
  1764. .HasColumnType("bigint");
  1765. b.Property<string>("RequestComments")
  1766. .HasColumnType("nvarchar(max)");
  1767. b.Property<string>("RequestingEmployeeId")
  1768. .IsRequired()
  1769. .HasColumnType("nvarchar(max)");
  1770. b.Property<DateTime>("StartDate")
  1771. .HasColumnType("datetime2");
  1772. b.Property<DateTime?>("UpdateDate")
  1773. .HasColumnType("datetime2")
  1774. .HasColumnOrder(4);
  1775. b.Property<string>("UpdateUser")
  1776. .HasMaxLength(450)
  1777. .HasColumnType("nvarchar(450)")
  1778. .HasColumnOrder(2);
  1779. b.HasKey("Id");
  1780. b.HasIndex("CompanyId");
  1781. b.HasIndex("LeaveTypeId");
  1782. b.HasIndex("OrderTypeId");
  1783. b.ToTable("OrderRequests");
  1784. });
  1785. modelBuilder.Entity("MTWorkHR.Core.Entities.UserLog", b =>
  1786. {
  1787. b.Property<long>("Id")
  1788. .ValueGeneratedOnAdd()
  1789. .HasColumnType("bigint")
  1790. .HasColumnOrder(0);
  1791. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1792. b.Property<string>("Channel")
  1793. .HasColumnType("nvarchar(max)");
  1794. b.Property<DateTime>("CreateDate")
  1795. .HasColumnType("datetime2");
  1796. b.Property<string>("CreateUser")
  1797. .IsRequired()
  1798. .HasColumnType("nvarchar(max)");
  1799. b.Property<string>("ErrorCode")
  1800. .IsRequired()
  1801. .HasColumnType("nvarchar(max)");
  1802. b.Property<string>("ErrorDescription")
  1803. .IsRequired()
  1804. .HasColumnType("nvarchar(max)");
  1805. b.Property<string>("InnerException")
  1806. .HasColumnType("nvarchar(max)");
  1807. b.Property<string>("Input")
  1808. .HasColumnType("nvarchar(max)");
  1809. b.Property<string>("Method")
  1810. .IsRequired()
  1811. .HasColumnType("nvarchar(max)");
  1812. b.Property<string>("QueryString")
  1813. .HasColumnType("nvarchar(max)");
  1814. b.Property<string>("ServerIP")
  1815. .HasColumnType("nvarchar(max)");
  1816. b.Property<string>("ServiceResponseTimeInSeconds")
  1817. .IsRequired()
  1818. .HasColumnType("nvarchar(max)");
  1819. b.Property<string>("UserIP")
  1820. .HasColumnType("nvarchar(max)");
  1821. b.Property<string>("userAgent")
  1822. .HasColumnType("nvarchar(max)");
  1823. b.HasKey("Id");
  1824. b.ToTable("UserLogs");
  1825. });
  1826. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  1827. {
  1828. b.Property<long>("Id")
  1829. .ValueGeneratedOnAdd()
  1830. .HasColumnType("bigint")
  1831. .HasColumnOrder(0);
  1832. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1833. b.Property<string>("AssignedUserId")
  1834. .IsRequired()
  1835. .HasColumnType("nvarchar(max)");
  1836. b.Property<long>("CompanyId")
  1837. .HasColumnType("bigint");
  1838. b.Property<DateTime>("CreateDate")
  1839. .HasColumnType("datetime2")
  1840. .HasColumnOrder(3);
  1841. b.Property<string>("CreateUser")
  1842. .HasMaxLength(450)
  1843. .HasColumnType("nvarchar(450)")
  1844. .HasColumnOrder(1);
  1845. b.Property<string>("DeleteUserId")
  1846. .HasMaxLength(450)
  1847. .HasColumnType("nvarchar(450)")
  1848. .HasColumnOrder(8);
  1849. b.Property<string>("Description")
  1850. .IsRequired()
  1851. .HasColumnType("nvarchar(max)");
  1852. b.Property<DateTime>("DueDate")
  1853. .HasColumnType("datetime2");
  1854. b.Property<bool>("IsDeleted")
  1855. .HasColumnType("bit")
  1856. .HasColumnOrder(7);
  1857. b.Property<int>("Priority")
  1858. .HasColumnType("int");
  1859. b.Property<long>("ProjectId")
  1860. .HasColumnType("bigint");
  1861. b.Property<long>("StatusId")
  1862. .HasColumnType("bigint");
  1863. b.Property<string>("Title")
  1864. .IsRequired()
  1865. .HasColumnType("nvarchar(max)");
  1866. b.Property<DateTime?>("UpdateDate")
  1867. .HasColumnType("datetime2")
  1868. .HasColumnOrder(4);
  1869. b.Property<string>("UpdateUser")
  1870. .HasMaxLength(450)
  1871. .HasColumnType("nvarchar(450)")
  1872. .HasColumnOrder(2);
  1873. b.HasKey("Id");
  1874. b.HasIndex("CompanyId");
  1875. b.HasIndex("ProjectId");
  1876. b.HasIndex("StatusId");
  1877. b.ToTable("UserTasks");
  1878. });
  1879. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskAttachment", b =>
  1880. {
  1881. b.Property<long>("Id")
  1882. .ValueGeneratedOnAdd()
  1883. .HasColumnType("bigint")
  1884. .HasColumnOrder(0);
  1885. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1886. b.Property<long?>("AttachmentTypeId")
  1887. .HasColumnType("bigint");
  1888. b.Property<DateTime>("CreateDate")
  1889. .HasColumnType("datetime2")
  1890. .HasColumnOrder(3);
  1891. b.Property<string>("CreateUser")
  1892. .HasMaxLength(450)
  1893. .HasColumnType("nvarchar(450)")
  1894. .HasColumnOrder(1);
  1895. b.Property<string>("FileName")
  1896. .HasMaxLength(250)
  1897. .HasColumnType("nvarchar(250)");
  1898. b.Property<string>("OriginalName")
  1899. .HasMaxLength(250)
  1900. .HasColumnType("nvarchar(250)");
  1901. b.Property<long>("TaskId")
  1902. .HasColumnType("bigint");
  1903. b.Property<DateTime?>("UpdateDate")
  1904. .HasColumnType("datetime2")
  1905. .HasColumnOrder(4);
  1906. b.Property<string>("UpdateUser")
  1907. .HasMaxLength(450)
  1908. .HasColumnType("nvarchar(450)")
  1909. .HasColumnOrder(2);
  1910. b.HasKey("Id");
  1911. b.HasIndex("AttachmentTypeId");
  1912. b.HasIndex("TaskId");
  1913. b.ToTable("UserTaskAttachments");
  1914. });
  1915. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskHistory", b =>
  1916. {
  1917. b.Property<long>("Id")
  1918. .ValueGeneratedOnAdd()
  1919. .HasColumnType("bigint")
  1920. .HasColumnOrder(0);
  1921. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1922. b.Property<long>("AssignedToUserId")
  1923. .HasColumnType("bigint");
  1924. b.Property<string>("Comment")
  1925. .HasMaxLength(500)
  1926. .HasColumnType("nvarchar(500)");
  1927. b.Property<DateTime>("CreateDate")
  1928. .HasColumnType("datetime2")
  1929. .HasColumnOrder(3);
  1930. b.Property<string>("CreateUser")
  1931. .HasMaxLength(450)
  1932. .HasColumnType("nvarchar(450)")
  1933. .HasColumnOrder(1);
  1934. b.Property<long>("CurrentStatusId")
  1935. .HasColumnType("bigint");
  1936. b.Property<bool>("IsDeleted")
  1937. .HasColumnType("bit");
  1938. b.Property<long>("TaskId")
  1939. .HasColumnType("bigint");
  1940. b.Property<DateTime?>("UpdateDate")
  1941. .HasColumnType("datetime2")
  1942. .HasColumnOrder(4);
  1943. b.Property<string>("UpdateUser")
  1944. .HasMaxLength(450)
  1945. .HasColumnType("nvarchar(450)")
  1946. .HasColumnOrder(2);
  1947. b.Property<long?>("UserTaskId")
  1948. .HasColumnType("bigint");
  1949. b.HasKey("Id");
  1950. b.HasIndex("CurrentStatusId");
  1951. b.HasIndex("UserTaskId");
  1952. b.ToTable("UserTaskHistories");
  1953. });
  1954. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskLog", b =>
  1955. {
  1956. b.Property<long>("Id")
  1957. .ValueGeneratedOnAdd()
  1958. .HasColumnType("bigint")
  1959. .HasColumnOrder(0);
  1960. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1961. b.Property<string>("Channel")
  1962. .HasColumnType("nvarchar(max)");
  1963. b.Property<DateTime>("CreateDate")
  1964. .HasColumnType("datetime2");
  1965. b.Property<string>("CreateUser")
  1966. .IsRequired()
  1967. .HasColumnType("nvarchar(max)");
  1968. b.Property<string>("ErrorCode")
  1969. .IsRequired()
  1970. .HasColumnType("nvarchar(max)");
  1971. b.Property<string>("ErrorDescription")
  1972. .IsRequired()
  1973. .HasColumnType("nvarchar(max)");
  1974. b.Property<string>("InnerException")
  1975. .HasColumnType("nvarchar(max)");
  1976. b.Property<string>("Input")
  1977. .HasColumnType("nvarchar(max)");
  1978. b.Property<string>("Method")
  1979. .IsRequired()
  1980. .HasColumnType("nvarchar(max)");
  1981. b.Property<string>("QueryString")
  1982. .HasColumnType("nvarchar(max)");
  1983. b.Property<string>("ServerIP")
  1984. .HasColumnType("nvarchar(max)");
  1985. b.Property<string>("ServiceResponseTimeInSeconds")
  1986. .IsRequired()
  1987. .HasColumnType("nvarchar(max)");
  1988. b.Property<string>("UserIP")
  1989. .HasColumnType("nvarchar(max)");
  1990. b.Property<string>("userAgent")
  1991. .HasColumnType("nvarchar(max)");
  1992. b.HasKey("Id");
  1993. b.ToTable("UserTaskLogs");
  1994. });
  1995. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskStatus", b =>
  1996. {
  1997. b.Property<long>("Id")
  1998. .ValueGeneratedOnAdd()
  1999. .HasColumnType("bigint")
  2000. .HasColumnOrder(0);
  2001. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  2002. b.Property<string>("NameAr")
  2003. .IsRequired()
  2004. .HasMaxLength(250)
  2005. .HasColumnType("nvarchar(250)");
  2006. b.Property<string>("NameEn")
  2007. .IsRequired()
  2008. .HasMaxLength(250)
  2009. .HasColumnType("nvarchar(250)");
  2010. b.HasKey("Id");
  2011. b.ToTable("UserTaskStatuses");
  2012. b.HasData(
  2013. new
  2014. {
  2015. Id = 1L,
  2016. NameAr = "جديدة",
  2017. NameEn = "New"
  2018. },
  2019. new
  2020. {
  2021. Id = 2L,
  2022. NameAr = "قيد العمل",
  2023. NameEn = "Under progress"
  2024. },
  2025. new
  2026. {
  2027. Id = 3L,
  2028. NameAr = "أغلقت",
  2029. NameEn = "Closed"
  2030. },
  2031. new
  2032. {
  2033. Id = 4L,
  2034. NameAr = "تمت",
  2035. NameEn = "Completed"
  2036. },
  2037. new
  2038. {
  2039. Id = 5L,
  2040. NameAr = "مؤجلة",
  2041. NameEn = "Delayed"
  2042. });
  2043. });
  2044. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationRole", b =>
  2045. {
  2046. b.Property<string>("Id")
  2047. .HasColumnType("nvarchar(450)");
  2048. b.Property<string>("ConcurrencyStamp")
  2049. .IsConcurrencyToken()
  2050. .HasColumnType("nvarchar(max)");
  2051. b.Property<DateTime>("CreateDate")
  2052. .HasColumnType("datetime2");
  2053. b.Property<string>("CreateUser")
  2054. .HasColumnType("nvarchar(max)");
  2055. b.Property<string>("DeleteUserId")
  2056. .HasColumnType("nvarchar(max)");
  2057. b.Property<bool?>("IsAdmin")
  2058. .HasColumnType("bit");
  2059. b.Property<bool>("IsDeleted")
  2060. .HasColumnType("bit");
  2061. b.Property<string>("Name")
  2062. .HasMaxLength(256)
  2063. .HasColumnType("nvarchar(256)");
  2064. b.Property<string>("NormalizedName")
  2065. .HasMaxLength(256)
  2066. .HasColumnType("nvarchar(256)");
  2067. b.Property<DateTime?>("UpdateDate")
  2068. .HasColumnType("datetime2");
  2069. b.Property<string>("UpdateUser")
  2070. .HasColumnType("nvarchar(max)");
  2071. b.HasKey("Id");
  2072. b.HasIndex("NormalizedName")
  2073. .IsUnique()
  2074. .HasDatabaseName("RoleNameIndex")
  2075. .HasFilter("[NormalizedName] IS NOT NULL");
  2076. b.ToTable("AspNetRoles", (string)null);
  2077. b.HasData(
  2078. new
  2079. {
  2080. Id = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A",
  2081. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2082. IsAdmin = true,
  2083. IsDeleted = false,
  2084. Name = "Admin",
  2085. NormalizedName = "ADMIN"
  2086. },
  2087. new
  2088. {
  2089. Id = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E",
  2090. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2091. IsAdmin = false,
  2092. IsDeleted = false,
  2093. Name = "Employee",
  2094. NormalizedName = "EMPLOYEE"
  2095. },
  2096. new
  2097. {
  2098. Id = "CO5B3B92-2311-48F8-9DEC-F9FAEF1F211R",
  2099. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2100. IsAdmin = false,
  2101. IsDeleted = false,
  2102. Name = "Contractor",
  2103. NormalizedName = "CONTRACTOR"
  2104. });
  2105. });
  2106. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  2107. {
  2108. b.Property<string>("Id")
  2109. .HasColumnType("nvarchar(450)");
  2110. b.Property<int>("AccessFailedCount")
  2111. .HasColumnType("int");
  2112. b.Property<long?>("CompanyId")
  2113. .HasColumnType("bigint");
  2114. b.Property<string>("ConcurrencyStamp")
  2115. .IsConcurrencyToken()
  2116. .HasColumnType("nvarchar(max)");
  2117. b.Property<long?>("CountryId")
  2118. .HasColumnType("bigint");
  2119. b.Property<string>("CreateUser")
  2120. .HasColumnType("nvarchar(max)");
  2121. b.Property<DateTime>("DateOfBirth")
  2122. .HasColumnType("datetime2");
  2123. b.Property<string>("DeleteUserId")
  2124. .HasColumnType("nvarchar(max)");
  2125. b.Property<string>("Email")
  2126. .HasMaxLength(256)
  2127. .HasColumnType("nvarchar(256)");
  2128. b.Property<bool>("EmailConfirmed")
  2129. .HasColumnType("bit");
  2130. b.Property<string>("FavoriteName")
  2131. .HasColumnType("nvarchar(max)");
  2132. b.Property<string>("FirstName")
  2133. .IsRequired()
  2134. .HasColumnType("nvarchar(max)");
  2135. b.Property<string>("IdNumber")
  2136. .IsRequired()
  2137. .HasColumnType("nvarchar(max)");
  2138. b.Property<decimal?>("IncomeTaxValue")
  2139. .HasColumnType("decimal(18,2)");
  2140. b.Property<long?>("IndustryId")
  2141. .HasColumnType("bigint");
  2142. b.Property<bool>("IsDeleted")
  2143. .HasColumnType("bit");
  2144. b.Property<bool>("IsStopped")
  2145. .HasColumnType("bit");
  2146. b.Property<long?>("JobTitleId")
  2147. .HasColumnType("bigint");
  2148. b.Property<string>("LastName")
  2149. .IsRequired()
  2150. .HasColumnType("nvarchar(max)");
  2151. b.Property<string>("LinkedInLink")
  2152. .HasColumnType("nvarchar(max)");
  2153. b.Property<bool>("LockoutEnabled")
  2154. .HasColumnType("bit");
  2155. b.Property<DateTimeOffset?>("LockoutEnd")
  2156. .HasColumnType("datetimeoffset");
  2157. b.Property<string>("ManagerId")
  2158. .HasColumnType("nvarchar(450)");
  2159. b.Property<string>("NormalizedEmail")
  2160. .HasMaxLength(256)
  2161. .HasColumnType("nvarchar(256)");
  2162. b.Property<string>("NormalizedUserName")
  2163. .HasMaxLength(256)
  2164. .HasColumnType("nvarchar(256)");
  2165. b.Property<string>("PassportNumber")
  2166. .IsRequired()
  2167. .HasColumnType("nvarchar(max)");
  2168. b.Property<string>("PasswordHash")
  2169. .HasColumnType("nvarchar(max)");
  2170. b.Property<string>("PhoneNumber")
  2171. .HasColumnType("nvarchar(max)");
  2172. b.Property<bool>("PhoneNumberConfirmed")
  2173. .HasColumnType("bit");
  2174. b.Property<long?>("QualificationId")
  2175. .HasColumnType("bigint");
  2176. b.Property<string>("SecurityStamp")
  2177. .HasColumnType("nvarchar(max)");
  2178. b.Property<decimal?>("TaxNumber")
  2179. .HasColumnType("decimal(18,2)");
  2180. b.Property<bool>("TwoFactorEnabled")
  2181. .HasColumnType("bit");
  2182. b.Property<long?>("UniversityId")
  2183. .HasColumnType("bigint");
  2184. b.Property<string>("UpdateUser")
  2185. .HasColumnType("nvarchar(max)");
  2186. b.Property<string>("UserName")
  2187. .HasMaxLength(256)
  2188. .HasColumnType("nvarchar(256)");
  2189. b.Property<int>("UserType")
  2190. .HasColumnType("int");
  2191. b.HasKey("Id");
  2192. b.HasIndex("CountryId");
  2193. b.HasIndex("IndustryId");
  2194. b.HasIndex("JobTitleId");
  2195. b.HasIndex("ManagerId");
  2196. b.HasIndex("NormalizedEmail")
  2197. .HasDatabaseName("EmailIndex");
  2198. b.HasIndex("NormalizedUserName")
  2199. .IsUnique()
  2200. .HasDatabaseName("UserNameIndex")
  2201. .HasFilter("[NormalizedUserName] IS NOT NULL");
  2202. b.HasIndex("QualificationId");
  2203. b.HasIndex("UniversityId");
  2204. b.ToTable("AspNetUsers", (string)null);
  2205. b.HasData(
  2206. new
  2207. {
  2208. Id = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  2209. AccessFailedCount = 0,
  2210. CompanyId = 1L,
  2211. ConcurrencyStamp = "7cc87689-9eab-4280-b8e3-1834080783a5",
  2212. DateOfBirth = new DateTime(2000, 2, 10, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2213. Email = "a@b.com",
  2214. EmailConfirmed = true,
  2215. FirstName = "Zinab",
  2216. IdNumber = "123",
  2217. IncomeTaxValue = 1m,
  2218. IsDeleted = false,
  2219. IsStopped = false,
  2220. LastName = "Elgendy",
  2221. LockoutEnabled = false,
  2222. NormalizedEmail = "A@B.COM",
  2223. NormalizedUserName = "A@B.COM",
  2224. PassportNumber = "1234567",
  2225. PasswordHash = "AQAAAAIAAYagAAAAEPg+ASbciPFxtyxQq8Wx5ilBUQ0RbAoITXXkOQm1PzC5BzySX0sn/wUmOjBKPDGV9w==",
  2226. PhoneNumber = "1234567890",
  2227. PhoneNumberConfirmed = true,
  2228. SecurityStamp = "49bb16c3-4704-4c60-908d-dc8506950acc",
  2229. TaxNumber = 111m,
  2230. TwoFactorEnabled = false,
  2231. UserName = "A@b.com",
  2232. UserType = 1
  2233. },
  2234. new
  2235. {
  2236. Id = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  2237. AccessFailedCount = 0,
  2238. CompanyId = 1L,
  2239. ConcurrencyStamp = "4af7b4cf-802a-455b-b598-997e167745b3",
  2240. DateOfBirth = new DateTime(2001, 5, 13, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2241. Email = "ali@b.com",
  2242. EmailConfirmed = true,
  2243. FirstName = "Ali",
  2244. IdNumber = "343434",
  2245. IncomeTaxValue = 100m,
  2246. IsDeleted = false,
  2247. IsStopped = false,
  2248. LastName = "Farok",
  2249. LockoutEnabled = false,
  2250. NormalizedEmail = "ALI@B.COM",
  2251. NormalizedUserName = "ALI@B.COM",
  2252. PassportNumber = "7654321001010",
  2253. PasswordHash = "AQAAAAIAAYagAAAAEI3QJkcZjCH4Y8Db4rEgL8Mmll5oCvYcWiXZjQSN9bGW4SMcjHe3ZPMnkN/l9DmJeQ==",
  2254. PhoneNumber = "1234567888",
  2255. PhoneNumberConfirmed = true,
  2256. SecurityStamp = "62549056-1b9d-46d4-84f8-adea3e4d8b68",
  2257. TaxNumber = 222m,
  2258. TwoFactorEnabled = false,
  2259. UserName = "Ali@b.com",
  2260. UserType = 1
  2261. });
  2262. });
  2263. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.RolePermission", b =>
  2264. {
  2265. b.Property<long>("Id")
  2266. .ValueGeneratedOnAdd()
  2267. .HasColumnType("bigint")
  2268. .HasColumnOrder(0);
  2269. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  2270. b.Property<long>("PermissionId")
  2271. .HasColumnType("bigint");
  2272. b.Property<string>("PermissionName")
  2273. .IsRequired()
  2274. .HasColumnType("nvarchar(max)");
  2275. b.Property<string>("RoleId")
  2276. .IsRequired()
  2277. .HasColumnType("nvarchar(450)");
  2278. b.HasKey("Id");
  2279. b.HasIndex("PermissionId");
  2280. b.HasIndex("RoleId");
  2281. b.ToTable("RolePermissions");
  2282. });
  2283. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAddress", b =>
  2284. {
  2285. b.Property<long>("Id")
  2286. .ValueGeneratedOnAdd()
  2287. .HasColumnType("bigint")
  2288. .HasColumnOrder(0);
  2289. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  2290. b.Property<string>("AddressDesc")
  2291. .HasColumnType("nvarchar(max)");
  2292. b.Property<long?>("CityId")
  2293. .HasColumnType("bigint");
  2294. b.Property<long?>("CountryId")
  2295. .HasColumnType("bigint");
  2296. b.Property<DateTime>("CreateDate")
  2297. .HasColumnType("datetime2")
  2298. .HasColumnOrder(3);
  2299. b.Property<string>("CreateUser")
  2300. .HasMaxLength(450)
  2301. .HasColumnType("nvarchar(450)")
  2302. .HasColumnOrder(1);
  2303. b.Property<string>("PostalCode")
  2304. .HasColumnType("nvarchar(max)");
  2305. b.Property<DateTime?>("UpdateDate")
  2306. .HasColumnType("datetime2")
  2307. .HasColumnOrder(4);
  2308. b.Property<string>("UpdateUser")
  2309. .HasMaxLength(450)
  2310. .HasColumnType("nvarchar(450)")
  2311. .HasColumnOrder(2);
  2312. b.Property<string>("UserId")
  2313. .IsRequired()
  2314. .HasColumnType("nvarchar(450)");
  2315. b.HasKey("Id");
  2316. b.HasIndex("CityId");
  2317. b.HasIndex("CountryId");
  2318. b.HasIndex("UserId")
  2319. .IsUnique();
  2320. b.ToTable("UserAddress");
  2321. });
  2322. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAttachment", b =>
  2323. {
  2324. b.Property<long>("Id")
  2325. .ValueGeneratedOnAdd()
  2326. .HasColumnType("bigint")
  2327. .HasColumnOrder(0);
  2328. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  2329. b.Property<long>("AttachmentTypeId")
  2330. .HasColumnType("bigint");
  2331. b.Property<byte[]>("Content")
  2332. .IsRequired()
  2333. .HasColumnType("varbinary(max)");
  2334. b.Property<string>("ContentType")
  2335. .HasColumnType("nvarchar(max)");
  2336. b.Property<DateTime>("CreateDate")
  2337. .HasColumnType("datetime2")
  2338. .HasColumnOrder(3);
  2339. b.Property<string>("CreateUser")
  2340. .HasMaxLength(450)
  2341. .HasColumnType("nvarchar(450)")
  2342. .HasColumnOrder(1);
  2343. b.Property<string>("FileName")
  2344. .IsRequired()
  2345. .HasMaxLength(250)
  2346. .HasColumnType("nvarchar(250)");
  2347. b.Property<string>("FilePath")
  2348. .HasColumnType("nvarchar(max)");
  2349. b.Property<string>("OriginalName")
  2350. .IsRequired()
  2351. .HasMaxLength(250)
  2352. .HasColumnType("nvarchar(250)");
  2353. b.Property<DateTime?>("UpdateDate")
  2354. .HasColumnType("datetime2")
  2355. .HasColumnOrder(4);
  2356. b.Property<string>("UpdateUser")
  2357. .HasMaxLength(450)
  2358. .HasColumnType("nvarchar(450)")
  2359. .HasColumnOrder(2);
  2360. b.Property<string>("UserId")
  2361. .IsRequired()
  2362. .HasColumnType("nvarchar(450)");
  2363. b.HasKey("Id");
  2364. b.HasIndex("AttachmentTypeId");
  2365. b.HasIndex("UserId");
  2366. b.ToTable("UserAttachments");
  2367. });
  2368. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  2369. {
  2370. b.Property<int>("Id")
  2371. .ValueGeneratedOnAdd()
  2372. .HasColumnType("int");
  2373. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  2374. b.Property<string>("ClaimType")
  2375. .HasColumnType("nvarchar(max)");
  2376. b.Property<string>("ClaimValue")
  2377. .HasColumnType("nvarchar(max)");
  2378. b.Property<string>("RoleId")
  2379. .IsRequired()
  2380. .HasColumnType("nvarchar(450)");
  2381. b.HasKey("Id");
  2382. b.HasIndex("RoleId");
  2383. b.ToTable("AspNetRoleClaims", (string)null);
  2384. });
  2385. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  2386. {
  2387. b.Property<int>("Id")
  2388. .ValueGeneratedOnAdd()
  2389. .HasColumnType("int");
  2390. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  2391. b.Property<string>("ClaimType")
  2392. .HasColumnType("nvarchar(max)");
  2393. b.Property<string>("ClaimValue")
  2394. .HasColumnType("nvarchar(max)");
  2395. b.Property<string>("UserId")
  2396. .IsRequired()
  2397. .HasColumnType("nvarchar(450)");
  2398. b.HasKey("Id");
  2399. b.HasIndex("UserId");
  2400. b.ToTable("AspNetUserClaims", (string)null);
  2401. });
  2402. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  2403. {
  2404. b.Property<string>("LoginProvider")
  2405. .HasColumnType("nvarchar(450)");
  2406. b.Property<string>("ProviderKey")
  2407. .HasColumnType("nvarchar(450)");
  2408. b.Property<string>("ProviderDisplayName")
  2409. .HasColumnType("nvarchar(max)");
  2410. b.Property<string>("UserId")
  2411. .IsRequired()
  2412. .HasColumnType("nvarchar(450)");
  2413. b.HasKey("LoginProvider", "ProviderKey");
  2414. b.HasIndex("UserId");
  2415. b.ToTable("AspNetUserLogins", (string)null);
  2416. });
  2417. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  2418. {
  2419. b.Property<string>("UserId")
  2420. .HasColumnType("nvarchar(450)");
  2421. b.Property<string>("RoleId")
  2422. .HasColumnType("nvarchar(450)");
  2423. b.HasKey("UserId", "RoleId");
  2424. b.HasIndex("RoleId");
  2425. b.ToTable("AspNetUserRoles", (string)null);
  2426. b.HasData(
  2427. new
  2428. {
  2429. UserId = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  2430. RoleId = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A"
  2431. },
  2432. new
  2433. {
  2434. UserId = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  2435. RoleId = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E"
  2436. });
  2437. });
  2438. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  2439. {
  2440. b.Property<string>("UserId")
  2441. .HasColumnType("nvarchar(450)");
  2442. b.Property<string>("LoginProvider")
  2443. .HasColumnType("nvarchar(450)");
  2444. b.Property<string>("Name")
  2445. .HasColumnType("nvarchar(450)");
  2446. b.Property<string>("Value")
  2447. .HasColumnType("nvarchar(max)");
  2448. b.HasKey("UserId", "LoginProvider", "Name");
  2449. b.ToTable("AspNetUserTokens", (string)null);
  2450. });
  2451. modelBuilder.Entity("ApplicationRoleApplicationUser", b =>
  2452. {
  2453. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  2454. .WithMany()
  2455. .HasForeignKey("UserRolesId")
  2456. .OnDelete(DeleteBehavior.Cascade)
  2457. .IsRequired();
  2458. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2459. .WithMany()
  2460. .HasForeignKey("UsersId")
  2461. .OnDelete(DeleteBehavior.Cascade)
  2462. .IsRequired();
  2463. });
  2464. modelBuilder.Entity("MTWorkHR.Core.Entities.City", b =>
  2465. {
  2466. b.HasOne("MTWorkHR.Core.Entities.CountryLookup", "Country")
  2467. .WithMany()
  2468. .HasForeignKey("CountryId")
  2469. .OnDelete(DeleteBehavior.Cascade)
  2470. .IsRequired();
  2471. b.Navigation("Country");
  2472. });
  2473. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingUser", b =>
  2474. {
  2475. b.HasOne("MTWorkHR.Core.Entities.Meeting", "Meeting")
  2476. .WithMany("MeetingUsers")
  2477. .HasForeignKey("MeetingId")
  2478. .OnDelete(DeleteBehavior.Cascade)
  2479. .IsRequired();
  2480. b.Navigation("Meeting");
  2481. });
  2482. modelBuilder.Entity("MTWorkHR.Core.Entities.OrderAllocation", b =>
  2483. {
  2484. b.HasOne("MTWorkHR.Core.Entities.LeaveType", "LeaveType")
  2485. .WithMany()
  2486. .HasForeignKey("LeaveTypeId");
  2487. b.HasOne("MTWorkHR.Core.Entities.OrderType", "OrderType")
  2488. .WithMany()
  2489. .HasForeignKey("OrderTypeId")
  2490. .OnDelete(DeleteBehavior.Cascade)
  2491. .IsRequired();
  2492. b.Navigation("LeaveType");
  2493. b.Navigation("OrderType");
  2494. });
  2495. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamUser", b =>
  2496. {
  2497. b.HasOne("MTWorkHR.Core.Entities.Team", "Team")
  2498. .WithMany("TeamUsers")
  2499. .HasForeignKey("TeamId")
  2500. .OnDelete(DeleteBehavior.Cascade)
  2501. .IsRequired();
  2502. b.Navigation("Team");
  2503. });
  2504. modelBuilder.Entity("MTWorkHR.Core.Entities.User.OrderRequest", b =>
  2505. {
  2506. b.HasOne("MTWorkHR.Core.Entities.LeaveType", "LeaveType")
  2507. .WithMany()
  2508. .HasForeignKey("LeaveTypeId");
  2509. b.HasOne("MTWorkHR.Core.Entities.OrderType", "OrderType")
  2510. .WithMany()
  2511. .HasForeignKey("OrderTypeId")
  2512. .OnDelete(DeleteBehavior.Cascade)
  2513. .IsRequired();
  2514. b.Navigation("LeaveType");
  2515. b.Navigation("OrderType");
  2516. });
  2517. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  2518. {
  2519. b.HasOne("MTWorkHR.Core.Entities.Project", "Project")
  2520. .WithMany()
  2521. .HasForeignKey("ProjectId")
  2522. .OnDelete(DeleteBehavior.Cascade)
  2523. .IsRequired();
  2524. b.HasOne("MTWorkHR.Core.Entities.UserTaskStatus", "TaskStatus")
  2525. .WithMany()
  2526. .HasForeignKey("StatusId")
  2527. .OnDelete(DeleteBehavior.Cascade)
  2528. .IsRequired();
  2529. b.Navigation("Project");
  2530. b.Navigation("TaskStatus");
  2531. });
  2532. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskAttachment", b =>
  2533. {
  2534. b.HasOne("MTWorkHR.Core.Entities.Base.AttachmentType", "AttachmentType")
  2535. .WithMany()
  2536. .HasForeignKey("AttachmentTypeId");
  2537. b.HasOne("MTWorkHR.Core.Entities.UserTask", "UserTask")
  2538. .WithMany("TaskAttachments")
  2539. .HasForeignKey("TaskId")
  2540. .OnDelete(DeleteBehavior.Cascade)
  2541. .IsRequired();
  2542. b.Navigation("AttachmentType");
  2543. b.Navigation("UserTask");
  2544. });
  2545. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskHistory", b =>
  2546. {
  2547. b.HasOne("MTWorkHR.Core.Entities.UserTaskStatus", "TaskStatus")
  2548. .WithMany()
  2549. .HasForeignKey("CurrentStatusId")
  2550. .OnDelete(DeleteBehavior.Cascade)
  2551. .IsRequired();
  2552. b.HasOne("MTWorkHR.Core.Entities.UserTask", null)
  2553. .WithMany("UserTaskHistories")
  2554. .HasForeignKey("UserTaskId");
  2555. b.Navigation("TaskStatus");
  2556. });
  2557. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  2558. {
  2559. b.HasOne("MTWorkHR.Core.Entities.CountryLookup", "Country")
  2560. .WithMany()
  2561. .HasForeignKey("CountryId");
  2562. b.HasOne("MTWorkHR.Core.Entities.Industry", "Industry")
  2563. .WithMany()
  2564. .HasForeignKey("IndustryId");
  2565. b.HasOne("MTWorkHR.Core.Entities.JobTitle", "JobTitle")
  2566. .WithMany()
  2567. .HasForeignKey("JobTitleId");
  2568. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "Manager")
  2569. .WithMany()
  2570. .HasForeignKey("ManagerId");
  2571. b.HasOne("MTWorkHR.Core.Entities.Qualification", "Qualification")
  2572. .WithMany()
  2573. .HasForeignKey("QualificationId");
  2574. b.HasOne("MTWorkHR.Core.Entities.University", "University")
  2575. .WithMany()
  2576. .HasForeignKey("UniversityId");
  2577. b.Navigation("Country");
  2578. b.Navigation("Industry");
  2579. b.Navigation("JobTitle");
  2580. b.Navigation("Manager");
  2581. b.Navigation("Qualification");
  2582. b.Navigation("University");
  2583. });
  2584. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.RolePermission", b =>
  2585. {
  2586. b.HasOne("MTWorkHR.Core.Entities.Permission", "Permission")
  2587. .WithMany()
  2588. .HasForeignKey("PermissionId")
  2589. .OnDelete(DeleteBehavior.Cascade)
  2590. .IsRequired();
  2591. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", "Role")
  2592. .WithMany("RolePermissions")
  2593. .HasForeignKey("RoleId")
  2594. .OnDelete(DeleteBehavior.Cascade)
  2595. .IsRequired();
  2596. b.Navigation("Permission");
  2597. b.Navigation("Role");
  2598. });
  2599. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAddress", b =>
  2600. {
  2601. b.HasOne("MTWorkHR.Core.Entities.City", "City")
  2602. .WithMany()
  2603. .HasForeignKey("CityId");
  2604. b.HasOne("MTWorkHR.Core.Entities.CountryLookup", "Country")
  2605. .WithMany()
  2606. .HasForeignKey("CountryId");
  2607. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "User")
  2608. .WithOne("UserAddress")
  2609. .HasForeignKey("MTWorkHR.Infrastructure.Entities.UserAddress", "UserId")
  2610. .OnDelete(DeleteBehavior.Cascade)
  2611. .IsRequired();
  2612. b.Navigation("City");
  2613. b.Navigation("Country");
  2614. b.Navigation("User");
  2615. });
  2616. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAttachment", b =>
  2617. {
  2618. b.HasOne("MTWorkHR.Core.Entities.Base.AttachmentType", "AttachmentType")
  2619. .WithMany()
  2620. .HasForeignKey("AttachmentTypeId")
  2621. .OnDelete(DeleteBehavior.Cascade)
  2622. .IsRequired();
  2623. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "User")
  2624. .WithMany("UserAttachments")
  2625. .HasForeignKey("UserId")
  2626. .OnDelete(DeleteBehavior.Cascade)
  2627. .IsRequired();
  2628. b.Navigation("AttachmentType");
  2629. b.Navigation("User");
  2630. });
  2631. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  2632. {
  2633. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  2634. .WithMany()
  2635. .HasForeignKey("RoleId")
  2636. .OnDelete(DeleteBehavior.Cascade)
  2637. .IsRequired();
  2638. });
  2639. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  2640. {
  2641. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2642. .WithMany()
  2643. .HasForeignKey("UserId")
  2644. .OnDelete(DeleteBehavior.Cascade)
  2645. .IsRequired();
  2646. });
  2647. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  2648. {
  2649. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2650. .WithMany()
  2651. .HasForeignKey("UserId")
  2652. .OnDelete(DeleteBehavior.Cascade)
  2653. .IsRequired();
  2654. });
  2655. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  2656. {
  2657. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  2658. .WithMany()
  2659. .HasForeignKey("RoleId")
  2660. .OnDelete(DeleteBehavior.Cascade)
  2661. .IsRequired();
  2662. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2663. .WithMany()
  2664. .HasForeignKey("UserId")
  2665. .OnDelete(DeleteBehavior.Cascade)
  2666. .IsRequired();
  2667. });
  2668. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  2669. {
  2670. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2671. .WithMany()
  2672. .HasForeignKey("UserId")
  2673. .OnDelete(DeleteBehavior.Cascade)
  2674. .IsRequired();
  2675. });
  2676. modelBuilder.Entity("MTWorkHR.Core.Entities.Meeting", b =>
  2677. {
  2678. b.Navigation("MeetingUsers");
  2679. });
  2680. modelBuilder.Entity("MTWorkHR.Core.Entities.Team", b =>
  2681. {
  2682. b.Navigation("TeamUsers");
  2683. });
  2684. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  2685. {
  2686. b.Navigation("TaskAttachments");
  2687. b.Navigation("UserTaskHistories");
  2688. });
  2689. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationRole", b =>
  2690. {
  2691. b.Navigation("RolePermissions");
  2692. });
  2693. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  2694. {
  2695. b.Navigation("UserAddress")
  2696. .IsRequired();
  2697. b.Navigation("UserAttachments");
  2698. });
  2699. #pragma warning restore 612, 618
  2700. }
  2701. }
  2702. }