v2.5.31: Fixed export PDF generation error
- Fixed return value handling in generateCompleteCA3PDF() method - Export now correctly returns file path instead of boolean - Improved error handling for PDF generation failures - Export functionality now works with both fillable and improved layouts - Updated module version to 2.5.31
This commit is contained in:
parent
e9592d5314
commit
a64b60a412
@ -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.31
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
- **Fixed Export PDF Generation**: Fixed return value handling in unified PDF generation method
|
||||||
|
- **Correct File Path Return**: Export now correctly returns file path instead of boolean
|
||||||
|
- **Error Handling**: Improved error handling for PDF generation failures
|
||||||
|
- **Export Functionality**: Export now works correctly with both fillable and improved layouts
|
||||||
|
|
||||||
## 2.5.30
|
## 2.5.30
|
||||||
|
|
||||||
### Major Refactoring
|
### Major Refactoring
|
||||||
|
|||||||
@ -192,12 +192,14 @@ class DeclarationTVA_PDF
|
|||||||
$template_file = $this->getTemplatePath();
|
$template_file = $this->getTemplatePath();
|
||||||
if ($template_file && file_exists($template_file) && $this->isFillablePDF($template_file)) {
|
if ($template_file && file_exists($template_file) && $this->isFillablePDF($template_file)) {
|
||||||
// Use fillable PDF template for export
|
// Use fillable PDF template for export
|
||||||
return $this->fillFillablePDF($template_file, $output_path, $declaration, $ca3_data, $mysoc);
|
$result = $this->fillFillablePDF($template_file, $output_path, $declaration, $ca3_data, $mysoc);
|
||||||
|
return $result ? $output_path : false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// For validation or when no fillable template exists, use improved layout
|
// For validation or when no fillable template exists, use improved layout
|
||||||
return $this->generateImprovedPDF($output_path, $declaration, $ca3_data, $mysoc);
|
$result = $this->generateImprovedPDF($output_path, $declaration, $ca3_data, $mysoc);
|
||||||
|
return $result ? $output_path : false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -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.30';
|
$this->version = '2.5.31';
|
||||||
// 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