Regarding finance module : Invoice and Receipt Printing

Dear All,

While printing the receipt, I want to select what and where (I mean on pre printed stationary) to print and according to it format the receipt and invoice…

Can any body guide me where to start ?

I have little knowledge of PHP and I have taken a look at finance module and tried to play with invoce_print.php and invoice_print_print.php but no fruit ful results… :frowning:

Please suggest…

I’m not sure I fully understand your question. Anyway, you will find most code regarding print contents in the following two functions of file modules/Finance/moduleFunctions.php:

  • invoiceContents
  • receiptContents

Hope this helps. :slight_smile:

Thanks for helping, meierrom.

The case is: my School has some pre-printed receipt stationary. On that stationary, I want to print only the name, receipt number, date, amount etc…

The receipt which we get in gibbon, is pre formatted. I can select the required data from your said module Functions.php but how to set the dimensions,margins and locations where the data will be printed ?

Can we make use of mPDF ?

please guide…

The pre printed receipt format…

I think, a pdf library is exactly what you need. :slight_smile:

Personally, I haven’t used mPDF before. I don’t even know which module is using this. Anybody?

When doing PDF stuff I always use tcpdf, which you can find here:
vendor/tecnickcom/tcpdf

Thanks…

Actually I have observed the content function that so many sql queries statements and so many joins are there and I am afraid that I am not able to understand the process flow. I want to print a receipt in the preprinted stationary every time the student pays the fees without printing the other details.

If anybody can guide please help me…

Don’t bother much about the sql queries. I don’t think they need adjustments in your case. Just poke around. It may look a bit overwhelming at first but once you get started, things gradually will become clearer and you will understand things very well. :wink: