v2.5.16: Fixed line 08 resume display for mixed account types
- Now shows separate counts for base and VAT accounts for lines 08, 09, 9B - Resume displays 'Comptes de base: X | Comptes de TVA: Y' for mixed account lines - More accurate account breakdown in PDF detailed pages - Clear distinction between base and VAT accounts in line summaries - Special handling for lines with both base and VAT accounts - Updated module version to 2.5.16
This commit is contained in:
parent
0b66cb4fd4
commit
68767840ac
@ -1,5 +1,13 @@
|
|||||||
# CHANGELOG MODULE DECLARATIONTVA FOR [DOLIBARR ERP CRM](https://www.dolibarr.org)
|
# CHANGELOG MODULE DECLARATIONTVA FOR [DOLIBARR ERP CRM](https://www.dolibarr.org)
|
||||||
|
|
||||||
|
## 2.5.16
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
- **Fixed Line 08 Resume Display**: Now shows separate counts for base and VAT accounts for lines 08, 09, 9B
|
||||||
|
- **Improved Account Summary**: Resume now displays "Comptes de base: X | Comptes de TVA: Y" for mixed account lines
|
||||||
|
- **Better Line Details**: More accurate account breakdown in PDF detailed pages
|
||||||
|
- **Enhanced Clarity**: Clear distinction between base and VAT accounts in line summaries
|
||||||
|
|
||||||
## 2.5.15
|
## 2.5.15
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
|||||||
@ -1077,7 +1077,24 @@ class DeclarationTVA_PDF
|
|||||||
// Add line summary information (without title) - using table font size
|
// Add line summary information (without title) - using table font size
|
||||||
$pdf->SetFont('helvetica', '', 7);
|
$pdf->SetFont('helvetica', '', 7);
|
||||||
$pdf->Cell(0, 6, 'Période: ' . dol_print_date($line_details['start_date'], 'day') . ' - ' . dol_print_date($line_details['end_date'], 'day'), 0, 1);
|
$pdf->Cell(0, 6, 'Période: ' . dol_print_date($line_details['start_date'], 'day') . ' - ' . dol_print_date($line_details['end_date'], 'day'), 0, 1);
|
||||||
$pdf->Cell(0, 6, 'Nombre de comptes: ' . $line_details['account_count'], 0, 1);
|
|
||||||
|
// Special handling for lines with both base and VAT accounts (08, 09, 9B)
|
||||||
|
if (in_array($line_code, array('08', '09', '9B'))) {
|
||||||
|
// Count base and VAT accounts separately
|
||||||
|
$base_count = 0;
|
||||||
|
$vat_count = 0;
|
||||||
|
foreach ($line_details['account_details'] as $account) {
|
||||||
|
if (strpos($account['mapping_type'], '_BASE') !== false) {
|
||||||
|
$base_count++;
|
||||||
|
} elseif (strpos($account['mapping_type'], '_VAT') !== false) {
|
||||||
|
$vat_count++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$pdf->Cell(0, 6, 'Comptes de base: ' . $base_count . ' | Comptes de TVA: ' . $vat_count, 0, 1);
|
||||||
|
} else {
|
||||||
|
// Standard count for other lines
|
||||||
|
$pdf->Cell(0, 6, 'Nombre de comptes: ' . $line_details['account_count'], 0, 1);
|
||||||
|
}
|
||||||
|
|
||||||
if (!empty($line_details['calculated_line'])) {
|
if (!empty($line_details['calculated_line'])) {
|
||||||
$calc = $line_details['calculated_line'];
|
$calc = $line_details['calculated_line'];
|
||||||
|
|||||||
@ -76,7 +76,7 @@ class modDeclarationTVA extends DolibarrModules
|
|||||||
$this->editor_squarred_logo = ''; // Must be image filename into the module/img directory followed with @modulename. Example: 'myimage.png@declarationtva'
|
$this->editor_squarred_logo = ''; // Must be image filename into the module/img directory followed with @modulename. Example: 'myimage.png@declarationtva'
|
||||||
|
|
||||||
// Possible values for version are: 'development', 'experimental', 'dolibarr', 'dolibarr_deprecated', 'experimental_deprecated' or a version string like 'x.y.z'
|
// Possible values for version are: 'development', 'experimental', 'dolibarr', 'dolibarr_deprecated', 'experimental_deprecated' or a version string like 'x.y.z'
|
||||||
$this->version = '2.5.15';
|
$this->version = '2.5.16';
|
||||||
// Url to the file with your last numberversion of this module
|
// Url to the file with your last numberversion of this module
|
||||||
//$this->url_last_version = 'http://www.example.com/versionmodule.txt';
|
//$this->url_last_version = 'http://www.example.com/versionmodule.txt';
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user