Show retail price and registered when logged

  • Posts: 1115
  • Thank you received: 12
  • Hikashop Business
10 years 8 months ago #183820

-- HikaShop version -- : 2.3.4
-- Joomla version -- : 3.3.6
-- PHP version -- : 5.4

Hi there!
Is there a way to show retail price and resgisted at the same time for logged in users?
I created a user group and asigned a user on it.
I have a producyt with retail price 2€ and price (for registered users) 5€.
When I m logged I can see both prices.
When I logout I see retail. Why I can see retail since I m logged out?

My goal is to have logged in users see both price retail and wholesale price.
but if you are logged out, you can see No price

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
10 years 8 months ago #183825

Hi,

You can edit the view "product / listing_price" and replace:

if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){ ?>
By:
if(hikasop_loadUser() != null && isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){ ?>
And:
if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){
By:
if(hikasop_loadUser() != null && isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){

Please Log in or Create an account to join the conversation.

  • Posts: 1115
  • Thank you received: 12
  • Hikashop Business
10 years 8 months ago #183897

Do you mean this

if(isset($this->element->main->product_msrp) && !(@$this->row->product_msrp > 0.0) )
$this->row->product_msrp = $this->element->main->product_msrp;
if(hikasop_loadUser() != null && isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){ ?>

because I cant find the second part as it is written on your post

Last edit: 10 years 8 months ago by verzevoul.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
10 years 8 months ago #183908

Hi,

Yes this code, I guess that you have a different one because you edited it before in order to display the retail price on listings and in modules too ;)

Please Log in or Create an account to join the conversation.

  • Posts: 1115
  • Thank you received: 12
  • Hikashop Business
10 years 8 months ago #184089

Sorry xavier but I can t make it. my code is

==============================

<?php
/**
 * @package	HikaShop for Joomla!
 * @version	2.3.4
 * @author	hikashop.com
 * @copyright	(C) 2010-2014 HIKARI SOFTWARE. All rights reserved.
 * @license	GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
 */
defined('_JEXEC') or die('Restricted access');
?><?php
$class ='';
if(!empty($this->row->prices) && count($this->row->prices)>1){
	$class = ' hikashop_product_several_prices';
}
if(isset($this->element->main->product_msrp) && !(@$this->row->product_msrp > 0.0) )
	$this->row->product_msrp = $this->element->main->product_msrp;
if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){ ?>
	<span class="hikashop_product_msrp_price hikashop_product_price_full">
		<span class="hikashop_product_msrp_price_title">
		<?php
			echo JText::_('PRODUCT_MSRP_BEFORE');
		?>
		</span>
		<span class="hikashop_product_price">
		<?php
			$mainCurr = $this->currencyHelper->mainCurrency();
			$app = JFactory::getApplication();
			$currCurrency = $app->getUserState( HIKASHOP_COMPONENT.'.currency_id', $mainCurr );
			$msrpCurrencied = $this->currencyHelper->convertUniquePrice($this->row->product_msrp,$mainCurr,$currCurrency);
			if($msrpCurrencied == $this->row->product_msrp)
				echo $this->currencyHelper->format($this->row->product_msrp,$mainCurr);
			else
				echo $this->currencyHelper->format($msrpCurrencied,$currCurrency).' ('.$this->currencyHelper->format($this->row->product_msrp,$mainCurr).')';
		?>
		</span>
	</span>
<?php } ?>

	<span class="hikashop_product_price_full<?php echo $class; ?>">
	<?php
	if(empty($this->row->prices)){
		echo JText::_('FREE_PRICE');
	}else{
		$first = true;
		echo JText::_('PRICE_BEGINNING');
		$i=0;

		if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){
			echo '<span class="hikashop_product_our_price_title">'.JText::_('PRODUCT_MSRP_AFTER').'</span> ';
		}

		$config =& hikashop_config();
		if($this->params->get('price_with_tax',3)==3){
			$this->params->set('price_with_tax',$config->get('price_with_tax'));
		}
		if($this->params->get('show_discount',3)==3){
			$this->params->set('show_discount',$config->get('show_discount'));
		}
		if($this->params->get('show_original_price','-1')=='-1'){
			$this->params->set('show_original_price',$config->get('show_original_price'));
		}
		if($this->params->get('show_original_price','-1')=='-1'){
			$this->params->set('show_original_price',$config->get('show_original_price'));
		}

		foreach($this->row->prices as $k => $price){
			if($first)$first=false;
			else echo JText::_('PRICE_SEPARATOR');
			if(!empty($this->unit) && isset($price->unit_price)){
				$price =& $price->unit_price;
			}
			$start = JText::_('PRICE_BEGINNING_'.$i);
			if($start!='PRICE_BEGINNING_'.$i){
				echo $start;
			}
			if(isset($price->price_min_quantity) && empty($this->cart_product_price) && $price->price_min_quantity>1){
				echo '<span class="hikashop_product_price_with_min_qty hikashop_product_price_for_at_least_'.$price->price_min_quantity.'">';
			}

			$classes = array('hikashop_product_price hikashop_product_price_'.$i);
			if(!empty($this->row->discount)){
				$classes[]='hikashop_product_price_with_discount';
			}

			if(!empty($this->row->discount)){
				if($this->params->get('show_discount')==1){
					echo '<span class="hikashop_product_discount">'.JText::_('PRICE_DISCOUNT_START');
					if(bccomp($this->row->discount->discount_flat_amount,0,5)!==0){
						echo $this->currencyHelper->format(-1*$this->row->discount->discount_flat_amount,$price->price_currency_id);
					}elseif(bccomp($this->row->discount->discount_percent_amount,0,5)!==0){
						echo -1*$this->row->discount->discount_percent_amount.'%';
					}
					echo JText::_('PRICE_DISCOUNT_END').'</span>';
				}elseif($this->params->get('show_discount')==2){
					echo '<span class="hikashop_product_price_before_discount">'.JText::_('PRICE_DISCOUNT_START');
					if($this->params->get('price_with_tax')){
						echo $this->currencyHelper->format($price->price_value_without_discount_with_tax,$price->price_currency_id);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_BEFORE_TAX');
					}
					if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
						echo $this->currencyHelper->format($price->price_value_without_discount,$price->price_currency_id);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_AFTER_TAX');
					}
					if($this->params->get('show_original_price') && !empty($price->price_orig_value_without_discount_with_tax)){
						echo JText::_('PRICE_BEFORE_ORIG');
						if($this->params->get('price_with_tax')){
							echo $this->currencyHelper->format($price->price_orig_value_without_discount_with_tax,$price->price_orig_currency_id);
						}
						if($this->params->get('price_with_tax')==2){
							echo JText::_('PRICE_BEFORE_TAX');
						}
						if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax') && !empty($price->price_orig_value_without_discount)){
							echo $this->currencyHelper->format($price->price_orig_value_without_discount,$price->price_orig_currency_id);
						}
						if($this->params->get('price_with_tax')==2){
							echo JText::_('PRICE_AFTER_TAX');
						}
						echo JText::_('PRICE_AFTER_ORIG');
					}
					echo JText::_('PRICE_DISCOUNT_END').'</span>';
				}elseif($this->params->get('show_discount')==3){

				}
			}

			echo '<span class="'.implode(' ',$classes).'">';
			if($this->params->get('price_with_tax')){
				echo $this->currencyHelper->format(@$price->price_value_with_tax,$price->price_currency_id);
			}
			if($this->params->get('price_with_tax')==2){
				echo JText::_('PRICE_BEFORE_TAX');
			}
			if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
				echo $this->currencyHelper->format(@$price->price_value,$price->price_currency_id);
			}
			if($this->params->get('price_with_tax')==2){
				echo JText::_('PRICE_AFTER_TAX');
			}
			if($this->params->get('show_original_price') && !empty($price->price_orig_value)){
				echo JText::_('PRICE_BEFORE_ORIG');
				if($this->params->get('price_with_tax')){
					echo $this->currencyHelper->format($price->price_orig_value_with_tax,$price->price_orig_currency_id);
				}
				if($this->params->get('price_with_tax')==2){
					echo JText::_('PRICE_BEFORE_TAX');
				}
				if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
					echo $this->currencyHelper->format($price->price_orig_value,$price->price_orig_currency_id);
				}
				if($this->params->get('price_with_tax')==2){
					echo JText::_('PRICE_AFTER_TAX');
				}
				echo JText::_('PRICE_AFTER_ORIG');
			}
			echo '</span> ';
			if(isset($price->price_min_quantity) && empty($this->cart_product_price) && $this->params->get('per_unit',1)){
				if($price->price_min_quantity>1){
					echo '<span class="hikashop_product_price_per_unit_x">'.JText::sprintf('PER_UNIT_AT_LEAST_X_BOUGHT',$price->price_min_quantity).'</span>';
				}else{
					echo '<span class="hikashop_product_price_per_unit">'.JText::_('PER_UNIT').'</span>';
				}
			}
			if($this->params->get('show_price_weight')){
				if(!empty($this->element->product_id) && isset($this->row->product_weight) && bccomp($this->row->product_weight,0,3)){

					echo JText::_('PRICE_SEPARATOR').'<span class="hikashop_product_price_per_weight_unit">';
					if($this->params->get('price_with_tax')){
						$weight_price = $price->price_value_with_tax / $this->row->product_weight;
						echo $this->currencyHelper->format($weight_price,$price->price_currency_id).' / '.JText::_($this->row->product_weight_unit);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_BEFORE_TAX');
					}
					if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
						$weight_price = $price->price_value / $this->row->product_weight;
						echo $this->currencyHelper->format($weight_price,$price->price_currency_id).' / '.JText::_($this->row->product_weight_unit);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_AFTER_TAX');
					}
					echo '</span>';
				}
			}
			if(isset($price->price_min_quantity) && empty($this->cart_product_price) && $price->price_min_quantity>1){
				echo '</span>';
			}
			$end = JText::_('PRICE_ENDING_'.$i);
			if($end!='PRICE_ENDING_'.$i){
				echo $end;
			}
			$i++;
		}
		echo JText::_('PRICE_END');
	}
	?></span>
