Files
api/services/nginx/app/routes/washCertificateRoute.php
T
Jepp9350 ca52d3b248 Update API endpoints, add wash certificate handling
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.
2025-01-31 09:25:18 +01:00

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();
});
}
}