1 (edited by agent182 11/18/2010 07:17:09 am)

Topic: How to customize the pdf reports?

Hi,

Its been 2 weeks that I have used FA, I have come across a big problem on the pdf reports of Direct Delivery, Direct Invoice, etc..  on how to change the positioning of the tables, width, logo, address, and also add more text and tables.

Cause the report generated is basically different on our reports.
Also I have looked at the header2.inc file ,doctext.inc, pdf_report.inc,  but there are no html codes for the tables in there and also i cant find the sql scripts for displaying the data so that maybe i can modify the positions and data.

Please help me on this and thank you in advance.

Looking Forward,
John

Re: How to customize the pdf reports?

Unfortunately we have no specialized report generator so far, so to change the report content you need to know php language. Moreover reports does not use html at all as the reports are generated as pdf files. Anyway all the reports definitions are in respective repxxx.php files, together with related sql queries used to retrieve reported data.

Janusz

Re: How to customize the pdf reports?

Hi,

thank you for the reply, just want to ask like in the PDF reports, how to put the logo at the center?
i mean which file to edit and if its ok what specific code to change?

although i have a bit knowledge on php..only basic...

please help and tanx in advance.

-john

Re: How to customize the pdf reports?

Logo in reports is included in reporting/pdf_report.inc about line 53 (2.3RC version0.

Janusz

5 (edited by zaky 01/03/2011 08:25:12 pm)

Re: How to customize the pdf reports?

how are you all ...? I have a problem ... how to generate a gross profit in the report profit. tanks

Re: How to customize the pdf reports?

All I need is to change footer text, change the word VAT to ITBM and other minor wording changes within the invoice pdf output format .....found this for the footer..... var $footerText;  // store user-generated footer text...... on line 62 of pdf_report.inc, but don´t know what to do with it.....please, advise.

Re: How to customize the pdf reports?

Create a new language with translations for VAT. See the en_IN .po file.

8 (edited by sbt507 11/15/2015 11:45:21 pm)

Re: How to customize the pdf reports?

See my problems within the below image......please, advise on fix.

[img]http://screenshot.net/5e6zot1.jpg[/img]

FYI, i have already done some changes myself, but there is some additional info I just don´t seem to figure out.

Would imagen that sames changes done to pdf reports will reflect on image below by default.......

[img]http://screenshot.net/5rl25ip.jpg[/img]

Thank you in advanced.

9 (edited by apmuthu 11/16/2015 03:36:25 am)

Re: How to customize the pdf reports?

I assume you are using the Spanish (Panama) Language (es_PA) file. The latest .po and compiled .mo files are here and they can replace the ones in your lang folder. The IVA => ITBM changed version is attached in this post that you may unzip into the lang/es_PA/LC_MESSAGES folder.

Any changes to the standard .po file for translation variations needed can be uploaded somewhere and link pasted here for making the .mo file in case you are unable to follow the wiki instructions.

Setup => Forms Setup is where you put in the next Invoice Number and other FA document numbers.

Check the Tax Name for IVA (7%) and change it there as well in the tax_types table. There are a whole lot of Account Names like "Hacienda Publica IVA soportado" in the chart_master table and also chart_types table where you might want to replace IVA as well. Just take a backup of the database and then do a search and replace of IVA to ITBM in a case sensitive manner and hope nothing breaks or do it one by one.... and then upload and restore the changed version.

Post's attachments

es_PA_pomo.zip 47.7 kb, 9 downloads since 2015-11-16 

You don't have the permssions to download the attachments of this post.

Re: How to customize the pdf reports?

Based on your instructions....the key was at db changes of tax types. Thanks alot.

However, and perhaps the most important request of all, will be to sync sales_order_entry and FORM setup with pdf files.

Here are snapshots of FA and DB for your review.

FA Form setup parameters .... [img]http://screenshot.net/vqmy2ce.jpg[/img]

FA Sales order Entry ...... [img]http://screenshot.net/vvnp9ap.jpg[/img]

FA Sales Order View ...... [img]http://screenshot.net/ve09xf9.jpg[/img]

DB Sales Order Table...... [img]http://screenshot.net/v5nzkhk.jpg[/img]

DB Ref Table ................ [img]http://screenshot.net/vzx3ju5.jpg[/img]

PDF Sales Quote file...... [img]http://screenshot.net/5e6zot1.jpg[/img]

My analysis is that Form Setup is drawing values from reference field. The values that prevail on all PDF reports and files are linked to, or in sync with, the order_id field. MY intentions are to change default order_id values to start at 100+. 

Is there a fix for the above ?

Finally, we want to thank you for such a fine job you guys are doing in making this project possible.

11 (edited by apmuthu 11/22/2015 12:52:56 pm)

Re: How to customize the pdf reports?

I shall assume that you have your language strings translated correctly in your forms and reports now.

The order_no (I do not find any order_id field in FA, there is however, a workorder_id field in FA)  field gets a system generated value that should generally come from the auto_increment value in the table but here this field is not auto_increment type. The ERD in the Wiki is self-explanatory. It is possible that one more than the highest allotted number for the invoice type record is used as the next one as far as the order_no field is concerned. Attempting to change the value in the order_no field for the last order in both sales_orders and sales_order_details tables to say 99 will make sure that the next invoice gets generated with order_no as 100.

Also note that many different order_no records can get billed from a single invoice whilst some may not get billed at all. In reality, there is no direct invoice generation at all in FA and the order_no is an internal relational field only. Even in Direct Invoice, the steps of preparing the Order and then making the invoice are automated and not that the former is skipped.

Post's attachments

sbt507_img.zip 683.1 kb, 4 downloads since 2015-11-22 

You don't have the permssions to download the attachments of this post.

Re: How to customize the pdf reports?

Hi everyone,

I would like to add horizontal line (or border) to separate the items one by one on Delivery Note. I believe i should update the PHP code in rep110.php. However I am not sure which line i should update and if it is possible. It will be much appreciated if anyone of you can advise me how to do this. Thank you.

Re: How to customize the pdf reports?

You're right, reporting/rep110.php provides the Delivery Note / Packing Slip.

At line 139:

                $rep->row = $newrow;

insert the following:

                $rep->Line($rep->row-1);