===========================
But it isnt changed (there is no trash in listing which shows the overide.)

Can you paste here the correct one?

Last edit: 10 years 8 months ago by Xavier. Reason: Use of [code]...[/code] tags

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
10 years 8 months ago #184103

Hi,

Here is the original code of this view:

<?php
$class ='';
if(!empty($this->row->prices) && count($this->row->prices)>1){
	$class = ' hikashop_product_several_prices';
}
if(isset($this->element->main->product_msrp) && !(@$this->row->product_msrp > 0.0) )
	$this->row->product_msrp = $this->element->main->product_msrp;
if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){ ?>
	<span class="hikashop_product_msrp_price hikashop_product_price_full">
		<span class="hikashop_product_msrp_price_title">
		<?php
			echo JText::_('PRODUCT_MSRP_BEFORE');
		?>
		</span>
		<span class="hikashop_product_price">
		<?php
			$mainCurr = $this->currencyHelper->mainCurrency();
			$app = JFactory::getApplication();
			$currCurrency = $app->getUserState( HIKASHOP_COMPONENT.'.currency_id', $mainCurr );
			$msrpCurrencied = $this->currencyHelper->convertUniquePrice($this->row->product_msrp,$mainCurr,$currCurrency);
			if($msrpCurrencied == $this->row->product_msrp)
				echo $this->currencyHelper->format($this->row->product_msrp,$mainCurr);
			else
				echo $this->currencyHelper->format($msrpCurrencied,$currCurrency).' ('.$this->currencyHelper->format($this->row->product_msrp,$mainCurr).')';
		?>
		</span>
	</span>
<?php } ?>

	<span class="hikashop_product_price_full<?php echo $class; ?>">
	<?php
	if(empty($this->row->prices)){
		echo JText::_('FREE_PRICE');
	}else{
		$first = true;
		echo JText::_('PRICE_BEGINNING');
		$i=0;

		if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){
			echo '<span class="hikashop_product_our_price_title">'.JText::_('PRODUCT_MSRP_AFTER').'</span> ';
		}

		$config =& hikashop_config();
		if($this->params->get('price_with_tax',3)==3){
			$this->params->set('price_with_tax',$config->get('price_with_tax'));
		}
		if($this->params->get('show_discount',3)==3){
			$this->params->set('show_discount',$config->get('show_discount'));
		}
		if($this->params->get('show_original_price','-1')=='-1'){
			$this->params->set('show_original_price',$config->get('show_original_price'));
		}
		if($this->params->get('show_original_price','-1')=='-1'){
			$this->params->set('show_original_price',$config->get('show_original_price'));
		}

		foreach($this->row->prices as $k => $price){
			if($first)$first=false;
			else echo JText::_('PRICE_SEPARATOR');
			if(!empty($this->unit) && isset($price->unit_price)){
				$price =& $price->unit_price;
			}
			$start = JText::_('PRICE_BEGINNING_'.$i);
			if($start!='PRICE_BEGINNING_'.$i){
				echo $start;
			}
			if(isset($price->price_min_quantity) && empty($this->cart_product_price) && $price->price_min_quantity>1){
				echo '<span class="hikashop_product_price_with_min_qty hikashop_product_price_for_at_least_'.$price->price_min_quantity.'">';
			}

			$classes = array('hikashop_product_price hikashop_product_price_'.$i);
			if(!empty($this->row->discount)){
				$classes[]='hikashop_product_price_with_discount';
			}

			if(!empty($this->row->discount)){
				if($this->params->get('show_discount')==1){
					echo '<span class="hikashop_product_discount">'.JText::_('PRICE_DISCOUNT_START');
					if(bccomp($this->row->discount->discount_flat_amount,0,5)!==0){
						echo $this->currencyHelper->format(-1*$this->row->discount->discount_flat_amount,$price->price_currency_id);
					}elseif(bccomp($this->row->discount->discount_percent_amount,0,5)!==0){
						echo -1*$this->row->discount->discount_percent_amount.'%';
					}
					echo JText::_('PRICE_DISCOUNT_END').'</span>';
				}elseif($this->params->get('show_discount')==2){
					echo '<span class="hikashop_product_price_before_discount">'.JText::_('PRICE_DISCOUNT_START');
					if($this->params->get('price_with_tax')){
						echo $this->currencyHelper->format($price->price_value_without_discount_with_tax,$price->price_currency_id);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_BEFORE_TAX');
					}
					if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
						echo $this->currencyHelper->format($price->price_value_without_discount,$price->price_currency_id);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_AFTER_TAX');
					}
					if($this->params->get('show_original_price') && !empty($price->price_orig_value_without_discount_with_tax)){
						echo JText::_('PRICE_BEFORE_ORIG');
						if($this->params->get('price_with_tax')){
							echo $this->currencyHelper->format($price->price_orig_value_without_discount_with_tax,$price->price_orig_currency_id);
						}
						if($this->params->get('price_with_tax')==2){
							echo JText::_('PRICE_BEFORE_TAX');
						}
						if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax') && !empty($price->price_orig_value_without_discount)){
							echo $this->currencyHelper->format($price->price_orig_value_without_discount,$price->price_orig_currency_id);
						}
						if($this->params->get('price_with_tax')==2){
							echo JText::_('PRICE_AFTER_TAX');
						}
						echo JText::_('PRICE_AFTER_ORIG');
					}
					echo JText::_('PRICE_DISCOUNT_END').'</span>';
				}elseif($this->params->get('show_discount')==3){

				}
			}

			echo '<span class="'.implode(' ',$classes).'">';
			if($this->params->get('price_with_tax')){
				echo $this->currencyHelper->format(@$price->price_value_with_tax,$price->price_currency_id);
			}
			if($this->params->get('price_with_tax')==2){
				echo JText::_('PRICE_BEFORE_TAX');
			}
			if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
				echo $this->currencyHelper->format(@$price->price_value,$price->price_currency_id);
			}
			if($this->params->get('price_with_tax')==2){
				echo JText::_('PRICE_AFTER_TAX');
			}
			if($this->params->get('show_original_price') && !empty($price->price_orig_value)){
				echo JText::_('PRICE_BEFORE_ORIG');
				if($this->params->get('price_with_tax')){
					echo $this->currencyHelper->format($price->price_orig_value_with_tax,$price->price_orig_currency_id);
				}
				if($this->params->get('price_with_tax')==2){
					echo JText::_('PRICE_BEFORE_TAX');
				}
				if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
					echo $this->currencyHelper->format($price->price_orig_value,$price->price_orig_currency_id);
				}
				if($this->params->get('price_with_tax')==2){
					echo JText::_('PRICE_AFTER_TAX');
				}
				echo JText::_('PRICE_AFTER_ORIG');
			}
			echo '</span> ';
			if(isset($price->price_min_quantity) && empty($this->cart_product_price) && $this->params->get('per_unit',1)){
				if($price->price_min_quantity>1){
					echo '<span class="hikashop_product_price_per_unit_x">'.JText::sprintf('PER_UNIT_AT_LEAST_X_BOUGHT',$price->price_min_quantity).'</span>';
				}else{
					echo '<span class="hikashop_product_price_per_unit">'.JText::_('PER_UNIT').'</span>';
				}
			}
			if($this->params->get('show_price_weight')){
				if(!empty($this->element->product_id) && isset($this->row->product_weight) && bccomp($this->row->product_weight,0,3)){

					echo JText::_('PRICE_SEPARATOR').'<span class="hikashop_product_price_per_weight_unit">';
					if($this->params->get('price_with_tax')){
						$weight_price = $price->price_value_with_tax / $this->row->product_weight;
						echo $this->currencyHelper->format($weight_price,$price->price_currency_id).' / '.JText::_($this->row->product_weight_unit);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_BEFORE_TAX');
					}
					if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
						$weight_price = $price->price_value / $this->row->product_weight;
						echo $this->currencyHelper->format($weight_price,$price->price_currency_id).' / '.JText::_($this->row->product_weight_unit);
					}
					if($this->params->get('price_with_tax')==2){
						echo JText::_('PRICE_AFTER_TAX');
					}
					echo '</span>';
				}
			}
			if(isset($price->price_min_quantity) && empty($this->cart_product_price) && $price->price_min_quantity>1){
				echo '</span>';
			}
			$end = JText::_('PRICE_ENDING_'.$i);
			if($end!='PRICE_ENDING_'.$i){
				echo $end;
			}
			$i++;
		}
		echo JText::_('PRICE_END');
	}
	?></span>

