Brashquido Posted December 7, 2013 Report Posted December 7, 2013 Using Blesta 3.0.6 on Windows 2012 Server / IIS 8 using PHP 5.4.20. When generating any of the available reports under billing as CSV I am getting files that contain the CSV values at the top as expected. However after that there is a couple of hundred lines of HTML and JavaScript code. Not a massive issue as it can be easily removed from the CSV, but shouldn't be there none the less.
Cody Posted December 7, 2013 Report Posted December 7, 2013 Could you attach one of the reports? Feel free to redact any invoice or transaction lines. But we need to see what else is contained in the CSV.
Brashquido Posted December 8, 2013 Author Report Posted December 8, 2013 Hi Cody, I have attached (hopefully) an example report. Blesta-Test.csv.txt
Tyson Posted December 9, 2013 Report Posted December 9, 2013 This is probably due to the output buffer not closing after downloading the CSV, but we're not able to duplicate this issue. However, the fix should be simple. If you're comfortable updating a file, I'd appreciate your feedback on whether this fixes the problem for you. Update /app/models/report_manager.php (line 231): // Download from temp file $this->Download->downloadFile($path_to_file, $new_file_name); @unlink($path_to_file); and change it to: // Download from temp file $this->Download->downloadFile($path_to_file, $new_file_name); @unlink($path_to_file); exit();
Brashquido Posted December 9, 2013 Author Report Posted December 9, 2013 Hi Tyson. I can firm the code update fixed the issue. Nothing other than the CSV data is exported now. Thanks.
Tyson Posted December 9, 2013 Report Posted December 9, 2013 Fantastic. Closing this thread as fixed in CORE-921 for v3.0.7.
Recommended Posts