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

20200914092358_Update.Designer.cs 53KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623
  1. // <auto-generated />
  2. using System;
  3. using Microsoft.EntityFrameworkCore;
  4. using Microsoft.EntityFrameworkCore.Infrastructure;
  5. using Microsoft.EntityFrameworkCore.Metadata;
  6. using Microsoft.EntityFrameworkCore.Migrations;
  7. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  8. using UnivateProperties_API.Context;
  9. namespace UnivateProperties_API.Migrations
  10. {
  11. [DbContext(typeof(DataContext))]
  12. [Migration("20200914092358_Update")]
  13. partial class Update
  14. {
  15. protected override void BuildTargetModel(ModelBuilder modelBuilder)
  16. {
  17. #pragma warning disable 612, 618
  18. modelBuilder
  19. .HasAnnotation("ProductVersion", "2.2.0-rtm-35687")
  20. .HasAnnotation("Relational:MaxIdentifierLength", 128)
  21. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  22. modelBuilder.Entity("UnivateProperties_API.Model.Banks.Bank", b =>
  23. {
  24. b.Property<int>("Id")
  25. .ValueGeneratedOnAdd()
  26. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  27. b.Property<DateTime>("Created");
  28. b.Property<bool>("IsDeleted");
  29. b.Property<DateTime>("Modified");
  30. b.Property<string>("ModifiedBy");
  31. b.Property<string>("Name");
  32. b.Property<string>("UniversalBranchCode");
  33. b.HasKey("Id");
  34. b.ToTable("Banks");
  35. });
  36. modelBuilder.Entity("UnivateProperties_API.Model.Banks.BankAccount", b =>
  37. {
  38. b.Property<int>("Id")
  39. .ValueGeneratedOnAdd()
  40. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  41. b.Property<string>("AccountHolder");
  42. b.Property<string>("AccountNumber");
  43. b.Property<int?>("BankId");
  44. b.Property<DateTime>("Created");
  45. b.Property<bool>("IsDeleted");
  46. b.Property<DateTime>("Modified");
  47. b.Property<string>("ModifiedBy");
  48. b.Property<int?>("OwnerId");
  49. b.HasKey("Id");
  50. b.HasIndex("BankId");
  51. b.HasIndex("OwnerId");
  52. b.ToTable("BankAccounts");
  53. });
  54. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.Campaign", b =>
  55. {
  56. b.Property<int>("Id")
  57. .ValueGeneratedOnAdd()
  58. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  59. b.Property<string>("Body");
  60. b.Property<DateTime>("Created");
  61. b.Property<DateTime>("EndDate");
  62. b.Property<bool>("IsDeleted");
  63. b.Property<string>("ItemBody");
  64. b.Property<int>("ItemsPerRow");
  65. b.Property<DateTime>("Modified");
  66. b.Property<string>("ModifiedBy");
  67. b.Property<string>("Name");
  68. b.Property<DateTime>("StartDate");
  69. b.Property<string>("Subject");
  70. b.HasKey("Id");
  71. b.ToTable("Campaigns");
  72. });
  73. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItem", b =>
  74. {
  75. b.Property<int>("Id")
  76. .ValueGeneratedOnAdd()
  77. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  78. b.Property<int>("CampaignId");
  79. b.Property<DateTime>("Created");
  80. b.Property<string>("Image");
  81. b.Property<bool>("IsDeleted");
  82. b.Property<DateTime>("Modified");
  83. b.Property<string>("ModifiedBy");
  84. b.Property<int>("WeekId");
  85. b.HasKey("Id");
  86. b.HasIndex("CampaignId");
  87. b.HasIndex("WeekId");
  88. b.ToTable("CampaignItems");
  89. });
  90. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItemPlaceHolder", b =>
  91. {
  92. b.Property<int>("Id")
  93. .ValueGeneratedOnAdd()
  94. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  95. b.Property<int>("CampaignItemId");
  96. b.Property<DateTime>("Created");
  97. b.Property<bool>("IsDeleted");
  98. b.Property<DateTime>("Modified");
  99. b.Property<string>("ModifiedBy");
  100. b.Property<string>("PlaceHolder");
  101. b.Property<string>("Value");
  102. b.HasKey("Id");
  103. b.HasIndex("CampaignItemId");
  104. b.ToTable("CampaignItemPlaceHolders");
  105. });
  106. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignPlaceHolder", b =>
  107. {
  108. b.Property<int>("Id")
  109. .ValueGeneratedOnAdd()
  110. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  111. b.Property<string>("BoundTo");
  112. b.Property<string>("BoundToClass");
  113. b.Property<string>("BoundToClassDisplay");
  114. b.Property<int>("CampaignId");
  115. b.Property<DateTime>("Created");
  116. b.Property<string>("Format");
  117. b.Property<bool>("IsDeleted");
  118. b.Property<DateTime>("Modified");
  119. b.Property<string>("ModifiedBy");
  120. b.Property<string>("Name");
  121. b.HasKey("Id");
  122. b.HasIndex("CampaignId");
  123. b.ToTable("CampaignPlaceHolders");
  124. });
  125. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Email", b =>
  126. {
  127. b.Property<int>("Id")
  128. .ValueGeneratedOnAdd()
  129. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  130. b.Property<string>("BCC");
  131. b.Property<string>("Body");
  132. b.Property<string>("CC");
  133. b.Property<string>("Comment");
  134. b.Property<DateTime>("Created");
  135. b.Property<bool>("IsBodyHtml");
  136. b.Property<bool>("IsDeleted");
  137. b.Property<DateTime>("Modified");
  138. b.Property<string>("ModifiedBy");
  139. b.Property<int>("SenderId");
  140. b.Property<string>("Subject");
  141. b.Property<string>("To");
  142. b.Property<string>("ToDisplay");
  143. b.HasKey("Id");
  144. b.HasIndex("SenderId");
  145. b.ToTable("Emails");
  146. });
  147. modelBuilder.Entity("UnivateProperties_API.Model.Communication.PlaceHolder", b =>
  148. {
  149. b.Property<int>("Id")
  150. .ValueGeneratedOnAdd()
  151. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  152. b.Property<string>("BoundTo");
  153. b.Property<string>("BoundToClass");
  154. b.Property<string>("BoundToClassDisplay");
  155. b.Property<DateTime>("Created");
  156. b.Property<bool>("IsDeleted");
  157. b.Property<DateTime>("Modified");
  158. b.Property<string>("ModifiedBy");
  159. b.Property<string>("Name");
  160. b.Property<int>("TemplateId");
  161. b.HasKey("Id");
  162. b.HasIndex("TemplateId");
  163. b.ToTable("PlaceHolders");
  164. });
  165. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPAccount", b =>
  166. {
  167. b.Property<int>("Id")
  168. .ValueGeneratedOnAdd()
  169. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  170. b.Property<string>("Address");
  171. b.Property<DateTime>("Created");
  172. b.Property<bool>("Default");
  173. b.Property<string>("DisplayName");
  174. b.Property<bool>("IsDeleted");
  175. b.Property<DateTime>("Modified");
  176. b.Property<string>("ModifiedBy");
  177. b.Property<int>("SMTPHostId");
  178. b.HasKey("Id");
  179. b.HasIndex("SMTPHostId");
  180. b.ToTable("Accounts");
  181. });
  182. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPHost", b =>
  183. {
  184. b.Property<int>("Id")
  185. .ValueGeneratedOnAdd()
  186. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  187. b.Property<DateTime>("Created");
  188. b.Property<string>("Host");
  189. b.Property<bool>("IsDeleted");
  190. b.Property<DateTime>("Modified");
  191. b.Property<string>("ModifiedBy");
  192. b.Property<bool>("NeedsAuthorize");
  193. b.Property<string>("Password");
  194. b.Property<bool>("UseSSL");
  195. b.Property<string>("User");
  196. b.HasKey("Id");
  197. b.ToTable("Hosts");
  198. });
  199. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Template", b =>
  200. {
  201. b.Property<int>("Id")
  202. .ValueGeneratedOnAdd()
  203. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  204. b.Property<string>("Body");
  205. b.Property<DateTime>("Created");
  206. b.Property<bool>("IsDeleted");
  207. b.Property<DateTime>("Modified");
  208. b.Property<string>("ModifiedBy");
  209. b.Property<string>("Name");
  210. b.Property<int?>("SenderId");
  211. b.Property<string>("Subject");
  212. b.HasKey("Id");
  213. b.HasIndex("SenderId");
  214. b.ToTable("Templates");
  215. });
  216. modelBuilder.Entity("UnivateProperties_API.Model.Financial.ListingFee", b =>
  217. {
  218. b.Property<int>("Id")
  219. .ValueGeneratedOnAdd()
  220. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  221. b.Property<double>("Amount");
  222. b.Property<DateTime>("Created");
  223. b.Property<bool>("IsDeleted");
  224. b.Property<DateTime>("Modified");
  225. b.Property<string>("ModifiedBy");
  226. b.Property<string>("Name");
  227. b.HasKey("Id");
  228. b.ToTable("ListingFees");
  229. });
  230. modelBuilder.Entity("UnivateProperties_API.Model.Financial.Payment", b =>
  231. {
  232. b.Property<int>("Id")
  233. .ValueGeneratedOnAdd()
  234. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  235. b.Property<decimal>("Amount");
  236. b.Property<DateTime>("Created");
  237. b.Property<int>("CreatedById");
  238. b.Property<bool>("IsDeleted");
  239. b.Property<DateTime>("Modified");
  240. b.Property<string>("ModifiedBy");
  241. b.Property<string>("PaymentStatus");
  242. b.Property<string>("PaymentToken");
  243. b.Property<int?>("PropertyId");
  244. b.Property<int?>("TimeshareWeekId");
  245. b.HasKey("Id");
  246. b.HasIndex("CreatedById");
  247. b.HasIndex("PropertyId");
  248. b.HasIndex("TimeshareWeekId");
  249. b.ToTable("Payments");
  250. });
  251. modelBuilder.Entity("UnivateProperties_API.Model.Logging.SearchLog", b =>
  252. {
  253. b.Property<int>("Id")
  254. .ValueGeneratedOnAdd()
  255. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  256. b.Property<DateTime>("Created");
  257. b.Property<bool>("IsDeleted");
  258. b.Property<DateTime>("Modified");
  259. b.Property<string>("ModifiedBy");
  260. b.Property<string>("Search");
  261. b.Property<string>("Type");
  262. b.HasKey("Id");
  263. b.ToTable("SearchLogs");
  264. });
  265. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Address", b =>
  266. {
  267. b.Property<int>("Id")
  268. .ValueGeneratedOnAdd()
  269. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  270. b.Property<string>("City");
  271. b.Property<DateTime>("Created");
  272. b.Property<bool>("IsDeleted");
  273. b.Property<DateTime>("Modified");
  274. b.Property<string>("ModifiedBy");
  275. b.Property<int?>("OwnerId");
  276. b.Property<string>("PostalCode");
  277. b.Property<string>("Province");
  278. b.Property<string>("Street");
  279. b.Property<string>("StreetNumber");
  280. b.Property<string>("Suburb");
  281. b.HasKey("Id");
  282. b.HasIndex("OwnerId");
  283. b.ToTable("Addresses");
  284. });
  285. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Carousel", b =>
  286. {
  287. b.Property<int>("Id")
  288. .ValueGeneratedOnAdd()
  289. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  290. b.Property<DateTime>("Created");
  291. b.Property<string>("Header");
  292. b.Property<string>("Image");
  293. b.Property<bool>("IsDeleted");
  294. b.Property<DateTime>("Modified");
  295. b.Property<string>("ModifiedBy");
  296. b.Property<int>("PropertyId");
  297. b.Property<int>("TimeshareId");
  298. b.HasKey("Id");
  299. b.ToTable("Carousel");
  300. });
  301. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Default", b =>
  302. {
  303. b.Property<string>("Id")
  304. .ValueGeneratedOnAdd();
  305. b.Property<string>("Value");
  306. b.HasKey("Id");
  307. b.ToTable("Defaults");
  308. });
  309. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Location", b =>
  310. {
  311. b.Property<int>("Id")
  312. .ValueGeneratedOnAdd()
  313. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  314. b.Property<DateTime>("Created");
  315. b.Property<bool>("IsDeleted");
  316. b.Property<bool>("IsTesting");
  317. b.Property<DateTime>("Modified");
  318. b.Property<string>("ModifiedBy");
  319. b.Property<string>("PropertyImageLocation");
  320. b.HasKey("Id");
  321. b.ToTable("Location");
  322. });
  323. modelBuilder.Entity("UnivateProperties_API.Model.Misc.PlaceHolderFormat", b =>
  324. {
  325. b.Property<int>("Id")
  326. .ValueGeneratedOnAdd()
  327. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  328. b.Property<DateTime>("Created");
  329. b.Property<string>("DisplayName");
  330. b.Property<string>("Format");
  331. b.Property<bool>("IsDeleted");
  332. b.Property<DateTime>("Modified");
  333. b.Property<string>("ModifiedBy");
  334. b.HasKey("Id");
  335. b.ToTable("PlaceHolderFormats");
  336. });
  337. modelBuilder.Entity("UnivateProperties_API.Model.Misc.TC", b =>
  338. {
  339. b.Property<int>("Id")
  340. .ValueGeneratedOnAdd()
  341. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  342. b.Property<DateTime>("Created");
  343. b.Property<bool>("IsDeleted");
  344. b.Property<DateTime>("Modified");
  345. b.Property<string>("ModifiedBy");
  346. b.Property<string>("TermsConditions");
  347. b.Property<string>("Version");
  348. b.HasKey("Id");
  349. b.ToTable("TermsConditions");
  350. });
  351. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.BidItem", b =>
  352. {
  353. b.Property<int>("Id")
  354. .ValueGeneratedOnAdd()
  355. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  356. b.Property<double>("Amount");
  357. b.Property<int?>("BidMakerId");
  358. b.Property<string>("Comment");
  359. b.Property<DateTime>("Created");
  360. b.Property<string>("DeclinedReason");
  361. b.Property<bool>("IsDeleted");
  362. b.Property<DateTime>("Modified");
  363. b.Property<string>("ModifiedBy");
  364. b.Property<int?>("PropertyId");
  365. b.Property<int?>("StatusId");
  366. b.Property<int?>("TimeshareWeekId");
  367. b.HasKey("Id");
  368. b.HasIndex("BidMakerId");
  369. b.HasIndex("PropertyId");
  370. b.HasIndex("StatusId");
  371. b.HasIndex("TimeshareWeekId");
  372. b.ToTable("BidItems");
  373. });
  374. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.ProcessFlow", b =>
  375. {
  376. b.Property<int>("Id")
  377. .ValueGeneratedOnAdd()
  378. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  379. b.Property<DateTime>("Created");
  380. b.Property<bool>("IsDeleted");
  381. b.Property<DateTime>("Modified");
  382. b.Property<string>("ModifiedBy");
  383. b.Property<int?>("PropertyID");
  384. b.Property<int>("StatusID");
  385. b.Property<int?>("TimeshareID");
  386. b.HasKey("Id");
  387. b.HasIndex("PropertyID");
  388. b.HasIndex("StatusID");
  389. b.HasIndex("TimeshareID");
  390. b.ToTable("ProcessFlows");
  391. });
  392. modelBuilder.Entity("UnivateProperties_API.Model.Properties.Property", b =>
  393. {
  394. b.Property<int>("Id")
  395. .ValueGeneratedOnAdd()
  396. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  397. b.Property<string>("AddressOther");
  398. b.Property<string>("AddressURL");
  399. b.Property<int?>("AgencyId");
  400. b.Property<int?>("AgentId");
  401. b.Property<string>("City");
  402. b.Property<string>("Country");
  403. b.Property<DateTime>("Created");
  404. b.Property<DateTime>("DateAvailable");
  405. b.Property<DateTime>("DatePublished");
  406. b.Property<string>("Description");
  407. b.Property<bool>("IsDeleted");
  408. b.Property<bool>("IsSale");
  409. b.Property<DateTime>("Modified");
  410. b.Property<string>("ModifiedBy");
  411. b.Property<decimal>("OperationalCosts");
  412. b.Property<int?>("OwnerId");
  413. b.Property<string>("PostalCode");
  414. b.Property<decimal>("Price");
  415. b.Property<string>("PricePer");
  416. b.Property<string>("PropertCoords");
  417. b.Property<string>("PropertyName");
  418. b.Property<string>("PropertyRef");
  419. b.Property<int>("PropertyTypeId");
  420. b.Property<string>("Province");
  421. b.Property<bool>("Published");
  422. b.Property<string>("ShortDescription");
  423. b.Property<bool>("ShowAddress");
  424. b.Property<DateTime>("StatusDate");
  425. b.Property<int?>("StatusId");
  426. b.Property<string>("StreetName");
  427. b.Property<string>("StreetNumber");
  428. b.Property<string>("Suburb");
  429. b.Property<string>("Unit");
  430. b.Property<string>("Video");
  431. b.Property<string>("VirtualTour");
  432. b.HasKey("Id");
  433. b.HasIndex("AgencyId");
  434. b.HasIndex("AgentId");
  435. b.HasIndex("OwnerId");
  436. b.HasIndex("PropertyTypeId");
  437. b.ToTable("Properties");
  438. });
  439. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyImage", b =>
  440. {
  441. b.Property<int>("Id")
  442. .ValueGeneratedOnAdd()
  443. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  444. b.Property<DateTime>("Created");
  445. b.Property<string>("Image");
  446. b.Property<bool>("IsDefault");
  447. b.Property<bool>("IsDeleted");
  448. b.Property<DateTime>("Modified");
  449. b.Property<string>("ModifiedBy");
  450. b.Property<int>("PropertyId");
  451. b.HasKey("Id");
  452. b.HasIndex("PropertyId");
  453. b.ToTable("PropertyImages");
  454. });
  455. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyType", b =>
  456. {
  457. b.Property<int>("Id")
  458. .ValueGeneratedOnAdd()
  459. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  460. b.Property<DateTime>("Created");
  461. b.Property<string>("Description");
  462. b.Property<bool>("IsDeleted");
  463. b.Property<DateTime>("Modified");
  464. b.Property<string>("ModifiedBy");
  465. b.Property<int>("UsageType");
  466. b.HasKey("Id");
  467. b.ToTable("PropertyTypes");
  468. });
  469. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyUserField", b =>
  470. {
  471. b.Property<int>("Id")
  472. .ValueGeneratedOnAdd()
  473. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  474. b.Property<DateTime>("Created");
  475. b.Property<string>("Description");
  476. b.Property<bool>("IsDeleted");
  477. b.Property<DateTime>("Modified");
  478. b.Property<string>("ModifiedBy");
  479. b.Property<int>("PropertyId");
  480. b.Property<int>("UserDefinedFieldId");
  481. b.Property<string>("Value");
  482. b.HasKey("Id");
  483. b.HasIndex("PropertyId");
  484. b.HasIndex("UserDefinedFieldId");
  485. b.ToTable("PropertyUserFields");
  486. });
  487. modelBuilder.Entity("UnivateProperties_API.Model.Properties.UserDefinedField", b =>
  488. {
  489. b.Property<int>("Id")
  490. .ValueGeneratedOnAdd()
  491. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  492. b.Property<DateTime>("Created");
  493. b.Property<string>("FieldName");
  494. b.Property<string>("FieldType");
  495. b.Property<int>("GroupId");
  496. b.Property<bool>("IsDeleted");
  497. b.Property<DateTime>("Modified");
  498. b.Property<string>("ModifiedBy");
  499. b.Property<int>("Rank");
  500. b.HasKey("Id");
  501. b.HasIndex("GroupId");
  502. b.ToTable("UserDefinedFields");
  503. });
  504. modelBuilder.Entity("UnivateProperties_API.Model.Properties.UserDefinedGroup", b =>
  505. {
  506. b.Property<int>("Id")
  507. .ValueGeneratedOnAdd()
  508. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  509. b.Property<DateTime>("Created");
  510. b.Property<string>("Description");
  511. b.Property<bool>("IsDeleted");
  512. b.Property<DateTime>("Modified");
  513. b.Property<string>("ModifiedBy");
  514. b.Property<int>("Rank");
  515. b.Property<int>("UsageType");
  516. b.HasKey("Id");
  517. b.ToTable("UserDefinedGroups");
  518. });
  519. modelBuilder.Entity("UnivateProperties_API.Model.Region.City", b =>
  520. {
  521. b.Property<int>("Id")
  522. .ValueGeneratedOnAdd()
  523. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  524. b.Property<string>("Code");
  525. b.Property<DateTime>("Created");
  526. b.Property<string>("Description");
  527. b.Property<bool>("IsDeleted");
  528. b.Property<DateTime>("Modified");
  529. b.Property<string>("ModifiedBy");
  530. b.Property<int>("ProvinceId");
  531. b.HasKey("Id");
  532. b.HasIndex("ProvinceId");
  533. b.ToTable("Cities");
  534. });
  535. modelBuilder.Entity("UnivateProperties_API.Model.Region.Province", b =>
  536. {
  537. b.Property<int>("Id")
  538. .ValueGeneratedOnAdd()
  539. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  540. b.Property<string>("Code");
  541. b.Property<DateTime>("Created");
  542. b.Property<string>("Description");
  543. b.Property<bool>("IsDeleted");
  544. b.Property<DateTime>("Modified");
  545. b.Property<string>("ModifiedBy");
  546. b.HasKey("Id");
  547. b.ToTable("Provinces");
  548. });
  549. modelBuilder.Entity("UnivateProperties_API.Model.Region.Suburb", b =>
  550. {
  551. b.Property<int>("Id")
  552. .ValueGeneratedOnAdd()
  553. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  554. b.Property<int>("CityId");
  555. b.Property<DateTime>("Created");
  556. b.Property<string>("Description");
  557. b.Property<bool>("IsDeleted");
  558. b.Property<DateTime>("Modified");
  559. b.Property<string>("ModifiedBy");
  560. b.Property<string>("PostalCode");
  561. b.HasKey("Id");
  562. b.HasIndex("CityId");
  563. b.ToTable("Suburbs");
  564. });
  565. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.Season", b =>
  566. {
  567. b.Property<int>("Id")
  568. .ValueGeneratedOnAdd()
  569. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  570. b.Property<DateTime>("Created");
  571. b.Property<bool>("IsDeleted");
  572. b.Property<DateTime>("Modified");
  573. b.Property<string>("ModifiedBy");
  574. b.Property<string>("Name");
  575. b.HasKey("Id");
  576. b.ToTable("Seasons");
  577. });
  578. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.Status", b =>
  579. {
  580. b.Property<int>("Id")
  581. .ValueGeneratedOnAdd()
  582. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  583. b.Property<string>("Code");
  584. b.Property<DateTime>("Created");
  585. b.Property<string>("Description");
  586. b.Property<bool>("IsDeleted");
  587. b.Property<DateTime>("Modified");
  588. b.Property<string>("ModifiedBy");
  589. b.Property<int>("StatusType");
  590. b.HasKey("Id");
  591. b.ToTable("Status");
  592. });
  593. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.TimeshareWeek", b =>
  594. {
  595. b.Property<int>("Id")
  596. .ValueGeneratedOnAdd()
  597. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  598. b.Property<int?>("AgencyId");
  599. b.Property<bool>("AgentAsRep");
  600. b.Property<double>("AgentCommision");
  601. b.Property<int?>("AgentId");
  602. b.Property<DateTime>("ArrivalDate");
  603. b.Property<string>("BankedWith");
  604. b.Property<int>("Bedrooms");
  605. b.Property<DateTime>("Created");
  606. b.Property<bool>("CurrentYearBanked");
  607. b.Property<DateTime>("DateMandated");
  608. b.Property<DateTime>("DepartureDate");
  609. b.Property<bool>("IsDeleted");
  610. b.Property<bool>("LeviesPaidInFull");
  611. b.Property<double>("LevyAmount");
  612. b.Property<bool>("Mandate");
  613. b.Property<int>("MaxSleep");
  614. b.Property<DateTime>("Modified");
  615. b.Property<string>("ModifiedBy");
  616. b.Property<string>("Module");
  617. b.Property<DateTime>("OriginalPurchaseDate");
  618. b.Property<double>("OriginalPurchasePrice");
  619. b.Property<bool>("OtherResort");
  620. b.Property<string>("OtherResortName");
  621. b.Property<int>("OwnerId");
  622. b.Property<bool>("ReferedByAgent");
  623. b.Property<int>("RegionId");
  624. b.Property<string>("ResortCode");
  625. b.Property<string>("ResortName");
  626. b.Property<string>("Season");
  627. b.Property<double>("SellPrice");
  628. b.Property<int>("StatusId");
  629. b.Property<string>("UnitNumber");
  630. b.Property<string>("WeekNumber");
  631. b.Property<bool>("WeekPlacedForRental");
  632. b.Property<int>("WeekType");
  633. b.HasKey("Id");
  634. b.HasIndex("AgencyId");
  635. b.HasIndex("AgentId");
  636. b.HasIndex("OwnerId");
  637. b.HasIndex("RegionId");
  638. b.HasIndex("StatusId");
  639. b.ToTable("Weeks");
  640. });
  641. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfiguration", b =>
  642. {
  643. b.Property<int>("Id")
  644. .ValueGeneratedOnAdd()
  645. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  646. b.Property<int>("Adults");
  647. b.Property<int>("Bedrooms");
  648. b.Property<int>("Children");
  649. b.Property<string>("Code");
  650. b.Property<DateTime>("Created");
  651. b.Property<bool>("IsDeleted");
  652. b.Property<DateTime>("Modified");
  653. b.Property<string>("ModifiedBy");
  654. b.HasKey("Id");
  655. b.HasIndex("Code")
  656. .IsUnique()
  657. .HasFilter("[Code] IS NOT NULL");
  658. b.ToTable("UnitConfigurations");
  659. });
  660. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfigurationType", b =>
  661. {
  662. b.Property<int>("Id")
  663. .ValueGeneratedOnAdd()
  664. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  665. b.Property<DateTime>("Created");
  666. b.Property<string>("Description");
  667. b.Property<bool>("IsDeleted");
  668. b.Property<DateTime>("Modified");
  669. b.Property<string>("ModifiedBy");
  670. b.Property<int>("UnitConfigurationId");
  671. b.HasKey("Id");
  672. b.HasIndex("UnitConfigurationId");
  673. b.ToTable("UnitConfigurationTypes");
  674. });
  675. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agency", b =>
  676. {
  677. b.Property<int>("Id")
  678. .ValueGeneratedOnAdd()
  679. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  680. b.Property<string>("AgencyName");
  681. b.Property<string>("CompanyRegNumber");
  682. b.Property<DateTime>("Created");
  683. b.Property<string>("EAABEFFCNumber");
  684. b.Property<bool>("IsDeleted");
  685. b.Property<DateTime>("Modified");
  686. b.Property<string>("ModifiedBy");
  687. b.HasKey("Id");
  688. b.ToTable("Agencies");
  689. });
  690. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agent", b =>
  691. {
  692. b.Property<int>("Id")
  693. .ValueGeneratedOnAdd()
  694. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  695. b.Property<int?>("AgencyId");
  696. b.Property<string>("CellNumber");
  697. b.Property<DateTime>("Created");
  698. b.Property<string>("Email");
  699. b.Property<bool>("IsDeleted");
  700. b.Property<DateTime>("Modified");
  701. b.Property<string>("ModifiedBy");
  702. b.Property<string>("Name");
  703. b.Property<string>("Surname");
  704. b.Property<string>("Telephone");
  705. b.Property<int?>("TemplateId");
  706. b.Property<int?>("UserId");
  707. b.HasKey("Id");
  708. b.HasIndex("AgencyId");
  709. b.HasIndex("TemplateId");
  710. b.HasIndex("UserId");
  711. b.ToTable("Agents");
  712. });
  713. modelBuilder.Entity("UnivateProperties_API.Model.Users.Individual", b =>
  714. {
  715. b.Property<int>("Id")
  716. .ValueGeneratedOnAdd()
  717. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  718. b.Property<int?>("AddressId");
  719. b.Property<int?>("BankAccountId");
  720. b.Property<string>("CellNumber");
  721. b.Property<string>("CompanyRegNumber");
  722. b.Property<DateTime>("Created");
  723. b.Property<string>("Email");
  724. b.Property<int>("HowMarried");
  725. b.Property<string>("IdNumber");
  726. b.Property<string>("IncomeTaxNumber");
  727. b.Property<bool>("IsDeleted");
  728. b.Property<DateTime>("Modified");
  729. b.Property<string>("ModifiedBy");
  730. b.Property<string>("Name");
  731. b.Property<string>("SpouseCellnumber");
  732. b.Property<string>("SpouseEmail");
  733. b.Property<string>("SpouseName");
  734. b.Property<string>("SpouseSurname");
  735. b.Property<string>("SpouseTelephone");
  736. b.Property<string>("Surname");
  737. b.Property<string>("Telephone");
  738. b.Property<int?>("TemplateId");
  739. b.Property<int?>("UserId");
  740. b.HasKey("Id");
  741. b.HasIndex("AddressId");
  742. b.HasIndex("BankAccountId");
  743. b.HasIndex("TemplateId");
  744. b.HasIndex("UserId");
  745. b.HasIndex("Telephone", "CellNumber", "Email")
  746. .IsUnique()
  747. .HasFilter("[Telephone] IS NOT NULL AND [CellNumber] IS NOT NULL AND [Email] IS NOT NULL");
  748. b.ToTable("Individuals");
  749. });
  750. modelBuilder.Entity("UnivateProperties_API.Model.Users.Person", b =>
  751. {
  752. b.Property<int>("Id")
  753. .ValueGeneratedOnAdd()
  754. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  755. b.Property<string>("CellNumber");
  756. b.Property<DateTime>("Created");
  757. b.Property<string>("Email");
  758. b.Property<bool>("IsDeleted");
  759. b.Property<DateTime>("Modified");
  760. b.Property<string>("ModifiedBy");
  761. b.Property<string>("Name");
  762. b.Property<string>("Surname");
  763. b.Property<string>("Telephone");
  764. b.Property<int?>("UserId");
  765. b.HasKey("Id");
  766. b.HasIndex("UserId");
  767. b.ToTable("Person");
  768. });
  769. modelBuilder.Entity("UnivateProperties_API.Model.Users.User", b =>
  770. {
  771. b.Property<int>("Id")
  772. .ValueGeneratedOnAdd()
  773. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  774. b.Property<bool>("AcceptedTerms");
  775. b.Property<DateTime>("Created");
  776. b.Property<bool>("IsDeleted");
  777. b.Property<DateTime>("Modified");
  778. b.Property<string>("ModifiedBy");
  779. b.Property<byte[]>("PasswordHash");
  780. b.Property<byte[]>("PasswordSalt");
  781. b.Property<string>("Role");
  782. b.Property<string>("Token");
  783. b.Property<string>("Username");
  784. b.Property<bool>("Verified");
  785. b.HasKey("Id");
  786. b.HasIndex("Username")
  787. .IsUnique()
  788. .HasFilter("[Username] IS NOT NULL");
  789. b.ToTable("Users");
  790. });
  791. modelBuilder.Entity("UnivateProperties_API.Model.Banks.BankAccount", b =>
  792. {
  793. b.HasOne("UnivateProperties_API.Model.Banks.Bank", "Bank")
  794. .WithMany()
  795. .HasForeignKey("BankId");
  796. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  797. .WithMany()
  798. .HasForeignKey("OwnerId");
  799. });
  800. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItem", b =>
  801. {
  802. b.HasOne("UnivateProperties_API.Model.Campaigns.Campaign", "Campaign")
  803. .WithMany("Items")
  804. .HasForeignKey("CampaignId")
  805. .OnDelete(DeleteBehavior.Cascade);
  806. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "Week")
  807. .WithMany()
  808. .HasForeignKey("WeekId")
  809. .OnDelete(DeleteBehavior.Cascade);
  810. });
  811. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItemPlaceHolder", b =>
  812. {
  813. b.HasOne("UnivateProperties_API.Model.Campaigns.CampaignItem", "CampaignItem")
  814. .WithMany("CampaignItemPlaceHolder")
  815. .HasForeignKey("CampaignItemId")
  816. .OnDelete(DeleteBehavior.Cascade);
  817. });
  818. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignPlaceHolder", b =>
  819. {
  820. b.HasOne("UnivateProperties_API.Model.Campaigns.Campaign", "Campaign")
  821. .WithMany("PlaceHolders")
  822. .HasForeignKey("CampaignId")
  823. .OnDelete(DeleteBehavior.Cascade);
  824. });
  825. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Email", b =>
  826. {
  827. b.HasOne("UnivateProperties_API.Model.Communication.SMTPAccount", "Sender")
  828. .WithMany("Emails")
  829. .HasForeignKey("SenderId")
  830. .OnDelete(DeleteBehavior.Cascade);
  831. });
  832. modelBuilder.Entity("UnivateProperties_API.Model.Communication.PlaceHolder", b =>
  833. {
  834. b.HasOne("UnivateProperties_API.Model.Communication.Template", "Template")
  835. .WithMany("PlaceHolders")
  836. .HasForeignKey("TemplateId")
  837. .OnDelete(DeleteBehavior.Cascade);
  838. });
  839. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPAccount", b =>
  840. {
  841. b.HasOne("UnivateProperties_API.Model.Communication.SMTPHost", "SMTPHost")
  842. .WithMany("SMTPAccounts")
  843. .HasForeignKey("SMTPHostId")
  844. .OnDelete(DeleteBehavior.Cascade);
  845. });
  846. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Template", b =>
  847. {
  848. b.HasOne("UnivateProperties_API.Model.Communication.SMTPAccount", "Sender")
  849. .WithMany("Templates")
  850. .HasForeignKey("SenderId");
  851. });
  852. modelBuilder.Entity("UnivateProperties_API.Model.Financial.Payment", b =>
  853. {
  854. b.HasOne("UnivateProperties_API.Model.Users.User", "CreatedBy")
  855. .WithMany()
  856. .HasForeignKey("CreatedById")
  857. .OnDelete(DeleteBehavior.Cascade);
  858. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  859. .WithMany()
  860. .HasForeignKey("PropertyId");
  861. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "TimeshareWeek")
  862. .WithMany()
  863. .HasForeignKey("TimeshareWeekId");
  864. });
  865. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Address", b =>
  866. {
  867. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  868. .WithMany()
  869. .HasForeignKey("OwnerId");
  870. });
  871. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.BidItem", b =>
  872. {
  873. b.HasOne("UnivateProperties_API.Model.Users.Individual", "BidMaker")
  874. .WithMany()
  875. .HasForeignKey("BidMakerId");
  876. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  877. .WithMany("BidItems")
  878. .HasForeignKey("PropertyId");
  879. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  880. .WithMany()
  881. .HasForeignKey("StatusId");
  882. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "TimeshareWeek")
  883. .WithMany("BidItems")
  884. .HasForeignKey("TimeshareWeekId");
  885. });
  886. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.ProcessFlow", b =>
  887. {
  888. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  889. .WithMany("ProcessFlows")
  890. .HasForeignKey("PropertyID");
  891. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  892. .WithMany()
  893. .HasForeignKey("StatusID")
  894. .OnDelete(DeleteBehavior.Cascade);
  895. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "Timeshare")
  896. .WithMany("ProcessFlows")
  897. .HasForeignKey("TimeshareID");
  898. });
  899. modelBuilder.Entity("UnivateProperties_API.Model.Properties.Property", b =>
  900. {
  901. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  902. .WithMany("Properties")
  903. .HasForeignKey("AgencyId");
  904. b.HasOne("UnivateProperties_API.Model.Users.Agent", "Agent")
  905. .WithMany("Properties")
  906. .HasForeignKey("AgentId");
  907. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  908. .WithMany("Properties")
  909. .HasForeignKey("OwnerId");
  910. b.HasOne("UnivateProperties_API.Model.Properties.PropertyType", "PropertyType")
  911. .WithMany()
  912. .HasForeignKey("PropertyTypeId")
  913. .OnDelete(DeleteBehavior.Cascade);
  914. });
  915. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyImage", b =>
  916. {
  917. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  918. .WithMany("PropertyImages")
  919. .HasForeignKey("PropertyId")
  920. .OnDelete(DeleteBehavior.Cascade);
  921. });
  922. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyUserField", b =>
  923. {
  924. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  925. .WithMany("PropertyUserFields")
  926. .HasForeignKey("PropertyId")
  927. .OnDelete(DeleteBehavior.Cascade);
  928. b.HasOne("UnivateProperties_API.Model.Properties.UserDefinedField", "UserDefinedField")
  929. .WithMany()
  930. .HasForeignKey("UserDefinedFieldId")
  931. .OnDelete(DeleteBehavior.Cascade);
  932. });
  933. modelBuilder.Entity("UnivateProperties_API.Model.Properties.UserDefinedField", b =>
  934. {
  935. b.HasOne("UnivateProperties_API.Model.Properties.UserDefinedGroup", "Group")
  936. .WithMany("Fields")
  937. .HasForeignKey("GroupId")
  938. .OnDelete(DeleteBehavior.Cascade);
  939. });
  940. modelBuilder.Entity("UnivateProperties_API.Model.Region.City", b =>
  941. {
  942. b.HasOne("UnivateProperties_API.Model.Region.Province", "Province")
  943. .WithMany()
  944. .HasForeignKey("ProvinceId")
  945. .OnDelete(DeleteBehavior.Cascade);
  946. });
  947. modelBuilder.Entity("UnivateProperties_API.Model.Region.Suburb", b =>
  948. {
  949. b.HasOne("UnivateProperties_API.Model.Region.City", "City")
  950. .WithMany()
  951. .HasForeignKey("CityId")
  952. .OnDelete(DeleteBehavior.Cascade);
  953. });
  954. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.TimeshareWeek", b =>
  955. {
  956. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  957. .WithMany()
  958. .HasForeignKey("AgencyId");
  959. b.HasOne("UnivateProperties_API.Model.Users.Agent", "Agent")
  960. .WithMany()
  961. .HasForeignKey("AgentId");
  962. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  963. .WithMany()
  964. .HasForeignKey("OwnerId")
  965. .OnDelete(DeleteBehavior.Cascade);
  966. b.HasOne("UnivateProperties_API.Model.Region.Province", "Region")
  967. .WithMany()
  968. .HasForeignKey("RegionId")
  969. .OnDelete(DeleteBehavior.Cascade);
  970. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  971. .WithMany()
  972. .HasForeignKey("StatusId")
  973. .OnDelete(DeleteBehavior.Cascade);
  974. });
  975. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfigurationType", b =>
  976. {
  977. b.HasOne("UnivateProperties_API.Model.Timeshare.UnitConfiguration", "UnitConfiguration")
  978. .WithMany("Types")
  979. .HasForeignKey("UnitConfigurationId")
  980. .OnDelete(DeleteBehavior.Cascade);
  981. });
  982. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agent", b =>
  983. {
  984. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  985. .WithMany("Agents")
  986. .HasForeignKey("AgencyId");
  987. b.HasOne("UnivateProperties_API.Model.Communication.Template")
  988. .WithMany("AgentBCC")
  989. .HasForeignKey("TemplateId");
  990. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  991. .WithMany()
  992. .HasForeignKey("UserId");
  993. });
  994. modelBuilder.Entity("UnivateProperties_API.Model.Users.Individual", b =>
  995. {
  996. b.HasOne("UnivateProperties_API.Model.Misc.Address", "Address")
  997. .WithMany()
  998. .HasForeignKey("AddressId");
  999. b.HasOne("UnivateProperties_API.Model.Banks.BankAccount", "BankAccount")
  1000. .WithMany()
  1001. .HasForeignKey("BankAccountId");
  1002. b.HasOne("UnivateProperties_API.Model.Communication.Template")
  1003. .WithMany("IndividualBCC")
  1004. .HasForeignKey("TemplateId");
  1005. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  1006. .WithMany()
  1007. .HasForeignKey("UserId");
  1008. });
  1009. modelBuilder.Entity("UnivateProperties_API.Model.Users.Person", b =>
  1010. {
  1011. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  1012. .WithMany()
  1013. .HasForeignKey("UserId");
  1014. });
  1015. #pragma warning restore 612, 618
  1016. }
  1017. }
  1018. }