But you should see the dustbin icon in the listing, or check in the template folder if there is no override of that view.
If not, so it is potentially because you edited that view directly in the hikashop views, so no overrides..

Please Log in or Create an account to join the conversation.

  • Posts: 1115
  • Thank you received: 12
  • Hikashop Business
10 years 8 months ago #184246

I tried but again in the product view I can see only the picture after the changes
Can you check it for me please?

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
10 years 8 months ago #184321

Hi,

I just added the indicated code from the second post of this topic to the original code given previously and it' working as expected ;)

Please Log in or Create an account to join the conversation.

  • Posts: 1115
  • Thank you received: 12
  • Hikashop Business
10 years 2 months ago #208366

Is this post valid for newer versions? (latest)

Please Log in or Create an account to join the conversation.

  • Posts: 84306
  • Thank you received: 13701
  • MODERATOR
10 years 2 months ago #208372

Yes.

Please Log in or Create an account to join the conversation.

  • Posts: 56
  • Thank you received: 2
9 years 9 months ago #222579

I'm having the same problem.
It breaks the page, page becomes white, with only product images and title and product_code not styled, but that's it.
I have the exact same code you used too ( using original from HS 2.6.0)
Php failed to render the rest of the code, so there's an error somewhere in there, ???

Anyways, I wrote a little php as I only need to know if a user form a certain group.
So i just use Joomla functions to get it.

