$rows = HFormEditor::getGeneralFields();
$referencesFields = array();
foreach($rows as $key => $tmp) {
if ($tmp->field == 'references') {
$referencesFields = $tmp;
unset($rows[$key]);
break;
}
}
if (!empty($referencesFields)) {
HFormEditor::renderViewRows($referencesFields, $data, $isPrintable);
}
if (!empty($referencesFields)) {
HFormEditor::renderViewRows($referencesFields, $data, $isPrintable);
}
if (!empty($referencesFields)) {
HFormEditor::renderViewRows([$referencesFields], $data, $isPrintable);
}
if (!empty($referencesFields)) {
HFormEditor::renderViewRows(array($referencesFields), $data, $isPrintable);
}
<div class="property_info_row">
<?php
$isPrintable = (isset($isPrintable)) ? $isPrintable : false;
if ($data->canShowInView('price') && issetModule('seasonalprices') && isset($data->seasonalPrices) && $data->seasonalPrices && $data->type == Apartment::TYPE_RENT) {
echo '<div class="ap-view-seasons-prices">' . $this->renderPartial('//modules/seasonalprices/views/_table', array('apartment' => $data, 'showDeleteButton' => false), true) . '</div>';
}
HFormEditor::$viewRowTemplate = '<tr><td><strong>{label}:</strong></td><td>{value}</td></tr>';
$rows = HFormEditor::getGeneralFields();
$referencesFields = array();
foreach($rows as $key => $tmp) {
if ($tmp->field == 'references') {
$referencesFields = $tmp;
unset($rows[$key]);
break;
}
}
?>
<div class="table-responsive">
<table class="table">
<tbody>
<?php
if ($data->deleted) {
HFormEditor::renderViewRow('', '<span class="deleted">' . tt('Listing is deleted', 'apartments') . '</span>');
}
HFormEditor::renderViewRow(tt('Apartment ID'), $data->id);
HFormEditor::renderViewRows($rows, $data, $isPrintable);
?>
</tbody>
</table>
</div>
<?php if ($data->type == Apartment::TYPE_CHANGE && $data->getStrByLang('exchange_to')): ?>
<dt><?php echo tt('Exchange to', 'apartments'); ?>:</dt>
<dd><?php echo CHtml::encode($data->getStrByLang('exchange_to')); ?></dd>
<?php
endif;
echo '<div class="clear"></div>';
if ($data->type == Apartment::TYPE_SALE && param('show_loan_calculator') && !$isPrintable) {
$this->widget('application.modules.loanCalculator.components.LoanCalculatorWidget', array(
'amount' => $data->getPriceFrom()
));
echo '<div class="clear"></div><br /><br />';
}
if (!empty($referencesFields)) {
HFormEditor::renderViewRows([$referencesFields], $data, $isPrintable);
}
?>
</div>
Вернуться в Вопросы и помощь по изменениям
Сейчас этот форум просматривают: нет зарегистрированных пользователей и гости: 7