HRDataContextModelSnapshot.cs 123 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357
  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<string>("EndTime")
  961. .IsRequired()
  962. .HasColumnType("nvarchar(max)");
  963. b.Property<bool>("IsDeleted")
  964. .HasColumnType("bit")
  965. .HasColumnOrder(7);
  966. b.Property<string>("Location")
  967. .HasMaxLength(250)
  968. .HasColumnType("nvarchar(250)");
  969. b.Property<DateTime>("MeetingDate")
  970. .HasColumnType("datetime2");
  971. b.Property<string>("MeetingLink")
  972. .HasMaxLength(250)
  973. .HasColumnType("nvarchar(250)");
  974. b.Property<int>("RepeatId")
  975. .HasColumnType("int");
  976. b.Property<string>("StartTime")
  977. .IsRequired()
  978. .HasColumnType("nvarchar(max)");
  979. b.Property<string>("Title")
  980. .IsRequired()
  981. .HasMaxLength(250)
  982. .HasColumnType("nvarchar(250)");
  983. b.Property<DateTime?>("UpdateDate")
  984. .HasColumnType("datetime2")
  985. .HasColumnOrder(4);
  986. b.Property<string>("UpdateUser")
  987. .HasMaxLength(450)
  988. .HasColumnType("nvarchar(450)")
  989. .HasColumnOrder(2);
  990. b.HasKey("Id");
  991. b.HasIndex("CompanyId");
  992. b.ToTable("Meetings");
  993. });
  994. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingLog", b =>
  995. {
  996. b.Property<long>("Id")
  997. .ValueGeneratedOnAdd()
  998. .HasColumnType("bigint")
  999. .HasColumnOrder(0);
  1000. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1001. b.Property<string>("Channel")
  1002. .HasColumnType("nvarchar(max)");
  1003. b.Property<DateTime>("CreateDate")
  1004. .HasColumnType("datetime2");
  1005. b.Property<string>("CreateUser")
  1006. .IsRequired()
  1007. .HasColumnType("nvarchar(max)");
  1008. b.Property<string>("ErrorCode")
  1009. .IsRequired()
  1010. .HasColumnType("nvarchar(max)");
  1011. b.Property<string>("ErrorDescription")
  1012. .IsRequired()
  1013. .HasColumnType("nvarchar(max)");
  1014. b.Property<string>("InnerException")
  1015. .HasColumnType("nvarchar(max)");
  1016. b.Property<string>("Input")
  1017. .HasColumnType("nvarchar(max)");
  1018. b.Property<string>("Method")
  1019. .IsRequired()
  1020. .HasColumnType("nvarchar(max)");
  1021. b.Property<string>("QueryString")
  1022. .HasColumnType("nvarchar(max)");
  1023. b.Property<string>("ServerIP")
  1024. .HasColumnType("nvarchar(max)");
  1025. b.Property<string>("ServiceResponseTimeInSeconds")
  1026. .IsRequired()
  1027. .HasColumnType("nvarchar(max)");
  1028. b.Property<string>("UserIP")
  1029. .HasColumnType("nvarchar(max)");
  1030. b.Property<string>("userAgent")
  1031. .HasColumnType("nvarchar(max)");
  1032. b.HasKey("Id");
  1033. b.ToTable("MeetingLogs");
  1034. });
  1035. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingUser", b =>
  1036. {
  1037. b.Property<long>("Id")
  1038. .ValueGeneratedOnAdd()
  1039. .HasColumnType("bigint")
  1040. .HasColumnOrder(0);
  1041. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1042. b.Property<string>("AssignedUserId")
  1043. .IsRequired()
  1044. .HasColumnType("nvarchar(max)");
  1045. b.Property<string>("AssignedUserName")
  1046. .IsRequired()
  1047. .HasColumnType("nvarchar(max)");
  1048. b.Property<DateTime>("CreateDate")
  1049. .HasColumnType("datetime2")
  1050. .HasColumnOrder(3);
  1051. b.Property<string>("CreateUser")
  1052. .HasMaxLength(450)
  1053. .HasColumnType("nvarchar(450)")
  1054. .HasColumnOrder(1);
  1055. b.Property<long>("MeetingId")
  1056. .HasColumnType("bigint");
  1057. b.Property<DateTime?>("UpdateDate")
  1058. .HasColumnType("datetime2")
  1059. .HasColumnOrder(4);
  1060. b.Property<string>("UpdateUser")
  1061. .HasMaxLength(450)
  1062. .HasColumnType("nvarchar(450)")
  1063. .HasColumnOrder(2);
  1064. b.HasKey("Id");
  1065. b.HasIndex("MeetingId");
  1066. b.ToTable("MeetingUser");
  1067. });
  1068. modelBuilder.Entity("MTWorkHR.Core.Entities.OrderAllocation", b =>
  1069. {
  1070. b.Property<long>("Id")
  1071. .ValueGeneratedOnAdd()
  1072. .HasColumnType("bigint")
  1073. .HasColumnOrder(0);
  1074. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1075. b.Property<long>("CompanyId")
  1076. .HasColumnType("bigint");
  1077. b.Property<DateTime>("CreateDate")
  1078. .HasColumnType("datetime2")
  1079. .HasColumnOrder(3);
  1080. b.Property<string>("CreateUser")
  1081. .HasMaxLength(450)
  1082. .HasColumnType("nvarchar(450)")
  1083. .HasColumnOrder(1);
  1084. b.Property<string>("EmployeeId")
  1085. .IsRequired()
  1086. .HasColumnType("nvarchar(max)");
  1087. b.Property<long?>("LeaveTypeId")
  1088. .HasColumnType("bigint");
  1089. b.Property<int>("NumberOfDays")
  1090. .HasColumnType("int");
  1091. b.Property<long>("OrderTypeId")
  1092. .HasColumnType("bigint");
  1093. b.Property<int>("Period")
  1094. .HasColumnType("int");
  1095. b.Property<DateTime?>("UpdateDate")
  1096. .HasColumnType("datetime2")
  1097. .HasColumnOrder(4);
  1098. b.Property<string>("UpdateUser")
  1099. .HasMaxLength(450)
  1100. .HasColumnType("nvarchar(450)")
  1101. .HasColumnOrder(2);
  1102. b.HasKey("Id");
  1103. b.HasIndex("CompanyId");
  1104. b.HasIndex("LeaveTypeId");
  1105. b.HasIndex("OrderTypeId");
  1106. b.ToTable("OrderAllocations");
  1107. });
  1108. modelBuilder.Entity("MTWorkHR.Core.Entities.OrderType", b =>
  1109. {
  1110. b.Property<long>("Id")
  1111. .ValueGeneratedOnAdd()
  1112. .HasColumnType("bigint")
  1113. .HasColumnOrder(0);
  1114. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1115. b.Property<int>("DefaultDays")
  1116. .HasColumnType("int");
  1117. b.Property<string>("NameAr")
  1118. .IsRequired()
  1119. .HasColumnType("nvarchar(max)");
  1120. b.Property<string>("NameEn")
  1121. .IsRequired()
  1122. .HasColumnType("nvarchar(max)");
  1123. b.HasKey("Id");
  1124. b.ToTable("OrderTypes");
  1125. b.HasData(
  1126. new
  1127. {
  1128. Id = 1L,
  1129. DefaultDays = 2,
  1130. NameAr = "إذن",
  1131. NameEn = "Leave"
  1132. },
  1133. new
  1134. {
  1135. Id = 2L,
  1136. DefaultDays = 15,
  1137. NameAr = "طبية",
  1138. NameEn = "Medical"
  1139. },
  1140. new
  1141. {
  1142. Id = 3L,
  1143. DefaultDays = 20,
  1144. NameAr = "وقت إضافي",
  1145. NameEn = "Overtime"
  1146. },
  1147. new
  1148. {
  1149. Id = 4L,
  1150. DefaultDays = 0,
  1151. NameAr = "رحلة عمل",
  1152. NameEn = "Business trip"
  1153. },
  1154. new
  1155. {
  1156. Id = 5L,
  1157. DefaultDays = 0,
  1158. NameAr = "دورة تدريبية",
  1159. NameEn = "Course"
  1160. });
  1161. });
  1162. modelBuilder.Entity("MTWorkHR.Core.Entities.Permission", b =>
  1163. {
  1164. b.Property<long>("Id")
  1165. .ValueGeneratedOnAdd()
  1166. .HasColumnType("bigint")
  1167. .HasColumnOrder(0);
  1168. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1169. b.Property<string>("CategoryName")
  1170. .IsRequired()
  1171. .HasMaxLength(150)
  1172. .HasColumnType("nvarchar(150)");
  1173. b.Property<string>("Desc")
  1174. .IsRequired()
  1175. .HasMaxLength(250)
  1176. .HasColumnType("nvarchar(250)");
  1177. b.Property<string>("Name")
  1178. .IsRequired()
  1179. .HasMaxLength(250)
  1180. .HasColumnType("nvarchar(250)");
  1181. b.Property<bool>("Show")
  1182. .HasColumnType("bit");
  1183. b.HasKey("Id");
  1184. b.ToTable("Permissions");
  1185. b.HasData(
  1186. new
  1187. {
  1188. Id = 1L,
  1189. CategoryName = "User",
  1190. Desc = "Project",
  1191. Name = "Project",
  1192. Show = true
  1193. },
  1194. new
  1195. {
  1196. Id = 2L,
  1197. CategoryName = "User",
  1198. Desc = "Project.Create",
  1199. Name = "Project.Create",
  1200. Show = false
  1201. },
  1202. new
  1203. {
  1204. Id = 3L,
  1205. CategoryName = "User",
  1206. Desc = "Project.Update",
  1207. Name = "Project.Update",
  1208. Show = false
  1209. },
  1210. new
  1211. {
  1212. Id = 4L,
  1213. CategoryName = "User",
  1214. Desc = "Project.Delete",
  1215. Name = "Project.Delete",
  1216. Show = false
  1217. },
  1218. new
  1219. {
  1220. Id = 5L,
  1221. CategoryName = "User",
  1222. Desc = "Meeting",
  1223. Name = "Meeting",
  1224. Show = true
  1225. },
  1226. new
  1227. {
  1228. Id = 6L,
  1229. CategoryName = "User",
  1230. Desc = "Meeting.Create",
  1231. Name = "Meeting.Create",
  1232. Show = false
  1233. },
  1234. new
  1235. {
  1236. Id = 7L,
  1237. CategoryName = "User",
  1238. Desc = "Meeting.Update",
  1239. Name = "Meeting.Update",
  1240. Show = false
  1241. },
  1242. new
  1243. {
  1244. Id = 8L,
  1245. CategoryName = "User",
  1246. Desc = "Meeting.Delete",
  1247. Name = "Meeting.Delete",
  1248. Show = false
  1249. },
  1250. new
  1251. {
  1252. Id = 9L,
  1253. CategoryName = "User",
  1254. Desc = "Team",
  1255. Name = "Team",
  1256. Show = true
  1257. },
  1258. new
  1259. {
  1260. Id = 10L,
  1261. CategoryName = "User",
  1262. Desc = "Team.Create",
  1263. Name = "Team.Create",
  1264. Show = false
  1265. },
  1266. new
  1267. {
  1268. Id = 11L,
  1269. CategoryName = "User",
  1270. Desc = "Team.Update",
  1271. Name = "Team.Update",
  1272. Show = false
  1273. },
  1274. new
  1275. {
  1276. Id = 12L,
  1277. CategoryName = "User",
  1278. Desc = "Team.Delete",
  1279. Name = "Team.Delete",
  1280. Show = false
  1281. },
  1282. new
  1283. {
  1284. Id = 13L,
  1285. CategoryName = "Sales",
  1286. Desc = "UserTask",
  1287. Name = "UserTask",
  1288. Show = true
  1289. },
  1290. new
  1291. {
  1292. Id = 14L,
  1293. CategoryName = "Sales",
  1294. Desc = "UserTask.Create",
  1295. Name = "UserTask.Create",
  1296. Show = false
  1297. },
  1298. new
  1299. {
  1300. Id = 15L,
  1301. CategoryName = "Sales",
  1302. Desc = "UserTask.Update",
  1303. Name = "UserTask.Update",
  1304. Show = false
  1305. },
  1306. new
  1307. {
  1308. Id = 16L,
  1309. CategoryName = "User",
  1310. Desc = "UserTask.Delete",
  1311. Name = "UserTask.Delete",
  1312. Show = false
  1313. },
  1314. new
  1315. {
  1316. Id = 17L,
  1317. CategoryName = "User",
  1318. Desc = "Company",
  1319. Name = "Company",
  1320. Show = true
  1321. },
  1322. new
  1323. {
  1324. Id = 18L,
  1325. CategoryName = "User",
  1326. Desc = "Company.Create",
  1327. Name = "Company.Create",
  1328. Show = false
  1329. },
  1330. new
  1331. {
  1332. Id = 19L,
  1333. CategoryName = "User",
  1334. Desc = "Company.Update",
  1335. Name = "Company.Update",
  1336. Show = false
  1337. },
  1338. new
  1339. {
  1340. Id = 20L,
  1341. CategoryName = "User",
  1342. Desc = "Company.Delete",
  1343. Name = "Company.Delete",
  1344. Show = false
  1345. },
  1346. new
  1347. {
  1348. Id = 21L,
  1349. CategoryName = "Adminstration",
  1350. Desc = "User",
  1351. Name = "User",
  1352. Show = true
  1353. },
  1354. new
  1355. {
  1356. Id = 22L,
  1357. CategoryName = "Adminstration",
  1358. Desc = "User.Create",
  1359. Name = "User.Create",
  1360. Show = false
  1361. },
  1362. new
  1363. {
  1364. Id = 23L,
  1365. CategoryName = "Adminstration",
  1366. Desc = "User.Update",
  1367. Name = "User.Update",
  1368. Show = false
  1369. },
  1370. new
  1371. {
  1372. Id = 24L,
  1373. CategoryName = "Adminstration",
  1374. Desc = "User.Delete",
  1375. Name = "User.Delete",
  1376. Show = false
  1377. },
  1378. new
  1379. {
  1380. Id = 25L,
  1381. CategoryName = "Adminstration",
  1382. Desc = "Role",
  1383. Name = "Role",
  1384. Show = true
  1385. },
  1386. new
  1387. {
  1388. Id = 26L,
  1389. CategoryName = "Adminstration",
  1390. Desc = "Role.Create",
  1391. Name = "Role.Create",
  1392. Show = false
  1393. },
  1394. new
  1395. {
  1396. Id = 27L,
  1397. CategoryName = "Adminstration",
  1398. Desc = "Role.Update",
  1399. Name = "Role.Update",
  1400. Show = false
  1401. },
  1402. new
  1403. {
  1404. Id = 28L,
  1405. CategoryName = "Adminstration",
  1406. Desc = "Role.Delete",
  1407. Name = "Role.Delete",
  1408. Show = false
  1409. });
  1410. });
  1411. modelBuilder.Entity("MTWorkHR.Core.Entities.Project", b =>
  1412. {
  1413. b.Property<long>("Id")
  1414. .ValueGeneratedOnAdd()
  1415. .HasColumnType("bigint")
  1416. .HasColumnOrder(0);
  1417. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1418. b.Property<long>("CompanyId")
  1419. .HasColumnType("bigint");
  1420. b.Property<DateTime>("CreateDate")
  1421. .HasColumnType("datetime2")
  1422. .HasColumnOrder(3);
  1423. b.Property<string>("CreateUser")
  1424. .HasMaxLength(450)
  1425. .HasColumnType("nvarchar(450)")
  1426. .HasColumnOrder(1);
  1427. b.Property<string>("DeleteUserId")
  1428. .HasMaxLength(450)
  1429. .HasColumnType("nvarchar(450)")
  1430. .HasColumnOrder(8);
  1431. b.Property<bool>("IsDeleted")
  1432. .HasColumnType("bit")
  1433. .HasColumnOrder(7);
  1434. b.Property<string>("NameAr")
  1435. .IsRequired()
  1436. .HasMaxLength(250)
  1437. .HasColumnType("nvarchar(250)");
  1438. b.Property<string>("NameEn")
  1439. .IsRequired()
  1440. .HasMaxLength(250)
  1441. .HasColumnType("nvarchar(250)");
  1442. b.Property<DateTime?>("UpdateDate")
  1443. .HasColumnType("datetime2")
  1444. .HasColumnOrder(4);
  1445. b.Property<string>("UpdateUser")
  1446. .HasMaxLength(450)
  1447. .HasColumnType("nvarchar(450)")
  1448. .HasColumnOrder(2);
  1449. b.HasKey("Id");
  1450. b.HasIndex("CompanyId");
  1451. b.ToTable("Projects");
  1452. });
  1453. modelBuilder.Entity("MTWorkHR.Core.Entities.Qualification", b =>
  1454. {
  1455. b.Property<long>("Id")
  1456. .ValueGeneratedOnAdd()
  1457. .HasColumnType("bigint")
  1458. .HasColumnOrder(0);
  1459. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1460. b.Property<string>("NameAr")
  1461. .IsRequired()
  1462. .HasMaxLength(250)
  1463. .HasColumnType("nvarchar(250)");
  1464. b.Property<string>("NameEn")
  1465. .IsRequired()
  1466. .HasMaxLength(250)
  1467. .HasColumnType("nvarchar(250)");
  1468. b.HasKey("Id");
  1469. b.ToTable("Qualifications");
  1470. b.HasData(
  1471. new
  1472. {
  1473. Id = 1L,
  1474. NameAr = "بكالوريوس",
  1475. NameEn = "BSC"
  1476. },
  1477. new
  1478. {
  1479. Id = 2L,
  1480. NameAr = "درجة الماجيستير",
  1481. NameEn = "Master"
  1482. },
  1483. new
  1484. {
  1485. Id = 3L,
  1486. NameAr = "درحة الدكتوراه",
  1487. NameEn = "Doctor"
  1488. });
  1489. });
  1490. modelBuilder.Entity("MTWorkHR.Core.Entities.RoleLog", b =>
  1491. {
  1492. b.Property<long>("Id")
  1493. .ValueGeneratedOnAdd()
  1494. .HasColumnType("bigint")
  1495. .HasColumnOrder(0);
  1496. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1497. b.Property<string>("Channel")
  1498. .HasColumnType("nvarchar(max)");
  1499. b.Property<DateTime>("CreateDate")
  1500. .HasColumnType("datetime2");
  1501. b.Property<string>("CreateUser")
  1502. .IsRequired()
  1503. .HasColumnType("nvarchar(max)");
  1504. b.Property<string>("ErrorCode")
  1505. .IsRequired()
  1506. .HasColumnType("nvarchar(max)");
  1507. b.Property<string>("ErrorDescription")
  1508. .IsRequired()
  1509. .HasColumnType("nvarchar(max)");
  1510. b.Property<string>("InnerException")
  1511. .HasColumnType("nvarchar(max)");
  1512. b.Property<string>("Input")
  1513. .HasColumnType("nvarchar(max)");
  1514. b.Property<string>("Method")
  1515. .IsRequired()
  1516. .HasColumnType("nvarchar(max)");
  1517. b.Property<string>("QueryString")
  1518. .HasColumnType("nvarchar(max)");
  1519. b.Property<string>("ServerIP")
  1520. .HasColumnType("nvarchar(max)");
  1521. b.Property<string>("ServiceResponseTimeInSeconds")
  1522. .IsRequired()
  1523. .HasColumnType("nvarchar(max)");
  1524. b.Property<string>("UserIP")
  1525. .HasColumnType("nvarchar(max)");
  1526. b.Property<string>("userAgent")
  1527. .HasColumnType("nvarchar(max)");
  1528. b.HasKey("Id");
  1529. b.ToTable("RoleLogs");
  1530. });
  1531. modelBuilder.Entity("MTWorkHR.Core.Entities.SettingLog", b =>
  1532. {
  1533. b.Property<long>("Id")
  1534. .ValueGeneratedOnAdd()
  1535. .HasColumnType("bigint")
  1536. .HasColumnOrder(0);
  1537. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1538. b.Property<string>("Channel")
  1539. .HasColumnType("nvarchar(max)");
  1540. b.Property<DateTime>("CreateDate")
  1541. .HasColumnType("datetime2");
  1542. b.Property<string>("CreateUser")
  1543. .IsRequired()
  1544. .HasColumnType("nvarchar(max)");
  1545. b.Property<string>("ErrorCode")
  1546. .IsRequired()
  1547. .HasColumnType("nvarchar(max)");
  1548. b.Property<string>("ErrorDescription")
  1549. .IsRequired()
  1550. .HasColumnType("nvarchar(max)");
  1551. b.Property<string>("InnerException")
  1552. .HasColumnType("nvarchar(max)");
  1553. b.Property<string>("Input")
  1554. .HasColumnType("nvarchar(max)");
  1555. b.Property<string>("Method")
  1556. .IsRequired()
  1557. .HasColumnType("nvarchar(max)");
  1558. b.Property<string>("QueryString")
  1559. .HasColumnType("nvarchar(max)");
  1560. b.Property<string>("ServerIP")
  1561. .HasColumnType("nvarchar(max)");
  1562. b.Property<string>("ServiceResponseTimeInSeconds")
  1563. .IsRequired()
  1564. .HasColumnType("nvarchar(max)");
  1565. b.Property<string>("UserIP")
  1566. .HasColumnType("nvarchar(max)");
  1567. b.Property<string>("userAgent")
  1568. .HasColumnType("nvarchar(max)");
  1569. b.HasKey("Id");
  1570. b.ToTable("SettingLogs");
  1571. });
  1572. modelBuilder.Entity("MTWorkHR.Core.Entities.Team", b =>
  1573. {
  1574. b.Property<long>("Id")
  1575. .ValueGeneratedOnAdd()
  1576. .HasColumnType("bigint")
  1577. .HasColumnOrder(0);
  1578. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1579. b.Property<long>("CompanyId")
  1580. .HasColumnType("bigint");
  1581. b.Property<DateTime>("CreateDate")
  1582. .HasColumnType("datetime2")
  1583. .HasColumnOrder(3);
  1584. b.Property<string>("CreateUser")
  1585. .HasMaxLength(450)
  1586. .HasColumnType("nvarchar(450)")
  1587. .HasColumnOrder(1);
  1588. b.Property<string>("DeleteUserId")
  1589. .HasMaxLength(450)
  1590. .HasColumnType("nvarchar(450)")
  1591. .HasColumnOrder(8);
  1592. b.Property<bool>("IsDeleted")
  1593. .HasColumnType("bit")
  1594. .HasColumnOrder(7);
  1595. b.Property<string>("NameAr")
  1596. .IsRequired()
  1597. .HasMaxLength(250)
  1598. .HasColumnType("nvarchar(250)");
  1599. b.Property<string>("NameEn")
  1600. .IsRequired()
  1601. .HasMaxLength(250)
  1602. .HasColumnType("nvarchar(250)");
  1603. b.Property<DateTime?>("UpdateDate")
  1604. .HasColumnType("datetime2")
  1605. .HasColumnOrder(4);
  1606. b.Property<string>("UpdateUser")
  1607. .HasMaxLength(450)
  1608. .HasColumnType("nvarchar(450)")
  1609. .HasColumnOrder(2);
  1610. b.HasKey("Id");
  1611. b.HasIndex("CompanyId");
  1612. b.ToTable("Teams");
  1613. });
  1614. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamLog", b =>
  1615. {
  1616. b.Property<long>("Id")
  1617. .ValueGeneratedOnAdd()
  1618. .HasColumnType("bigint")
  1619. .HasColumnOrder(0);
  1620. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1621. b.Property<string>("Channel")
  1622. .HasColumnType("nvarchar(max)");
  1623. b.Property<DateTime>("CreateDate")
  1624. .HasColumnType("datetime2");
  1625. b.Property<string>("CreateUser")
  1626. .IsRequired()
  1627. .HasColumnType("nvarchar(max)");
  1628. b.Property<string>("ErrorCode")
  1629. .IsRequired()
  1630. .HasColumnType("nvarchar(max)");
  1631. b.Property<string>("ErrorDescription")
  1632. .IsRequired()
  1633. .HasColumnType("nvarchar(max)");
  1634. b.Property<string>("InnerException")
  1635. .HasColumnType("nvarchar(max)");
  1636. b.Property<string>("Input")
  1637. .HasColumnType("nvarchar(max)");
  1638. b.Property<string>("Method")
  1639. .IsRequired()
  1640. .HasColumnType("nvarchar(max)");
  1641. b.Property<string>("QueryString")
  1642. .HasColumnType("nvarchar(max)");
  1643. b.Property<string>("ServerIP")
  1644. .HasColumnType("nvarchar(max)");
  1645. b.Property<string>("ServiceResponseTimeInSeconds")
  1646. .IsRequired()
  1647. .HasColumnType("nvarchar(max)");
  1648. b.Property<string>("UserIP")
  1649. .HasColumnType("nvarchar(max)");
  1650. b.Property<string>("userAgent")
  1651. .HasColumnType("nvarchar(max)");
  1652. b.HasKey("Id");
  1653. b.ToTable("TeamLogs");
  1654. });
  1655. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamUser", b =>
  1656. {
  1657. b.Property<long>("Id")
  1658. .ValueGeneratedOnAdd()
  1659. .HasColumnType("bigint")
  1660. .HasColumnOrder(0);
  1661. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1662. b.Property<string>("AssignedUserId")
  1663. .IsRequired()
  1664. .HasColumnType("nvarchar(max)");
  1665. b.Property<string>("AssignedUserName")
  1666. .IsRequired()
  1667. .HasColumnType("nvarchar(max)");
  1668. b.Property<DateTime>("CreateDate")
  1669. .HasColumnType("datetime2")
  1670. .HasColumnOrder(3);
  1671. b.Property<string>("CreateUser")
  1672. .HasMaxLength(450)
  1673. .HasColumnType("nvarchar(450)")
  1674. .HasColumnOrder(1);
  1675. b.Property<bool>("IsAdmin")
  1676. .HasColumnType("bit");
  1677. b.Property<long>("TeamId")
  1678. .HasColumnType("bigint");
  1679. b.Property<DateTime?>("UpdateDate")
  1680. .HasColumnType("datetime2")
  1681. .HasColumnOrder(4);
  1682. b.Property<string>("UpdateUser")
  1683. .HasMaxLength(450)
  1684. .HasColumnType("nvarchar(450)")
  1685. .HasColumnOrder(2);
  1686. b.HasKey("Id");
  1687. b.HasIndex("TeamId");
  1688. b.ToTable("TeamUser");
  1689. });
  1690. modelBuilder.Entity("MTWorkHR.Core.Entities.University", b =>
  1691. {
  1692. b.Property<long>("Id")
  1693. .ValueGeneratedOnAdd()
  1694. .HasColumnType("bigint")
  1695. .HasColumnOrder(0);
  1696. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1697. b.Property<string>("NameAr")
  1698. .IsRequired()
  1699. .HasMaxLength(250)
  1700. .HasColumnType("nvarchar(250)");
  1701. b.Property<string>("NameEn")
  1702. .IsRequired()
  1703. .HasMaxLength(250)
  1704. .HasColumnType("nvarchar(250)");
  1705. b.HasKey("Id");
  1706. b.ToTable("Universities");
  1707. b.HasData(
  1708. new
  1709. {
  1710. Id = 1L,
  1711. NameAr = "جامعة الملك فهد",
  1712. NameEn = "Fahd Univ"
  1713. },
  1714. new
  1715. {
  1716. Id = 2L,
  1717. NameAr = "جامعة الرياض",
  1718. NameEn = "Riydh Univ"
  1719. },
  1720. new
  1721. {
  1722. Id = 3L,
  1723. NameAr = "جامعة جدة",
  1724. NameEn = "Geda Univ"
  1725. });
  1726. });
  1727. modelBuilder.Entity("MTWorkHR.Core.Entities.User.OrderRequest", b =>
  1728. {
  1729. b.Property<long>("Id")
  1730. .ValueGeneratedOnAdd()
  1731. .HasColumnType("bigint")
  1732. .HasColumnOrder(0);
  1733. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1734. b.Property<int?>("CityId")
  1735. .HasColumnType("int");
  1736. b.Property<long>("CompanyId")
  1737. .HasColumnType("bigint");
  1738. b.Property<int?>("CountryId")
  1739. .HasColumnType("int");
  1740. b.Property<DateTime>("CreateDate")
  1741. .HasColumnType("datetime2")
  1742. .HasColumnOrder(3);
  1743. b.Property<string>("CreateUser")
  1744. .HasMaxLength(450)
  1745. .HasColumnType("nvarchar(450)")
  1746. .HasColumnOrder(1);
  1747. b.Property<string>("DeleteUserId")
  1748. .HasMaxLength(450)
  1749. .HasColumnType("nvarchar(450)")
  1750. .HasColumnOrder(8);
  1751. b.Property<DateTime?>("EndDate")
  1752. .HasColumnType("datetime2");
  1753. b.Property<bool>("IsDeleted")
  1754. .HasColumnType("bit")
  1755. .HasColumnOrder(7);
  1756. b.Property<long?>("LeaveTypeId")
  1757. .HasColumnType("bigint");
  1758. b.Property<int?>("OrderStatus")
  1759. .HasColumnType("int");
  1760. b.Property<long>("OrderTypeId")
  1761. .HasColumnType("bigint");
  1762. b.Property<string>("RequestComments")
  1763. .HasColumnType("nvarchar(max)");
  1764. b.Property<string>("RequestingEmployeeId")
  1765. .IsRequired()
  1766. .HasColumnType("nvarchar(max)");
  1767. b.Property<DateTime>("StartDate")
  1768. .HasColumnType("datetime2");
  1769. b.Property<DateTime?>("UpdateDate")
  1770. .HasColumnType("datetime2")
  1771. .HasColumnOrder(4);
  1772. b.Property<string>("UpdateUser")
  1773. .HasMaxLength(450)
  1774. .HasColumnType("nvarchar(450)")
  1775. .HasColumnOrder(2);
  1776. b.HasKey("Id");
  1777. b.HasIndex("CompanyId");
  1778. b.HasIndex("LeaveTypeId");
  1779. b.HasIndex("OrderTypeId");
  1780. b.ToTable("OrderRequests");
  1781. });
  1782. modelBuilder.Entity("MTWorkHR.Core.Entities.UserLog", b =>
  1783. {
  1784. b.Property<long>("Id")
  1785. .ValueGeneratedOnAdd()
  1786. .HasColumnType("bigint")
  1787. .HasColumnOrder(0);
  1788. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1789. b.Property<string>("Channel")
  1790. .HasColumnType("nvarchar(max)");
  1791. b.Property<DateTime>("CreateDate")
  1792. .HasColumnType("datetime2");
  1793. b.Property<string>("CreateUser")
  1794. .IsRequired()
  1795. .HasColumnType("nvarchar(max)");
  1796. b.Property<string>("ErrorCode")
  1797. .IsRequired()
  1798. .HasColumnType("nvarchar(max)");
  1799. b.Property<string>("ErrorDescription")
  1800. .IsRequired()
  1801. .HasColumnType("nvarchar(max)");
  1802. b.Property<string>("InnerException")
  1803. .HasColumnType("nvarchar(max)");
  1804. b.Property<string>("Input")
  1805. .HasColumnType("nvarchar(max)");
  1806. b.Property<string>("Method")
  1807. .IsRequired()
  1808. .HasColumnType("nvarchar(max)");
  1809. b.Property<string>("QueryString")
  1810. .HasColumnType("nvarchar(max)");
  1811. b.Property<string>("ServerIP")
  1812. .HasColumnType("nvarchar(max)");
  1813. b.Property<string>("ServiceResponseTimeInSeconds")
  1814. .IsRequired()
  1815. .HasColumnType("nvarchar(max)");
  1816. b.Property<string>("UserIP")
  1817. .HasColumnType("nvarchar(max)");
  1818. b.Property<string>("userAgent")
  1819. .HasColumnType("nvarchar(max)");
  1820. b.HasKey("Id");
  1821. b.ToTable("UserLogs");
  1822. });
  1823. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  1824. {
  1825. b.Property<long>("Id")
  1826. .ValueGeneratedOnAdd()
  1827. .HasColumnType("bigint")
  1828. .HasColumnOrder(0);
  1829. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1830. b.Property<long>("AssignedUserId")
  1831. .HasColumnType("bigint");
  1832. b.Property<long>("CompanyId")
  1833. .HasColumnType("bigint");
  1834. b.Property<DateTime>("CreateDate")
  1835. .HasColumnType("datetime2")
  1836. .HasColumnOrder(3);
  1837. b.Property<string>("CreateUser")
  1838. .HasMaxLength(450)
  1839. .HasColumnType("nvarchar(450)")
  1840. .HasColumnOrder(1);
  1841. b.Property<string>("DeleteUserId")
  1842. .HasMaxLength(450)
  1843. .HasColumnType("nvarchar(450)")
  1844. .HasColumnOrder(8);
  1845. b.Property<string>("Description")
  1846. .IsRequired()
  1847. .HasColumnType("nvarchar(max)");
  1848. b.Property<DateTime>("DueDate")
  1849. .HasColumnType("datetime2");
  1850. b.Property<bool>("IsDeleted")
  1851. .HasColumnType("bit")
  1852. .HasColumnOrder(7);
  1853. b.Property<int>("Priority")
  1854. .HasColumnType("int");
  1855. b.Property<long>("ProjectId")
  1856. .HasColumnType("bigint");
  1857. b.Property<long>("StatusId")
  1858. .HasColumnType("bigint");
  1859. b.Property<string>("Title")
  1860. .IsRequired()
  1861. .HasColumnType("nvarchar(max)");
  1862. b.Property<DateTime?>("UpdateDate")
  1863. .HasColumnType("datetime2")
  1864. .HasColumnOrder(4);
  1865. b.Property<string>("UpdateUser")
  1866. .HasMaxLength(450)
  1867. .HasColumnType("nvarchar(450)")
  1868. .HasColumnOrder(2);
  1869. b.HasKey("Id");
  1870. b.HasIndex("CompanyId");
  1871. b.HasIndex("ProjectId");
  1872. b.HasIndex("StatusId");
  1873. b.ToTable("UserTasks");
  1874. });
  1875. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskAttachment", b =>
  1876. {
  1877. b.Property<long>("Id")
  1878. .ValueGeneratedOnAdd()
  1879. .HasColumnType("bigint")
  1880. .HasColumnOrder(0);
  1881. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1882. b.Property<long?>("AttachmentTypeId")
  1883. .HasColumnType("bigint");
  1884. b.Property<DateTime>("CreateDate")
  1885. .HasColumnType("datetime2")
  1886. .HasColumnOrder(3);
  1887. b.Property<string>("CreateUser")
  1888. .HasMaxLength(450)
  1889. .HasColumnType("nvarchar(450)")
  1890. .HasColumnOrder(1);
  1891. b.Property<string>("FileName")
  1892. .HasMaxLength(250)
  1893. .HasColumnType("nvarchar(250)");
  1894. b.Property<string>("OriginalName")
  1895. .HasMaxLength(250)
  1896. .HasColumnType("nvarchar(250)");
  1897. b.Property<long>("TaskId")
  1898. .HasColumnType("bigint");
  1899. b.Property<DateTime?>("UpdateDate")
  1900. .HasColumnType("datetime2")
  1901. .HasColumnOrder(4);
  1902. b.Property<string>("UpdateUser")
  1903. .HasMaxLength(450)
  1904. .HasColumnType("nvarchar(450)")
  1905. .HasColumnOrder(2);
  1906. b.HasKey("Id");
  1907. b.HasIndex("AttachmentTypeId");
  1908. b.HasIndex("TaskId");
  1909. b.ToTable("UserTaskAttachments");
  1910. });
  1911. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskHistory", b =>
  1912. {
  1913. b.Property<long>("Id")
  1914. .ValueGeneratedOnAdd()
  1915. .HasColumnType("bigint")
  1916. .HasColumnOrder(0);
  1917. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1918. b.Property<long>("AssignedToUserId")
  1919. .HasColumnType("bigint");
  1920. b.Property<string>("Comment")
  1921. .HasMaxLength(500)
  1922. .HasColumnType("nvarchar(500)");
  1923. b.Property<DateTime>("CreateDate")
  1924. .HasColumnType("datetime2")
  1925. .HasColumnOrder(3);
  1926. b.Property<string>("CreateUser")
  1927. .HasMaxLength(450)
  1928. .HasColumnType("nvarchar(450)")
  1929. .HasColumnOrder(1);
  1930. b.Property<long>("CurrentStatusId")
  1931. .HasColumnType("bigint");
  1932. b.Property<bool>("IsDeleted")
  1933. .HasColumnType("bit");
  1934. b.Property<long>("TaskId")
  1935. .HasColumnType("bigint");
  1936. b.Property<DateTime?>("UpdateDate")
  1937. .HasColumnType("datetime2")
  1938. .HasColumnOrder(4);
  1939. b.Property<string>("UpdateUser")
  1940. .HasMaxLength(450)
  1941. .HasColumnType("nvarchar(450)")
  1942. .HasColumnOrder(2);
  1943. b.Property<long?>("UserTaskId")
  1944. .HasColumnType("bigint");
  1945. b.HasKey("Id");
  1946. b.HasIndex("CurrentStatusId");
  1947. b.HasIndex("UserTaskId");
  1948. b.ToTable("UserTaskHistories");
  1949. });
  1950. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskLog", b =>
  1951. {
  1952. b.Property<long>("Id")
  1953. .ValueGeneratedOnAdd()
  1954. .HasColumnType("bigint")
  1955. .HasColumnOrder(0);
  1956. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1957. b.Property<string>("Channel")
  1958. .HasColumnType("nvarchar(max)");
  1959. b.Property<DateTime>("CreateDate")
  1960. .HasColumnType("datetime2");
  1961. b.Property<string>("CreateUser")
  1962. .IsRequired()
  1963. .HasColumnType("nvarchar(max)");
  1964. b.Property<string>("ErrorCode")
  1965. .IsRequired()
  1966. .HasColumnType("nvarchar(max)");
  1967. b.Property<string>("ErrorDescription")
  1968. .IsRequired()
  1969. .HasColumnType("nvarchar(max)");
  1970. b.Property<string>("InnerException")
  1971. .HasColumnType("nvarchar(max)");
  1972. b.Property<string>("Input")
  1973. .HasColumnType("nvarchar(max)");
  1974. b.Property<string>("Method")
  1975. .IsRequired()
  1976. .HasColumnType("nvarchar(max)");
  1977. b.Property<string>("QueryString")
  1978. .HasColumnType("nvarchar(max)");
  1979. b.Property<string>("ServerIP")
  1980. .HasColumnType("nvarchar(max)");
  1981. b.Property<string>("ServiceResponseTimeInSeconds")
  1982. .IsRequired()
  1983. .HasColumnType("nvarchar(max)");
  1984. b.Property<string>("UserIP")
  1985. .HasColumnType("nvarchar(max)");
  1986. b.Property<string>("userAgent")
  1987. .HasColumnType("nvarchar(max)");
  1988. b.HasKey("Id");
  1989. b.ToTable("UserTaskLogs");
  1990. });
  1991. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskStatus", b =>
  1992. {
  1993. b.Property<long>("Id")
  1994. .ValueGeneratedOnAdd()
  1995. .HasColumnType("bigint")
  1996. .HasColumnOrder(0);
  1997. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  1998. b.Property<string>("NameAr")
  1999. .IsRequired()
  2000. .HasMaxLength(250)
  2001. .HasColumnType("nvarchar(250)");
  2002. b.Property<string>("NameEn")
  2003. .IsRequired()
  2004. .HasMaxLength(250)
  2005. .HasColumnType("nvarchar(250)");
  2006. b.HasKey("Id");
  2007. b.ToTable("UserTaskStatuses");
  2008. b.HasData(
  2009. new
  2010. {
  2011. Id = 1L,
  2012. NameAr = "جديدة",
  2013. NameEn = "New"
  2014. },
  2015. new
  2016. {
  2017. Id = 2L,
  2018. NameAr = "قيد العمل",
  2019. NameEn = "Under progress"
  2020. },
  2021. new
  2022. {
  2023. Id = 3L,
  2024. NameAr = "أغلقت",
  2025. NameEn = "Closed"
  2026. },
  2027. new
  2028. {
  2029. Id = 4L,
  2030. NameAr = "تمت",
  2031. NameEn = "Completed"
  2032. },
  2033. new
  2034. {
  2035. Id = 5L,
  2036. NameAr = "مؤجلة",
  2037. NameEn = "Delayed"
  2038. });
  2039. });
  2040. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationRole", b =>
  2041. {
  2042. b.Property<string>("Id")
  2043. .HasColumnType("nvarchar(450)");
  2044. b.Property<string>("ConcurrencyStamp")
  2045. .IsConcurrencyToken()
  2046. .HasColumnType("nvarchar(max)");
  2047. b.Property<DateTime>("CreateDate")
  2048. .HasColumnType("datetime2");
  2049. b.Property<string>("CreateUser")
  2050. .HasColumnType("nvarchar(max)");
  2051. b.Property<string>("DeleteUserId")
  2052. .HasColumnType("nvarchar(max)");
  2053. b.Property<bool?>("IsAdmin")
  2054. .HasColumnType("bit");
  2055. b.Property<bool>("IsDeleted")
  2056. .HasColumnType("bit");
  2057. b.Property<string>("Name")
  2058. .HasMaxLength(256)
  2059. .HasColumnType("nvarchar(256)");
  2060. b.Property<string>("NormalizedName")
  2061. .HasMaxLength(256)
  2062. .HasColumnType("nvarchar(256)");
  2063. b.Property<DateTime?>("UpdateDate")
  2064. .HasColumnType("datetime2");
  2065. b.Property<string>("UpdateUser")
  2066. .HasColumnType("nvarchar(max)");
  2067. b.HasKey("Id");
  2068. b.HasIndex("NormalizedName")
  2069. .IsUnique()
  2070. .HasDatabaseName("RoleNameIndex")
  2071. .HasFilter("[NormalizedName] IS NOT NULL");
  2072. b.ToTable("AspNetRoles", (string)null);
  2073. b.HasData(
  2074. new
  2075. {
  2076. Id = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A",
  2077. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2078. IsAdmin = true,
  2079. IsDeleted = false,
  2080. Name = "Admin",
  2081. NormalizedName = "ADMIN"
  2082. },
  2083. new
  2084. {
  2085. Id = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E",
  2086. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2087. IsAdmin = false,
  2088. IsDeleted = false,
  2089. Name = "Employee",
  2090. NormalizedName = "EMPLOYEE"
  2091. },
  2092. new
  2093. {
  2094. Id = "CO5B3B92-2311-48F8-9DEC-F9FAEF1F211R",
  2095. CreateDate = new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2096. IsAdmin = false,
  2097. IsDeleted = false,
  2098. Name = "Contractor",
  2099. NormalizedName = "CONTRACTOR"
  2100. });
  2101. });
  2102. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  2103. {
  2104. b.Property<string>("Id")
  2105. .HasColumnType("nvarchar(450)");
  2106. b.Property<int>("AccessFailedCount")
  2107. .HasColumnType("int");
  2108. b.Property<long?>("CompanyId")
  2109. .HasColumnType("bigint");
  2110. b.Property<string>("ConcurrencyStamp")
  2111. .IsConcurrencyToken()
  2112. .HasColumnType("nvarchar(max)");
  2113. b.Property<long?>("CountryId")
  2114. .HasColumnType("bigint");
  2115. b.Property<string>("CreateUser")
  2116. .HasColumnType("nvarchar(max)");
  2117. b.Property<DateTime>("DateOfBirth")
  2118. .HasColumnType("datetime2");
  2119. b.Property<string>("DeleteUserId")
  2120. .HasColumnType("nvarchar(max)");
  2121. b.Property<string>("Email")
  2122. .HasMaxLength(256)
  2123. .HasColumnType("nvarchar(256)");
  2124. b.Property<bool>("EmailConfirmed")
  2125. .HasColumnType("bit");
  2126. b.Property<string>("FavoriteName")
  2127. .HasColumnType("nvarchar(max)");
  2128. b.Property<string>("FirstName")
  2129. .IsRequired()
  2130. .HasColumnType("nvarchar(max)");
  2131. b.Property<string>("IdNumber")
  2132. .IsRequired()
  2133. .HasColumnType("nvarchar(max)");
  2134. b.Property<decimal?>("IncomeTaxValue")
  2135. .HasColumnType("decimal(18,2)");
  2136. b.Property<long?>("IndustryId")
  2137. .HasColumnType("bigint");
  2138. b.Property<bool>("IsDeleted")
  2139. .HasColumnType("bit");
  2140. b.Property<bool>("IsStopped")
  2141. .HasColumnType("bit");
  2142. b.Property<long?>("JobTitleId")
  2143. .HasColumnType("bigint");
  2144. b.Property<string>("LastName")
  2145. .IsRequired()
  2146. .HasColumnType("nvarchar(max)");
  2147. b.Property<string>("LinkedInLink")
  2148. .HasColumnType("nvarchar(max)");
  2149. b.Property<bool>("LockoutEnabled")
  2150. .HasColumnType("bit");
  2151. b.Property<DateTimeOffset?>("LockoutEnd")
  2152. .HasColumnType("datetimeoffset");
  2153. b.Property<string>("ManagerId")
  2154. .HasColumnType("nvarchar(450)");
  2155. b.Property<string>("NormalizedEmail")
  2156. .HasMaxLength(256)
  2157. .HasColumnType("nvarchar(256)");
  2158. b.Property<string>("NormalizedUserName")
  2159. .HasMaxLength(256)
  2160. .HasColumnType("nvarchar(256)");
  2161. b.Property<string>("PassportNumber")
  2162. .IsRequired()
  2163. .HasColumnType("nvarchar(max)");
  2164. b.Property<string>("PasswordHash")
  2165. .HasColumnType("nvarchar(max)");
  2166. b.Property<string>("PhoneNumber")
  2167. .HasColumnType("nvarchar(max)");
  2168. b.Property<bool>("PhoneNumberConfirmed")
  2169. .HasColumnType("bit");
  2170. b.Property<long?>("QualificationId")
  2171. .HasColumnType("bigint");
  2172. b.Property<string>("SecurityStamp")
  2173. .HasColumnType("nvarchar(max)");
  2174. b.Property<decimal?>("TaxNumber")
  2175. .HasColumnType("decimal(18,2)");
  2176. b.Property<bool>("TwoFactorEnabled")
  2177. .HasColumnType("bit");
  2178. b.Property<long?>("UniversityId")
  2179. .HasColumnType("bigint");
  2180. b.Property<string>("UpdateUser")
  2181. .HasColumnType("nvarchar(max)");
  2182. b.Property<string>("UserName")
  2183. .HasMaxLength(256)
  2184. .HasColumnType("nvarchar(256)");
  2185. b.Property<int>("UserType")
  2186. .HasColumnType("int");
  2187. b.HasKey("Id");
  2188. b.HasIndex("CountryId");
  2189. b.HasIndex("IndustryId");
  2190. b.HasIndex("JobTitleId");
  2191. b.HasIndex("ManagerId");
  2192. b.HasIndex("NormalizedEmail")
  2193. .HasDatabaseName("EmailIndex");
  2194. b.HasIndex("NormalizedUserName")
  2195. .IsUnique()
  2196. .HasDatabaseName("UserNameIndex")
  2197. .HasFilter("[NormalizedUserName] IS NOT NULL");
  2198. b.HasIndex("QualificationId");
  2199. b.HasIndex("UniversityId");
  2200. b.ToTable("AspNetUsers", (string)null);
  2201. b.HasData(
  2202. new
  2203. {
  2204. Id = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  2205. AccessFailedCount = 0,
  2206. CompanyId = 1L,
  2207. ConcurrencyStamp = "7cc87689-9eab-4280-b8e3-1834080783a5",
  2208. DateOfBirth = new DateTime(2000, 2, 10, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2209. Email = "a@b.com",
  2210. EmailConfirmed = true,
  2211. FirstName = "Zinab",
  2212. IdNumber = "123",
  2213. IncomeTaxValue = 1m,
  2214. IsDeleted = false,
  2215. IsStopped = false,
  2216. LastName = "Elgendy",
  2217. LockoutEnabled = false,
  2218. NormalizedEmail = "A@B.COM",
  2219. NormalizedUserName = "A@B.COM",
  2220. PassportNumber = "1234567",
  2221. PasswordHash = "AQAAAAIAAYagAAAAEPg+ASbciPFxtyxQq8Wx5ilBUQ0RbAoITXXkOQm1PzC5BzySX0sn/wUmOjBKPDGV9w==",
  2222. PhoneNumber = "1234567890",
  2223. PhoneNumberConfirmed = true,
  2224. SecurityStamp = "49bb16c3-4704-4c60-908d-dc8506950acc",
  2225. TaxNumber = 111m,
  2226. TwoFactorEnabled = false,
  2227. UserName = "A@b.com",
  2228. UserType = 1
  2229. },
  2230. new
  2231. {
  2232. Id = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  2233. AccessFailedCount = 0,
  2234. CompanyId = 1L,
  2235. ConcurrencyStamp = "4af7b4cf-802a-455b-b598-997e167745b3",
  2236. DateOfBirth = new DateTime(2001, 5, 13, 0, 0, 0, 0, DateTimeKind.Unspecified),
  2237. Email = "ali@b.com",
  2238. EmailConfirmed = true,
  2239. FirstName = "Ali",
  2240. IdNumber = "343434",
  2241. IncomeTaxValue = 100m,
  2242. IsDeleted = false,
  2243. IsStopped = false,
  2244. LastName = "Farok",
  2245. LockoutEnabled = false,
  2246. NormalizedEmail = "ALI@B.COM",
  2247. NormalizedUserName = "ALI@B.COM",
  2248. PassportNumber = "7654321001010",
  2249. PasswordHash = "AQAAAAIAAYagAAAAEI3QJkcZjCH4Y8Db4rEgL8Mmll5oCvYcWiXZjQSN9bGW4SMcjHe3ZPMnkN/l9DmJeQ==",
  2250. PhoneNumber = "1234567888",
  2251. PhoneNumberConfirmed = true,
  2252. SecurityStamp = "62549056-1b9d-46d4-84f8-adea3e4d8b68",
  2253. TaxNumber = 222m,
  2254. TwoFactorEnabled = false,
  2255. UserName = "Ali@b.com",
  2256. UserType = 1
  2257. });
  2258. });
  2259. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.RolePermission", b =>
  2260. {
  2261. b.Property<long>("Id")
  2262. .ValueGeneratedOnAdd()
  2263. .HasColumnType("bigint")
  2264. .HasColumnOrder(0);
  2265. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  2266. b.Property<long>("PermissionId")
  2267. .HasColumnType("bigint");
  2268. b.Property<string>("PermissionName")
  2269. .IsRequired()
  2270. .HasColumnType("nvarchar(max)");
  2271. b.Property<string>("RoleId")
  2272. .IsRequired()
  2273. .HasColumnType("nvarchar(450)");
  2274. b.HasKey("Id");
  2275. b.HasIndex("PermissionId");
  2276. b.HasIndex("RoleId");
  2277. b.ToTable("RolePermissions");
  2278. });
  2279. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAddress", b =>
  2280. {
  2281. b.Property<long>("Id")
  2282. .ValueGeneratedOnAdd()
  2283. .HasColumnType("bigint")
  2284. .HasColumnOrder(0);
  2285. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  2286. b.Property<string>("AddressDesc")
  2287. .HasColumnType("nvarchar(max)");
  2288. b.Property<long?>("CityId")
  2289. .HasColumnType("bigint");
  2290. b.Property<long?>("CountryId")
  2291. .HasColumnType("bigint");
  2292. b.Property<DateTime>("CreateDate")
  2293. .HasColumnType("datetime2")
  2294. .HasColumnOrder(3);
  2295. b.Property<string>("CreateUser")
  2296. .HasMaxLength(450)
  2297. .HasColumnType("nvarchar(450)")
  2298. .HasColumnOrder(1);
  2299. b.Property<string>("PostalCode")
  2300. .HasColumnType("nvarchar(max)");
  2301. b.Property<DateTime?>("UpdateDate")
  2302. .HasColumnType("datetime2")
  2303. .HasColumnOrder(4);
  2304. b.Property<string>("UpdateUser")
  2305. .HasMaxLength(450)
  2306. .HasColumnType("nvarchar(450)")
  2307. .HasColumnOrder(2);
  2308. b.Property<string>("UserId")
  2309. .IsRequired()
  2310. .HasColumnType("nvarchar(450)");
  2311. b.HasKey("Id");
  2312. b.HasIndex("CityId");
  2313. b.HasIndex("CountryId");
  2314. b.HasIndex("UserId")
  2315. .IsUnique();
  2316. b.ToTable("UserAddress");
  2317. });
  2318. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAttachment", b =>
  2319. {
  2320. b.Property<long>("Id")
  2321. .ValueGeneratedOnAdd()
  2322. .HasColumnType("bigint")
  2323. .HasColumnOrder(0);
  2324. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
  2325. b.Property<long>("AttachmentTypeId")
  2326. .HasColumnType("bigint");
  2327. b.Property<byte[]>("Content")
  2328. .IsRequired()
  2329. .HasColumnType("varbinary(max)");
  2330. b.Property<string>("ContentType")
  2331. .HasColumnType("nvarchar(max)");
  2332. b.Property<DateTime>("CreateDate")
  2333. .HasColumnType("datetime2")
  2334. .HasColumnOrder(3);
  2335. b.Property<string>("CreateUser")
  2336. .HasMaxLength(450)
  2337. .HasColumnType("nvarchar(450)")
  2338. .HasColumnOrder(1);
  2339. b.Property<string>("FileName")
  2340. .IsRequired()
  2341. .HasMaxLength(250)
  2342. .HasColumnType("nvarchar(250)");
  2343. b.Property<string>("FilePath")
  2344. .HasColumnType("nvarchar(max)");
  2345. b.Property<string>("OriginalName")
  2346. .IsRequired()
  2347. .HasMaxLength(250)
  2348. .HasColumnType("nvarchar(250)");
  2349. b.Property<DateTime?>("UpdateDate")
  2350. .HasColumnType("datetime2")
  2351. .HasColumnOrder(4);
  2352. b.Property<string>("UpdateUser")
  2353. .HasMaxLength(450)
  2354. .HasColumnType("nvarchar(450)")
  2355. .HasColumnOrder(2);
  2356. b.Property<string>("UserId")
  2357. .IsRequired()
  2358. .HasColumnType("nvarchar(450)");
  2359. b.HasKey("Id");
  2360. b.HasIndex("AttachmentTypeId");
  2361. b.HasIndex("UserId");
  2362. b.ToTable("UserAttachments");
  2363. });
  2364. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  2365. {
  2366. b.Property<int>("Id")
  2367. .ValueGeneratedOnAdd()
  2368. .HasColumnType("int");
  2369. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  2370. b.Property<string>("ClaimType")
  2371. .HasColumnType("nvarchar(max)");
  2372. b.Property<string>("ClaimValue")
  2373. .HasColumnType("nvarchar(max)");
  2374. b.Property<string>("RoleId")
  2375. .IsRequired()
  2376. .HasColumnType("nvarchar(450)");
  2377. b.HasKey("Id");
  2378. b.HasIndex("RoleId");
  2379. b.ToTable("AspNetRoleClaims", (string)null);
  2380. });
  2381. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  2382. {
  2383. b.Property<int>("Id")
  2384. .ValueGeneratedOnAdd()
  2385. .HasColumnType("int");
  2386. SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
  2387. b.Property<string>("ClaimType")
  2388. .HasColumnType("nvarchar(max)");
  2389. b.Property<string>("ClaimValue")
  2390. .HasColumnType("nvarchar(max)");
  2391. b.Property<string>("UserId")
  2392. .IsRequired()
  2393. .HasColumnType("nvarchar(450)");
  2394. b.HasKey("Id");
  2395. b.HasIndex("UserId");
  2396. b.ToTable("AspNetUserClaims", (string)null);
  2397. });
  2398. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  2399. {
  2400. b.Property<string>("LoginProvider")
  2401. .HasColumnType("nvarchar(450)");
  2402. b.Property<string>("ProviderKey")
  2403. .HasColumnType("nvarchar(450)");
  2404. b.Property<string>("ProviderDisplayName")
  2405. .HasColumnType("nvarchar(max)");
  2406. b.Property<string>("UserId")
  2407. .IsRequired()
  2408. .HasColumnType("nvarchar(450)");
  2409. b.HasKey("LoginProvider", "ProviderKey");
  2410. b.HasIndex("UserId");
  2411. b.ToTable("AspNetUserLogins", (string)null);
  2412. });
  2413. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  2414. {
  2415. b.Property<string>("UserId")
  2416. .HasColumnType("nvarchar(450)");
  2417. b.Property<string>("RoleId")
  2418. .HasColumnType("nvarchar(450)");
  2419. b.HasKey("UserId", "RoleId");
  2420. b.HasIndex("RoleId");
  2421. b.ToTable("AspNetUserRoles", (string)null);
  2422. b.HasData(
  2423. new
  2424. {
  2425. UserId = "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
  2426. RoleId = "AD5B3B92-2311-48F8-9DEC-F9FAEF1F211A"
  2427. },
  2428. new
  2429. {
  2430. UserId = "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
  2431. RoleId = "EM5B3B92-2311-48F8-9DEC-F9FAEF1F211E"
  2432. });
  2433. });
  2434. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  2435. {
  2436. b.Property<string>("UserId")
  2437. .HasColumnType("nvarchar(450)");
  2438. b.Property<string>("LoginProvider")
  2439. .HasColumnType("nvarchar(450)");
  2440. b.Property<string>("Name")
  2441. .HasColumnType("nvarchar(450)");
  2442. b.Property<string>("Value")
  2443. .HasColumnType("nvarchar(max)");
  2444. b.HasKey("UserId", "LoginProvider", "Name");
  2445. b.ToTable("AspNetUserTokens", (string)null);
  2446. });
  2447. modelBuilder.Entity("ApplicationRoleApplicationUser", b =>
  2448. {
  2449. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  2450. .WithMany()
  2451. .HasForeignKey("UserRolesId")
  2452. .OnDelete(DeleteBehavior.Cascade)
  2453. .IsRequired();
  2454. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2455. .WithMany()
  2456. .HasForeignKey("UsersId")
  2457. .OnDelete(DeleteBehavior.Cascade)
  2458. .IsRequired();
  2459. });
  2460. modelBuilder.Entity("MTWorkHR.Core.Entities.City", b =>
  2461. {
  2462. b.HasOne("MTWorkHR.Core.Entities.CountryLookup", "Country")
  2463. .WithMany()
  2464. .HasForeignKey("CountryId")
  2465. .OnDelete(DeleteBehavior.Cascade)
  2466. .IsRequired();
  2467. b.Navigation("Country");
  2468. });
  2469. modelBuilder.Entity("MTWorkHR.Core.Entities.MeetingUser", b =>
  2470. {
  2471. b.HasOne("MTWorkHR.Core.Entities.Meeting", "Meeting")
  2472. .WithMany("MeetingUsers")
  2473. .HasForeignKey("MeetingId")
  2474. .OnDelete(DeleteBehavior.Cascade)
  2475. .IsRequired();
  2476. b.Navigation("Meeting");
  2477. });
  2478. modelBuilder.Entity("MTWorkHR.Core.Entities.OrderAllocation", b =>
  2479. {
  2480. b.HasOne("MTWorkHR.Core.Entities.LeaveType", "LeaveType")
  2481. .WithMany()
  2482. .HasForeignKey("LeaveTypeId");
  2483. b.HasOne("MTWorkHR.Core.Entities.OrderType", "OrderType")
  2484. .WithMany()
  2485. .HasForeignKey("OrderTypeId")
  2486. .OnDelete(DeleteBehavior.Cascade)
  2487. .IsRequired();
  2488. b.Navigation("LeaveType");
  2489. b.Navigation("OrderType");
  2490. });
  2491. modelBuilder.Entity("MTWorkHR.Core.Entities.TeamUser", b =>
  2492. {
  2493. b.HasOne("MTWorkHR.Core.Entities.Team", "Team")
  2494. .WithMany("TeamUsers")
  2495. .HasForeignKey("TeamId")
  2496. .OnDelete(DeleteBehavior.Cascade)
  2497. .IsRequired();
  2498. b.Navigation("Team");
  2499. });
  2500. modelBuilder.Entity("MTWorkHR.Core.Entities.User.OrderRequest", b =>
  2501. {
  2502. b.HasOne("MTWorkHR.Core.Entities.LeaveType", "LeaveType")
  2503. .WithMany()
  2504. .HasForeignKey("LeaveTypeId");
  2505. b.HasOne("MTWorkHR.Core.Entities.OrderType", "OrderType")
  2506. .WithMany()
  2507. .HasForeignKey("OrderTypeId")
  2508. .OnDelete(DeleteBehavior.Cascade)
  2509. .IsRequired();
  2510. b.Navigation("LeaveType");
  2511. b.Navigation("OrderType");
  2512. });
  2513. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  2514. {
  2515. b.HasOne("MTWorkHR.Core.Entities.Project", "Project")
  2516. .WithMany()
  2517. .HasForeignKey("ProjectId")
  2518. .OnDelete(DeleteBehavior.Cascade)
  2519. .IsRequired();
  2520. b.HasOne("MTWorkHR.Core.Entities.UserTaskStatus", "TaskStatus")
  2521. .WithMany()
  2522. .HasForeignKey("StatusId")
  2523. .OnDelete(DeleteBehavior.Cascade)
  2524. .IsRequired();
  2525. b.Navigation("Project");
  2526. b.Navigation("TaskStatus");
  2527. });
  2528. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskAttachment", b =>
  2529. {
  2530. b.HasOne("MTWorkHR.Core.Entities.Base.AttachmentType", "AttachmentType")
  2531. .WithMany()
  2532. .HasForeignKey("AttachmentTypeId");
  2533. b.HasOne("MTWorkHR.Core.Entities.UserTask", "UserTask")
  2534. .WithMany("TaskAttachments")
  2535. .HasForeignKey("TaskId")
  2536. .OnDelete(DeleteBehavior.Cascade)
  2537. .IsRequired();
  2538. b.Navigation("AttachmentType");
  2539. b.Navigation("UserTask");
  2540. });
  2541. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTaskHistory", b =>
  2542. {
  2543. b.HasOne("MTWorkHR.Core.Entities.UserTaskStatus", "TaskStatus")
  2544. .WithMany()
  2545. .HasForeignKey("CurrentStatusId")
  2546. .OnDelete(DeleteBehavior.Cascade)
  2547. .IsRequired();
  2548. b.HasOne("MTWorkHR.Core.Entities.UserTask", null)
  2549. .WithMany("UserTaskHistories")
  2550. .HasForeignKey("UserTaskId");
  2551. b.Navigation("TaskStatus");
  2552. });
  2553. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  2554. {
  2555. b.HasOne("MTWorkHR.Core.Entities.CountryLookup", "Country")
  2556. .WithMany()
  2557. .HasForeignKey("CountryId");
  2558. b.HasOne("MTWorkHR.Core.Entities.Industry", "Industry")
  2559. .WithMany()
  2560. .HasForeignKey("IndustryId");
  2561. b.HasOne("MTWorkHR.Core.Entities.JobTitle", "JobTitle")
  2562. .WithMany()
  2563. .HasForeignKey("JobTitleId");
  2564. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "Manager")
  2565. .WithMany()
  2566. .HasForeignKey("ManagerId");
  2567. b.HasOne("MTWorkHR.Core.Entities.Qualification", "Qualification")
  2568. .WithMany()
  2569. .HasForeignKey("QualificationId");
  2570. b.HasOne("MTWorkHR.Core.Entities.University", "University")
  2571. .WithMany()
  2572. .HasForeignKey("UniversityId");
  2573. b.Navigation("Country");
  2574. b.Navigation("Industry");
  2575. b.Navigation("JobTitle");
  2576. b.Navigation("Manager");
  2577. b.Navigation("Qualification");
  2578. b.Navigation("University");
  2579. });
  2580. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.RolePermission", b =>
  2581. {
  2582. b.HasOne("MTWorkHR.Core.Entities.Permission", "Permission")
  2583. .WithMany()
  2584. .HasForeignKey("PermissionId")
  2585. .OnDelete(DeleteBehavior.Cascade)
  2586. .IsRequired();
  2587. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", "Role")
  2588. .WithMany("RolePermissions")
  2589. .HasForeignKey("RoleId")
  2590. .OnDelete(DeleteBehavior.Cascade)
  2591. .IsRequired();
  2592. b.Navigation("Permission");
  2593. b.Navigation("Role");
  2594. });
  2595. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAddress", b =>
  2596. {
  2597. b.HasOne("MTWorkHR.Core.Entities.City", "City")
  2598. .WithMany()
  2599. .HasForeignKey("CityId");
  2600. b.HasOne("MTWorkHR.Core.Entities.CountryLookup", "Country")
  2601. .WithMany()
  2602. .HasForeignKey("CountryId");
  2603. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "User")
  2604. .WithOne("UserAddress")
  2605. .HasForeignKey("MTWorkHR.Infrastructure.Entities.UserAddress", "UserId")
  2606. .OnDelete(DeleteBehavior.Cascade)
  2607. .IsRequired();
  2608. b.Navigation("City");
  2609. b.Navigation("Country");
  2610. b.Navigation("User");
  2611. });
  2612. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.UserAttachment", b =>
  2613. {
  2614. b.HasOne("MTWorkHR.Core.Entities.Base.AttachmentType", "AttachmentType")
  2615. .WithMany()
  2616. .HasForeignKey("AttachmentTypeId")
  2617. .OnDelete(DeleteBehavior.Cascade)
  2618. .IsRequired();
  2619. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", "User")
  2620. .WithMany("UserAttachments")
  2621. .HasForeignKey("UserId")
  2622. .OnDelete(DeleteBehavior.Cascade)
  2623. .IsRequired();
  2624. b.Navigation("AttachmentType");
  2625. b.Navigation("User");
  2626. });
  2627. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>", b =>
  2628. {
  2629. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  2630. .WithMany()
  2631. .HasForeignKey("RoleId")
  2632. .OnDelete(DeleteBehavior.Cascade)
  2633. .IsRequired();
  2634. });
  2635. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserClaim<string>", b =>
  2636. {
  2637. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2638. .WithMany()
  2639. .HasForeignKey("UserId")
  2640. .OnDelete(DeleteBehavior.Cascade)
  2641. .IsRequired();
  2642. });
  2643. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserLogin<string>", b =>
  2644. {
  2645. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2646. .WithMany()
  2647. .HasForeignKey("UserId")
  2648. .OnDelete(DeleteBehavior.Cascade)
  2649. .IsRequired();
  2650. });
  2651. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserRole<string>", b =>
  2652. {
  2653. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationRole", null)
  2654. .WithMany()
  2655. .HasForeignKey("RoleId")
  2656. .OnDelete(DeleteBehavior.Cascade)
  2657. .IsRequired();
  2658. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2659. .WithMany()
  2660. .HasForeignKey("UserId")
  2661. .OnDelete(DeleteBehavior.Cascade)
  2662. .IsRequired();
  2663. });
  2664. modelBuilder.Entity("Microsoft.AspNetCore.Identity.IdentityUserToken<string>", b =>
  2665. {
  2666. b.HasOne("MTWorkHR.Infrastructure.Entities.ApplicationUser", null)
  2667. .WithMany()
  2668. .HasForeignKey("UserId")
  2669. .OnDelete(DeleteBehavior.Cascade)
  2670. .IsRequired();
  2671. });
  2672. modelBuilder.Entity("MTWorkHR.Core.Entities.Meeting", b =>
  2673. {
  2674. b.Navigation("MeetingUsers");
  2675. });
  2676. modelBuilder.Entity("MTWorkHR.Core.Entities.Team", b =>
  2677. {
  2678. b.Navigation("TeamUsers");
  2679. });
  2680. modelBuilder.Entity("MTWorkHR.Core.Entities.UserTask", b =>
  2681. {
  2682. b.Navigation("TaskAttachments");
  2683. b.Navigation("UserTaskHistories");
  2684. });
  2685. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationRole", b =>
  2686. {
  2687. b.Navigation("RolePermissions");
  2688. });
  2689. modelBuilder.Entity("MTWorkHR.Infrastructure.Entities.ApplicationUser", b =>
  2690. {
  2691. b.Navigation("UserAddress")
  2692. .IsRequired();
  2693. b.Navigation("UserAttachments");
  2694. });
  2695. #pragma warning restore 612, 618
  2696. }
  2697. }
  2698. }