Skip to content

Commit

Permalink
Build plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
simonhamp authored and github-actions[bot] committed Dec 26, 2024
1 parent 51f7750 commit d5e7c28
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions resources/js/electron-plugin/dist/server/api/system.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,19 @@ router.post('/print', (req, res) => __awaiter(void 0, void 0, void 0, function*
silent: true,
deviceName: printer,
}, (success, errorType) => {
res.sendStatus(200);
if (success) {
console.log('Print job completed successfully.');
res.sendStatus(200);
}
else {
console.error('Print job failed:', errorType);
res.sendStatus(500);
}
if (printWindow) {
printWindow.close();
printWindow = null;
}
});
printWindow = null;
});
yield printWindow.loadURL(`data:text/html;charset=UTF-8,${html}`);
}));
Expand Down

0 comments on commit d5e7c28

Please sign in to comment.