Replaced legacy 'nnks.truckwash.dk' endpoint with 'api.truckwash.dk' across the codebase for consistency. Implemented a feature to handle certificate downloads, including file serving and validation. Updated PHP configuration to support additional dependencies like PHPMailer, and introduced necessary route and configuration changes for wash certificate processing.
23 lines
535 B
PHP
23 lines
535 B
PHP
<?php
|
|
|
|
namespace routes;
|
|
|
|
use traits\route_t;
|
|
|
|
class washCertificateRoute
|
|
{
|
|
use route_t;
|
|
|
|
public function run(): void
|
|
{
|
|
/** All bookings */
|
|
$this->get('/modules/washcertificates', function () {
|
|
// Set the working directory to /modules/washcertificates,
|
|
// so the output directory is created in the correct location
|
|
chdir(WD . '/modules/washcertificates');
|
|
// Run the index.php file
|
|
require_once 'index.php';
|
|
exit();
|
|
});
|
|
}
|
|
} |