First I made template override for prodcut's listing_price.php to my templates html>com_hikashop>products directory.
The open the copied listing_price.php and added this code:

$user = JFactory::getUser();
//Get group id number array
$usergroup = $user->getAuthorisedGroups();

Then create conditional statement to show the prices you want to show to that group.
if(in_array(10,$usergroup)){
	if(isset($this->element->main->product_msrp) && !(@$this->row->product_msrp > 0.0) )
		$this->row->product_msrp = $this->element->main->product_msrp;
	if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){ ?>
		<div class="hikashop_product_msrp_price hikashop_product_price_full">
			<span class="hikashop_product_msrp_price_title">
			<?php
				echo JText::_('PRODUCT_MSRP_BEFORE');
			?>
			</span>
			<span class="hikashop_product_price">
			<?php
				$mainCurr = $this->currencyHelper->mainCurrency();
				$app = JFactory::getApplication();
				$currCurrency = $app->getUserState( HIKASHOP_COMPONENT.'.currency_id', $mainCurr );
				$msrpCurrencied = $this->currencyHelper->convertUniquePrice($this->row->product_msrp,$mainCurr,$currCurrency);
				if($msrpCurrencied == $this->row->product_msrp)
					echo $this->currencyHelper->format($this->row->product_msrp,$mainCurr);
				else
					echo $this->currencyHelper->format($msrpCurrencied,$currCurrency).' ('.$this->currencyHelper->format($this->row->product_msrp,$mainCurr).')';
			?>
			</span>
		</div>
<?php } 
}?>

