Documentation Module

The documentation engine should be a SQL query which gets transformed into an XML structure which then has an XSLT transform applied to it to produce output, usually in HTML. This raises the barrier to entry slightly. Another option would be to have the data come out in JSON format, and then have a JSONT transform ( The XML is probably preferred as it's more of an official standard even though it is ugly.

The documentation engine is used to send out emails, faxes, sms messages, etc. It's for outgoing documentation. The process would be that the document would be generated, then the user would have the opportunity to edit it. Once the user was happy with it, then the output would be saved as a file (converted from HTML into other file format such as CSV, PDF, etc). The system would then pick up the file and send it as an attachment (or as the body of the email). The system could also use Email to Fax gateways and Email to SMS gateways.

Copies of the documents which are sent out will be stored as files on the file system. This will reduce the database size. All documents will have a link in the database which will have a cron job to spider the files to ensure there is integrity.

The features for the documentation module should include:

  • There should be example versions of “standard documentation” such as invoices, supplier requests, reminder emails for payments, vouchers for travel, manifests, quotations, etc.
  • As a bare minimum the system should be able to send emails.
  • Have a nice editor for creating ad-hoc documents. This will also have some sort of SQL validation to make sure the user is not doing anything malicious.
  • Documentation can be customised based on the currency of the booking/quote.

Usually the interaction with the database would be through stored procedures, however this module is one of the exceptions to this.