David E Jones wrote:
We probably should do more of this. I think the reason the invoice PDF
was initially a high priority was so that it could be generated or
regenerated in the future without worrying about something on it
suddenly changing. The alternative would be to archive the generated
binary of the PDF.
-David
I'd like to comment about David's idea about archiving generated invoices.
Some time ago I was wondering about the best solution for implementing
the ability to archieve the generated output in OFBiz.
After having studied the solutions for this adopted by a few big ERP
vendors, here are some misc ideas:
a) if possible, we should try to archive the data and not the
information about the layout and the output distribution channel (print,
mail etc...); one way we could do this is by storing in the db the
serialized version of the context passed to the ftl or fo.ftl template,
together with the date, a job id, the user that created the report etc...
b) another option would be that of storing the generated xsl-fo template
in the db
c) I think that we should use the data model of the Content component to
do this
d) the print archive framework should be indipendent from the report
(for example, we could use a seca to trigger the archive feature of the
reports we want to archieve)
e) we could create a new generic screen in the Content application so
manage all the archieved reports and possibly recreate them choosing the
original distribution channel or a new one (e.g. for a report that was
sent out by mail, we could choose a different output, for example a pdf
file, or we could resend it to a different email address)
Doest this make sense?
Jacopo