.... further down the page.....

if(in_array(10,$usergroup)){
			if(isset($this->row->product_msrp) && @$this->row->product_msrp > 0.0 && JRequest::getCmd('layout') == 'show' && $this->params->get('from_module','') == ''){
				echo '<span class="hikashop_product_our_price_title">'.JText::_('PRODUCT_MSRP_AFTER').'</span> ';
			}
		}

In my case groupid = 10, which is a group I created callled: Retailers.
So now, If log in using a retailers account I see both prices.
Now the I just have to alter the Product's Price ACL ( Prices and taxes section) , enter a 'Retail price' (for retailers) and 'Price' for consume and click the ACL and deselect retailers, I think????

Please Hikashop crew, correct me if I wrong, but shouldn't that disable 'Price' and force Hikashop to use the 'Retail price' ???

Thx in advance.

I wanted isolate the retail price from the price and only show it to retailers who want to buy this stores products.

Please Log in or Create an account to join the conversation.

  • Posts: 84306
  • Thank you received: 13701
  • MODERATOR
9 years 9 months ago #222693

Hi,

It breaks the page, page becomes white, with only product images and title and product_code not styled, but that's it.

This means that you've made a mistake in the code that you wrote. We would need the fatal error message that is in your PHP error log file regarding that blank page, and the full code of the file where that error is (probably the file where you did your modifications). Then we can tell you what's wrong with it.

