API
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

DataContextModelSnapshot.cs 54KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658
  1. // <auto-generated />
  2. using System;
  3. using Microsoft.EntityFrameworkCore;
  4. using Microsoft.EntityFrameworkCore.Infrastructure;
  5. using Microsoft.EntityFrameworkCore.Metadata;
  6. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  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("ProductVersion", "2.2.0-rtm-35687")
  18. .HasAnnotation("Relational:MaxIdentifierLength", 128)
  19. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  20. modelBuilder.Entity("UnivateProperties_API.Model.Banks.Bank", b =>
  21. {
  22. b.Property<int>("Id")
  23. .ValueGeneratedOnAdd()
  24. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  25. b.Property<DateTime>("Created");
  26. b.Property<bool>("IsDeleted");
  27. b.Property<DateTime>("Modified");
  28. b.Property<string>("ModifiedBy");
  29. b.Property<string>("Name");
  30. b.Property<string>("UniversalBranchCode");
  31. b.HasKey("Id");
  32. b.ToTable("Banks");
  33. });
  34. modelBuilder.Entity("UnivateProperties_API.Model.Banks.BankAccount", b =>
  35. {
  36. b.Property<int>("Id")
  37. .ValueGeneratedOnAdd()
  38. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  39. b.Property<string>("AccountHolder");
  40. b.Property<string>("AccountNumber");
  41. b.Property<int?>("BankId");
  42. b.Property<DateTime>("Created");
  43. b.Property<bool>("IsDeleted");
  44. b.Property<DateTime>("Modified");
  45. b.Property<string>("ModifiedBy");
  46. b.Property<int?>("OwnerId");
  47. b.HasKey("Id");
  48. b.HasIndex("BankId");
  49. b.HasIndex("OwnerId");
  50. b.ToTable("BankAccounts");
  51. });
  52. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.Campaign", b =>
  53. {
  54. b.Property<int>("Id")
  55. .ValueGeneratedOnAdd()
  56. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  57. b.Property<string>("Body");
  58. b.Property<DateTime>("Created");
  59. b.Property<DateTime>("EndDate");
  60. b.Property<bool>("IsDeleted");
  61. b.Property<string>("ItemBody");
  62. b.Property<int>("ItemsPerRow");
  63. b.Property<DateTime>("Modified");
  64. b.Property<string>("ModifiedBy");
  65. b.Property<string>("Name");
  66. b.Property<DateTime>("StartDate");
  67. b.Property<string>("Subject");
  68. b.HasKey("Id");
  69. b.ToTable("Campaigns");
  70. });
  71. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItem", b =>
  72. {
  73. b.Property<int>("Id")
  74. .ValueGeneratedOnAdd()
  75. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  76. b.Property<int>("CampaignId");
  77. b.Property<DateTime>("Created");
  78. b.Property<string>("Image");
  79. b.Property<bool>("IsDeleted");
  80. b.Property<DateTime>("Modified");
  81. b.Property<string>("ModifiedBy");
  82. b.Property<int>("WeekId");
  83. b.HasKey("Id");
  84. b.HasIndex("CampaignId");
  85. b.HasIndex("WeekId");
  86. b.ToTable("CampaignItems");
  87. });
  88. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItemPlaceHolder", b =>
  89. {
  90. b.Property<int>("Id")
  91. .ValueGeneratedOnAdd()
  92. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  93. b.Property<int>("CampaignItemId");
  94. b.Property<DateTime>("Created");
  95. b.Property<bool>("IsDeleted");
  96. b.Property<DateTime>("Modified");
  97. b.Property<string>("ModifiedBy");
  98. b.Property<string>("PlaceHolder");
  99. b.Property<string>("Value");
  100. b.HasKey("Id");
  101. b.HasIndex("CampaignItemId");
  102. b.ToTable("CampaignItemPlaceHolders");
  103. });
  104. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignPlaceHolder", b =>
  105. {
  106. b.Property<int>("Id")
  107. .ValueGeneratedOnAdd()
  108. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  109. b.Property<string>("BoundTo");
  110. b.Property<string>("BoundToClass");
  111. b.Property<string>("BoundToClassDisplay");
  112. b.Property<int>("CampaignId");
  113. b.Property<DateTime>("Created");
  114. b.Property<string>("Format");
  115. b.Property<bool>("IsDeleted");
  116. b.Property<DateTime>("Modified");
  117. b.Property<string>("ModifiedBy");
  118. b.Property<string>("Name");
  119. b.HasKey("Id");
  120. b.HasIndex("CampaignId");
  121. b.ToTable("CampaignPlaceHolders");
  122. });
  123. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Email", b =>
  124. {
  125. b.Property<int>("Id")
  126. .ValueGeneratedOnAdd()
  127. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  128. b.Property<string>("BCC");
  129. b.Property<string>("Body");
  130. b.Property<string>("CC");
  131. b.Property<string>("Comment");
  132. b.Property<DateTime>("Created");
  133. b.Property<bool>("IsBodyHtml");
  134. b.Property<bool>("IsDeleted");
  135. b.Property<DateTime>("Modified");
  136. b.Property<string>("ModifiedBy");
  137. b.Property<int>("SenderId");
  138. b.Property<string>("Subject");
  139. b.Property<string>("To");
  140. b.Property<string>("ToDisplay");
  141. b.HasKey("Id");
  142. b.HasIndex("SenderId");
  143. b.ToTable("Emails");
  144. });
  145. modelBuilder.Entity("UnivateProperties_API.Model.Communication.PlaceHolder", b =>
  146. {
  147. b.Property<int>("Id")
  148. .ValueGeneratedOnAdd()
  149. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  150. b.Property<string>("BoundTo");
  151. b.Property<string>("BoundToClass");
  152. b.Property<string>("BoundToClassDisplay");
  153. b.Property<DateTime>("Created");
  154. b.Property<bool>("IsDeleted");
  155. b.Property<DateTime>("Modified");
  156. b.Property<string>("ModifiedBy");
  157. b.Property<string>("Name");
  158. b.Property<int>("TemplateId");
  159. b.HasKey("Id");
  160. b.HasIndex("TemplateId");
  161. b.ToTable("PlaceHolders");
  162. });
  163. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPAccount", b =>
  164. {
  165. b.Property<int>("Id")
  166. .ValueGeneratedOnAdd()
  167. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  168. b.Property<string>("Address");
  169. b.Property<DateTime>("Created");
  170. b.Property<bool>("Default");
  171. b.Property<string>("DisplayName");
  172. b.Property<bool>("IsDeleted");
  173. b.Property<DateTime>("Modified");
  174. b.Property<string>("ModifiedBy");
  175. b.Property<int>("SMTPHostId");
  176. b.HasKey("Id");
  177. b.HasIndex("SMTPHostId");
  178. b.ToTable("Accounts");
  179. });
  180. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPHost", b =>
  181. {
  182. b.Property<int>("Id")
  183. .ValueGeneratedOnAdd()
  184. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  185. b.Property<DateTime>("Created");
  186. b.Property<string>("Host");
  187. b.Property<bool>("IsDeleted");
  188. b.Property<DateTime>("Modified");
  189. b.Property<string>("ModifiedBy");
  190. b.Property<bool>("NeedsAuthorize");
  191. b.Property<string>("Password");
  192. b.Property<bool>("UseSSL");
  193. b.Property<string>("User");
  194. b.HasKey("Id");
  195. b.ToTable("Hosts");
  196. });
  197. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Template", b =>
  198. {
  199. b.Property<int>("Id")
  200. .ValueGeneratedOnAdd()
  201. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  202. b.Property<string>("Body");
  203. b.Property<DateTime>("Created");
  204. b.Property<bool>("IsDeleted");
  205. b.Property<DateTime>("Modified");
  206. b.Property<string>("ModifiedBy");
  207. b.Property<string>("Name");
  208. b.Property<int?>("SenderId");
  209. b.Property<string>("Subject");
  210. b.HasKey("Id");
  211. b.HasIndex("SenderId");
  212. b.ToTable("Templates");
  213. });
  214. modelBuilder.Entity("UnivateProperties_API.Model.Financial.ListingFee", b =>
  215. {
  216. b.Property<int>("Id")
  217. .ValueGeneratedOnAdd()
  218. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  219. b.Property<double>("Amount");
  220. b.Property<DateTime>("Created");
  221. b.Property<bool>("IsDeleted");
  222. b.Property<DateTime>("Modified");
  223. b.Property<string>("ModifiedBy");
  224. b.Property<string>("Name");
  225. b.HasKey("Id");
  226. b.ToTable("ListingFees");
  227. });
  228. modelBuilder.Entity("UnivateProperties_API.Model.Financial.Payment", b =>
  229. {
  230. b.Property<int>("Id")
  231. .ValueGeneratedOnAdd()
  232. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  233. b.Property<decimal>("Amount");
  234. b.Property<DateTime>("Created");
  235. b.Property<int>("CreatedById");
  236. b.Property<bool>("IsDeleted");
  237. b.Property<DateTime>("Modified");
  238. b.Property<string>("ModifiedBy");
  239. b.Property<string>("PaymentStatus");
  240. b.Property<string>("PaymentToken");
  241. b.Property<int?>("PropertyId");
  242. b.Property<int?>("TimeshareWeekId");
  243. b.HasKey("Id");
  244. b.HasIndex("CreatedById");
  245. b.HasIndex("PropertyId");
  246. b.HasIndex("TimeshareWeekId");
  247. b.ToTable("Payments");
  248. });
  249. modelBuilder.Entity("UnivateProperties_API.Model.Logging.SearchLog", b =>
  250. {
  251. b.Property<int>("Id")
  252. .ValueGeneratedOnAdd()
  253. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  254. b.Property<DateTime>("Created");
  255. b.Property<bool>("IsDeleted");
  256. b.Property<DateTime>("Modified");
  257. b.Property<string>("ModifiedBy");
  258. b.Property<string>("Search");
  259. b.Property<string>("Type");
  260. b.HasKey("Id");
  261. b.ToTable("SearchLogs");
  262. });
  263. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Address", b =>
  264. {
  265. b.Property<int>("Id")
  266. .ValueGeneratedOnAdd()
  267. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  268. b.Property<string>("City");
  269. b.Property<DateTime>("Created");
  270. b.Property<bool>("IsDeleted");
  271. b.Property<DateTime>("Modified");
  272. b.Property<string>("ModifiedBy");
  273. b.Property<int?>("OwnerId");
  274. b.Property<string>("PostalCode");
  275. b.Property<string>("Province");
  276. b.Property<string>("Street");
  277. b.Property<string>("StreetNumber");
  278. b.Property<string>("Suburb");
  279. b.HasKey("Id");
  280. b.HasIndex("OwnerId");
  281. b.ToTable("Addresses");
  282. });
  283. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Carousel", b =>
  284. {
  285. b.Property<int>("Id")
  286. .ValueGeneratedOnAdd()
  287. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  288. b.Property<DateTime>("Created");
  289. b.Property<string>("Header");
  290. b.Property<string>("Image");
  291. b.Property<bool>("IsDeleted");
  292. b.Property<DateTime>("Modified");
  293. b.Property<string>("ModifiedBy");
  294. b.Property<int>("PropertyId");
  295. b.Property<int>("TimeshareId");
  296. b.HasKey("Id");
  297. b.ToTable("Carousel");
  298. });
  299. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Default", b =>
  300. {
  301. b.Property<string>("Id")
  302. .ValueGeneratedOnAdd();
  303. b.Property<string>("Value");
  304. b.HasKey("Id");
  305. b.ToTable("Defaults");
  306. });
  307. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Location", b =>
  308. {
  309. b.Property<int>("Id")
  310. .ValueGeneratedOnAdd()
  311. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  312. b.Property<DateTime>("Created");
  313. b.Property<bool>("IsDeleted");
  314. b.Property<bool>("IsTesting");
  315. b.Property<DateTime>("Modified");
  316. b.Property<string>("ModifiedBy");
  317. b.Property<string>("PropertyImageLocation");
  318. b.HasKey("Id");
  319. b.ToTable("Location");
  320. });
  321. modelBuilder.Entity("UnivateProperties_API.Model.Misc.PlaceHolderFormat", b =>
  322. {
  323. b.Property<int>("Id")
  324. .ValueGeneratedOnAdd()
  325. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  326. b.Property<DateTime>("Created");
  327. b.Property<string>("DisplayName");
  328. b.Property<string>("Format");
  329. b.Property<bool>("IsDeleted");
  330. b.Property<DateTime>("Modified");
  331. b.Property<string>("ModifiedBy");
  332. b.HasKey("Id");
  333. b.ToTable("PlaceHolderFormats");
  334. });
  335. modelBuilder.Entity("UnivateProperties_API.Model.Misc.TC", b =>
  336. {
  337. b.Property<int>("Id")
  338. .ValueGeneratedOnAdd()
  339. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  340. b.Property<DateTime>("Created");
  341. b.Property<bool>("IsDeleted");
  342. b.Property<DateTime>("Modified");
  343. b.Property<string>("ModifiedBy");
  344. b.Property<string>("TermsConditions");
  345. b.Property<string>("Version");
  346. b.HasKey("Id");
  347. b.ToTable("TermsConditions");
  348. });
  349. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.BidItem", b =>
  350. {
  351. b.Property<int>("Id")
  352. .ValueGeneratedOnAdd()
  353. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  354. b.Property<double>("Amount");
  355. b.Property<int?>("BidMakerId");
  356. b.Property<string>("Comment");
  357. b.Property<DateTime>("Created");
  358. b.Property<string>("DeclinedReason");
  359. b.Property<bool>("IsDeleted");
  360. b.Property<DateTime>("Modified");
  361. b.Property<string>("ModifiedBy");
  362. b.Property<int?>("PropertyId");
  363. b.Property<int?>("StatusId");
  364. b.Property<int?>("TimeshareWeekId");
  365. b.HasKey("Id");
  366. b.HasIndex("BidMakerId");
  367. b.HasIndex("PropertyId");
  368. b.HasIndex("StatusId");
  369. b.HasIndex("TimeshareWeekId");
  370. b.ToTable("BidItems");
  371. });
  372. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.ProcessFlow", b =>
  373. {
  374. b.Property<int>("Id")
  375. .ValueGeneratedOnAdd()
  376. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  377. b.Property<DateTime>("Created");
  378. b.Property<bool>("IsDeleted");
  379. b.Property<DateTime>("Modified");
  380. b.Property<string>("ModifiedBy");
  381. b.Property<int?>("PropertyID");
  382. b.Property<int>("StatusID");
  383. b.Property<int?>("TimeshareID");
  384. b.HasKey("Id");
  385. b.HasIndex("PropertyID");
  386. b.HasIndex("StatusID");
  387. b.HasIndex("TimeshareID");
  388. b.ToTable("ProcessFlows");
  389. });
  390. modelBuilder.Entity("UnivateProperties_API.Model.Properties.Property", b =>
  391. {
  392. b.Property<int>("Id")
  393. .ValueGeneratedOnAdd()
  394. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  395. b.Property<string>("AddressOther");
  396. b.Property<string>("AddressURL");
  397. b.Property<int?>("AgencyId");
  398. b.Property<int?>("AgentId");
  399. b.Property<string>("City");
  400. b.Property<string>("Country");
  401. b.Property<DateTime>("Created");
  402. b.Property<DateTime>("CutOffDisplayDate");
  403. b.Property<DateTime>("DateAvailable");
  404. b.Property<DateTime>("DatePublished");
  405. b.Property<string>("Description");
  406. b.Property<bool>("IsDeleted");
  407. b.Property<bool>("IsSale");
  408. b.Property<DateTime>("Modified");
  409. b.Property<string>("ModifiedBy");
  410. b.Property<decimal>("OperationalCosts");
  411. b.Property<int?>("OwnerId");
  412. b.Property<string>("PostalCode");
  413. b.Property<decimal>("Price");
  414. b.Property<string>("PricePer");
  415. b.Property<bool>("PriceRedused");
  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<double>("AskingPrice");
  604. b.Property<string>("BankedWith");
  605. b.Property<int>("Bedrooms");
  606. b.Property<DateTime>("Created");
  607. b.Property<bool>("CurrentYearBanked");
  608. b.Property<DateTime>("DateMandated");
  609. b.Property<DateTime>("DepartureDate");
  610. b.Property<bool>("IsDeleted");
  611. b.Property<bool>("LeviesPaidInFull");
  612. b.Property<double>("LevyAmount");
  613. b.Property<bool>("Mandate");
  614. b.Property<int>("MaxSleep");
  615. b.Property<DateTime>("Modified");
  616. b.Property<string>("ModifiedBy");
  617. b.Property<string>("Module");
  618. b.Property<DateTime>("OriginalPurchaseDate");
  619. b.Property<double>("OriginalPurchasePrice");
  620. b.Property<bool>("OtherResort");
  621. b.Property<string>("OtherResortName");
  622. b.Property<int>("OwnerId");
  623. b.Property<bool>("Publish");
  624. b.Property<DateTime>("PulbishedDate");
  625. b.Property<bool>("ReferedByAgent");
  626. b.Property<int>("RegionId");
  627. b.Property<string>("ResortCode");
  628. b.Property<string>("ResortName");
  629. b.Property<string>("Season");
  630. b.Property<double>("SellPrice");
  631. b.Property<int>("StatusId");
  632. b.Property<string>("UnitNumber");
  633. b.Property<string>("WeekNumber");
  634. b.Property<bool>("WeekPlacedForRental");
  635. b.Property<string>("WeekStatus");
  636. b.Property<int>("WeekType");
  637. b.HasKey("Id");
  638. b.HasIndex("AgencyId");
  639. b.HasIndex("AgentId");
  640. b.HasIndex("OwnerId");
  641. b.HasIndex("RegionId");
  642. b.HasIndex("StatusId");
  643. b.ToTable("Weeks");
  644. });
  645. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfiguration", b =>
  646. {
  647. b.Property<int>("Id")
  648. .ValueGeneratedOnAdd()
  649. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  650. b.Property<int>("Adults");
  651. b.Property<int>("Bedrooms");
  652. b.Property<int>("Children");
  653. b.Property<string>("Code");
  654. b.Property<DateTime>("Created");
  655. b.Property<bool>("IsDeleted");
  656. b.Property<DateTime>("Modified");
  657. b.Property<string>("ModifiedBy");
  658. b.HasKey("Id");
  659. b.HasIndex("Code")
  660. .IsUnique()
  661. .HasFilter("[Code] IS NOT NULL");
  662. b.ToTable("UnitConfigurations");
  663. });
  664. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfigurationType", b =>
  665. {
  666. b.Property<int>("Id")
  667. .ValueGeneratedOnAdd()
  668. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  669. b.Property<DateTime>("Created");
  670. b.Property<string>("Description");
  671. b.Property<bool>("IsDeleted");
  672. b.Property<DateTime>("Modified");
  673. b.Property<string>("ModifiedBy");
  674. b.Property<int>("UnitConfigurationId");
  675. b.HasKey("Id");
  676. b.HasIndex("UnitConfigurationId");
  677. b.ToTable("UnitConfigurationTypes");
  678. });
  679. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agency", b =>
  680. {
  681. b.Property<int>("Id")
  682. .ValueGeneratedOnAdd()
  683. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  684. b.Property<string>("AgencyName");
  685. b.Property<string>("CompanyRegNumber");
  686. b.Property<DateTime>("Created");
  687. b.Property<string>("EAABEFFCNumber");
  688. b.Property<bool>("IsDeleted");
  689. b.Property<DateTime>("Modified");
  690. b.Property<string>("ModifiedBy");
  691. b.HasKey("Id");
  692. b.ToTable("Agencies");
  693. });
  694. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agent", b =>
  695. {
  696. b.Property<int>("Id")
  697. .ValueGeneratedOnAdd()
  698. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  699. b.Property<int?>("AgencyId");
  700. b.Property<string>("CellNumber");
  701. b.Property<DateTime>("Created");
  702. b.Property<string>("Email");
  703. b.Property<bool>("IsDeleted");
  704. b.Property<DateTime>("Modified");
  705. b.Property<string>("ModifiedBy");
  706. b.Property<string>("Name");
  707. b.Property<string>("Surname");
  708. b.Property<string>("Telephone");
  709. b.Property<int?>("TemplateId");
  710. b.Property<int?>("UserId");
  711. b.HasKey("Id");
  712. b.HasIndex("AgencyId");
  713. b.HasIndex("TemplateId");
  714. b.HasIndex("UserId");
  715. b.ToTable("Agents");
  716. });
  717. modelBuilder.Entity("UnivateProperties_API.Model.Users.Individual", b =>
  718. {
  719. b.Property<int>("Id")
  720. .ValueGeneratedOnAdd()
  721. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  722. b.Property<int?>("AddressId");
  723. b.Property<int?>("BankAccountId");
  724. b.Property<string>("CellNumber");
  725. b.Property<string>("CompanyRegNumber");
  726. b.Property<DateTime>("Created");
  727. b.Property<string>("Email");
  728. b.Property<int>("HowMarried");
  729. b.Property<string>("IdNumber");
  730. b.Property<string>("IncomeTaxNumber");
  731. b.Property<bool>("IsDeleted");
  732. b.Property<DateTime>("Modified");
  733. b.Property<string>("ModifiedBy");
  734. b.Property<string>("Name");
  735. b.Property<string>("SpouseCellnumber");
  736. b.Property<string>("SpouseEmail");
  737. b.Property<string>("SpouseName");
  738. b.Property<string>("SpouseSurname");
  739. b.Property<string>("SpouseTelephone");
  740. b.Property<string>("Surname");
  741. b.Property<string>("Telephone");
  742. b.Property<int?>("TemplateId");
  743. b.Property<int?>("UserId");
  744. b.HasKey("Id");
  745. b.HasIndex("AddressId");
  746. b.HasIndex("BankAccountId");
  747. b.HasIndex("TemplateId");
  748. b.HasIndex("UserId");
  749. b.HasIndex("Telephone", "CellNumber", "Email")
  750. .IsUnique()
  751. .HasFilter("[Telephone] IS NOT NULL AND [CellNumber] IS NOT NULL AND [Email] IS NOT NULL");
  752. b.ToTable("Individuals");
  753. });
  754. modelBuilder.Entity("UnivateProperties_API.Model.Users.Person", b =>
  755. {
  756. b.Property<int>("Id")
  757. .ValueGeneratedOnAdd()
  758. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  759. b.Property<string>("CellNumber");
  760. b.Property<DateTime>("Created");
  761. b.Property<string>("Email");
  762. b.Property<bool>("IsDeleted");
  763. b.Property<DateTime>("Modified");
  764. b.Property<string>("ModifiedBy");
  765. b.Property<string>("Name");
  766. b.Property<string>("Surname");
  767. b.Property<string>("Telephone");
  768. b.Property<int?>("UserId");
  769. b.HasKey("Id");
  770. b.HasIndex("UserId");
  771. b.ToTable("Person");
  772. });
  773. modelBuilder.Entity("UnivateProperties_API.Model.Users.User", b =>
  774. {
  775. b.Property<int>("Id")
  776. .ValueGeneratedOnAdd()
  777. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  778. b.Property<bool>("AcceptedTerms");
  779. b.Property<DateTime>("Created");
  780. b.Property<bool>("IsDeleted");
  781. b.Property<bool>("LoginPasswordChange");
  782. b.Property<DateTime>("Modified");
  783. b.Property<string>("ModifiedBy");
  784. b.Property<byte[]>("PasswordHash");
  785. b.Property<byte[]>("PasswordSalt");
  786. b.Property<string>("Role");
  787. b.Property<string>("Token");
  788. b.Property<string>("Username");
  789. b.Property<bool>("Verified");
  790. b.HasKey("Id");
  791. b.HasIndex("Username")
  792. .IsUnique()
  793. .HasFilter("[Username] IS NOT NULL");
  794. b.ToTable("Users");
  795. });
  796. modelBuilder.Entity("UnivateProperties_API.Model.Users.UserRole", b =>
  797. {
  798. b.Property<int>("Id")
  799. .ValueGeneratedOnAdd()
  800. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  801. b.Property<DateTime>("Created");
  802. b.Property<bool>("IsDeleted");
  803. b.Property<DateTime>("Modified");
  804. b.Property<string>("ModifiedBy");
  805. b.Property<string>("RoleDescription");
  806. b.Property<string>("RoleName");
  807. b.HasKey("Id");
  808. b.ToTable("Roles");
  809. });
  810. modelBuilder.Entity("UnivateProperties_API.Model.Banks.BankAccount", b =>
  811. {
  812. b.HasOne("UnivateProperties_API.Model.Banks.Bank", "Bank")
  813. .WithMany()
  814. .HasForeignKey("BankId");
  815. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  816. .WithMany()
  817. .HasForeignKey("OwnerId");
  818. });
  819. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItem", b =>
  820. {
  821. b.HasOne("UnivateProperties_API.Model.Campaigns.Campaign", "Campaign")
  822. .WithMany("Items")
  823. .HasForeignKey("CampaignId")
  824. .OnDelete(DeleteBehavior.Cascade);
  825. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "Week")
  826. .WithMany()
  827. .HasForeignKey("WeekId")
  828. .OnDelete(DeleteBehavior.Cascade);
  829. });
  830. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignItemPlaceHolder", b =>
  831. {
  832. b.HasOne("UnivateProperties_API.Model.Campaigns.CampaignItem", "CampaignItem")
  833. .WithMany("CampaignItemPlaceHolder")
  834. .HasForeignKey("CampaignItemId")
  835. .OnDelete(DeleteBehavior.Cascade);
  836. });
  837. modelBuilder.Entity("UnivateProperties_API.Model.Campaigns.CampaignPlaceHolder", b =>
  838. {
  839. b.HasOne("UnivateProperties_API.Model.Campaigns.Campaign", "Campaign")
  840. .WithMany("PlaceHolders")
  841. .HasForeignKey("CampaignId")
  842. .OnDelete(DeleteBehavior.Cascade);
  843. });
  844. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Email", b =>
  845. {
  846. b.HasOne("UnivateProperties_API.Model.Communication.SMTPAccount", "Sender")
  847. .WithMany("Emails")
  848. .HasForeignKey("SenderId")
  849. .OnDelete(DeleteBehavior.Cascade);
  850. });
  851. modelBuilder.Entity("UnivateProperties_API.Model.Communication.PlaceHolder", b =>
  852. {
  853. b.HasOne("UnivateProperties_API.Model.Communication.Template", "Template")
  854. .WithMany("PlaceHolders")
  855. .HasForeignKey("TemplateId")
  856. .OnDelete(DeleteBehavior.Cascade);
  857. });
  858. modelBuilder.Entity("UnivateProperties_API.Model.Communication.SMTPAccount", b =>
  859. {
  860. b.HasOne("UnivateProperties_API.Model.Communication.SMTPHost", "SMTPHost")
  861. .WithMany("SMTPAccounts")
  862. .HasForeignKey("SMTPHostId")
  863. .OnDelete(DeleteBehavior.Cascade);
  864. });
  865. modelBuilder.Entity("UnivateProperties_API.Model.Communication.Template", b =>
  866. {
  867. b.HasOne("UnivateProperties_API.Model.Communication.SMTPAccount", "Sender")
  868. .WithMany("Templates")
  869. .HasForeignKey("SenderId");
  870. });
  871. modelBuilder.Entity("UnivateProperties_API.Model.Financial.Payment", b =>
  872. {
  873. b.HasOne("UnivateProperties_API.Model.Users.User", "CreatedBy")
  874. .WithMany()
  875. .HasForeignKey("CreatedById")
  876. .OnDelete(DeleteBehavior.Cascade);
  877. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  878. .WithMany()
  879. .HasForeignKey("PropertyId");
  880. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "TimeshareWeek")
  881. .WithMany()
  882. .HasForeignKey("TimeshareWeekId");
  883. });
  884. modelBuilder.Entity("UnivateProperties_API.Model.Misc.Address", b =>
  885. {
  886. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  887. .WithMany()
  888. .HasForeignKey("OwnerId");
  889. });
  890. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.BidItem", b =>
  891. {
  892. b.HasOne("UnivateProperties_API.Model.Users.Individual", "BidMaker")
  893. .WithMany()
  894. .HasForeignKey("BidMakerId");
  895. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  896. .WithMany("BidItems")
  897. .HasForeignKey("PropertyId");
  898. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  899. .WithMany()
  900. .HasForeignKey("StatusId");
  901. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "TimeshareWeek")
  902. .WithMany("BidItems")
  903. .HasForeignKey("TimeshareWeekId");
  904. });
  905. modelBuilder.Entity("UnivateProperties_API.Model.ProcessFlow.ProcessFlow", b =>
  906. {
  907. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  908. .WithMany("ProcessFlows")
  909. .HasForeignKey("PropertyID");
  910. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  911. .WithMany()
  912. .HasForeignKey("StatusID")
  913. .OnDelete(DeleteBehavior.Cascade);
  914. b.HasOne("UnivateProperties_API.Model.Timeshare.TimeshareWeek", "Timeshare")
  915. .WithMany("ProcessFlows")
  916. .HasForeignKey("TimeshareID");
  917. });
  918. modelBuilder.Entity("UnivateProperties_API.Model.Properties.Property", b =>
  919. {
  920. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  921. .WithMany("Properties")
  922. .HasForeignKey("AgencyId");
  923. b.HasOne("UnivateProperties_API.Model.Users.Agent", "Agent")
  924. .WithMany("Properties")
  925. .HasForeignKey("AgentId");
  926. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  927. .WithMany("Properties")
  928. .HasForeignKey("OwnerId");
  929. b.HasOne("UnivateProperties_API.Model.Properties.PropertyType", "PropertyType")
  930. .WithMany()
  931. .HasForeignKey("PropertyTypeId")
  932. .OnDelete(DeleteBehavior.Cascade);
  933. });
  934. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyImage", b =>
  935. {
  936. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  937. .WithMany("PropertyImages")
  938. .HasForeignKey("PropertyId")
  939. .OnDelete(DeleteBehavior.Cascade);
  940. });
  941. modelBuilder.Entity("UnivateProperties_API.Model.Properties.PropertyUserField", b =>
  942. {
  943. b.HasOne("UnivateProperties_API.Model.Properties.Property", "Property")
  944. .WithMany("PropertyUserFields")
  945. .HasForeignKey("PropertyId")
  946. .OnDelete(DeleteBehavior.Cascade);
  947. b.HasOne("UnivateProperties_API.Model.Properties.UserDefinedField", "UserDefinedField")
  948. .WithMany()
  949. .HasForeignKey("UserDefinedFieldId")
  950. .OnDelete(DeleteBehavior.Cascade);
  951. });
  952. modelBuilder.Entity("UnivateProperties_API.Model.Properties.UserDefinedField", b =>
  953. {
  954. b.HasOne("UnivateProperties_API.Model.Properties.UserDefinedGroup", "Group")
  955. .WithMany("Fields")
  956. .HasForeignKey("GroupId")
  957. .OnDelete(DeleteBehavior.Cascade);
  958. });
  959. modelBuilder.Entity("UnivateProperties_API.Model.Region.City", b =>
  960. {
  961. b.HasOne("UnivateProperties_API.Model.Region.Province", "Province")
  962. .WithMany()
  963. .HasForeignKey("ProvinceId")
  964. .OnDelete(DeleteBehavior.Cascade);
  965. });
  966. modelBuilder.Entity("UnivateProperties_API.Model.Region.Suburb", b =>
  967. {
  968. b.HasOne("UnivateProperties_API.Model.Region.City", "City")
  969. .WithMany()
  970. .HasForeignKey("CityId")
  971. .OnDelete(DeleteBehavior.Cascade);
  972. });
  973. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.TimeshareWeek", b =>
  974. {
  975. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  976. .WithMany()
  977. .HasForeignKey("AgencyId");
  978. b.HasOne("UnivateProperties_API.Model.Users.Agent", "Agent")
  979. .WithMany()
  980. .HasForeignKey("AgentId");
  981. b.HasOne("UnivateProperties_API.Model.Users.Individual", "Owner")
  982. .WithMany()
  983. .HasForeignKey("OwnerId")
  984. .OnDelete(DeleteBehavior.Cascade);
  985. b.HasOne("UnivateProperties_API.Model.Region.Province", "Region")
  986. .WithMany()
  987. .HasForeignKey("RegionId")
  988. .OnDelete(DeleteBehavior.Cascade);
  989. b.HasOne("UnivateProperties_API.Model.Timeshare.Status", "Status")
  990. .WithMany()
  991. .HasForeignKey("StatusId")
  992. .OnDelete(DeleteBehavior.Cascade);
  993. });
  994. modelBuilder.Entity("UnivateProperties_API.Model.Timeshare.UnitConfigurationType", b =>
  995. {
  996. b.HasOne("UnivateProperties_API.Model.Timeshare.UnitConfiguration", "UnitConfiguration")
  997. .WithMany("Types")
  998. .HasForeignKey("UnitConfigurationId")
  999. .OnDelete(DeleteBehavior.Cascade);
  1000. });
  1001. modelBuilder.Entity("UnivateProperties_API.Model.Users.Agent", b =>
  1002. {
  1003. b.HasOne("UnivateProperties_API.Model.Users.Agency", "Agency")
  1004. .WithMany("Agents")
  1005. .HasForeignKey("AgencyId");
  1006. b.HasOne("UnivateProperties_API.Model.Communication.Template")
  1007. .WithMany("AgentBCC")
  1008. .HasForeignKey("TemplateId");
  1009. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  1010. .WithMany()
  1011. .HasForeignKey("UserId");
  1012. });
  1013. modelBuilder.Entity("UnivateProperties_API.Model.Users.Individual", b =>
  1014. {
  1015. b.HasOne("UnivateProperties_API.Model.Misc.Address", "Address")
  1016. .WithMany()
  1017. .HasForeignKey("AddressId");
  1018. b.HasOne("UnivateProperties_API.Model.Banks.BankAccount", "BankAccount")
  1019. .WithMany()
  1020. .HasForeignKey("BankAccountId");
  1021. b.HasOne("UnivateProperties_API.Model.Communication.Template")
  1022. .WithMany("IndividualBCC")
  1023. .HasForeignKey("TemplateId");
  1024. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  1025. .WithMany()
  1026. .HasForeignKey("UserId");
  1027. });
  1028. modelBuilder.Entity("UnivateProperties_API.Model.Users.Person", b =>
  1029. {
  1030. b.HasOne("UnivateProperties_API.Model.Users.User", "User")
  1031. .WithMany()
  1032. .HasForeignKey("UserId");
  1033. });
  1034. #pragma warning restore 612, 618
  1035. }
  1036. }
  1037. }