示例#1
0
 public function getTab1Content()
 {
     $contentArray = array();
     $location = new Location($this->_posting->locId);
     $contentArray[] = array('head' => 'Location:', 'value' => $location->getLocationString(), 'cssClass' => '');
     $categoryTable = new Refcategory();
     $contentArray[] = array('head' => 'Property Type:', 'value' => $categoryTable->getCatNameById($this->_posting->cat3), 'cssClass' => '');
     $contentArray[] = array('head' => 'Bedrooms:', 'value' => Tag::getUnitsAmount($this->_pstCategory->rooms), 'cssClass' => '');
     $contentArray[] = array('head' => 'Bathrooms:', 'value' => Tag::getUnitsAmount($this->_pstCategory->baths), 'cssClass' => '');
     $contentArray[] = array('head' => 'Parking:', 'value' => Tag::getUnitsAmount($this->_pstCategory->parking), 'cssClass' => '');
     if (!empty($this->_pstCategory->buildingArea)) {
         $contentArray[] = array('head' => 'Building Area:', 'value' => $this->_pstCategory->buildingArea . 'm&sup2', 'cssClass' => '');
     }
     if (!empty($this->_pstCategory->landArea)) {
         $contentArray[] = array('head' => 'Land Area:', 'value' => $this->_pstCategory->landArea . 'm&sup2', 'cssClass' => '');
     }
     $contentArray[] = array('head' => 'Property Age:', 'value' => Tag::getAges($this->_pstCategory->age), 'cssClass' => '');
     $contentArray[] = array('head' => 'Morning Sun Dir:', 'value' => $this->_pstCategory->sunDirection, 'cssClass' => '');
     $contentArray[] = array('head' => 'Views of:', 'value' => $this->_pstCategory->views, 'cssClass' => '');
     $contentArray[] = array('head' => 'Levels in Building:', 'value' => $this->_pstCategory->buildingLevel, 'cssClass' => '');
     $contentArray[] = array('head' => 'Property is on floor:', 'value' => $this->_pstCategory->level, 'cssClass' => '');
     if (!empty($this->_pstCategory->strataRate)) {
         $contentArray[] = array('head' => 'Strata Rate:', 'value' => $location->getCurrencySymbol() . $this->_pstCategory->strataRate . ' per quarter', 'cssClass' => '');
     }
     if (!empty($this->_pstCategory->councilRate)) {
         $contentArray[] = array('head' => 'Council Rate:', 'value' => $location->getCurrencySymbol() . $this->_pstCategory->councilRate . ' per quarter', 'cssClass' => '');
     }
     if (!empty($this->_pstCategory->waterRate)) {
         $contentArray[] = array('head' => 'Water Rate:', 'value' => $location->getCurrencySymbol() . $this->_pstCategory->waterRate . ' per quarter', 'cssClass' => '');
     }
     $contentArray[] = array('head' => 'Best Features:', 'value' => $this->_pstCategory->bestFeatures, 'cssClass' => '');
     $this->printTable($contentArray, true);
     /*
     echo '<table>';
     
     echo '<tr>';
     echo '<th> </th>';
     echo '<td>' . $this->getCatsString() . '</td>';
     echo '</tr>';
     
     echo '<tr>';
     echo '<th>Location: </th>';
     
     
     echo '<td>' . $location->getLocationString() . '</td>';
     echo '</tr>';
     
     echo '<tr>';
     echo '<th>Salary Info: </th>';
     echo '<td>' . $this->_pstCategory->priceInfo . '</td>';
     echo '</tr>';
     
     echo '<tr>';
     echo '<th>Requried Skills: </th>';
     echo '<td>' . $this->_pstCategory->skills . '</td>';
     echo '</tr>';
     
     echo '</table>';
     */
 }
示例#2
0
 protected function buildRefineUri($businessType, $formData)
 {
     if (strtolower($formData['cat2']) == strtolower('Any')) {
         $formData['cat2name'] = 'Any';
     } else {
         $refcat2 = new Refcategory();
         $formData['cat2name'] = $refcat2->getCatNameById($formData['cat2']);
     }
     return parent::buildRefineUri($businessType, $formData);
 }
示例#3
0
文件: DetailTab.php 项目: xinghao/shs
 public function getCatsString($showCat1 = true)
 {
     $retString = '';
     if (!empty($this->_posting->cat1) && $showCat1) {
         $refcat1 = new Refcat1();
         $retString = $refcat1->getCatNameById($this->_posting->cat1);
     }
     if (!empty($this->_posting->cat2)) {
         $refcat = new Refcategory();
         $cat = $refcat->getCatNameById($this->_posting->cat2);
         if (empty($retString)) {
             $retString = $cat;
         } else {
             $retString .= ', ' . $cat;
         }
     }
     if (!empty($this->_posting->cat3)) {
         $refcat = new Refcategory();
         $cat = $refcat->getCatNameById($this->_posting->cat3);
         if (empty($retString)) {
             $retString = $cat;
         } else {
             $retString .= ', ' . $cat;
         }
     }
     if (!empty($this->_posting->cat4)) {
         $refcat = new Refcategory();
         $cat = $refcat->getCatNameById($this->_posting->cat4);
         if (empty($retString)) {
             $retString = $cat;
         } else {
             $retString .= ', ' . $cat;
         }
     }
     if (!empty($this->_posting->cat5)) {
         $refcat = new Refcategory();
         $cat = $refcat->getCatNameById($this->_posting->cat5);
         if (empty($retString)) {
             $retString = $cat;
         } else {
             $retString .= ', ' . $cat;
         }
     }
     return $retString;
 }
示例#4
0
文件: Business.php 项目: xinghao/shs
 public function getCat3NameById($cat3)
 {
     $refCat3Tables = new Refcategory();
     return $refCat3Tables->getCatNameById($cat3);
 }
示例#5
0
 public function getTitle()
 {
     $title = "";
     $cat2 = "";
     $cat3 = "";
     $catTables = new Refcategory();
     if (!empty($this->_posting->cat2)) {
         $cat2 = $catTables->getCatNameById($this->_posting->cat2);
     }
     if (!empty($this->_posting->cat3)) {
         $cat3 = $catTables->getCatNameById($this->_posting->cat3);
     }
     $title .= $this->_pstCategory->makeYear . ' ' . $cat2 . ' ' . $cat3;
     $location = new Location($this->_posting->locId);
     $suburb = $location->getSuburb();
     $title .= '<br /><span class="titlesecond">';
     $cat1Table = new Refcat1();
     $title .= $cat1Table->getCatNameById($this->_posting->cat1) . ' - ' . $this->_posting->priceDisplay . '<span class="titleend"> (' . $suburb . ")</span>" . "</span>";
     return $title;
 }