2
0
forked from Wavyzz/dolibarr

Try to fix phan warning

This commit is contained in:
Laurent Destailleur
2024-08-02 17:06:07 +02:00
parent b138957cfb
commit 2f415cafcd

View File

@@ -6940,7 +6940,7 @@ function showDimensionInBestUnit($dimension, $unit, $type, $outputlangs, $round
* @param Societe $thirdparty_buyer Object of buying third party
* @param Societe $thirdparty_seller Object of selling third party ($mysoc if not defined)
* @param int $vatnpr If vat rate is NPR or not
* @return int<0,0>|string 0 if not found, localtax rate if found
* @return int<0,0>|string 0 if not found, localtax rate if found (Can be '20', '-19:-15:-9')
* @see get_default_tva()
*/
function get_localtax($vatrate, $local, $thirdparty_buyer = null, $thirdparty_seller = null, $vatnpr = 0)
@@ -7020,7 +7020,7 @@ function get_localtax($vatrate, $local, $thirdparty_buyer = null, $thirdparty_se
}
} else { // i am the seller
if (!isOnlyOneLocalTax($local)) { // TODO If seller is me, why not always returning this, even if there is only one locatax vat.
return $conf->global->MAIN_INFO_VALUE_LOCALTAX1;
return getDolGlobalString('MAIN_INFO_VALUE_LOCALTAX1');
}
}
}
@@ -7034,7 +7034,7 @@ function get_localtax($vatrate, $local, $thirdparty_buyer = null, $thirdparty_se
if (in_array($mysoc->country_code, array('ES'))) {
return $thirdparty_buyer->localtax2_value;
} else {
return $conf->global->MAIN_INFO_VALUE_LOCALTAX2;
return getDolGlobalString('MAIN_INFO_VALUE_LOCALTAX2');
}
}
}
@@ -7204,7 +7204,7 @@ function getTaxesFromId($vatrate, $buyer = null, $seller = null, $firstparamisid
* @param Societe $buyer Company object
* @param Societe $seller Company object
* @param int<0,1> $firstparamisid 1 if first param is ID into table instead of Rate+code (use this if you can)
* @return array{}|array{0:string,1:float,2:string,3:string}|array{0:string,1:float,2:string,3:float,4:string,5:string} array(localtax_type1(1-6 or 0 if not found), rate localtax1, localtax_type2, rate localtax2, accountancycodecust, accountancycodesupp)
* @return array{}|array{0:string,1:int|string,2:string,3:string}|array{0:string,1:int|string,2:string,3:int|string,4:string,5:string} array(localtax_type1('1-6' or '0' if not found), rate localtax1, localtax_type2, rate localtax2, accountancycodecust, accountancycodesupp)
* @see getTaxesFromId()
*/
function getLocalTaxesFromRate($vatrate, $local, $buyer, $seller, $firstparamisid = 0)