Klocke-Verlag Posted April 24, 2021 Report Share Posted April 24, 2021 Hallo ! Ich habe nach dem Update auf Version 6.3.2 ein Problem mit den Kundengruppen/Staffelpreisen: Die hinterlegten Staffelpreise für unterschiedliche Kundengruppen werden nicht mehr berücksichtigt, da anscheinend es nicht mehr möglich ist einen Staffelpreis ab einer Stückzahl 1 anzubieten. Wenn ich das entsprechende Fenster öffne, ist das Feld "Mengengrenze" ROT unterlegt (ERROR_REGEX). Bisher war dies kein Problem. Ich konnte damit jahrelang einen Artikel der entsprechenden Kundengruppe zu dem hinterlegten Preis verkaufen. Dies ist jetzt nicht mehr möglich. Jeder Kunde bekomt jetzt den im Artikel hinterlegten Originalpreis angezeigt. Mir ist klar, dass dies in der jetzigen Form logischer ist, da ein Staffelpreis ja erst ab einem mehrfachen von 1 gelten sollte, aber ich habe das halt so genutzt und es hat ja auch funktioniert. Mit dem jetzigen Update scheint dies nicht mehr möglich zu sein.? Oder gibt es irgendwo eine Einstellung, dass auch die Mengengrenze 1 als Staffelpreis erlaubt ist? Hier ein Bildschrimfoto von den verschiedenen Staffelpreisen für die unterschiedlichen Kundengruppen: Dies ist für hunderte Artikel so hinterlegt. (Der erste Artikel mit dieser Konfiguration wurde immer wieder kopiert) Es handelt sich um einen reinen B2B Shop. Nicht für den Endkunden - nur falls dies wichtig ist. Wäre toll wenn da jemand helfen könnte. DANKE. Beste Grüße G. Klocke Quote Link to comment Share on other sites More sharing options...
homer1 Posted April 24, 2021 Report Share Posted April 24, 2021 Hallo G. Klocke, ich benutze den Staffelpreis auf genau die gleiche Art und weise wie du. Ich steuer damit die Preise für eine andere Kundengruppe. Und das auch mit der Menge 1. Ich habe noch die 6.2.2. und es klappt perfekt. Ich habe das Update auf 6.3.2 in 4 bis 6 Wochen geplant. Ich hoffe das wird behoben. Es wäre nett wenn du hier posten würdest wie und ob das Problem beseitigt wurde. LG Homer Quote Link to comment Share on other sites More sharing options...
Klocke-Verlag Posted April 26, 2021 Author Report Share Posted April 26, 2021 Quote Link to comment Share on other sites More sharing options...
oldbear Posted April 29, 2021 Report Share Posted April 29, 2021 hallo, habe den Sachverhalt auch auch xtc gemeldet. Abhilfe: in der class.products_price.php auskommentieren: $header['discount_quantity'] = ['regex' => '^(?:[2-9]|\d\d\d*)$']; Dann kann man wieder die 1 eingeben. Leider reicht das nicht ... habe deshalb Hookpoint zu beliebigem Plugin hinzugefügt: HOOK: class.product.php:getGroupPrice_top INHALT: $prices = array(); if ($customers_status->customers_status_graduated_prices != 0) { if ($sp_type=='group') { $record = $db->Execute("SELECT * FROM ".TABLE_PRODUCTS_PRICE_GROUP.$price->p_group." WHERE products_id=? ORDER BY discount_quantity ASC",array($this->data['products_id'])); } else { $record = $db->Execute("SELECT * FROM ".TABLE_PRODUCTS_PRICE_GROUP."all WHERE products_id=? ORDER BY discount_quantity ASC",array($this->data['products_id'])); } if ($record->RecordCount() >= 1) { $single_price = $this->data['products_price_db']; if (is_null($single_price) && !is_array($this->data['products_price'])) { $single_price = $this->data['products_price']; } else if(is_array($this->data['products_price'])) { $single_price = $this->data['products_price']['plain_otax']; } if ($special_price) { $single_price = $special_price; } $prices[] = array('qty'=>1,'price'=>$single_price); while (!$record->EOF) { if ($record->fields['discount_quantity']!=0) { $prices[] = array('qty'=>$record->fields['discount_quantity'],'price'=>$record->fields['price']); } else if ($record->fields['discount_quantity']!=1) { $prices[0] = array('qty'=>1,'price'=>$record->fields['price']); } $record->MoveNext(); } $record->Close(); $qty = $this->qty; if ($qty_force!=-1) $qty = $qty_force; $data = array(); for ($i = 0, $n = sizeof($prices); $i < $n; $i++) { if ($prices[$i+1]['qty']>$qty) { $data['price']=$prices[$i]['price']; break; } else { // kleiner if (!isset($prices[$i+1]['qty'])) { $data['price']=$prices[$i]['price']; break; } else { if ($prices[$i+1]['qty']>$this->qty) { $data['price']=$prices[$i]['price']; break; } } } } if (count($prices) == 2 && $prices[1]['qty'] == 1) { $data['price']=$prices[1]['price']; unset($prices[0]); $prices[0] = $prices[1]; unset($prices[1]); } $data['no_graduated']=0; $data['graduated_single']=0; //only one check rule if (sizeof($prices) == 1 && $prices[0]['qty']<2) { for ($i = 0, $n = sizeof($prices); $i < $n; $i++) { $prices[$i]['price'] = $price->_calcCurrency($prices[$i]['price']); } $data['no_graduated']=1; $data['graduated_single']=1; } else { for ($i = 0, $n = sizeof($prices); $i < $n; $i++) { $prices[$i]['price'] = $price->_calcCurrency($prices[$i]['price']); } $data['prices']=$prices; $size = count($prices); if ($size==0) $data['no_graduated']=1; //$last = array_pop($prices); $data['cheapest'] = $prices[$size-1]['price']; } ($plugin_code = $xtPlugin->PluginCode('class.product.php:getGroupPrice_data')) ? eval($plugin_code) : false; $plugin_return_value = $data; return $plugin_return_value; } else { return false; } } else { return false; } Grüsse Quote Link to comment Share on other sites More sharing options...
Klocke-Verlag Posted April 29, 2021 Author Report Share Posted April 29, 2021 4 hours ago, oldbear said: in der class.products_price.php auskommentieren: Hallo ! Danke für die Nachricht und den Lösungsweg. Leider bin ich nicht ganz so firm darin. Wo finde ich die "class.products_price.php" ? Eine Serversuche ergab leider kein Ergebnis bei mir. Auskommentieren heißt die Zeile einfügen oder ersetzen ? Danke schon mal. Beste Grüße G.Klocke Quote Link to comment Share on other sites More sharing options...
oldbear Posted April 30, 2021 Report Share Posted April 30, 2021 hallo, habe den Sachverhalt auch auch xtc gemeldet. Abhilfe: in der class.products_price.php auskommentieren: $header['discount_quantity'] = ['regex' => '^(?:[2-9]|\d\d\d*)$']; Dann kann man wieder die 1 eingeben. Leider reicht das nicht ... habe deshalb Hookpoint zu beliebigem Plugin hinzugefügt: HOOK: class.product.php:getGroupPrice_top INHALT: $prices = array(); if ($customers_status->customers_status_graduated_prices != 0) { if ($sp_type=='group') { $record = $db->Execute("SELECT * FROM ".TABLE_PRODUCTS_PRICE_GROUP.$price->p_group." WHERE products_id=? ORDER BY discount_quantity ASC",array($this->data['products_id'])); } else { $record = $db->Execute("SELECT * FROM ".TABLE_PRODUCTS_PRICE_GROUP."all WHERE products_id=? ORDER BY discount_quantity ASC",array($this->data['products_id'])); } if ($record->RecordCount() >= 1) { $single_price = $this->data['products_price_db']; if (is_null($single_price) && !is_array($this->data['products_price'])) { $single_price = $this->data['products_price']; } else if(is_array($this->data['products_price'])) { $single_price = $this->data['products_price']['plain_otax']; } if ($special_price) { $single_price = $special_price; } $prices[] = array('qty'=>1,'price'=>$single_price); while (!$record->EOF) { if ($record->fields['discount_quantity']!=0) { $prices[] = array('qty'=>$record->fields['discount_quantity'],'price'=>$record->fields['price']); } else if ($record->fields['discount_quantity']!=1) { $prices[0] = array('qty'=>1,'price'=>$record->fields['price']); } $record->MoveNext(); } $record->Close(); $qty = $this->qty; if ($qty_force!=-1) $qty = $qty_force; $data = array(); for ($i = 0, $n = sizeof($prices); $i < $n; $i++) { if ($prices[$i+1]['qty']>$qty) { $data['price']=$prices[$i]['price']; break; } else { // kleiner if (!isset($prices[$i+1]['qty'])) { $data['price']=$prices[$i]['price']; break; } else { if ($prices[$i+1]['qty']>$this->qty) { $data['price']=$prices[$i]['price']; break; } } } } if (count($prices) == 2 && $prices[1]['qty'] == 1) { $data['price']=$prices[1]['price']; unset($prices[0]); $prices[0] = $prices[1]; unset($prices[1]); } $data['no_graduated']=0; $data['graduated_single']=0; //only one check rule if (sizeof($prices) == 1 && $prices[0]['qty']<2) { for ($i = 0, $n = sizeof($prices); $i < $n; $i++) { $prices[$i]['price'] = $price->_calcCurrency($prices[$i]['price']); } $data['no_graduated']=1; $data['graduated_single']=1; } else { for ($i = 0, $n = sizeof($prices); $i < $n; $i++) { $prices[$i]['price'] = $price->_calcCurrency($prices[$i]['price']); } $data['prices']=$prices; $size = count($prices); if ($size==0) $data['no_graduated']=1; //$last = array_pop($prices); $data['cheapest'] = $prices[$size-1]['price']; } ($plugin_code = $xtPlugin->PluginCode('class.product.php:getGroupPrice_data')) ? eval($plugin_code) : false; $plugin_return_value = $data; return $plugin_return_value; } else { return false; } } else { return false; } Grüsse hallo, das ist die xtFramework(classes/class.product_price.php Auskommentieren oder löschen ist egal, nur weg mit ... Grüsse Quote Link to comment Share on other sites More sharing options...
Klocke-Verlag Posted April 30, 2021 Author Report Share Posted April 30, 2021 Hallo Oldbear, danke für die Hilfe. Hat super geklappt. Beste Grüße G.Klocke Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.