Implemented UNIFI_SSID_PASSWORD environment variable. Updated email template. Updated PDF template. Updated ESC/POS template. Updated README.md. Changed qr.js output based on open or password protected networks

This commit is contained in:
Glenn de Haan
2024-09-21 20:46:05 +02:00
parent da15cf9e34
commit d475c1cc28
8 changed files with 53 additions and 10 deletions

View File

@@ -7,7 +7,7 @@ const variables = require('../modules/variables');
* Util function to calculate paper size based on voucher data
*/
module.exports = (voucher) => {
let base = variables.unifiSsid !== '' ? 375 : 260;
let base = variables.unifiSsid !== '' ? variables.unifiSsidPassword !== '' ? 385 : 375 : 260;
if(voucher.qos_usage_quota) {
base += 10;