Refactor invoice PDF generation and VAT validation
- Updated PDF template to display a fixed software code instead of "SOFTWARE". - Changed VAT label to include tax label dynamically and set to 0% for certain conditions. - Enhanced JavaScript for VAT number validation with asynchronous checks against the VIES database. - Implemented debounce for VAT number input to optimize validation calls. - Updated country settings to include country codes for VAT validation. - Modified email sending functions in webhook handlers to use dynamic attachment names for invoices.
This commit is contained in:
@@ -4,8 +4,9 @@ defined(page_security_key) or exit;
|
||||
//=============================
|
||||
// Configuration file
|
||||
//=============================
|
||||
$domain = getDomainName($_SERVER['SERVER_NAME']);
|
||||
$file = ((file_exists(dirname(__FILE__).'/custom/'.$domain.'/settings/'.$domain.'_config.php')) ? dirname(__FILE__).'/custom/'.$domain.'/settings/'.$domain.'_config.php' : dirname(__FILE__).'/settings/config.php');
|
||||
|
||||
$env = getenv('APP_ENV') ?: 'development';
|
||||
$file = ((file_exists(dirname(__FILE__).'/custom/'.$env.'/settings/'.$env.'_config.php')) ? dirname(__FILE__).'/custom/'.$env.'/settings/'.$env.'_config.php' : dirname(__FILE__).'/settings/'.$env.'_config.php');
|
||||
|
||||
//Check if allowed
|
||||
if (isAllowed('settings',$_SESSION['authorization']['permissions'],$_SESSION['authorization']['permission'],'R') === 0){
|
||||
|
||||
Reference in New Issue
Block a user