Bugfixes presta, support for project specific number ranges

This commit is contained in:
Andreas Palm 2023-01-29 14:34:47 +01:00
parent 1af809954c
commit 100024391d
2 changed files with 3 additions and 3 deletions

View File

@ -29439,7 +29439,7 @@ function Firmendaten($field,$projekt="")
$process_lock = $this->app->erp->ProzessLock("erpapi_getnextnummer"); $process_lock = $this->app->erp->ProzessLock("erpapi_getnextnummer");
$eigenernummernkreis = 0; $eigenernummernkreis = $this->app->DB->Select("SELECT eigenernummernkreis FROM projekt WHERE id='$projekt' LIMIT 1");
$newbelegnr = ''; $newbelegnr = '';
if($eigenernummernkreis=='1') if($eigenernummernkreis=='1')
{ {

View File

@ -253,13 +253,13 @@ class Shopimporter_Presta extends ShopimporterBase
if (!empty($cart['lieferadresse_land']) && $this->taxationByDestinationCountry) { if (!empty($cart['lieferadresse_land']) && $this->taxationByDestinationCountry) {
$taxedCountry = $cart['lieferadresse_land']; $taxedCountry = $cart['lieferadresse_land'];
} }
$lieferschwelle = $this->app->DB->Select("SELECT * FROM lieferschwelle WHERE empfaengerland='$taxedCountry' LIMIT 1"); $lieferschwelle = $this->app->DB->SelectArr("SELECT * FROM lieferschwelle WHERE empfaengerland='$taxedCountry' LIMIT 1");
if ($this->app->erp->IstEU($taxedCountry) || !empty($lieferschwelle['ueberschreitungsdatum'])) { if ($this->app->erp->IstEU($taxedCountry) || !empty($lieferschwelle['ueberschreitungsdatum'])) {
$cart['ust_befreit'] = 1; $cart['ust_befreit'] = 1;
} elseif ($this->app->erp->Export($taxedCountry)) { } elseif ($this->app->erp->Export($taxedCountry)) {
$cart['ust_befreit'] = 2; $cart['ust_befreit'] = 2;
} }
$taxes = []; $taxes = [];
$this->app->erp->RunHook('getTaxRatesFromShopOrder', 2, $taxedCountry, $taxes); $this->app->erp->RunHook('getTaxRatesFromShopOrder', 2, $taxedCountry, $taxes);