Новости Joomla

👩‍💻 События плагинов и порядок их срабатывания при работе с пользовательскими полями Joomla и использовании FieldsHelper.

👩‍💻 События плагинов и порядок их срабатывания при работе с пользовательскими полями Joomla и использовании FieldsHelper.

В процессе работы с Joomla бывает необходимо работать с пользовательским интерфейсом более тонко, чем обычно. Все формы Joomla состоят из стандартных полей, содержанием, стилем отображения, состоянием (включено/выключено, доступно для редактирования или нет и т.д.) можно управлять с помощью плагинов. Да и для нестандартных проектов хорошей практикой является создание одного системного или нескольких плагинов групп "под проект", в которых храниться весь "нестандарт".

В этой статье описаны все триггеры, которые вызываются через Event Dispatcher из administrator/components/com_fields/src/Helper/FieldsHelper.php, с привязкой к жизненному циклу (порядку этапов работы запроса), аргументам, изменяемым данным и дальнейшему распространению по Joomla. Это поможет вам работать с Joomla свободнее и не опасаясь при этом потерять изменения при очередном обновлении движка.

Подходы, описанные в статье, полезны в тех случаях, когда вы работаете с данными в com_fields - механизме создания и редактирования пользовательских полей ядра Joomla и при использовании FieldsHelper. Многие сторонние компоненты не используют эту возможность, поэтому данная статья будет полезна лишь частично.

Читать статью на Хабре.

@joomlafeed

🏆 Открыто голосование за Joomla в премии CMS Critic People’s Choice Awards 2025

🏆 Открыто голосование за Joomla в  премии CMS Critic People’s Choice Awards 2025

🗓 Голосование продлится до 27 февраля 2026 года.

👩‍💻 Проголосовать! 👩‍💻

Номинации, в которых можно проголосовать за Joomla:
⭐️ Best Free CMS
⭐️ Best Open Source CMS
⭐️ Best Enterprise CMS

Также в номинации Best e-Commerce Solution участвуют компоненты интернет-магазинов для Joomla:
⭐️ HikaShop
⭐️ Virtuemart

В номинации Best Website Builder оказались:
⭐️ YooTheme
⭐️ SP Page Builder

Что такое CMS Critic Awards?
С 2012 года премия CMS Critic Awards занимает особое место в сообществе систем управления контентом (CMS). Это единственный в своем роде сайт, который составляет рейтинг системы управления контентом и связанных с ними решений на рынке — от малого до крупного и подчеркивает их инновации и услуги.

Каждый год награда CMS Critic Awards присуждается одному победителю в различных отраслевых категориях, таких как: «Лучшая облачная CMS», «Лучший DXP», «Лучшая Headless CMS и других. Затем результаты оглашаются через СМИ вместе с выбором редакции CMS Critic.
В этом году премия вернулась к своим традициям и только TOP-5 движков по количеству номинаций попали в 2-й этап - голосование.

@joomlafeed

0 Пользователей и 1 Гость просматривают эту тему.
  • 2 Ответов
  • 2497 Просмотров
*

SaidGGV

  • Осваиваюсь на форуме
  • 14
  • 0 / 0
День добрый.
В категории нет товаров, но есть подкатегории.
Если нет товара, то не отображается описание категории при просмотре сайта (при добавлении товара все работает).
В админке WM описание есть, в списке категорий описание отображается.

Титл страницы отображается. Заголовок нет.


Собственно как это вылечить?

WM 2.0.16 +Joomla! 2.5.6
Обновляться пока не вариант, т.к. изменений очень много.


