So jetzt klappts:
lag an:
$xtPrice->xtcFormat(MODULE_SHIPPING_FREEAMOUNT_AMOUNT,true,0,true)
hier die komplette Funktion:
function ap() {
// BOF- Tomcraft - 2015-08-09 - Don't show ap module upon reaching freeamount value
//global $order;
global $order, $xtPrice;
// EOF- Tomcraft - 2015-08-09 - Don't show ap module upon reaching freeamount value
$this->code = 'ap';
$this->title = MODULE_SHIPPING_AP_TEXT_TITLE;
$this->description = MODULE_SHIPPING_AP_TEXT_DESCRIPTION;
$this->sort_order = MODULE_SHIPPING_AP_SORT_ORDER;
$this->icon = DIR_WS_ICONS . 'shipping_ap.gif';
$this->tax_class = MODULE_SHIPPING_AP_TAX_CLASS;
$this->enabled = ((MODULE_SHIPPING_AP_STATUS == 'True') ? true : false);
if ( ($this->enabled == true) && ((int)MODULE_SHIPPING_AP_ZONE > 0) ) {
$check_flag = false;
$check_query = xtc_db_query("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . MODULE_SHIPPING_AP_ZONE . "' and zone_country_id = '" . $order->delivery['country']['id'] . "' order by zone_id");
while ($check = xtc_db_fetch_array($check_query)) {
if ($check['zone_id'] < 1) {
$check_flag = true;
break;
} elseif ($check['zone_id'] == $order->delivery['zone_id']) {
$check_flag = true;
break;
}
}
if ($check_flag == false) {
$this->enabled = false;
}
}
// BOF- Tomcraft - 2015-08-09 - Don't show ap module upon reaching freeamount value
if ( $xtPrice->xtcRemoveCurr($_SESSION['cart']->show_total()) > $xtPrice->xtcFormat(MODULE_SHIPPING_FREEAMOUNT_AMOUNT,true,0,true) ) {
$this->enabled = false;
}
// EOF- Tomcraft - 2015-08-09 - Don't show ap module upon reaching freeamount value
/**
* CUSTOMIZE THIS SETTING FOR THE NUMBER OF ZONES NEEDED
*/
$this->num_ap = 8;
}
Muss dieser Part aus der ap.php entfernt werden weil du ergänzen geschrieben hast?
if ($check_flag == false) {
$this->enabled = false;
}
Danke.