HRDataContextModelSnapshot.cs 123 KB

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