Заранее благодарю.
Решено заменой части кода
Код
<?php // Show child categories
if (!empty($this->products)) {
?>
<div class="orderby-displaynumber">
<div class="width70 floatleft">
<?php echo $this->orderByList['orderby']; ?>
<?php echo $this->orderByList['manufacturer']; ?>
</div>
<div class="width30 floatright display-number"><?php echo $this->vmPagination->getResultsCounter ();?><br/><?php echo $this->vmPagination->getLimitBox (); ?></div>
<div class="vm-pagination">
<?php echo $this->vmPagination->getPagesLinks (); ?>
<span style="float:right"><?php echo $this->vmPagination->getPagesCounter (); ?></span>
</div>

<div class="clear"></div>
</div> <!-- end of orderby-displaynumber -->

<h1><?php echo $this->category->category_name; ?></h1>
<div class="category_description">
<?php
 $start = JRequest::getInt('limitstart',0);
 $option = JRequest::getVar('option','');
If (!$start && $option == 'com_virtuemart'){ ?>
<div style="width:100%;float:left;">
 <?php echo $this->category->category_description ; ?> </div> <?php } ?>
</div>
<?php
// Category and Columns Counter
$iBrowseCol = 1;
$iBrowseProduct = 1;

// Calculating Products Per Row
$BrowseProducts_per_row = $this->perRow;
$Browsecellwidth = ' width' . floor (100 / $BrowseProducts_per_row);

// Separator
$verticalseparator = " vertical-separator";

// Count products ?? why not just count ($this->products)  ?? note by Max Milbers
$BrowseTotalProducts = 0;
foreach ($this->products as $product) {
$BrowseTotalProducts++;
}

// Start the Output
foreach ($this->products as $product) {

// Show the horizontal seperator
if ($iBrowseCol == 1 && $iBrowseProduct > $BrowseProducts_per_row) {
?>
<div class="horizontal-separator"></div>
<?php
}

// this is an indicator wether a row needs to be opened or not
if ($iBrowseCol == 1) {
?>
<div class="row">
<?php
}

// Show the vertical seperator
if ($iBrowseProduct == $BrowseProducts_per_row or $iBrowseProduct % $BrowseProducts_per_row == 0) {
$show_vertical_separator = ' ';
} else {
$show_vertical_separator = $verticalseparator;
}

// Show Products
?>
<div class="product floatleft<?php echo $Browsecellwidth . $show_vertical_separator ?>">
<div class="spacer">
<div class="width30 floatleft center">
    <a title="<?php echo $product->link ?>" rel="vm-additional-images" href="<?php echo $product->link; ?>">
<?php
echo $product->images[0]->displayMediaThumb('class="browseProductImage"', false);
?>
</a>

<!-- The "Average Customer Rating" Part -->
<?php if ($this->showRating) { ?>
<span class="contentpagetitle"><?php echo JText::_ ('COM_VIRTUEMART_CUSTOMER_RATING')?>:</span>
<br/>
<?php
// $img_url = JURI::root().VmConfig::get('assets_general_path').'/reviews/'.$product->votes->rating.'.gif';
// echo JHTML::image($img_url, $product->votes->rating.' '.JText::_('COM_VIRTUEMART_REVIEW_STARS'));
// echo JText::_('COM_VIRTUEMART_TOTAL_VOTES').": ". $product->votes->allvotes;
?>
<?php } ?>
  <?php
if ( VmConfig::get ('display_stock', 1)) { ?>
<!-- if (!VmConfig::get('use_as_catalog') and !(VmConfig::get('stockhandle','none')=='none')){?> -->
<div class="paddingtop8">
<span class="vmicon vm2-<?php echo $product->stock->stock_level ?>" title="<?php echo $product->stock->stock_tip ?>"></span>
<span class="stock-level"><?php echo JText::_ ('COM_VIRTUEMART_STOCK_LEVEL_DISPLAY_TITLE_TIP')?></span>
</div>
<?php } ?>
</div>

<div class="width70 floatright">

<h2><?php echo JHTML::link ($product->link, $product->product_name); ?></h2>

<?php // Product Short Description
if (!empty($product->product_s_desc)) {
?>
<p class="product_s_desc">
<?php echo shopFunctionsF::limitStringByWord ($product->product_s_desc, 40, '...')?>
</p>
<?php } ?>
<?echo JText::_('COM_VIRTUEMART_CART_SKU')?><span  style="font-weight: bold;">:&nbsp;<?echo $product->product_sku?></span>

<?echo '<br />';
if($product->customfields){
foreach ($product->customfields as $customfields) {
echo '';
echo $customfields->custom_title;
echo '<span  style="font-weight: bold;">:&nbsp;';
echo $customfields->display;
echo '';
}
}
echo '</span>'; ?>






<div class="product-price marginbottom12" id="productPrice<?php echo $product->virtuemart_product_id ?>">
<?php
if ($this->show_prices == '1') {
if ($product->prices['salesPrice']<=0 and VmConfig::get ('askprice', 1) and  !$product->images[0]->file_is_downloadable) {
echo JText::_ ('COM_VIRTUEMART_PRODUCT_ASKPRICE');
}
//todo add config settings
if ($this->showBasePrice) {
echo $this->currency->createPriceDiv ('basePrice', 'COM_VIRTUEMART_PRODUCT_BASEPRICE', $product->prices);
echo $this->currency->createPriceDiv ('basePriceVariant', 'COM_VIRTUEMART_PRODUCT_BASEPRICE_VARIANT', $product->prices);
}
echo $this->currency->createPriceDiv ('variantModification', 'COM_VIRTUEMART_PRODUCT_VARIANT_MOD', $product->prices);
if (round($product->prices['basePriceWithTax'],$this->currency->_priceConfig['salesPrice'][1])!= $product->prices['salesPrice']) {
echo '<span class="price-crossed" >' . $this->currency->createPriceDiv ('basePriceWithTax', 'COM_VIRTUEMART_PRODUCT_BASEPRICE_WITHTAX', $product->prices). "</span>";
}
if (round($product->prices['salesPriceWithDiscount'],$this->currency->_priceConfig['salesPrice'][1])!= $product->prices['salesPrice']) {
echo $this->currency->createPriceDiv ('salesPriceWithDiscount', 'COM_VIRTUEMART_PRODUCT_SALESPRICE_WITH_DISCOUNT', $product->prices);
}
echo $this->currency->createPriceDiv ('salesPrice', 'COM_VIRTUEMART_PRODUCT_SALESPRICE', $product->prices);
echo $this->currency->createPriceDiv ('priceWithoutTax', 'COM_VIRTUEMART_PRODUCT_SALESPRICE_WITHOUT_TAX', $product->prices);
echo $this->currency->createPriceDiv ('discountAmount', 'COM_VIRTUEMART_PRODUCT_DISCOUNT_AMOUNT', $product->prices);
echo $this->currency->createPriceDiv ('taxAmount', 'COM_VIRTUEMART_PRODUCT_TAX_AMOUNT', $product->prices);
$unitPriceDescription = JText::sprintf ('COM_VIRTUEMART_PRODUCT_UNITPRICE', $product->product_unit);
echo $this->currency->createPriceDiv ('unitPrice', $unitPriceDescription, $product->prices);
} ?>

</div>

<p>
<?php // Product Details Button
echo JHTML::link ($product->link, JText::_ ('COM_VIRTUEMART_PRODUCT_DETAILS'), array('title' => $product->product_name, 'class' => 'product-details'));
?>
</p>

</div>
<div class="clear"></div>
</div>
<!-- end of spacer -->
</div> <!-- end of product -->
<?php

// Do we need to close the current row now?
if ($iBrowseCol == $BrowseProducts_per_row || $iBrowseProduct == $BrowseTotalProducts) {
?>
<div class="clear"></div>
   </div> <!-- end of row -->
<?php
$iBrowseCol = 1;
} else {
$iBrowseCol++;
}

$iBrowseProduct++;
} // end of foreach ( $this->products as $product )
// Do we need a final closing row tag?
if ($iBrowseCol != 1) {
?>
<div class="clear"></div>

<?php
}
?>

<div class="vm-pagination"><?php echo $this->vmPagination->getPagesLinks (); ?><span style="float:right"><?php echo $this->vmPagination->getPagesCounter (); ?></span></div>

<?php
} elseif ($this->search !== NULL) {
echo JText::_ ('COM_VIRTUEMART_NO_RESULT'). ($this->keyword ? ' : (' . $this->keyword . ')' : '');
}
?>

на
Код
<?php // Show child categories

?>
<div class="orderby-displaynumber">
<div class="width70 floatleft">
<?php echo $this->orderByList['orderby']; ?>
<?php echo $this->orderByList['manufacturer']; ?>
</div>
<div class="width30 floatright display-number"><?php echo $this->vmPagination->getResultsCounter ();?><br/><?php echo $this->vmPagination->getLimitBox (); ?></div>
<div class="vm-pagination">
<?php echo $this->vmPagination->getPagesLinks (); ?>
<span style="float:right"><?php echo $this->vmPagination->getPagesCounter (); ?></span>
</div>

<div class="clear"></div>
</div> <!-- end of orderby-displaynumber -->

<h1><?php echo $this->category->category_name; ?></h1>
<div class="category_description">
<?php
 $start = JRequest::getInt('limitstart',0);
 $option = JRequest::getVar('option','');
If (!$start && $option == 'com_virtuemart'){ ?>
<div style="width:100%;float:left;">
 <?php echo $this->category->category_description ; ?> </div> <?php } ?>
</div>
<?php
// Category and Columns Counter
$iBrowseCol = 1;
$iBrowseProduct = 1;

// Calculating Products Per Row
$BrowseProducts_per_row = $this->perRow;
$Browsecellwidth = ' width' . floor (100 / $BrowseProducts_per_row);

// Separator
$verticalseparator = " vertical-separator";

// Count products ?? why not just count ($this->products)  ?? note by Max Milbers
$BrowseTotalProducts = 0;
foreach ($this->products as $product) {
$BrowseTotalProducts++;
}

// Start the Output
foreach ($this->products as $product) {

// Show the horizontal seperator
if ($iBrowseCol == 1 && $iBrowseProduct > $BrowseProducts_per_row) {
?>
<div class="horizontal-separator"></div>
<?php
}

// this is an indicator wether a row needs to be opened or not
if ($iBrowseCol == 1) {
?>
<div class="row">
<?php
}

// Show the vertical seperator
if ($iBrowseProduct == $BrowseProducts_per_row or $iBrowseProduct % $BrowseProducts_per_row == 0) {
$show_vertical_separator = ' ';
} else {
$show_vertical_separator = $verticalseparator;
}

// Show Products
?>
<div class="product floatleft<?php echo $Browsecellwidth . $show_vertical_separator ?>">
<div class="spacer">
<div class="width30 floatleft center">
    <a title="<?php echo $product->link ?>" rel="vm-additional-images" href="<?php echo $product->link; ?>">
<?php
echo $product->images[0]->displayMediaThumb('class="browseProductImage"', false);
?>
</a>

<!-- The "Average Customer Rating" Part -->
<?php if ($this->showRating) { ?>
<span class="contentpagetitle"><?php echo JText::_ ('COM_VIRTUEMART_CUSTOMER_RATING')?>:</span>
<br/>
<?php
// $img_url = JURI::root().VmConfig::get('assets_general_path').'/reviews/'.$product->votes->rating.'.gif';
// echo JHTML::image($img_url, $product->votes->rating.' '.JText::_('COM_VIRTUEMART_REVIEW_STARS'));
// echo JText::_('COM_VIRTUEMART_TOTAL_VOTES').": ". $product->votes->allvotes;
?>
<?php } ?>
  <?php
if ( VmConfig::get ('display_stock', 1)) { ?>
<!-- if (!VmConfig::get('use_as_catalog') and !(VmConfig::get('stockhandle','none')=='none')){?> -->
<div class="paddingtop8">
<span class="vmicon vm2-<?php echo $product->stock->stock_level ?>" title="<?php echo $product->stock->stock_tip ?>"></span>
<span class="stock-level"><?php echo JText::_ ('COM_VIRTUEMART_STOCK_LEVEL_DISPLAY_TITLE_TIP')?></span>
</div>
<?php } ?>
</div>

<div class="width70 floatright">

<h2><?php echo JHTML::link ($product->link, $product->product_name); ?></h2>

<?php // Product Short Description
if (!empty($product->product_s_desc)) {
?>
<p class="product_s_desc">
<?php echo shopFunctionsF::limitStringByWord ($product->product_s_desc, 40, '...')?>
</p>
<?php } ?>
<?echo JText::_('COM_VIRTUEMART_CART_SKU')?><span  style="font-weight: bold;">:&nbsp;<?echo $product->product_sku?></span>

<?echo '<br />';
if($product->customfields){
foreach ($product->customfields as $customfields) {
echo '';
echo $customfields->custom_title;
echo '<span  style="font-weight: bold;">:&nbsp;';
echo $customfields->display;
echo '';
}
}
echo '</span>'; ?>






<div class="product-price marginbottom12" id="productPrice<?php echo $product->virtuemart_product_id ?>">
<?php
if ($this->show_prices == '1') {
if ($product->prices['salesPrice']<=0 and VmConfig::get ('askprice', 1) and  !$product->images[0]->file_is_downloadable) {
echo JText::_ ('COM_VIRTUEMART_PRODUCT_ASKPRICE');
}
//todo add config settings
if ($this->showBasePrice) {
echo $this->currency->createPriceDiv ('basePrice', 'COM_VIRTUEMART_PRODUCT_BASEPRICE', $product->prices);
echo $this->currency->createPriceDiv ('basePriceVariant', 'COM_VIRTUEMART_PRODUCT_BASEPRICE_VARIANT', $product->prices);
}
echo $this->currency->createPriceDiv ('variantModification', 'COM_VIRTUEMART_PRODUCT_VARIANT_MOD', $product->prices);
if (round($product->prices['basePriceWithTax'],$this->currency->_priceConfig['salesPrice'][1])!= $product->prices['salesPrice']) {
echo '<span class="price-crossed" >' . $this->currency->createPriceDiv ('basePriceWithTax', 'COM_VIRTUEMART_PRODUCT_BASEPRICE_WITHTAX', $product->prices). "</span>";
}
if (round($product->prices['salesPriceWithDiscount'],$this->currency->_priceConfig['salesPrice'][1])!= $product->prices['salesPrice']) {
echo $this->currency->createPriceDiv ('salesPriceWithDiscount', 'COM_VIRTUEMART_PRODUCT_SALESPRICE_WITH_DISCOUNT', $product->prices);
}
echo $this->currency->createPriceDiv ('salesPrice', 'COM_VIRTUEMART_PRODUCT_SALESPRICE', $product->prices);
echo $this->currency->createPriceDiv ('priceWithoutTax', 'COM_VIRTUEMART_PRODUCT_SALESPRICE_WITHOUT_TAX', $product->prices);
echo $this->currency->createPriceDiv ('discountAmount', 'COM_VIRTUEMART_PRODUCT_DISCOUNT_AMOUNT', $product->prices);
echo $this->currency->createPriceDiv ('taxAmount', 'COM_VIRTUEMART_PRODUCT_TAX_AMOUNT', $product->prices);
$unitPriceDescription = JText::sprintf ('COM_VIRTUEMART_PRODUCT_UNITPRICE', $product->product_unit);
echo $this->currency->createPriceDiv ('unitPrice', $unitPriceDescription, $product->prices);
} ?>

</div>

<p>
<?php // Product Details Button
echo JHTML::link ($product->link, JText::_ ('COM_VIRTUEMART_PRODUCT_DETAILS'), array('title' => $product->product_name, 'class' => 'product-details'));
?>
</p>

</div>
<div class="clear"></div>
</div>
<!-- end of spacer -->
</div> <!-- end of product -->
<?php

// Do we need to close the current row now?
if ($iBrowseCol == $BrowseProducts_per_row || $iBrowseProduct == $BrowseTotalProducts) {
?>
<div class="clear"></div>
   </div> <!-- end of row -->
<?php
$iBrowseCol = 1;
} else {
$iBrowseCol++;
}

$iBrowseProduct++;
} // end of foreach ( $this->products as $product )
// Do we need a final closing row tag?
if ($iBrowseCol != 1) {
?>
<div class="clear"></div>

<?php
}
?>

<div class="vm-pagination"><?php echo $this->vmPagination->getPagesLinks (); ?><span style="float:right"><?php echo $this->vmPagination->getPagesCounter (); ?></span></div>

<?php
?>

« Последнее редактирование: 20.11.2013, 14:19:36 от SaidGGV »
*

magistr91

  • Осваиваюсь на форуме
  • 35
  • 1 / 0
Шаблон категории стандартный?
*

SaidGGV

  • Осваиваюсь на форуме
  • 14
  • 0 / 0
да, шаблон  по умолчанию.
При отсутствии товаров, эта часть кода не генерится на страницу
Код
<?php // Show child categories
if (!empty($this->products)) {
?>
<div class="orderby-displaynumber">
<div class="width70 floatleft">
<?php echo $this->orderByList['orderby']; ?>
<?php echo $this->orderByList['manufacturer']; ?>
</div>
<div class="width30 floatright display-number"><?php echo $this->vmPagination->getResultsCounter ();?><br/><?php echo $this->vmPagination->getLimitBox (); ?></div>
<div class="vm-pagination">
<?php echo $this->vmPagination->getPagesLinks (); ?>
<span style="float:right"><?php echo $this->vmPagination->getPagesCounter (); ?></span>
</div>

<div class="clear"></div>
</div> <!-- end of orderby-displaynumber -->

<h1><?php echo $this->category->category_name; ?></h1>
<div class="category_description">
<?php
 $start = JRequest::getInt('limitstart',0);
 $option = JRequest::getVar('option','');
If (!$start && $option == 'com_virtuemart'){ ?>
<div style="width:100%;float:left;">
 <?php echo $this->category->category_description ; ?> </div> <?php } ?>
</div>
<?php
// Category and Columns Counter
$iBrowseCol = 1;
$iBrowseProduct = 1;

// Calculating Products Per Row
$BrowseProducts_per_row = $this->perRow;
$Browsecellwidth = ' width' . floor (100 / $BrowseProducts_per_row);

// Separator
$verticalseparator = " vertical-separator";

// Count products ?? why not just count ($this->products)  ?? note by Max Milbers
$BrowseTotalProducts = 0;
foreach ($this->products as $product) {
$BrowseTotalProducts++;
}

// Start the Output
foreach ($this->products as $product) {

// Show the horizontal seperator
if ($iBrowseCol == 1 && $iBrowseProduct > $BrowseProducts_per_row) {
?>
<div class="horizontal-separator"></div>
<?php
}

// this is an indicator wether a row needs to be opened or not
if ($iBrowseCol == 1) {
?>
<div class="row">
<?php
}

// Show the vertical seperator
if ($iBrowseProduct == $BrowseProducts_per_row or $iBrowseProduct % $BrowseProducts_per_row == 0) {
$show_vertical_separator = ' ';
} else {
$show_vertical_separator = $verticalseparator;
}

// Show Products
?>
<div class="product floatleft<?php echo $Browsecellwidth . $show_vertical_separator ?>">
<div class="spacer">
<div class="width30 floatleft center">
    <a title="<?php echo $product->link ?>" rel="vm-additional-images" href="<?php echo $product->link; ?>">
<?php
echo $product->images[0]->displayMediaThumb('class="browseProductImage"', false);
?>
</a>

<!-- The "Average Customer Rating" Part -->
<?php if ($this->showRating) { ?>
<span class="contentpagetitle"><?php echo JText::_ ('COM_VIRTUEMART_CUSTOMER_RATING')?>:</span>
<br/>
<?php
// $img_url = JURI::root().VmConfig::get('assets_general_path').'/reviews/'.$product->votes->rating.'.gif';
// echo JHTML::image($img_url, $product->votes->rating.' '.JText::_('COM_VIRTUEMART_REVIEW_STARS'));
// echo JText::_('COM_VIRTUEMART_TOTAL_VOTES').": ". $product->votes->allvotes;
?>
<?php } ?>
  <?php
if ( VmConfig::get ('display_stock', 1)) { ?>
<!-- if (!VmConfig::get('use_as_catalog') and !(VmConfig::get('stockhandle','none')=='none')){?> -->
<div class="paddingtop8">
<span class="vmicon vm2-<?php echo $product->stock->stock_level ?>" title="<?php echo $product->stock->stock_tip ?>"></span>
<span class="stock-level"><?php echo JText::_ ('COM_VIRTUEMART_STOCK_LEVEL_DISPLAY_TITLE_TIP')?></span>
</div>
<?php } ?>
</div>

<div class="width70 floatright">

<h2><?php echo JHTML::link ($product->link, $product->product_name); ?></h2>

<?php // Product Short Description
if (!empty($product->product_s_desc)) {
?>
<p class="product_s_desc">
<?php echo shopFunctionsF::limitStringByWord ($product->product_s_desc, 40, '...')?>
</p>
<?php } ?>
<?echo JText::_('COM_VIRTUEMART_CART_SKU')?><span  style="font-weight: bold;">:&nbsp;<?echo $product->product_sku?></span>

<?echo '<br />';
if($product->customfields){
foreach ($product->customfields as $customfields) {
echo '';
echo $customfields->custom_title;
echo '<span  style="font-weight: bold;">:&nbsp;';
echo $customfields->display;
echo '';
}
}
echo '</span>'; ?>






<div class="product-price marginbottom12" id="productPrice<?php echo $product->virtuemart_product_id ?>">
<?php
if ($this->show_prices == '1') {
if ($product->prices['salesPrice']<=0 and VmConfig::get ('askprice', 1) and  !$product->images[0]->file_is_downloadable) {
echo JText::_ ('COM_VIRTUEMART_PRODUCT_ASKPRICE');
}
//todo add config settings
if ($this->showBasePrice) {
echo $this->currency->createPriceDiv ('basePrice', 'COM_VIRTUEMART_PRODUCT_BASEPRICE', $product->prices);
echo $this->currency->createPriceDiv ('basePriceVariant', 'COM_VIRTUEMART_PRODUCT_BASEPRICE_VARIANT', $product->prices);
}
echo $this->currency->createPriceDiv ('variantModification', 'COM_VIRTUEMART_PRODUCT_VARIANT_MOD', $product->prices);
if (round($product->prices['basePriceWithTax'],$this->currency->_priceConfig['salesPrice'][1])!= $product->prices['salesPrice']) {
echo '<span class="price-crossed" >' . $this->currency->createPriceDiv ('basePriceWithTax', 'COM_VIRTUEMART_PRODUCT_BASEPRICE_WITHTAX', $product->prices). "</span>";
}
if (round($product->prices['salesPriceWithDiscount'],$this->currency->_priceConfig['salesPrice'][1])!= $product->prices['salesPrice']) {
echo $this->currency->createPriceDiv ('salesPriceWithDiscount', 'COM_VIRTUEMART_PRODUCT_SALESPRICE_WITH_DISCOUNT', $product->prices);
}
echo $this->currency->createPriceDiv ('salesPrice', 'COM_VIRTUEMART_PRODUCT_SALESPRICE', $product->prices);
echo $this->currency->createPriceDiv ('priceWithoutTax', 'COM_VIRTUEMART_PRODUCT_SALESPRICE_WITHOUT_TAX', $product->prices);
echo $this->currency->createPriceDiv ('discountAmount', 'COM_VIRTUEMART_PRODUCT_DISCOUNT_AMOUNT', $product->prices);
echo $this->currency->createPriceDiv ('taxAmount', 'COM_VIRTUEMART_PRODUCT_TAX_AMOUNT', $product->prices);
$unitPriceDescription = JText::sprintf ('COM_VIRTUEMART_PRODUCT_UNITPRICE', $product->product_unit);
echo $this->currency->createPriceDiv ('unitPrice', $unitPriceDescription, $product->prices);
} ?>

</div>

<p>
<?php // Product Details Button
echo JHTML::link ($product->link, JText::_ ('COM_VIRTUEMART_PRODUCT_DETAILS'), array('title' => $product->product_name, 'class' => 'product-details'));
?>
</p>

</div>
<div class="clear"></div>
</div>
<!-- end of spacer -->
</div> <!-- end of product -->
<?php

// Do we need to close the current row now?
if ($iBrowseCol == $BrowseProducts_per_row || $iBrowseProduct == $BrowseTotalProducts) {
?>
<div class="clear"></div>
   </div> <!-- end of row -->
<?php
$iBrowseCol = 1;
} else {
$iBrowseCol++;
}

$iBrowseProduct++;
} // end of foreach ( $this->products as $product )
// Do we need a final closing row tag?
if ($iBrowseCol != 1) {
?>
<div class="clear"></div>

<?php
}
?>

<div class="vm-pagination"><?php echo $this->vmPagination->getPagesLinks (); ?><span style="float:right"><?php echo $this->vmPagination->getPagesCounter (); ?></span></div>

<?php
} elseif ($this->search !== NULL) {
echo JText::_ ('COM_VIRTUEMART_NO_RESULT'). ($this->keyword ? ' : (' . $this->keyword . ')' : '');
}
?>
Чтобы оставить сообщение,
Вам необходимо Войти или Зарегистрироваться
 

Не отображаются товары в категории

Автор iZacNT

Ответов: 0
Просмотров: 2986
Последний ответ 23.06.2023, 12:20:49
от iZacNT
Перестали выводиться категории

Автор sergspb

Ответов: 0
Просмотров: 3136
Последний ответ 12.02.2022, 12:53:31
от sergspb
Привязка кода как id как категории так и меню

Автор Stasweb

Ответов: 8
Просмотров: 1200
Последний ответ 18.11.2020, 12:37:06
от Stasweb
Дублируются категории, как исправить

Автор Stasweb

Ответов: 2
Просмотров: 961
Последний ответ 05.11.2020, 09:14:01
от Stasweb
Как увеличить краткое описание?

Автор Wargoth

Ответов: 1
Просмотров: 685
Последний ответ 01.10.2020, 12:14:12
от Wargoth