The "Retail price" that you can set in a product is only for display on the product page. It cannot be used in the cart/checkout, and especially not with modifications in the views. But just for the purpose of the display of the prices, yes, you can alter the views to change the display of the price using the retail price.

Please Log in or Create an account to join the conversation.

  • Posts: 56
  • Thank you received: 2
9 years 9 months ago #222713

No, I'm sorry but I didn't make a mistake. I tried it several times.
I even just copied your original listing_price.php that you posted , added the code and I still get the same result, again.

But now that you say the retail price is only for display, I'll have to find another solution, which I think I already have touched upon, is to assign the Price's ACL to the corresponding user groups, right ?

Or maybe it has something to do with this horrible template I'm now stuck with: Holax template by BD Themes.
Worst template ever, they only styled the product details page and the product_listing.php the rest they just left, so the HS carousel doesn't work, no category menu style, the main menu drop down's go off page, the WArp framework is joke compared to all the other amazing ones out there(it's bascially Uikit revamped). If you make changes to the theme manually , then you use the framework to make a change and save it , it will overwrite all the changes you did; plus the support they offer is virtually non-existant, as they just try and brush you off by passing to blame on to Hikashop or Joomla or whatever they can conjure up to not help you. basically no assistance just resistance.
Hikashop should think twice before recommending them on your template page, as what they did so far is far form complete.

Sorry, but had to get that off my chest, it's been so frustrating.

Please Log in or Create an account to join the conversation.

  • Posts: 84306
  • Thank you received: 13701
  • MODERATOR
9 years 9 months ago #222716

Hi,

Even if you didn't make any mistake, we still need the fatal error message that you get with the modification. Otherwise, we can't tell you what's wrong.

But yes, you can have different prices for different user groups with the "ACL" column of the product prices listing.

Thank you for your feedback on your template. We'll take it into account.

Please Log in or Create an account to join the conversation.

Time to create page: 0.083 seconds
Powered by Kunena Forum