mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 13:12:50 +01:00
FIxes for the base rule
This commit is contained in:
parent
36449fa56c
commit
e5c3c1b257
@ -182,7 +182,7 @@ class BaseRule implements RuleInterface
|
|||||||
* Destination - Client Tax Data
|
* Destination - Client Tax Data
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
// $tax_data = new Response([]);
|
|
||||||
$tax_data = false;
|
$tax_data = false;
|
||||||
|
|
||||||
if($this->seller_region == 'US' && $this->client_region == 'US'){
|
if($this->seller_region == 'US' && $this->client_region == 'US'){
|
||||||
@ -193,14 +193,12 @@ class BaseRule implements RuleInterface
|
|||||||
/** We should never encounter this scenario */
|
/** We should never encounter this scenario */
|
||||||
if(!$company->origin_tax_data)
|
if(!$company->origin_tax_data)
|
||||||
{
|
{
|
||||||
$this->should_calc_tax = false;
|
$this->should_calc_tax = false;
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** If we are in a Origin based state, force the company tax here */
|
/** If we are in a Origin based state, force the company tax here */
|
||||||
if($company?->origin_tax_data?->originDestination == 'O' && ($company->tax_data?->seller_subregion == $this->client_subregion)) {
|
if($company->origin_tax_data?->originDestination == 'O' && ($company->tax_data?->seller_subregion == $this->client_subregion)) {
|
||||||
|
|
||||||
$tax_data = $company->origin_tax_data;
|
$tax_data = $company->origin_tax_data;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user