× Здесь вы можете свободно общаться на русском языке. Просим отнестись с пониманием к тому, что мы не разговариваем на этом языке и не можем осуществлять поддержку на нем.

Количество товара и его ограничение (сбой)

  • Posts: 68
  • Thank you received: 0
8 years 7 months ago #237244

пробовал 1-неограничен
также

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

  • Posts: 68
  • Thank you received: 0
8 years 7 months ago #237245

Xavier ответил попробую
роюсь ищу где находится файл show_quantity
www.hikashop.com/forum/orders-management/883923.html#237006

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

  • Posts: 68
  • Thank you received: 0
8 years 7 months ago #237247

Решено!Ура работает!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!Спасибо огромное Xavier дорогой человек!!!!!!!!!!!!!!!! Спасибо!!!!!!!!Спасибо!!!!!!!!Спасибо!!!!!!!!Спасибо!!!!!!!!Низкий поклон Вам!!!!!!!
www.hikashop.com/forum/orders-management/883923.html#237006

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

  • Posts: 68
  • Thank you received: 0
8 years 7 months ago #237252

Версию скорректировали!!!!!!!
Скачал.
Версия 2.6.2

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

  • Posts: 68
  • Thank you received: 0
8 years 7 months ago #237254

файл находится по адресу
/components/com_hikashop/views/product/tmpl/show_quantity.php

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

  • Posts: 68
  • Thank you received: 0
8 years 7 months ago #237255

Изменение чтобы не переустанавливать.

<?php
/**
 * @package	HikaShop for Joomla!
 * @version	2.6.2
 * @author	hikashop.com
 * @copyright	(C) 2010-2016 HIKARI SOFTWARE. All rights reserved.
 * @license	GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
 */

$i = $this->params->get('i');
$min_quantity = ($this->params->get('min_quantity'))?$this->params->get('min_quantity'):1;
$max_quantity = $this->params->get('max_quantity','0');
$html = $this->params->get('html');

$qLayout = JRequest::getVar('quantitylayout','show_default');
switch($qLayout){
	case 'show_none':
?>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_regrouped">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_regrouped':
?>
		<div class="input-append hikashop_product_quantity_div hikashop_product_quantity_input_div_regrouped">
			<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="text" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
			<div class="add-on hikashop_product_quantity_div hikashop_product_quantity_change_div_regrouped">
				<div class="hikashop_product_quantity_change_div_plus_regrouped">
					<a id="hikashop_product_quantity_field_change_plus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_plus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',1,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">+</a>
				</div>
				<div class="hikashop_product_quantity_change_div_plus_regrouped">
					<a id="hikashop_product_quantity_field_change_minus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_minus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',0,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">&ndash;</a>
				</div>
			</div>
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_regrouped">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_select':
		if(!$max_quantity)
			$max_quantity = (int)$min_quantity * 15;
?>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_input_div_select">
			<select id="hikashop_product_quantity_select_<?php echo $i; ?>" onchange="var id = this.id.replace('select','field'); document.getElementById(id).value = this.value;">
				<?php
				for($j = $min_quantity; $j <= $max_quantity; $j += $min_quantity){
					echo '<option value="'.$j.'">'.$j.'</option>';
				}
				?>
			</select>
			<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="hidden" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_select">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_select_price':
		if(!$max_quantity)
			$max_quantity = (int)$min_quantity * 15;
?>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_input_div_select">
			<select id="hikashop_product_quantity_select_<?php echo $i; ?>" onchange="var id = this.id.replace('select','field'); document.getElementById(id).value = this.value;">
				<?php
				$pricesSet = array();
				foreach($this->row->prices as $price){
					if($price->price_min_quantity == 0)
						$price->price_min_quantity = 1;
					if(in_array($price->price_min_quantity,$pricesSet) || $price->price_min_quantity < $min_quantity || $price->price_min_quantity > $max_quantity)
						continue;
					$pricesSet[] = $price->price_min_quantity;
					echo '<option value="'.$price->price_min_quantity.'">'.$price->price_min_quantity.'</option>';
				}
				if(empty($pricesSet)){
					for($j = $min_quantity; $j <= $max_quantity; $j += $min_quantity){
						echo '<option value="'.$j.'">'.$j.'</option>';
					}
				}
				?>
			</select>
			<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="hidden" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_select">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_simple':
?>
		<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="hidden" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" />
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_simple">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_leftright':
?>
		<div class="input-prepend input-append hikashop_product_quantity_div hikashop_product_quantity_change_div_leftright">
			<span class="add-on">
				<a id="hikashop_product_quantity_field_change_plus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_plus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',1,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">+</a>
			</span>
			<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="text" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
			<span class="add-on">
				<a id="hikashop_product_quantity_field_change_minus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_minus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',0,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">&ndash;</a>
			</span>
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_leftright">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_simplified':
?>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_input_div_simplified">
			<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="text" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_simplified">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_default_div':
?>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_input_div_default">
			<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="text" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_change_div_default">
			<div class="hikashop_product_quantity_change_div_plus_default">
				<a id="hikashop_product_quantity_field_change_plus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_plus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',1,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">+</a>
			</div>
			<div class="hikashop_product_quantity_change_div_minus_default">
				<a id="hikashop_product_quantity_field_change_minus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_minus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',0,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">&ndash;</a>
			</div>
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_default">
			<?php echo $html; ?>
		</div>
<?php
		break;

	case 'show_default':
?>
		<table>
			<tr>
				<td rowspan="2">
					<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="text" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
				</td>
				<td>
					<a id="hikashop_product_quantity_field_change_plus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_plus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',1,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">+</a>
				</td>
				<td rowspan="2">
					<?php echo $html; ?>
				</td>
			</tr>
			<tr>
				<td>
					<a id="hikashop_product_quantity_field_change_minus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_minus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',0,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">&ndash;</a>
				</td>
			</tr>
		</table>
<?php
		break;

	default:
		if(substr($qLayout,0,14) == 'show_quantity_'){
			$doc = JFactory::getDocument();
			$app = JFactory::getApplication();
			$quantityDisplayType = hikashop_get('type.quantitydisplay');
			if($quantityDisplayType->check( $qLayout, $app->getTemplate())){
				$controller = new hikashopBridgeController(array('name'=>'product'));
				$viewType	= $doc->getType();
				if(!HIKASHOP_PHP5) {
					$view = & $controller->getView( '', $viewType, '');
				} else {
					$view = $controller->getView( '', $viewType, '');
				}
				$view->setLayout($qLayout);
				echo $view->loadTemplate();
				break;
			}
		}
?>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_input_div_default">
			<input id="hikashop_product_quantity_field_<?php echo $i; ?>" type="text" value="<?php echo JRequest::getInt('quantity',$min_quantity); ?>" class="hikashop_product_quantity_field" name="quantity" onchange="hikashopCheckQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);" />
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_change_div_default">
			<div class="hikashop_product_quantity_change_div_plus_default">
				<a id="hikashop_product_quantity_field_change_plus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_plus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',1,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">+</a>
			</div>
			<div class="hikashop_product_quantity_change_div_minus_default">
				<a id="hikashop_product_quantity_field_change_minus_<?php echo $i; ?>" class="hikashop_product_quantity_field_change_minus hikashop_product_quantity_field_change" href="#" onclick="return hikashopQuantityChange('hikashop_product_quantity_field_<?php echo $i; ?>',0,<?php echo $max_quantity; ?>,<?php echo $min_quantity; ?>);">&ndash;</a>
			</div>
		</div>
		<div class="hikashop_product_quantity_div hikashop_product_quantity_add_to_cart_div hikashop_product_quantity_add_to_cart_div_default">
			<?php echo $html; ?>
		</div>
<?php
		break;
}

Last edit: 8 years 7 months ago by progreccor.

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

  • Posts: 68
  • Thank you received: 0
8 years 7 months ago #237256

Всем спасибо не ругайтесь.
Пока пока пока...........

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

  • Posts: 2293
  • Thank you received: 315
8 years 7 months ago #237287

я не поленился и сравнил этот файл с тем, что есть у меня в установленной хика.
Ни одного отличия.

Ну и на всякий случай повторю для вас - скачивать надо с сайта hikashop.com


Я не явлюсь официальной службой поддержки!
Я здесь добровольно!

Хочешь получить купон на скидку Hikashop? Спроси меня как!

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

  • Posts: 2293
  • Thank you received: 315
8 years 7 months ago #237297

и менять надо не в каком-то файле в файловой системе - для этого в хика предусмотрены шаблоны:


Я не явлюсь официальной службой поддержки!
Я здесь добровольно!

Хочешь получить купон на скидку Hikashop? Спроси меня как!
Attachments:

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

Moderators: progreccor
Time to create page: 0.089 seconds
Powered by Kunena Forum