|
|
|
|
|
by rad_gruchalski
1424 days ago
|
|
12 years ago, I was working on a contract for an aircraft spares supplier. One of the hard requirements: all sales invoices, purchase orders, quotations, invoices, and so on, had to be printed AND available as PDF. The solution was to use JasperReports. The business could design their templates in a iReport Designer, test with dummy data, put the jrxml templates in a dedicated storage, and a simple http call would merge the real data with the template in a java service (200 lines of code) resulting in a PDF. That PDF would then get printed using ColdFusion cfprint (those huge multi-source laser printers with 10 different drawers). It was worth spending £800 for CF just for the cfprint stuff. Hundreds of these were printed and generated every day. |
|
You just reminded me of a customer I was working for as a junior ERP consultant. They required us to have the proof a document was printed by a user.
I went far down the rabbit hole trying to come up with an end-to-end solution involving cryptographically signed messages sent to the printer, a physical QR code on the document to be scanned back for validation, and others convoluted half-backed contraptions. But I couldn't find an unhackable way to reconcile the state in the machine with the reality of the physical world.
A senior consultant solved it in 10 minutes. Showed them. They were ecstatic and we were paid.
What has he done? Just updated a "printed" column in the database to "True" when the user clicked the HTML "print" button.