API
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

DataContextModelSnapshot.cs 38KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263
  1. // <auto-generated />
  2. using System;
  3. using Microsoft.EntityFrameworkCore;
  4. using Microsoft.EntityFrameworkCore.Infrastructure;
  5. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  6. using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
  7. using UnivateProperties_API.Context;
  8. namespace UnivateProperties_API.Migrations
  9. {
  10. [DbContext(typeof(DataContext))]
  11. partial class DataContextModelSnapshot : ModelSnapshot
  12. {
  13. protected override void BuildModel(ModelBuilder modelBuilder)
  14. {
  15. #pragma warning disable 612, 618
  16. modelBuilder
  17. .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.SerialColumn)
  18. .HasAnnotation("ProductVersion", "2.2.6-servicing-10079")
  19. .HasAnnotation("Relational:MaxIdentifierLength", 63);
  20. modelBuilder.Entity("UnivateProperties_API.Model.Banks.Bank", b =>
  21. {
  22. b.Property<int>("Id")
  23. .ValueGeneratedOnAdd();
  24. b.Property<DateTime>("Created");
  25. b.Property<bool>("IsDeleted");
  26. b.Property<DateTime>("Modified");
  27. b.Property<string>("ModifiedBy");
  28. b.Property<string>("Name");
  29. b.Property<string>("UniversalBranchCode");
  30. b.HasKey("Id");
  31. b.ToTable("Banks");
  32. });
  33. modelBuilder.Entity("UnivateProperties_API.Model.Banks.BankAccount", b =>
  34. {
  35. b.Property<int>("Id")
  36. .ValueGeneratedOnAdd();
  37. b.Property<string>("AccountHolder");
  38. b.Property<string>("AccountNumber");
  39. b.Property<int?>("BankId");
  40. b.Property<DateTime>("Created");
  41. b.Property<bool>("IsDeleted");
  42. b.Property<DateTime>("Modified");
  43. b.Property<string>("ModifiedBy");
  44. b.Property<int?>("OwnerId");
  45. b.HasKey("Id");
  46. b.HasIndex("BankId");
  47. b.HasIndex("OwnerId");
  48. b.ToTable("BankAccounts");
  49. });
  50. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Email", b =>
  51. {
  52. b.Property<int>("Id")
  53. .ValueGeneratedOnAdd();
  54. b.Property<string>("BCC");
  55. b.Property<string>("Body");
  56. b.Property<string>("CC");
  57. b.Property<string>("Comment");
  58. b.Property<DateTime>("Created");
  59. b.Property<bool>("IsBodyHtml");
  60. b.Property<bool>("IsDeleted");
  61. b.Property<DateTime>("Modified");
  62. b.Property<string>("ModifiedBy");
  63. b.Property<int>("SenderId");
  64. b.Property<string>("Subject");
  65. b.Property<string>("To");
  66. b.Property<string>("ToDisplay");
  67. b.HasKey("Id");
  68. b.HasIndex("SenderId");
  69. b.ToTable("Emails");
  70. });
  71. modelBuilder.Entity("UnivateProperties_API.Model.Communication.PlaceHolder", b =>
  72. {
  73. b.Property<int>("Id")
  74. .ValueGeneratedOnAdd();
  75. b.Property<string>("BoundTo");
  76. b.Property<string>("BoundToClass");
  77. b.Property<string>("BoundToClassDisplay");
  78. b.Property<DateTime>("Created");
  79. b.Property<bool>("IsDeleted");
  80. b.Property<DateTime>("Modified");
  81. b.Property<string>("ModifiedBy");
  82. b.Property<string>("Name");
  83. b.Property<int>("TemplateId");
  84. b.HasKey("Id");
  85. b.HasIndex("TemplateId");
  86. b.ToTable("PlaceHolders");
  87. });
  88. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPAccount", b =>
  89. {
  90. b.Property<int>("Id")
  91. .ValueGeneratedOnAdd();
  92. b.Property<string>("Address");
  93. b.Property<DateTime>("Created");
  94. b.Property<string>("DisplayName");
  95. b.Property<bool>("IsDeleted");
  96. b.Property<DateTime>("Modified");
  97. b.Property<string>("ModifiedBy");
  98. b.Property<int>("SMTPHostId");
  99. b.HasKey("Id");
  100. b.HasIndex("SMTPHostId");
  101. b.ToTable("Accounts");
  102. });
  103. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPHost", b =>
  104. {
  105. b.Property<int>("Id")
  106. .ValueGeneratedOnAdd();
  107. b.Property<DateTime>("Created");
  108. b.Property<string>("Host");
  109. b.Property<bool>("IsDeleted");
  110. b.Property<DateTime>("Modified");
  111. b.Property<string>("ModifiedBy");
  112. b.Property<bool>("NeedsAuthorize");
  113. b.Property<string>("Password");
  114. b.Property<bool>("UseSSL");
  115. b.Property<string>("User");
  116. b.HasKey("Id");
  117. b.ToTable("Hosts");
  118. });
  119. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Template", b =>
  120. {
  121. b.Property<int>("Id")
  122. .ValueGeneratedOnAdd();
  123. b.Property<string>("Body");
  124. b.Property<DateTime>("Created");
  125. b.Property<bool>("IsDeleted");
  126. b.Property<DateTime>("Modified");
  127. b.Property<string>("ModifiedBy");
  128. b.Property<string>("Name");
  129. b.Property<string>("Subject");
  130. b.HasKey("Id");
  131. b.ToTable("Templates");
  132. });
  133. modelBuilder.Entity("UnivateProperties_API.Model.Logging.SearchLog", b =>
  134. {
  135. b.Property<int>("Id")
  136. .ValueGeneratedOnAdd();
  137. b.Property<DateTime>("Created");
  138. b.Property<bool>("IsDeleted");
  139. b.Property<DateTime>("Modified");
  140. b.Property<string>("ModifiedBy");
  141. b.Property<string>("Search");
  142. b.Property<string>("Type");
  143. b.HasKey("Id");
  144. b.ToTable("SearchLogs");
  145. });
  146. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Address", b =>
  147. {
  148. b.Property<int>("Id")
  149. .ValueGeneratedOnAdd();
  150. b.Property<string>("City");
  151. b.Property<DateTime>("Created");
  152. b.Property<bool>("IsDeleted");
  153. b.Property<DateTime>("Modified");
  154. b.Property<string>("ModifiedBy");
  155. b.Property<int?>("OwnerId");
  156. b.Property<string>("PostalCode");
  157. b.Property<string>("Street");
  158. b.Property<string>("StreetNumber");
  159. b.Property<string>("Suburb");
  160. b.HasKey("Id");
  161. b.HasIndex("OwnerId");
  162. b.ToTable("Addresses");
  163. });
  164. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Carousel", b =>
  165. {
  166. b.Property<int>("Id")
  167. .ValueGeneratedOnAdd();
  168. b.Property<DateTime>("Created");
  169. b.Property<string>("Header");
  170. b.Property<string>("Image");
  171. b.Property<bool>("IsDeleted");
  172. b.Property<DateTime>("Modified");
  173. b.Property<string>("ModifiedBy");
  174. b.Property<int>("PropertyId");
  175. b.Property<int>("TimeshareId");
  176. b.HasKey("Id");
  177. b.ToTable("Carousel");
  178. });
  179. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Location", b =>
  180. {
  181. b.Property<int>("Id")
  182. .ValueGeneratedOnAdd();
  183. b.Property<DateTime>("Created");
  184. b.Property<bool>("IsDeleted");
  185. b.Property<bool>("IsTesting");
  186. b.Property<DateTime>("Modified");
  187. b.Property<string>("ModifiedBy");
  188. b.Property<string>("PropertyImageLocation");
  189. b.HasKey("Id");
  190. b.ToTable("Location");
  191. });
  192. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.BidItem", b =>
  193. {
  194. b.Property<int>("Id")
  195. .ValueGeneratedOnAdd();
  196. b.Property<double>("Amount");
  197. b.Property<int?>("BidMakerId");
  198. b.Property<string>("Comment");
  199. b.Property<DateTime>("Created");
  200. b.Property<string>("DeclinedReason");
  201. b.Property<bool>("IsDeleted");
  202. b.Property<DateTime>("Modified");
  203. b.Property<string>("ModifiedBy");
  204. b.Property<int?>("PropertyId");
  205. b.Property<int?>("StatusId");
  206. b.Property<int?>("TimeshareWeekId");
  207. b.HasKey("Id");
  208. b.HasIndex("BidMakerId");
  209. b.HasIndex("PropertyId");
  210. b.HasIndex("StatusId");
  211. b.HasIndex("TimeshareWeekId");
  212. b.ToTable("BidItems");
  213. });
  214. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.ProcessFlow", b =>
  215. {
  216. b.Property<int>("Id")
  217. .ValueGeneratedOnAdd();
  218. b.Property<DateTime>("Created");
  219. b.Property<bool>("IsDeleted");
  220. b.Property<DateTime>("Modified");
  221. b.Property<string>("ModifiedBy");
  222. b.Property<int?>("PropertyID");
  223. b.Property<int>("StatusID");
  224. b.Property<int?>("TimeshareID");
  225. b.HasKey("Id");
  226. b.HasIndex("PropertyID");
  227. b.HasIndex("StatusID");
  228. b.HasIndex("TimeshareID");
  229. b.ToTable("ProcessFlows");
  230. });
  231. modelBuilder.Entity("UnivateProperties_API.Model.Properties.Property", b =>
  232. {
  233. b.Property<int>("Id")
  234. .ValueGeneratedOnAdd();
  235. b.Property<string>("AddressLine1");
  236. b.Property<string>("AddressLine2");
  237. b.Property<string>("AddressLine3");
  238. b.Property<int?>("AgencyId");
  239. b.Property<int?>("AgentId");
  240. b.Property<int>("CityId");
  241. b.Property<DateTime>("Created");
  242. b.Property<string>("Description");
  243. b.Property<bool>("IsDeleted");
  244. b.Property<bool>("IsSale");
  245. b.Property<DateTime>("Modified");
  246. b.Property<string>("ModifiedBy");
  247. b.Property<decimal>("OperationalCosts");
  248. b.Property<int?>("OwnerId");
  249. b.Property<decimal>("Price");
  250. b.Property<string>("PricePer");
  251. b.Property<string>("PropertyName");
  252. b.Property<int>("PropertyTypeId");
  253. b.Property<int>("ProvinceId");
  254. b.Property<bool>("Published");
  255. b.Property<string>("ShortDescription");
  256. b.Property<int?>("StatusId");
  257. b.Property<int>("SuburbId");
  258. b.Property<string>("Unit");
  259. b.Property<string>("Video");
  260. b.Property<string>("VirtualTour");
  261. b.HasKey("Id");
  262. b.HasIndex("AgencyId");
  263. b.HasIndex("AgentId");
  264. b.HasIndex("CityId");
  265. b.HasIndex("OwnerId");
  266. b.HasIndex("PropertyTypeId");
  267. b.HasIndex("ProvinceId");
  268. b.HasIndex("StatusId");
  269. b.HasIndex("SuburbId");
  270. b.ToTable("Properties");
  271. });
  272. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyImage", b =>
  273. {
  274. b.Property<int>("Id")
  275. .ValueGeneratedOnAdd();
  276. b.Property<DateTime>("Created");
  277. b.Property<string>("Image");
  278. b.Property<bool>("IsDefault");
  279. b.Property<bool>("IsDeleted");
  280. b.Property<DateTime>("Modified");
  281. b.Property<string>("ModifiedBy");
  282. b.Property<int>("PropertyId");
  283. b.HasKey("Id");
  284. b.HasIndex("PropertyId");
  285. b.ToTable("PropertyImages");
  286. });
  287. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyType", b =>
  288. {
  289. b.Property<int>("Id")
  290. .ValueGeneratedOnAdd();
  291. b.Property<DateTime>("Created");
  292. b.Property<string>("Description");
  293. b.Property<bool>("IsDeleted");
  294. b.Property<DateTime>("Modified");
  295. b.Property<string>("ModifiedBy");
  296. b.Property<int>("UsageType");
  297. b.HasKey("Id");
  298. b.ToTable("PropertyTypes");
  299. });
  300. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyUserField", b =>
  301. {
  302. b.Property<int>("Id")
  303. .ValueGeneratedOnAdd();
  304. b.Property<DateTime>("Created");
  305. b.Property<string>("Description");
  306. b.Property<bool>("IsDeleted");
  307. b.Property<DateTime>("Modified");
  308. b.Property<string>("ModifiedBy");
  309. b.Property<int>("PropertyId");
  310. b.Property<int>("UserDefinedFieldId");
  311. b.Property<string>("Value");
  312. b.HasKey("Id");
  313. b.HasIndex("PropertyId");
  314. b.HasIndex("UserDefinedFieldId");
  315. b.ToTable("PropertyUserFields");
  316. });
  317. modelBuilder.Entity("UnivateProperties_API.Model.Properties.UserDefinedField", b =>
  318. {
  319. b.Property<int>("Id")
  320. .ValueGeneratedOnAdd();
  321. b.Property<DateTime>("Created");
  322. b.Property<string>("FieldName");
  323. b.Property<string>("FieldType");
  324. b.Property<int>("GroupId");
  325. b.Property<bool>("IsDeleted");
  326. b.Property<DateTime>("Modified");
  327. b.Property<string>("ModifiedBy");
  328. b.Property<int>("Rank");
  329. b.HasKey("Id");
  330. b.HasIndex("GroupId");
  331. b.ToTable("UserDefinedFields");
  332. });
  333. modelBuilder.Entity("UnivateProperties_API.Model.Properties.UserDefinedGroup", b =>
  334. {
  335. b.Property<int>("Id")
  336. .ValueGeneratedOnAdd();
  337. b.Property<DateTime>("Created");
  338. b.Property<string>("Description");
  339. b.Property<bool>("IsDeleted");
  340. b.Property<DateTime>("Modified");
  341. b.Property<string>("ModifiedBy");
  342. b.Property<int>("Rank");
  343. b.Property<int>("UsageType");
  344. b.HasKey("Id");
  345. b.ToTable("UserDefinedGroups");
  346. });
  347. modelBuilder.Entity("UnivateProperties_API.Model.Region.City", b =>
  348. {
  349. b.Property<int>("Id")
  350. .ValueGeneratedOnAdd();
  351. b.Property<string>("Code");
  352. b.Property<DateTime>("Created");
  353. b.Property<string>("Description");
  354. b.Property<bool>("IsDeleted");
  355. b.Property<DateTime>("Modified");
  356. b.Property<string>("ModifiedBy");
  357. b.Property<int>("ProvinceId");
  358. b.HasKey("Id");
  359. b.HasIndex("ProvinceId");
  360. b.ToTable("Cities");
  361. });
  362. modelBuilder.Entity("UnivateProperties_API.Model.Region.Province", b =>
  363. {
  364. b.Property<int>("Id")
  365. .ValueGeneratedOnAdd();
  366. b.Property<string>("Code");
  367. b.Property<DateTime>("Created");
  368. b.Property<string>("Description");
  369. b.Property<bool>("IsDeleted");
  370. b.Property<DateTime>("Modified");
  371. b.Property<string>("ModifiedBy");
  372. b.HasKey("Id");
  373. b.ToTable("Provinces");
  374. });
  375. modelBuilder.Entity("UnivateProperties_API.Model.Region.Suburb", b =>
  376. {
  377. b.Property<int>("Id")
  378. .ValueGeneratedOnAdd();
  379. b.Property<int>("CityId");
  380. b.Property<DateTime>("Created");
  381. b.Property<string>("Description");
  382. b.Property<bool>("IsDeleted");
  383. b.Property<DateTime>("Modified");
  384. b.Property<string>("ModifiedBy");
  385. b.Property<string>("PostalCode");
  386. b.HasKey("Id");
  387. b.HasIndex("CityId");
  388. b.ToTable("Suburbs");
  389. });
  390. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.Season", b =>
  391. {
  392. b.Property<int>("Id")
  393. .ValueGeneratedOnAdd();
  394. b.Property<DateTime>("Created");
  395. b.Property<bool>("IsDeleted");
  396. b.Property<DateTime>("Modified");
  397. b.Property<string>("ModifiedBy");
  398. b.Property<string>("Name");
  399. b.HasKey("Id");
  400. b.ToTable("Seasons");
  401. });
  402. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.Status", b =>
  403. {
  404. b.Property<int>("Id")
  405. .ValueGeneratedOnAdd();
  406. b.Property<string>("Code");
  407. b.Property<DateTime>("Created");
  408. b.Property<string>("Description");
  409. b.Property<bool>("IsDeleted");
  410. b.Property<DateTime>("Modified");
  411. b.Property<string>("ModifiedBy");
  412. b.Property<int>("StatusType");
  413. b.HasKey("Id");
  414. b.ToTable("Status");
  415. });
  416. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.TimeshareWeek", b =>
  417. {
  418. b.Property<int>("Id")
  419. .ValueGeneratedOnAdd();
  420. b.Property<int?>("AgencyId");
  421. b.Property<bool>("AgentAsRep");
  422. b.Property<double>("AgentCommision");
  423. b.Property<int?>("AgentId");
  424. b.Property<DateTime>("ArrivalDate");
  425. b.Property<string>("BankedWith");
  426. b.Property<int>("Bedrooms");
  427. b.Property<DateTime>("Created");
  428. b.Property<bool>("CurrentYearBanked");
  429. b.Property<DateTime>("DepartureDate");
  430. b.Property<bool>("IsDeleted");
  431. b.Property<bool>("LeviesPaidInFull");
  432. b.Property<double>("LevyAmount");
  433. b.Property<string>("Mandate");
  434. b.Property<int>("MaxSleep");
  435. b.Property<DateTime>("Modified");
  436. b.Property<string>("ModifiedBy");
  437. b.Property<string>("Module");
  438. b.Property<DateTime>("OriginalPurchaseDate");
  439. b.Property<double>("OriginalPurchasePrice");
  440. b.Property<bool>("OtherResort");
  441. b.Property<string>("OtherResortName");
  442. b.Property<int>("OwnerId");
  443. b.Property<bool>("ReferedByAgent");
  444. b.Property<int>("RegionId");
  445. b.Property<string>("ResortCode");
  446. b.Property<string>("ResortName");
  447. b.Property<string>("Season");
  448. b.Property<double>("SellPrice");
  449. b.Property<int>("StatusId");
  450. b.Property<string>("UnitNumber");
  451. b.Property<string>("WeekNumber");
  452. b.Property<bool>("WeekPlacedForRental");
  453. b.HasKey("Id");
  454. b.HasIndex("AgencyId");
  455. b.HasIndex("AgentId");
  456. b.HasIndex("OwnerId");
  457. b.HasIndex("RegionId");
  458. b.HasIndex("StatusId");
  459. b.ToTable("Weeks");
  460. });
  461. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfiguration", b =>
  462. {
  463. b.Property<int>("Id")
  464. .ValueGeneratedOnAdd();
  465. b.Property<int>("Adults");
  466. b.Property<int>("Bedrooms");
  467. b.Property<int>("Children");
  468. b.Property<string>("Code");
  469. b.Property<DateTime>("Created");
  470. b.Property<bool>("IsDeleted");
  471. b.Property<DateTime>("Modified");
  472. b.Property<string>("ModifiedBy");
  473. b.HasKey("Id");
  474. b.HasIndex("Code")
  475. .IsUnique();
  476. b.ToTable("UnitConfigurations");
  477. });
  478. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfigurationType", b =>
  479. {
  480. b.Property<int>("Id")
  481. .ValueGeneratedOnAdd();
  482. b.Property<DateTime>("Created");
  483. b.Property<string>("Description");
  484. b.Property<bool>("IsDeleted");
  485. b.Property<DateTime>("Modified");
  486. b.Property<string>("ModifiedBy");
  487. b.Property<int>("UnitConfigurationId");
  488. b.HasKey("Id");
  489. b.HasIndex("UnitConfigurationId");
  490. b.ToTable("UnitConfigurationTypes");
  491. });
  492. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agency", b =>
  493. {
  494. b.Property<int>("Id")
  495. .ValueGeneratedOnAdd();
  496. b.Property<string>("AgencyName");
  497. b.Property<string>("CompanyRegNumber");
  498. b.Property<DateTime>("Created");
  499. b.Property<string>("EAABEFFCNumber");
  500. b.Property<bool>("IsDeleted");
  501. b.Property<DateTime>("Modified");
  502. b.Property<string>("ModifiedBy");
  503. b.HasKey("Id");
  504. b.ToTable("Agencies");
  505. });
  506. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agent", b =>
  507. {
  508. b.Property<int>("Id")
  509. .ValueGeneratedOnAdd();
  510. b.Property<int?>("AgencyId");
  511. b.Property<string>("CellNumber");
  512. b.Property<DateTime>("Created");
  513. b.Property<string>("Email");
  514. b.Property<bool>("IsDeleted");
  515. b.Property<DateTime>("Modified");
  516. b.Property<string>("ModifiedBy");
  517. b.Property<string>("Name");
  518. b.Property<string>("Surname");
  519. b.Property<string>("Telephone");
  520. b.Property<int?>("UserId");
  521. b.HasKey("Id");
  522. b.HasIndex("AgencyId");
  523. b.HasIndex("UserId");
  524. b.ToTable("Agents");
  525. });
  526. modelBuilder.Entity("UnivateProperties_API.Model.Users.Individual", b =>
  527. {
  528. b.Property<int>("Id")
  529. .ValueGeneratedOnAdd();
  530. b.Property<int?>("AddressId");
  531. b.Property<int?>("BankAccountId");
  532. b.Property<string>("CellNumber");
  533. b.Property<string>("CompanyRegNumber");
  534. b.Property<DateTime>("Created");
  535. b.Property<string>("Email");
  536. b.Property<string>("IdNumber");
  537. b.Property<string>("IncomeTaxNumber");
  538. b.Property<bool>("IsDeleted");
  539. b.Property<string>("MaritalStatus");
  540. b.Property<DateTime>("Modified");
  541. b.Property<string>("ModifiedBy");
  542. b.Property<string>("Name");
  543. b.Property<string>("Surname");
  544. b.Property<string>("Telephone");
  545. b.Property<int?>("UserId");
  546. b.HasKey("Id");
  547. b.HasIndex("AddressId");
  548. b.HasIndex("BankAccountId");
  549. b.HasIndex("UserId");
  550. b.HasIndex("Telephone", "CellNumber", "Email")
  551. .IsUnique();
  552. b.ToTable("Individuals");
  553. });
  554. modelBuilder.Entity("UnivateProperties_API.Model.Users.Person", b =>
  555. {
  556. b.Property<int>("Id")
  557. .ValueGeneratedOnAdd();
  558. b.Property<string>("CellNumber");
  559. b.Property<DateTime>("Created");
  560. b.Property<string>("Email");
  561. b.Property<bool>("IsDeleted");
  562. b.Property<DateTime>("Modified");
  563. b.Property<string>("ModifiedBy");
  564. b.Property<string>("Name");
  565. b.Property<string>("Surname");
  566. b.Property<string>("Telephone");
  567. b.Property<int?>("UserId");
  568. b.HasKey("Id");
  569. b.HasIndex("UserId");
  570. b.ToTable("Person");
  571. });
  572. modelBuilder.Entity("UnivateProperties_API.Model.Users.User", b =>
  573. {
  574. b.Property<int>("Id")
  575. .ValueGeneratedOnAdd();
  576. b.Property<DateTime>("Created");
  577. b.Property<bool>("IsDeleted");
  578. b.Property<DateTime>("Modified");
  579. b.Property<string>("ModifiedBy");
  580. b.Property<byte[]>("PasswordHash");
  581. b.Property<byte[]>("PasswordSalt");
  582. b.Property<string>("Role");
  583. b.Property<string>("Token");
  584. b.Property<string>("Username");
  585. b.Property<bool>("Verified");
  586. b.HasKey("Id");
  587. b.HasIndex("Username")
  588. .IsUnique();
  589. b.ToTable("Users");
  590. });
  591. modelBuilder.Entity("UnivateProperties_API.Model.Banks.BankAccount", b =>
  592. {
  593. b.HasOne("UnivateProperties_API.Model.Banks.Bank", "Bank")
  594. .WithMany()
  595. .HasForeignKey("BankId");
  596. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  597. .WithMany()
  598. .HasForeignKey("OwnerId");
  599. });
  600. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Email", b =>
  601. {
  602. b.HasOne("UnivateProperties_API.Model.Communication.SMTPAccount", "Sender")
  603. .WithMany("Emails")
  604. .HasForeignKey("SenderId")
  605. .OnDelete(DeleteBehavior.Cascade);
  606. });
  607. modelBuilder.Entity("UnivateProperties_API.Model.Communication.PlaceHolder", b =>
  608. {
  609. b.HasOne("UnivateProperties_API.Model.Communication.Template", "Template")
  610. .WithMany("PlaceHolders")
  611. .HasForeignKey("TemplateId")
  612. .OnDelete(DeleteBehavior.Cascade);
  613. });
  614. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPAccount", b =>
  615. {
  616. b.HasOne("UnivateProperties_API.Model.Communication.SMTPHost", "SMTPHost")
  617. .WithMany("SMTPAccounts")
  618. .HasForeignKey("SMTPHostId")
  619. .OnDelete(DeleteBehavior.Cascade);
  620. });
  621. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Address", b =>
  622. {
  623. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  624. .WithMany()
  625. .HasForeignKey("OwnerId");
  626. });
  627. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.BidItem", b =>
  628. {
  629. b.HasOne("UnivateProperties_API.Model.Users.Individual", "BidMaker")
  630. .WithMany()
  631. .HasForeignKey("BidMakerId");
  632. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  633. .WithMany("BidItems")
  634. .HasForeignKey("PropertyId");
  635. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  636. .WithMany()
  637. .HasForeignKey("StatusId");
  638. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "TimeshareWeek")
  639. .WithMany("BidItems")
  640. .HasForeignKey("TimeshareWeekId");
  641. });
  642. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.ProcessFlow", b =>
  643. {
  644. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  645. .WithMany("ProcessFlows")
  646. .HasForeignKey("PropertyID");
  647. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  648. .WithMany()
  649. .HasForeignKey("StatusID")
  650. .OnDelete(DeleteBehavior.Cascade);
  651. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "Timeshare")
  652. .WithMany("ProcessFlows")
  653. .HasForeignKey("TimeshareID");
  654. });
  655. modelBuilder.Entity("UnivateProperties_API.Model.Properties.Property", b =>
  656. {
  657. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  658. .WithMany("Properties")
  659. .HasForeignKey("AgencyId");
  660. b.HasOne("UnivateProperties_API.Model.Users.Agent", "Agent")
  661. .WithMany("Properties")
  662. .HasForeignKey("AgentId");
  663. b.HasOne("UnivateProperties_API.Model.Region.City", "City")
  664. .WithMany()
  665. .HasForeignKey("CityId")
  666. .OnDelete(DeleteBehavior.Cascade);
  667. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  668. .WithMany("Properties")
  669. .HasForeignKey("OwnerId");
  670. b.HasOne("UnivateProperties_API.Model.Properties.PropertyType", "PropertyType")
  671. .WithMany()
  672. .HasForeignKey("PropertyTypeId")
  673. .OnDelete(DeleteBehavior.Cascade);
  674. b.HasOne("UnivateProperties_API.Model.Region.Province", "Province")
  675. .WithMany()
  676. .HasForeignKey("ProvinceId")
  677. .OnDelete(DeleteBehavior.Cascade);
  678. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  679. .WithMany()
  680. .HasForeignKey("StatusId");
  681. b.HasOne("UnivateProperties_API.Model.Region.Suburb", "Suburb")
  682. .WithMany()
  683. .HasForeignKey("SuburbId")
  684. .OnDelete(DeleteBehavior.Cascade);
  685. });
  686. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyImage", b =>
  687. {
  688. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  689. .WithMany("PropertyImages")
  690. .HasForeignKey("PropertyId")
  691. .OnDelete(DeleteBehavior.Cascade);
  692. });
  693. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyUserField", b =>
  694. {
  695. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  696. .WithMany("PropertyUserFields")
  697. .HasForeignKey("PropertyId")
  698. .OnDelete(DeleteBehavior.Cascade);
  699. b.HasOne("UnivateProperties_API.Model.Properties.UserDefinedField", "UserDefinedField")
  700. .WithMany()
  701. .HasForeignKey("UserDefinedFieldId")
  702. .OnDelete(DeleteBehavior.Cascade);
  703. });
  704. modelBuilder.Entity("UnivateProperties_API.Model.Properties.UserDefinedField", b =>
  705. {
  706. b.HasOne("UnivateProperties_API.Model.Properties.UserDefinedGroup", "Group")
  707. .WithMany("Fields")
  708. .HasForeignKey("GroupId")
  709. .OnDelete(DeleteBehavior.Cascade);
  710. });
  711. modelBuilder.Entity("UnivateProperties_API.Model.Region.City", b =>
  712. {
  713. b.HasOne("UnivateProperties_API.Model.Region.Province", "Province")
  714. .WithMany()
  715. .HasForeignKey("ProvinceId")
  716. .OnDelete(DeleteBehavior.Cascade);
  717. });
  718. modelBuilder.Entity("UnivateProperties_API.Model.Region.Suburb", b =>
  719. {
  720. b.HasOne("UnivateProperties_API.Model.Region.City", "City")
  721. .WithMany()
  722. .HasForeignKey("CityId")
  723. .OnDelete(DeleteBehavior.Cascade);
  724. });
  725. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.TimeshareWeek", b =>
  726. {
  727. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  728. .WithMany()
  729. .HasForeignKey("AgencyId");
  730. b.HasOne("UnivateProperties_API.Model.Users.Agent", "Agent")
  731. .WithMany()
  732. .HasForeignKey("AgentId");
  733. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  734. .WithMany()
  735. .HasForeignKey("OwnerId")
  736. .OnDelete(DeleteBehavior.Cascade);
  737. b.HasOne("UnivateProperties_API.Model.Region.Province", "Region")
  738. .WithMany()
  739. .HasForeignKey("RegionId")
  740. .OnDelete(DeleteBehavior.Cascade);
  741. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  742. .WithMany()
  743. .HasForeignKey("StatusId")
  744. .OnDelete(DeleteBehavior.Cascade);
  745. });
  746. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfigurationType", b =>
  747. {
  748. b.HasOne("UnivateProperties_API.Model.Timeshare.UnitConfiguration", "UnitConfiguration")
  749. .WithMany("Types")
  750. .HasForeignKey("UnitConfigurationId")
  751. .OnDelete(DeleteBehavior.Cascade);
  752. });
  753. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agent", b =>
  754. {
  755. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  756. .WithMany("Agents")
  757. .HasForeignKey("AgencyId");
  758. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  759. .WithMany()
  760. .HasForeignKey("UserId");
  761. });
  762. modelBuilder.Entity("UnivateProperties_API.Model.Users.Individual", b =>
  763. {
  764. b.HasOne("UnivateProperties_API.Model.Misc.Address", "Address")
  765. .WithMany()
  766. .HasForeignKey("AddressId");
  767. b.HasOne("UnivateProperties_API.Model.Banks.BankAccount", "BankAccount")
  768. .WithMany()
  769. .HasForeignKey("BankAccountId");
  770. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  771. .WithMany()
  772. .HasForeignKey("UserId");
  773. });
  774. modelBuilder.Entity("UnivateProperties_API.Model.Users.Person", b =>
  775. {
  776. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  777. .WithMany()
  778. .HasForeignKey("UserId");
  779. });
  780. #pragma warning restore 612, 618
  781. }
  782. }
  783. }