HRDataContextModelSnapshot.cs 110 KB

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