HRDataContextModelSnapshot.cs 151 KB

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