From e605be20f1ce7db402444e573bf013c33af95709 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Mon, 9 Sep 2024 13:05:03 -0400 Subject: [PATCH] .. --- mccs-it/thermal/app.js | 2 +- mccs-it/thermal/modules/Thermal.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mccs-it/thermal/app.js b/mccs-it/thermal/app.js index 7fd6b62..2c4fa65 100644 --- a/mccs-it/thermal/app.js +++ b/mccs-it/thermal/app.js @@ -10,7 +10,7 @@ app.use(express.static('public')); // Test print function app.post('/test-print', async (req, res) => { try { - Thermal.generateFile('Grant.Aiden2', '5012345'); + Thermal.generateFile('Grant.Aiden2', '5012345', req, res); } catch (error) { console.error('Print Error:', error); res.status(500).json({ message: 'Print Error', error: error.message }); diff --git a/mccs-it/thermal/modules/Thermal.js b/mccs-it/thermal/modules/Thermal.js index 4d456f2..ed081bd 100644 --- a/mccs-it/thermal/modules/Thermal.js +++ b/mccs-it/thermal/modules/Thermal.js @@ -3,7 +3,7 @@ const { spawn } = require('child_process'); module.exports = { - generateFile(username, studentId) { + generateFile(username, studentId, req, res) { // Create the output text const infoArray = [ 'Username:',