CoreBOSBB
gendoc + workflow email - Printable Version

+- CoreBOSBB (https://discussions.corebos.org)
+-- Forum: Support (https://discussions.corebos.org/forumdisplay.php?fid=17)
+--- Forum: Administrator Support (https://discussions.corebos.org/forumdisplay.php?fid=8)
+--- Thread: gendoc + workflow email (/showthread.php?tid=2123)

Pages: 1 2 3


gendoc + workflow email - jmery24 - 03-08-2021

Hello, is there a way to do a workflow, so that an invoice is sent (when X condition is met) attached in PDF with GENDOC?
I did not find in the SEND MAIL task, how to get the invoice attached

Thanks


RE: gendoc + workflow email - joebordes - 03-09-2021

yes, you can do this. if gendoc is configured and you select a document template to be sent in an email workflow task, corebos will notice that the selected document is a template and the gendoc is active and will generate the document and attach the result instead of the document. If PDF generation is also configured, it will generate the PDF and send that.

In short: select the document template in the email task


RE: gendoc + workflow email - jmery24 - 03-09-2021

(03-09-2021, 12:08 AM)joebordes Wrote: yes, you can do this. if gendoc is configured and you select a document template to be sent in an email workflow task, corebos will notice that the selected document is a template and the gendoc is active and will generate the document and attach the result instead of the document. If PDF generation is also configured, it will generate the PDF and send that.

In short: select the document template in the email task

Thanks Joe. There I chose the ODT template of the invoices as a document in the workflow task "Send mail", but when he sends me the emails he does so in ODT and not PDF. I checked if I had to set a global variable with that, but I couldn't find it. Where can I tell the system to do it in PDF? Thanks


RE: gendoc + workflow email - joebordes - 03-09-2021

GenDoc_Convert_URL or the PDF conversion server URL configured: you must be able to generate PDFs from the action panel in the invoice


RE: gendoc + workflow email - jmery24 - 03-09-2021

(03-09-2021, 03:45 PM)joebordes Wrote: GenDoc_Convert_URL or the PDF conversion server URL configured: you must be able to generate PDFs from the action panel in the invoice

Joe, I have libreoffice installed on the same server as corebos. Add on database in the cb_settings table and add a row
key: cbgendoc_showpdflinks  value: 1
In the invoice panel I have to generate PDF and work perfect. But when the workflow that I put together for recurring invoices is executed, it does not send PDF send ODT.
In turn, something strange is happening to me. It happened to me several times, that the PDF button disappears in the panel, and when I enter the database, what I added in cb_settings disappeared, and I must add it again.
Thanks


RE: gendoc + workflow email - joebordes - 03-10-2021

Hi

I just pushed a couple of changes that may fix this issue. Please update your code and give it a try when you can. Let me know how it goes


RE: gendoc + workflow email - joebordes - 03-10-2021

how are you adding the value in cb_settings? You are using the GenDoc settings page, right?


RE: gendoc + workflow email - jmery24 - 03-11-2021

(03-10-2021, 11:53 PM)joebordes Wrote: Hi

I just pushed a couple of changes that may fix this issue. Please update your code and give it a try when you can. Let me know how it goes

Thanks Joe

(03-10-2021, 11:54 PM)joebordes Wrote: how are you adding the value in cb_settings? You are using the GenDoc settings page, right?

add it directly from the database.
in the cb_settings table and add a row like this:

key: cbgendoc_showpdflinks
value: 1

That's wrong ? had to do it another way?


RE: gendoc + workflow email - joebordes - 03-11-2021

go to Settings > Module manager > click on Document Generation > Settings

I think it can be done from there


RE: gendoc + workflow email - jmery24 - 03-11-2021

(03-11-2021, 12:57 AM)joebordes Wrote: go to Settings > Module manager > click on Document Generation > Settings

I think it can be done from there

I don't see that option.
I only see Activated modules and server settings.
in server settings. Should I have something set up?
From the invoice panel the PDFs are perfectly generated, but from the workflows, send the file in ODT