We were able to reproduce the problem on our end and fixed it. You need to replace the code
if($coupon->discount_quota && $coupon->discount_quota<=$coupon->discount_used_times){
$error_message = JText::_('QUOTA_REACHED_FOR_COUPON');
}elseif($coupon->discount_zone_id && !in_array($coupon->discount_zone_id,$zones)){
$error_message = JText::_('COUPON_NOT_AVAILABLE_IN_YOUR_ZONE');
}elseif(bccomp($coupon->discount_minimum_order,0,5)){
$currency->convertCoupon($coupon,$total->prices[0]->price_currency_id);
if($coupon->discount_minimum_order>$total->prices[0]->price_value){
$error_message = JText::sprintf('ORDER_NOT_EXPENSIVE_ENOUGH_FOR_COUPON',$currency->format($coupon->discount_minimum_order,$coupon->discount_currency_id));
}
}
by the code
if($coupon->discount_quota && $coupon->discount_quota<=$coupon->discount_used_times){
$error_message = JText::_('QUOTA_REACHED_FOR_COUPON');
}else{
if($coupon->discount_zone_id){
$class = hikashop::get('class.zone');
$zone = $class->get($coupon->discount_zone_id);
if(!in_array($zone->zone_namekey,$zones)){
$error_message = JText::_('COUPON_NOT_AVAILABLE_IN_YOUR_ZONE');
}
}
if(empty($error_message) && bccomp($coupon->discount_minimum_order,0,5)){
$currency->convertCoupon($coupon,$total->prices[0]->price_currency_id);
if($coupon->discount_minimum_order>$total->prices[0]->price_value){
$error_message = JText::sprintf('ORDER_NOT_EXPENSIVE_ENOUGH_FOR_COUPON',$currency->format($coupon->discount_minimum_order,$coupon->discount_currency_id));
}
}
}
in the file administrator/components/com_hikashop/classes/discount.php near line 75. That will fix the check of the zone restriction. For the display problem of the zone name in the edit you can replace the code
if(!empty($element->price_product_id)){
$query = 'SELECT * FROM '.hikashop::table('product').' WHERE product_id = '.(int)$element->price_product_id;
$database->setQuery($query);
$product = $database->loadObject();
if(!empty($product)){
foreach(get_object_vars($product) as $key => $val){
$element->$key = $val;
}
}
}
if(empty($element->product_name)){
$element->product_name = JText::_('PRODUCT_NOT_FOUND');
}
//get category info
if(!empty($element->price_category_id)){
$query = 'SELECT * FROM '.hikashop::table('category').' WHERE category_id = '.(int)$element->price_category_id;
$database->setQuery($query);
$category = $database->loadObject();
if(!empty($category)){
foreach(get_object_vars($category) as $key => $val){
$element->$key = $val;
}
}
}
if(empty($element->category_name)){
$element->category_name = JText::_('CATEGORY_NOT_FOUND');
}
//get zone info
if(!empty($element->price_zone_id)){
$query = 'SELECT * FROM '.hikashop::table('zone').' WHERE zone_id = '.(int)$element->price_zone_id;
$database->setQuery($query);
$zone = $database->loadObject();
if(!empty($zone)){
foreach(get_object_vars($zone) as $key => $val){
$element->$key = $val;
}
}
}
by the code
if(!empty($element->discount_product_id)){
$query = 'SELECT * FROM '.hikashop::table('product').' WHERE product_id = '.(int)$element->discount_product_id;
$database->setQuery($query);
$product = $database->loadObject();
if(!empty($product)){
foreach(get_object_vars($product) as $key => $val){
$element->$key = $val;
}
}
}
if(empty($element->product_name)){
$element->product_name = JText::_('PRODUCT_NOT_FOUND');
}
//get category info
if(!empty($element->discount_category_id)){
$query = 'SELECT * FROM '.hikashop::table('category').' WHERE category_id = '.(int)$element->discount_category_id;
$database->setQuery($query);
$category = $database->loadObject();
if(!empty($category)){
foreach(get_object_vars($category) as $key => $val){
$element->$key = $val;
}
}
}
if(empty($element->category_name)){
$element->category_name = JText::_('CATEGORY_NOT_FOUND');
}
//get zone info
if(!empty($element->discount_zone_id)){
$query = 'SELECT * FROM '.hikashop::table('zone').' WHERE zone_id = '.(int)$element->discount_zone_id;
$database->setQuery($query);
$zone = $database->loadObject();
if(!empty($zone)){
foreach(get_object_vars($zone) as $key => $val){
$element->$key = $val;
}
}
}
in the file amdinistrator/components/com_hikashop/views/discount/view.html.php near line 210.