property_grid_view.php 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. <?php if ($ajax!=='load') include 'header.php'; ?>
  2. <section id="content">
  3. <div class="filter-bar">
  4. <div class="filter-input-wrap minus">
  5. <select name="ertekesites" id="ertekesites" class="modal-input property-search-select" onchange="set_ertekesites_tipus($(this).val())">
  6. <option value="">Összes értékesítés típus</option>
  7. <?php foreach ($ertekesites as $item) : ?>
  8. <option value="<?=$item->ertekesites?>" <?php if ($_SESSION['search']['ertekesites']==$item->ertekesites) echo 'selected'; ?>><?=lang::_($item->ertekesites)?></option>
  9. <?php endforeach; ?>
  10. </select>
  11. </div>
  12. <div class="filter-input-wrap minus">
  13. <select name="jelleg" id="jelleg" class="modal-input property-search-select" onchange="setDetailedForm($(this),'grid')">
  14. <?php
  15. if ($_SESSION['search']['jelleg']=='lakoingatlan') {
  16. $check = 'Lakóingatlan - '.$_SESSION['search']['tipus'];
  17. }
  18. elseif ($_SESSION['search']['tipus']=='nyaralo') {
  19. $check = 'nyaralo';
  20. }
  21. else {
  22. $check = $_SESSION['search']['jelleg'];
  23. }
  24. ?>
  25. <option value="">Összes ingatlan jelleg</option>
  26. <?php foreach ($jelleg as $item) : $item->jelleg = str_replace('tanya','Tanya',$item->jelleg); $item->jelleg = str_replace('beruhazasi','Beruházást igénylő',$item->jelleg); ?>
  27. <option value="<?=$item->jelleg?>" <?php if ($check==$item->jelleg) echo 'selected'; ?>><?php $nev = lang::_(str_replace("Lakóingatlan - ","",$item->jelleg)); if ($nev=='Társasházi') { echo 'Lakás'; } elseif ($nev=='onalloepulet') { echo 'Önálló épület'; } elseif ($nev=='sorhaz') { echo 'Sorház'; } else { echo $nev; } ?></option>
  28. <?php endforeach; ?>
  29. <option value="nyaralo" <?php if ($check=='nyaralo') echo 'selected'; ?>>Nyaraló</option>
  30. </select>
  31. </div>
  32. <div class="filter-input-wrap selectize-wrap">
  33. <select name="city[]" id="city" multiple="multiple">
  34. <option value="">Hol keresel?</option>
  35. <?php $actives = explode(",",$_SESSION['search']['city']); ?>
  36. <option value="Budapest" <?php if (in_array('Budapest',$actives)) echo 'selected'; ?>>Budapest</option>
  37. <?php foreach ($city as $item) : ?>
  38. <option value="<?=$item->telepules?>" <?php if (in_array($item->telepules,$actives)) echo 'selected'; ?>><?=$item->telepules?></option>
  39. <?php endforeach; ?>
  40. <?php foreach ($actives as $active) : ?>
  41. <?php if (stristr($active," (")) : ?>
  42. <option value="<?=$active?>" selected><?=$active?></option>
  43. <?php endif; ?>
  44. <?php endforeach; ?>
  45. </select>
  46. &nbsp;&nbsp;
  47. </div>
  48. <div class="sgPriceBox" onclick="sgSetEditable(this)" style="margin-left: 0px;">
  49. <small class="ar-label" style="<?php if ($_SESSION['search']['iranyar_min']!='' || $_SESSION['search']['iranyar_max']!='') echo 'display: none;'; ?> color: #ccc;">Ár</small>
  50. <input <?php if ($_SESSION['search']['iranyar_min']=='') echo 'style="display: none;"'; ?> type="text" name="armin" id="iranyar_min" class="arbox" value="<?=$_SESSION['search']['iranyar_min']?>" placeholder="min" onfocus="this.placeholder = ''" onblur="this.placeholder = 'min'"><span <?php if ($_SESSION['search']['iranyar_min']=='') echo 'style="display: none;"'; ?>>-</span><input <?php if ($_SESSION['search']['iranyar_max']=='') echo 'style="display: none;"'; ?> type="text" name="armax" id="iranyar_max" class="arbox" value="<?=$_SESSION['search']['iranyar_max']?>" placeholder="max" onfocus="this.placeholder = ''" onblur="this.placeholder = 'min'">
  51. <?php if ($_SESSION['search']['ertekesites']=='elado') : ?>
  52. <small class="currency-label">MFt</small>
  53. <?php else : ?>
  54. <small class="currency-label">eFt</small>
  55. <?php endif; ?>
  56. </div>
  57. <div class="sgSizeBox" onclick="sgSetSizeEditable(this)">
  58. <small class="size-label" style="<?php if ($_SESSION['search']['meret_netto_min']!='' || $_SESSION['search']['meret_netto_max']!='') echo 'display: none;'; ?> color: #ccc;">Terület</small>
  59. <input <?php if ($_SESSION['search']['meret_netto_min']=='') echo 'style="display: none;"'; ?> type="text" name="nmmin" id="meret_netto_min" class="sizebox" value="<?=$_SESSION['search']['meret_netto_min']?>" placeholder="min" onfocus="this.placeholder = ''" onblur="this.placeholder = 'min'"><span <?php if ($_SESSION['search']['meret_netto_min']=='') echo 'style="display: none;"'; ?>>-</span><input <?php if ($_SESSION['search']['meret_netto_max']=='') echo 'style="display: none;"'; ?> type="text" name="nmmax" id="meret_netto_max" class="sizebox" value="<?=$_SESSION['search']['meret_netto_max']?>" placeholder="max" onfocus="this.placeholder = ''" onblur="this.placeholder = 'max'">
  60. <small style="margin-top: 5px; float: right;">m<sup>2</sup></small>
  61. </div>
  62. <!--<div class="filter-input-wrap minus only-mobile">
  63. <input class="modal-input property-search-text first-property-searc-text" type="text" name="szoba_min" id="szoba_min" value="<?=$_SESSION['search']['szoba_min']?>" placeholder="Szobák (min)">
  64. <input class="modal-input property-search-text" type="text" name="szoba_max" id="szoba_max" value="<?=$_SESSION['search']['szoba_max']?>" placeholder="Szobák (max)">
  65. </div>-->
  66. <br class="only-mobile"><br class="only-mobile"><br class="only-mobile">
  67. <button type="button" id="gogogo" name="go" onclick="search('/property/search/filter/')" class="btn-black mini"><i class="fas fa-search"></i></button>
  68. <a href="javascript: void(0);" id="showhideDetailSearch" name="dsBtn" class="detailed-search-btn" onclick="showHideDetailSearch()">Részletes keresés</a>
  69. <a href="#" onclick="showGridView()" class="set-view view-list" style="display: none;"><i class="fas fa-list"></i>Lista</a>
  70. <a href="#" onclick="showMapView()" class="set-view view-map" style="display: none;"><i class="fas fa-th"></i>Térkép</a>
  71. </div>
  72. <a href="javascript: void(0);" id="nsBtn" class="ns-btn" name="nsBtn" onclick="showHideSearch()">Keresés</a>
  73. <div class="detailed-filter"></div>
  74. <div class="results-block mobile-block">
  75. <?php if (sizeof($properties)>0) : ?>
  76. <button type="button" id="showhideDetailSearch" name="nsBtn" class="btn-black hide-on-desktop showhideDetailSearch" style="width: 95.5%; margin-left: 8px; margin-top: -10px;" onclick="showHideSearch($(this))">Részletes keresés</button>
  77. <a href="javascript:;" id="showhideDetailClose" class="hide-on-desktop close-detail-search" style="display: none;" onclick="showHideSearch()"><i class="fas fa-times"></i> Részletes keresés bezárása</a>
  78. <!--<h3 style="padding-top: 10px; padding-bottom: 0px; margin-bottom: 15px; display: inline-block; font-weight: bold;"><strong style="font-weight: bold;"><?=$searchResultsCount?></strong> találat</h3>-->
  79. <h3 style="padding-top: 10px; padding-bottom: 0px; margin-bottom: 15px; display: inline-block; font-weight: bold;"><?=$keresesi_szoveg?></h3>
  80. <!--<div class="sorter-mobile">
  81. <?php $active_order = $_SESSION['storedOrderField']."_".$_SESSION['storedOrderDirection']; ?>
  82. <select name="sorting" onchange="setListOrderReloader($(this).val())">
  83. <option value="letrehozva_DESC" <?php if ($active_order=='letrehozva_DESC') echo 'selected'; ?>>Dátum szerint csökkenő</option>
  84. <option value="letrehozva_ASC" <?php if ($active_order=='letrehozva_ASC') echo 'selected'; ?>>Dátum szerint növekvő</option>
  85. <option value="iranyar_ASC" <?php if ($active_order=='iranyar_ASC') echo 'selected'; ?>>Ár szerint növekvő</option>
  86. <option value="iranyar_DESC" <?php if ($active_order=='iranyar_DESC') echo 'selected'; ?>>Ár szerint csökkenő</option>
  87. </select>
  88. </div>-->
  89. <!--<h4 id="keresesi_szoveg" style="margin-top: -15px; font-size: 14px;"><?=$keresesi_szoveg?></h4>-->
  90. <?php else : ?>
  91. <div class="error-message mobile-top" style="display: block;"><h2>Nincs találat : (</h2> <p style="padding-right: 20px;">Jelenleg nincs a megadott keresési feltételeknek megfelelő ingatlan az adatbázisunkban.<br>Kérjük adjon meg más keresési paramétereket!</p></div>
  92. <?php endif; ?>
  93. <div class="result-list-thin justmobile">
  94. <?php foreach ($properties as $property) : if ($property->tipus=='') $property->tipus=$property->jelleg; ?>
  95. <div class="result-item horizontal-item" onclick="window.location='/<?=$property->ertekesites?>/<?=$property->tipus?>/<?=common::generateSlug($property->telepules)?>/<?=$property->id?>-<?=$property->ertekesites?>-<?=$property->tipus?>-<?=common::generateSlug($property->iranyitoszam)?>-<?=common::generateSlug($property->telepules)?><?php if ($property->terkepesmegjelenes=='1') echo '-'.common::generateSlug($property->utcanev) ?>';">
  96. <figure class="result-details" style="background-image: url('<?=common::get_image_url_mark($property->indexkep)?>'); width: 200px;"></figure>
  97. <div class="result-details">
  98. <pre class="price"><?=formatize::currency($property->iranyar)?> <span class="currency">FT</span></pre>
  99. <?php if ($property->meret_netto!='0') : ?><span class="size"><?=$property->meret_netto?> m<sup>2</sup></span><?php endif; ?>
  100. <?php if ($property->meret_telek!=='0') : ?>
  101. <span class="site"><?=$property->meret_telek?> m<sup>2</sup> telek</span>
  102. <?php endif; ?>
  103. <?php $szobasum = 0; $szobasum = $property->szoba_egesz+$property->szoba_fel; ?>
  104. <?php if ($szobasum!='0') : ?><span class="rooms"><?php echo $szobasum; ?> szoba</span><br><?php endif; ?>
  105. <?php if ($property->terkepesmegjelenes!='0') : ?>
  106. <span class="address"><?=$property->iranyitoszam?>. <?=$property->telepules?>, <?=$property->korzet?><?php if ($property->terkepesmegjelenes=='1') : ?>, <?=$property->utcanev?><?php endif; ?></span>
  107. <?php endif; ?>
  108. </div>
  109. </div>
  110. <?php endforeach; ?>
  111. </div>
  112. <div class="result-list justdesktop">
  113. <?php foreach ($properties as $property) : if ($property->tipus=='') $property->tipus=$property->jelleg; ?>
  114. <div class="result-item" onclick="window.location='/<?=$property->ertekesites?>/<?=$property->tipus?>/<?=common::generateSlug($property->telepules)?>/<?=$property->id?>-<?=$property->ertekesites?>-<?=$property->tipus?>-<?=common::generateSlug($property->iranyitoszam)?>-<?=common::generateSlug($property->telepules)?><?php if ($property->terkepesmegjelenes=='1') echo '-'.common::generateSlug($property->utcanev) ?>';">
  115. <figure style="background-image: url('<?=common::get_image_url_mark($property->indexkep)?>');"></figure>
  116. <span class="gallery"><i class="fas fa-camera"></i> <small><?=common::getPropertyImagesCount($property->regszam)?></small></span>
  117. <pre class="price"><?=formatize::currency($property->iranyar)?> <span class="currency">FT</span></pre>
  118. <?php if ($property->meret_netto!='0') : ?><span class="size"><?=$property->meret_netto?> m<sup>2</sup></span><?php endif; ?>
  119. <?php if ($property->meret_telek!=='0') : ?>
  120. <span class="site"><?=$property->meret_telek?> m<sup>2</sup> telek</span>
  121. <?php endif; ?>
  122. <?php $szobasum = 0; $szobasum = $property->szoba_egesz+$property->szoba_fel; ?>
  123. <?php if ($szobasum!='0') : ?><span class="rooms"><?php echo $szobasum; ?> szoba</span><br><?php endif; ?>
  124. <?php if ($property->terkepesmegjelenes!='0') : ?>
  125. <span class="address"><?=$property->iranyitoszam?>. <?=$property->telepules?>, <?=$property->korzet?><?php if ($property->terkepesmegjelenes=='1') : ?>, <?=$property->utcanev?><?php endif; ?></span>
  126. <?php endif; ?>
  127. <!--<a class="tool-icon" href="javascript:;" onclick="window.location='/property/show/<?=$property->id?>';"><i class="fas fa-envelope"></i> Kapcsolat</a>-->
  128. </div>
  129. <?php endforeach; ?>
  130. </div>
  131. <div class="clear"></div>
  132. <?php if ($_SESSION['statusz_switch']!='arcsokkent') : ?>
  133. <?=$loaderBtn?>
  134. <?php endif; ?>
  135. <br><br>
  136. </div>
  137. </section>
  138. <?php if ($ajax!=='load') include 'footer.php'; ?>