HRDataContextModelSnapshot.cs 122 KB

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