System Documentation
Description
The current system has 3 main scripts.
- Script launched as a Cron job (cron_packingslips.php)
When a Cron process launches this script, manufacturers which have a mailing time within the last hour will be processed. Pending Orders for a manufacturer which were made within the last 24 hours of the mailing time will be included in a packing slip that is mailed to the manufacturer.
- Script for Administration panel (admin/admin_panel.php)
This script allows an administrator to Add/Delete/Update manufacturers in the system, and modify some of their settings. The admin login parameters can be set in admin/authenticate.php
- Script for Manufacturer's panel (manufacturer_panel.php)
This script allows a manufacturer to manage their Pending Orders. Based on the manufacturer's choices, the system can email messages and/or packing slips to customers and manufacturers. To access this panel, the manufacturer must use a link that is emailed along with his daily packing-slip.
Features
- Auto-password (currently set to Off in config.php)
This feature generates a new password each time a packing slip is sent. This means the manufacturer must always use the url link from most recent email to access his panel. If set to Off, the existing password is used in the email link.
Configuration files
The system has several configuration files where settings can be made:
- config.php
auto-password length, manufacturer's panel url, debugging settings, etc.
- pdf_config.php
settings for the pdf packing slip (fonts, spacings, document title, etc.)
- email_config.php
settings for the email messages (subject lines, server's address, attachment name, etc.)
- db_config.php
database related settings (table name, file paths, etc.)
List of included files:
Administration panel
- admin/admin_panel.php
- admin/admin_panel.inc.php
- admin/authenticate.php (user access validation)
Manufacturer panel
- manufacturer_panel.php
- manufacturer_panel.inc.php
Script for cron job
- cron_packingslips.php
Configuration files
- config.php
- db_config.php
- pdf_config.php
- email_config.php
Other files
- daily_email_template.html (email html template)
- functions.php (various functions)
- sql_queries.php (all sql queries used)
- pdfBg.jpg (packing-slip background-image)
- email_message.php (email-sending application)
- fpdf153/fpdf.php (PDF-making application)