From 8072d0b1940ef6f316ce78dcbcb9e5af5bab04e7 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 08:32:39 +0100 Subject: [PATCH 01/21] Added basic barcode generation ref #13 --- package.json | 1 + src/PdfCreator.ts | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/package.json b/package.json index 90132ef..effbbb9 100644 --- a/package.json +++ b/package.json @@ -41,6 +41,7 @@ "dependencies": { "@odit/class-validator-jsonschema": "^2.1.1", "axios": "^0.21.1", + "bwip-js": "^2.0.12", "cheerio": "^1.0.0-rc.5", "class-transformer": "0.3.1", "class-validator": "^0.13.1", diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index df60730..8c09b3b 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -179,6 +179,25 @@ export class PdfCreator { return (await mergedPdf.save()); } + /** + * A simple barcode generation function using default params suitable for usage in pdfs. + * Generates the barcodes as base64-encoded png. + * @param type Barcode type according to this list: https://github.com/metafloor/bwip-js/wiki/BWIPP-Barcode-Types + * @param content Barcode content/text - please remember that some formats only support certain input types. + * @returns Barcode image as base64 encoded png string. + */ + public async generateBarcode(type: string, content: string): Promise { + let barcode: Buffer = await bwipjs.toBuffer({ + bcid: type, + text: content, + scale: 3, + height: 10, + includetext: true, + textxalign: 'center', + }); + return `data:$image/png;base64,${barcode.toString('base64')}`; + } + /** * Generates a new dummy runner with halfspaces for all strings. * Can be used to generate empty sponsoring contracts. From 27d1d69360c8513079abcfe3a6fc2a50309a2b61 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 09:11:27 +0100 Subject: [PATCH 02/21] Added barcode field to template ref #13 --- src/templates/sponsoring_contract.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/templates/sponsoring_contract.html b/src/templates/sponsoring_contract.html index aba83be..e38574e 100644 --- a/src/templates/sponsoring_contract.html +++ b/src/templates/sponsoring_contract.html @@ -50,7 +50,7 @@

ID

- +
From a35f8cfd3aa94923968fd77425c074844d28ec0d Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 09:11:59 +0100 Subject: [PATCH 03/21] First part of the handlebars barcode generation ref #13 --- src/PdfCreator.ts | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index 8c09b3b..d1e17fd 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -1,4 +1,5 @@ import axios from 'axios'; +import bwipjs from "bwip-js"; import cheerio from "cheerio"; import fs from "fs"; import Handlebars from 'handlebars'; @@ -82,6 +83,11 @@ export class PdfCreator { return i18next.t(str, PdfCreator.interpolations).toString(); } ); + await Handlebars.registerHelper('--bc', + function (str) { + return "data:image"; + } + ); this.browser = await puppeteer.launch({ headless: true, args: minimal_args }); } @@ -121,6 +127,9 @@ export class PdfCreator { const $ = cheerio.load(html) $('img').each(async (index, element) => { let imgsrc = $(element).attr("src"); + if (imgsrc.startsWith("data:image")) { + return; + } const img_type = mime.lookup(imgsrc); if (!(img_type.includes("image"))) { @@ -186,7 +195,7 @@ export class PdfCreator { * @param content Barcode content/text - please remember that some formats only support certain input types. * @returns Barcode image as base64 encoded png string. */ - public async generateBarcode(type: string, content: string): Promise { + public static async generateBarcode(type: string, content: string): Promise { let barcode: Buffer = await bwipjs.toBuffer({ bcid: type, text: content, From 1c066898009883f510fa204c66800e5f6228a15d Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 09:20:45 +0100 Subject: [PATCH 04/21] Reworked template layout for barcode ref #13 --- src/templates/sponsoring_contract.html | 28 +++++++++++++++----------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/src/templates/sponsoring_contract.html b/src/templates/sponsoring_contract.html index e38574e..305d0ca 100644 --- a/src/templates/sponsoring_contract.html +++ b/src/templates/sponsoring_contract.html @@ -38,22 +38,26 @@

-

{{__ "sponsoring_subtitle"}}

-
-
- {{this.firstname}} - {{this.middlename}} -

{{__ "firstname"}}

-
-
- {{this.id}} -

ID

+
+
+

{{__ "sponsoring_subtitle"}}

+
+
+ {{this.firstname}} + {{this.middlename}} +

{{__ "firstname"}}

+
+
+ {{this.id}} +

ID

+
+
- +
-
+
{{this.lastname}}

{{__ "lastname"}}

From 3e2b011d2887d261fb9c36820982095d6dd6d847 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 09:24:10 +0100 Subject: [PATCH 05/21] Switched to using the current runner's id as the barcode text ref #13 --- src/templates/sponsoring_contract.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/templates/sponsoring_contract.html b/src/templates/sponsoring_contract.html index 305d0ca..b6e8e64 100644 --- a/src/templates/sponsoring_contract.html +++ b/src/templates/sponsoring_contract.html @@ -54,7 +54,7 @@
- +
From 75d2ac3c5f80f8440b6d48c33b15ef17565559b3 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 09:47:28 +0100 Subject: [PATCH 06/21] Added todo ref #13 --- src/PdfCreator.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index d1e17fd..2014fb7 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -2,15 +2,18 @@ import axios from 'axios'; import bwipjs from "bwip-js"; import cheerio from "cheerio"; import fs from "fs"; -import Handlebars from 'handlebars'; +import handlebars from 'handlebars'; import i18next from "i18next"; import Backend from 'i18next-fs-backend'; import mime from "mime-types"; import path from 'path'; import { PDFDocument } from 'pdf-lib'; +import promisedHandlebars from "promised-handlebars"; import puppeteer from "puppeteer"; import { Runner } from './models/Runner'; import { RunnerGroup } from './models/RunnerGroup'; + +const Handlebars = promisedHandlebars(handlebars); /** * This class is responsible for all things pdf creation. * This uses the html templates from src/templates. @@ -68,7 +71,6 @@ export class PdfCreator { '--use-gl=swiftshader', '--no-sandbox' ]; - await i18next .use(Backend) .init({ @@ -85,7 +87,8 @@ export class PdfCreator { ); await Handlebars.registerHelper('--bc', function (str) { - return "data:image"; + //TODO: Fix the async behaviour + return PdfCreator.generateBarcode("code39", str.toString()); } ); this.browser = await puppeteer.launch({ headless: true, args: minimal_args }); From 3bb322ede5db15a147c0d7a8db2a68ccb7fa2112 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 10:22:29 +0100 Subject: [PATCH 07/21] Added new env vars to config ref #16 --- src/config.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/config.ts b/src/config.ts index 3b95934..0a94d8e 100644 --- a/src/config.ts +++ b/src/config.ts @@ -4,7 +4,10 @@ configDotenv(); export const config = { internal_port: parseInt(process.env.APP_PORT) || 4010, development: process.env.NODE_ENV === "production", - version: process.env.VERSION || require('../package.json').version + version: process.env.VERSION || require('../package.json').version, + eventname: process.env.EVENT_NAME || "Please set the event name", + currency_symbol: process.env.CURRENCY_SYMBOL || "€", + sponsoring_receipt_minimum_amount: process.env.SPONSORING_RECEIPT_MINIMUM_AMOUNT || "10" } let errors = 0 if (typeof config.internal_port !== "number") { From b4ebae283b472b2f0c6e28caed49b30edb119585 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 10:22:49 +0100 Subject: [PATCH 08/21] Now loading interpolation vars from config/env ref #16 --- src/PdfCreator.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index df60730..baeed0b 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -8,6 +8,7 @@ import mime from "mime-types"; import path from 'path'; import { PDFDocument } from 'pdf-lib'; import puppeteer from "puppeteer"; +import { config } from './config'; import { Runner } from './models/Runner'; import { RunnerGroup } from './models/RunnerGroup'; /** @@ -17,7 +18,7 @@ import { RunnerGroup } from './models/RunnerGroup'; export class PdfCreator { private templateDir = path.join(__dirname, '/templates'); private browser; - private static interpolations = { eventname: "Lauf für Kaya! 2021", sponsoring_receipt_minimum_amount: '10', currency_symbol: "€" } + private static interpolations = { eventname: config.eventname, sponsoring_receipt_minimum_amount: config.sponsoring_receipt_minimum_amount, currency_symbol: config.currency_symbol } /** * Main constructor. From b77bb3ad9dba9d73c2c81215ba57936192155a9a Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 10:23:02 +0100 Subject: [PATCH 09/21] Added new env vars to readme ref #16 --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index bc8cedb..34fcd1a 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,9 @@ The basic generation mechanism makes the templates and routes interchangeable (i | - | - | - | - | APP_PORT | Number | 4010 | The port the backend server listens on. Is optional. | NODE_ENV | String | dev | The apps env - influences debug info. +| EVENT_NAME | String | "Please set the event name" | The event's name - used to generate pdf text. +| CURRENCY_SYMBOL | String | "€" | The your currency's symbol - used to generate pdf text. +| SPONSORING_RECEIPT_MINIMUM_AMOUNT | String | "10" | The mimimum total donation amount a sponsor has to donate to be able to receive a donation receipt - used to generate pdf text. ## Templates > The document server uses html templates to generate various pdf documents. From b6296b8d97cda943dfb5e11bc9dfbb2f363f5b81 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 16:37:35 +0000 Subject: [PATCH 10/21] =?UTF-8?q?=F0=9F=A7=BENew=20changelog=20file=20vers?= =?UTF-8?q?ion=20[CI=20SKIP]=20[skip=20ci]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a0e8f32..6fbb50e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,8 +2,18 @@ All notable changes to this project will be documented in this file. Dates are displayed in UTC. +#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.2...v0.1.2) + +- Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) +- Added new env vars to config [`3bb322e`](https://git.odit.services/lfk/document-server/commit/3bb322ede5db15a147c0d7a8db2a68ccb7fa2112) +- Added new env vars to readme [`b77bb3a`](https://git.odit.services/lfk/document-server/commit/b77bb3ad9dba9d73c2c81215ba57936192155a9a) +- Now loading interpolation vars from config/env [`b4ebae2`](https://git.odit.services/lfk/document-server/commit/b4ebae283b472b2f0c6e28caed49b30edb119585) +- 🧾New changelog file version [CI SKIP] [skip ci] [`a306009`](https://git.odit.services/lfk/document-server/commit/a30600943d01116b99e946cb705a16d0372b5095) + #### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.1...v0.1.2) +> 7 February 2021 + - Merge pull request 'Alpha Release 0.1.2 - Hotfix release' (#15) from dev into main [`123cf8a`](https://git.odit.services/lfk/document-server/commit/123cf8ad48a45fa10dcd5208215a6e525f31115a) - 🧾New changelog file version [CI SKIP] [skip ci] [`22b1e00`](https://git.odit.services/lfk/document-server/commit/22b1e0097efc865de9cc150cb0d0b99bf789b519) - 🚀Bumped version to v0.1.2 [`7e507d4`](https://git.odit.services/lfk/document-server/commit/7e507d4cc415877ac0b25503dc0ff9ecdceabf42) From 6a142328898d5b89fa11eaf033372971d1093b0c Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 17:38:42 +0100 Subject: [PATCH 11/21] =?UTF-8?q?=F0=9F=9A=80Bumped=20version=20to=20v0.1.?= =?UTF-8?q?3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 310 ++++++++++++++++++------------------ README.md | 154 +++++++++--------- package.json | 2 +- src/PdfCreator.ts | 396 +++++++++++++++++++++++----------------------- src/config.ts | 36 ++--- 5 files changed, 449 insertions(+), 449 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6fbb50e..e6bd92a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,155 +1,155 @@ -### Changelog - -All notable changes to this project will be documented in this file. Dates are displayed in UTC. - -#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.2...v0.1.2) - -- Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) -- Added new env vars to config [`3bb322e`](https://git.odit.services/lfk/document-server/commit/3bb322ede5db15a147c0d7a8db2a68ccb7fa2112) -- Added new env vars to readme [`b77bb3a`](https://git.odit.services/lfk/document-server/commit/b77bb3ad9dba9d73c2c81215ba57936192155a9a) -- Now loading interpolation vars from config/env [`b4ebae2`](https://git.odit.services/lfk/document-server/commit/b4ebae283b472b2f0c6e28caed49b30edb119585) -- 🧾New changelog file version [CI SKIP] [skip ci] [`a306009`](https://git.odit.services/lfk/document-server/commit/a30600943d01116b99e946cb705a16d0372b5095) - -#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.1...v0.1.2) - -> 7 February 2021 - -- Merge pull request 'Alpha Release 0.1.2 - Hotfix release' (#15) from dev into main [`123cf8a`](https://git.odit.services/lfk/document-server/commit/123cf8ad48a45fa10dcd5208215a6e525f31115a) -- 🧾New changelog file version [CI SKIP] [skip ci] [`22b1e00`](https://git.odit.services/lfk/document-server/commit/22b1e0097efc865de9cc150cb0d0b99bf789b519) -- 🚀Bumped version to v0.1.2 [`7e507d4`](https://git.odit.services/lfk/document-server/commit/7e507d4cc415877ac0b25503dc0ff9ecdceabf42) -- PAtch: Copy locales [`f7dfd6d`](https://git.odit.services/lfk/document-server/commit/f7dfd6d0c3c69881338bc1f66d5d33ae9abff628) - -#### [v0.1.1](https://git.odit.services/lfk/document-server/compare/v0.1.0...v0.1.1) - -> 7 February 2021 - -- Merge pull request 'Alpha Release 0.1.1 - Hotfix release' (#12) from dev into main [`cbff307`](https://git.odit.services/lfk/document-server/commit/cbff3074d10110dbb64dda1ed516d2a18402eeca) -- 🧾New changelog file version [CI SKIP] [skip ci] [`4fca5af`](https://git.odit.services/lfk/document-server/commit/4fca5afdfa15d3260ac28c1feb89d50221b1f03f) -- Updated dockerfile & build for dockerized puppeteer [`ea8028d`](https://git.odit.services/lfk/document-server/commit/ea8028dfd54861335e9752334db335ad21e75cf2) -- 📖New license file version [CI SKIP] [skip ci] [`8d4e7a1`](https://git.odit.services/lfk/document-server/commit/8d4e7a16d1ebae6976ec183b761ca3e6a8946629) -- Revert "Now only using our mirror to build" [`fe0f45e`](https://git.odit.services/lfk/document-server/commit/fe0f45ea92099a65d998e342ef885af39d06915f) -- Now only using our mirror to build [`b07c5a9`](https://git.odit.services/lfk/document-server/commit/b07c5a96f2a670f2279a6575b03f9c553b59e0a9) -- 🧾New changelog file version [CI SKIP] [skip ci] [`9755e43`](https://git.odit.services/lfk/document-server/commit/9755e437c2b68c09e9b0ffa47c6bc1729e6bee14) -- 🧾New changelog file version [CI SKIP] [skip ci] [`603a814`](https://git.odit.services/lfk/document-server/commit/603a814ad4783c0b29c1f6a1db638f269b29f775) -- Switched to using our mirrored images for buildi [`dba765c`](https://git.odit.services/lfk/document-server/commit/dba765cb017998ad636f3f91fb00a8a277d3b225) -- 🚀Bumped version to v0.1.1 [`d1b07f3`](https://git.odit.services/lfk/document-server/commit/d1b07f39fd7e3c282a631924bf45367e866e667a) -- Pinned alpine version [`6ab3946`](https://git.odit.services/lfk/document-server/commit/6ab3946c31a7716d1c42fb217b0a0f7be8172dba) - -#### v0.1.0 - -> 7 February 2021 - -- Merge pull request 'Alpha Release 0.1.0 - Contract generation' (#11) from dev into main [`bc2b6fa`](https://git.odit.services/lfk/document-server/commit/bc2b6fadd912f275bc05be29c6fbd87367d617df) -- 📖New license file version [CI SKIP] [skip ci] [`ee19efa`](https://git.odit.services/lfk/document-server/commit/ee19efa0e63f21a10fed1cf24beb16118bbe6cde) -- 🚀Bumped version to v0.0.2 [`de432c4`](https://git.odit.services/lfk/document-server/commit/de432c448129a8acb36fef6b40ef920eeb2f7887) -- First working (TM) template code [`a9e3360`](https://git.odit.services/lfk/document-server/commit/a9e3360ee258e4d48c8dbe3a55468409bb6ee0f7) -- Working Styleing [`c617c40`](https://git.odit.services/lfk/document-server/commit/c617c40e9d7e03382f647eafde9ff458db3c6c15) -- Removed base64 image [`e401d0e`](https://git.odit.services/lfk/document-server/commit/e401d0ec7219e88fbb277b2dcf456a22dae0d1e5) -- Updated the contract template to use external css [`6121b1e`](https://git.odit.services/lfk/document-server/commit/6121b1e3bfcf6fc9f88e0589205044c59859b4a7) -- Sorted locales [`1962499`](https://git.odit.services/lfk/document-server/commit/1962499d18685347302fd7d8491c6e3e7a355fcb) -- Switched to puppeteer for pdf generation [`5afd26e`](https://git.odit.services/lfk/document-server/commit/5afd26ea22cff3b8a339cf658ed37d2053db24ba) -- Added a coupple of real replacement strings to the sponsoring template [`041c0ed`](https://git.odit.services/lfk/document-server/commit/041c0ed6bbe5f8645e4e96b57c02d4e45b445402) -- Added automatic img to base64 conversion [`42443af`](https://git.odit.services/lfk/document-server/commit/42443af734ccc9ce202aec045a07775f4a054b92) -- Added i18n strings [`e345c36`](https://git.odit.services/lfk/document-server/commit/e345c36dd0b03f276259521aebf423853a81a04d) -- first working pdf generation from class 🎉 [`3af76a5`](https://git.odit.services/lfk/document-server/commit/3af76a53e3156bdc2d1d3ade6ff940db9d7b24b5) -- Added a bunch of english and german translations 🌎 [`784d7c6`](https://git.odit.services/lfk/document-server/commit/784d7c656fd2dfc726722459f3ccb7612021b882) -- Added translations using i18next [`75eb925`](https://git.odit.services/lfk/document-server/commit/75eb9252672883f7b6f89a812a37d2b96f9f626e) -- Switched to handlebars for templateing [`4acf3e3`](https://git.odit.services/lfk/document-server/commit/4acf3e39ce55c0ad9e697cf9598569ec1c1dcb44) -- Moved pdf creatior initialization to new function [`47a05fa`](https://git.odit.services/lfk/document-server/commit/47a05facb33c178e9bf3f99c25049abc010361c4) -- 🧾New changelog file version [CI SKIP] [skip ci] [`f3de80a`](https://git.odit.services/lfk/document-server/commit/f3de80af78c96bd697715a30dee7cae6806f9f9f) -- 🚀Bumped version to v0.1.0 [`6a42fe3`](https://git.odit.services/lfk/document-server/commit/6a42fe37d053a6a00005e3c5781edfcefe61183e) -- Merge pull request 'Sponsoring contract generation feature/5-sponsoring_contracts' (#10) from feature/5-sponsoring_contracts into dev [`84259d3`](https://git.odit.services/lfk/document-server/commit/84259d37d42234e1be75f3a5c95f4b442a9e5844) -- Added optimization args [`140fda1`](https://git.odit.services/lfk/document-server/commit/140fda11cc88cb93218116d4cbdbf13c014a659d) -- Added first parts of template [`13776d1`](https://git.odit.services/lfk/document-server/commit/13776d1ecb2db03f19dd0c01a930d4c98222cf6b) -- Added pdf merging for big requests (over 100 runners) [`785544c`](https://git.odit.services/lfk/document-server/commit/785544ca16cd4907a378eb2d48e4269778e3dccc) -- Fixed file broken in merge [`c07c6ae`](https://git.odit.services/lfk/document-server/commit/c07c6aeeab70589a4e1ddf025a07bde96c68ef6e) -- Now with workin i18n-ally config🥳 [`7c3813b`](https://git.odit.services/lfk/document-server/commit/7c3813b94d06ca38b83db90b7f9fba6c33716a05) -- Now with workin i18n-ally config🥳 [`b4232e5`](https://git.odit.services/lfk/document-server/commit/b4232e51e084f491d1a7fb4f929327e88f3b4c00) -- Now accepting arrays for sponsoring contract generation [`f833ae2`](https://git.odit.services/lfk/document-server/commit/f833ae222e68b7df9b8f8a8ec7ce17d679a9710f) -- Added full interpolation support to the i18n [`f755f4f`](https://git.odit.services/lfk/document-server/commit/f755f4f9fb1463af6bec3cf73b7fabf95ef3fb2e) -- Added option to generate empty sponsoring contracts [`1ced0e3`](https://git.odit.services/lfk/document-server/commit/1ced0e317544217599a42c6b270c9136dc73676d) -- Added translation sorting secript [`1e67672`](https://git.odit.services/lfk/document-server/commit/1e67672ef0d28f94a50b0377cca8e8ff2a87e983) -- Removed the example data from the fill-in fields [`5e12525`](https://git.odit.services/lfk/document-server/commit/5e1252545b7eafeee6c3a1d67567d00e5d615d85) -- Edited html template [`d58453f`](https://git.odit.services/lfk/document-server/commit/d58453faf9840037c583e029c41ef1b31a0bafa8) -- PDF Creator now accepts single instances of class [`78205ee`](https://git.odit.services/lfk/document-server/commit/78205ee8c7659ae0dc2e4a184554b042251d9271) -- PDF Creator now accepts single instances of class [`ba7cedd`](https://git.odit.services/lfk/document-server/commit/ba7cedd187dbc51a53ba169889d8e0ca22a97b5d) -- Updated template for i18n [`a596188`](https://git.odit.services/lfk/document-server/commit/a596188c00444c285565eecbb1f0bc668bb4706c) -- Parellized the chunks [`e92820e`](https://git.odit.services/lfk/document-server/commit/e92820e12f289b4fd28b4ebc985b5b711777fc35) -- Fixed the controller not waiting for initialization [`ee8ba99`](https://git.odit.services/lfk/document-server/commit/ee8ba99cc7778f89a8bb99400c7d1cf1a12898f7) -- Implemented language selection by query param [`6f81566`](https://git.odit.services/lfk/document-server/commit/6f81566cb82a0801a20523a7177996ea40cb3968) -- Added comments [`cd51e78`](https://git.odit.services/lfk/document-server/commit/cd51e78282278cae6cb86bd0c9616746612a97e3) -- Added example locales [`1969769`](https://git.odit.services/lfk/document-server/commit/19697692bcb6c0c1c978918916caccd95a8f2035) -- Fixed data validation problem [`bd6ec62`](https://git.odit.services/lfk/document-server/commit/bd6ec6215d362325c510611e4545b7643b918200) -- Removed fullname from groups (to be renabled later) [`388d8a2`](https://git.odit.services/lfk/document-server/commit/388d8a2dc6ee06d39e621e1e45ae595dae587483) -- Updated comments [`119102a`](https://git.odit.services/lfk/document-server/commit/119102aef8f43a68f537e7542c2f2cd3b41cd28e) -- Updated readme for handlebars [`05e4718`](https://git.odit.services/lfk/document-server/commit/05e471878f2321a1873b21730ae85ad6b8af5766) -- Updated readme [`f69e777`](https://git.odit.services/lfk/document-server/commit/f69e7779e42f18df7ec3ccb1cdf9dcf7fa845ee6) -- 🧾New changelog file version [CI SKIP] [skip ci] [`f4a34dd`](https://git.odit.services/lfk/document-server/commit/f4a34dd36b57bd122a650f2de4ea8e00816276ed) -- Typos [`95b882a`](https://git.odit.services/lfk/document-server/commit/95b882aceded275ad89446ad92a10cf36b166ab7) -- Added sentence about large requests to the /contracts openapi description [`4773a5f`](https://git.odit.services/lfk/document-server/commit/4773a5f18c866b6e9d50b421d7917416860cb6b5) -- Removed puppeteer args [`06dedc0`](https://git.odit.services/lfk/document-server/commit/06dedc0797b649f3fa8934f0d774ccae2b062849) -- Expanded max request body size to 500mb [`4f191dc`](https://git.odit.services/lfk/document-server/commit/4f191dcb52cd727e34770ab4304937cd1e7e480d) -- Now awaiting language change [`c07319b`](https://git.odit.services/lfk/document-server/commit/c07319b250db9452f6122e797b6059151031e2a9) -- 🧾New changelog file version [CI SKIP] [skip ci] [`42d6c40`](https://git.odit.services/lfk/document-server/commit/42d6c40d0c673f39c27e3d5a6484f01a4da77266) -- Formatting [`2d0b7ce`](https://git.odit.services/lfk/document-server/commit/2d0b7ce79ed47d4827096a2bbccfe3bbcd061810) -- Removed useless await [`4cd437b`](https://git.odit.services/lfk/document-server/commit/4cd437b6afe40e4c09027c0e2004a1130bc51870) -- Updated comments [`cf9cd29`](https://git.odit.services/lfk/document-server/commit/cf9cd298b638012e079be0a04d1b48efea20026f) -- Merge pull request 'Patch 0.0.2' (#9) from dev into main [`4585a83`](https://git.odit.services/lfk/document-server/commit/4585a83838b80552160c9d9e5be0af891eae39c8) -- Merge pull request 'Basic documentation feature/6-documentation' (#8) from feature/6-documentation into dev [`73915da`](https://git.odit.services/lfk/document-server/commit/73915da20321940e22145b4c5d830b9f700be566) -- 📖New license file version [CI SKIP] [skip ci] [`465efe0`](https://git.odit.services/lfk/document-server/commit/465efe03000ecc00d14479ac38710ffdba2cafb5) -- Typos [`68e34a9`](https://git.odit.services/lfk/document-server/commit/68e34a9054a195545b0bd10ce888f7274854fae6) -- Merge pull request 'Implemented the basics for templateing feature/3-pdf_templateing' (#4) from feature/3-pdf_templateing into dev [`15f1641`](https://git.odit.services/lfk/document-server/commit/15f16415c0ac5012df8126c8df6bd4da93ad0a20) -- Merge pull request 'Implemented the basic request classes feature/1-input_classes' (#2) from feature/1-input_classes into dev [`b5e79e5`](https://git.odit.services/lfk/document-server/commit/b5e79e51ef5d751a67e7a1763809ece91a7627f2) -- Added openapi viewers [`6435c8a`](https://git.odit.services/lfk/document-server/commit/6435c8a88e2ea3f4417ad5d8be9a07b9c043b41b) -- 📖New license file version [CI SKIP] [skip ci] [`d493e74`](https://git.odit.services/lfk/document-server/commit/d493e74bf39bc85de842ac7cd3e3d37ba8797a04) -- Initial commit [`0908bcd`](https://git.odit.services/lfk/document-server/commit/0908bcd63529b44463bc57ad7d6b8785564e4ddc) -- Added address class and errors [`d291cf0`](https://git.odit.services/lfk/document-server/commit/d291cf0d1bf375e96fda822543d5ceb29dc67010) -- Added drone file [`48d7cad`](https://git.odit.services/lfk/document-server/commit/48d7cad9f37485656cfb1c70abef158b5dd8d847) -- Added the donation classes [`1d73e4e`](https://git.odit.services/lfk/document-server/commit/1d73e4ed9ccb3dfb7709cb89957ed5bbcefad870) -- Added openapi related classes [`9d62225`](https://git.odit.services/lfk/document-server/commit/9d6222547811fd3c94b91496d9917b7df5115fc6) -- Added a bs example template [`f726a6e`](https://git.odit.services/lfk/document-server/commit/f726a6e699575b839d332c15e61c9008fe996fa9) -- Added a basic donor class [`cfa65e8`](https://git.odit.services/lfk/document-server/commit/cfa65e83cafcefbd6261a99ab7a4eaf099665a81) -- Added input class for contract generation [`63f9523`](https://git.odit.services/lfk/document-server/commit/63f952376698c3561754bfb206a64c58c1ae86f1) -- Initialized package [`b0427a6`](https://git.odit.services/lfk/document-server/commit/b0427a6d810656096c467881a302eef244f86d29) -- Added a simplified runnergroup class [`e29c17a`](https://git.odit.services/lfk/document-server/commit/e29c17a29a6ee84944f8d67d7b6f3c4292763c10) -- Resolved fun issues with promises [`4617f2c`](https://git.odit.services/lfk/document-server/commit/4617f2c5bdcb29534b46865ebe21d15e2b1cd72f) -- Added a runnercard class [`cb7325b`](https://git.odit.services/lfk/document-server/commit/cb7325bbf906b405955bd81e199abae5edc27d91) -- Added a basic readme [`df94b1b`](https://git.odit.services/lfk/document-server/commit/df94b1b750922989d870546150ff8d9ff8af4102) -- Added base app [`915ff92`](https://git.odit.services/lfk/document-server/commit/915ff92418a2859c11e0ce58b79220fb5ea06c7f) -- Added vscode workspace config [`ae466b4`](https://git.odit.services/lfk/document-server/commit/ae466b4d7e5b67c5cd1bc440214f477d15f768a2) -- Created a pdf class that takes care of the pdf wrapping [`7d5b575`](https://git.odit.services/lfk/document-server/commit/7d5b5750ad78fd979cb1b647d8b318a84513532a) -- Added editor and stageing infos to the README [`56b7227`](https://git.odit.services/lfk/document-server/commit/56b72275aca57b227c775c4a61e91fd03471f987) -- Added dockerfile and docker-compose [`b9d4cc3`](https://git.odit.services/lfk/document-server/commit/b9d4cc36199b8f0090d555e961a3454bf35f4bd6) -- Added loaders [`57afbd4`](https://git.odit.services/lfk/document-server/commit/57afbd4b6c48cf641b69a2fcbb28783ff84e1cfd) -- Added a certificaterunner class [`d08bdfd`](https://git.odit.services/lfk/document-server/commit/d08bdfd961f4128981b969cf149df7397a257193) -- Added a template section to the readme [`8141269`](https://git.odit.services/lfk/document-server/commit/8141269dd99f03b33019e5a8f4a010954c4fc44a) -- Created a barebones pdf controller [`64bd1ff`](https://git.odit.services/lfk/document-server/commit/64bd1ffc3ad8459c13154e2cd9a568f27baa2bf2) -- Moved distance to the main runner object [`1d1fa50`](https://git.odit.services/lfk/document-server/commit/1d1fa50327927328ce77af33c1abbf994df9ac8b) -- Added tsconfig [`e1f0378`](https://git.odit.services/lfk/document-server/commit/e1f03788dbdddcb1cb138556c1fed4da9ca104a8) -- Added basic dependencies [`43bb728`](https://git.odit.services/lfk/document-server/commit/43bb728d0d8b75239f1db765071d28a839300102) -- Added typeing to the buffer and stream conversion [`3fb8be2`](https://git.odit.services/lfk/document-server/commit/3fb8be22b74204accabed8a8c8fb5161c5ad7504) -- Added basic dependencies [`d450cea`](https://git.odit.services/lfk/document-server/commit/d450ceac74959bdfb694f9b12fb1fd14ff85b598) -- Added release-it config [`185e66f`](https://git.odit.services/lfk/document-server/commit/185e66fb5b2e4330233ff2e74101c4447c317b5a) -- Added config class [`278c563`](https://git.odit.services/lfk/document-server/commit/278c56386b0e9079a71d3339b40d08f046255a3e) -- Added Barebones pdf creator class [`557cc26`](https://git.odit.services/lfk/document-server/commit/557cc26f281da0b47621dff667435a788c42c103) -- Added a simple status controller [`1d62e7f`](https://git.odit.services/lfk/document-server/commit/1d62e7f14c8d6219607ed6ecf774ae152e362cc1) -- Added errorhandler middleware [`6539fd7`](https://git.odit.services/lfk/document-server/commit/6539fd785568971330639fb7055827417424c81a) -- Runners now use the runnergroup class instead of strings [`aae4f50`](https://git.odit.services/lfk/document-server/commit/aae4f507eafbfd51cd9972cf0fac4c5afafbb45a) -- Added files to gitignore [`66134c0`](https://git.odit.services/lfk/document-server/commit/66134c0e1e5dce2ebd9eae3f88a6ad893bad0283) -- Switched to the splitted functions [`3ca38ab`](https://git.odit.services/lfk/document-server/commit/3ca38abe9359e436fe0f80400ad0308ad9d64a4f) -- Cleaned up openapi stuff [`4efb629`](https://git.odit.services/lfk/document-server/commit/4efb62921bced79c817499b48bbc55b05e6371e5) -- Updated apidoc viewer settings [`36396af`](https://git.odit.services/lfk/document-server/commit/36396af50a1f7d1842effbd24e08a8d34946a375) -- Updated apidoc viewer settings [`4d45e0f`](https://git.odit.services/lfk/document-server/commit/4d45e0f80d5721c91de0b25334d040448d92e01d) -- 🧾New changelog file version [CI SKIP] [skip ci] [`8f250f7`](https://git.odit.services/lfk/document-server/commit/8f250f747a95feb246b1698a7c9be9ee19a1be12) -- Added missing dependencies [`c2d7141`](https://git.odit.services/lfk/document-server/commit/c2d714116e02bb4c2ff6501ba32417cd998e2f3e) -- Added license export and release scripts [`0c4e5a1`](https://git.odit.services/lfk/document-server/commit/0c4e5a182c91b99a657c83f2c24f4cfaae1ef48d) -- Added build script [`cbc421c`](https://git.odit.services/lfk/document-server/commit/cbc421cd838b6c874fbe50556350edeb08a7b882) -- Added dev script [`814b564`](https://git.odit.services/lfk/document-server/commit/814b564752aa95ed2c034a9a98c800b43452bf88) -- Adjusted template font styleing [`2c7b025`](https://git.odit.services/lfk/document-server/commit/2c7b0254ec7e49c31f8f33eed334ab4156052fb6) -- Added html-pdf package [`a7d4001`](https://git.odit.services/lfk/document-server/commit/a7d4001ad992d60e2af69e9bbed53366bc0a46d3) -- Added PDFs to gitignore [`9f3758d`](https://git.odit.services/lfk/document-server/commit/9f3758de39ef1d5b591a24868eb683caa742f694) -- Added version to config [`b1747f6`](https://git.odit.services/lfk/document-server/commit/b1747f6374c029e1e9c3a87584ea54b9d3714d92) -- fixed license-exporter call [`83c4bd6`](https://git.odit.services/lfk/document-server/commit/83c4bd62cbbb13ae33a790baa45cc15a77d99e41) -- Added version to config [`cff7011`](https://git.odit.services/lfk/document-server/commit/cff70110fde72c7fede0625872acdc0666703fa1) -- Added openapi dependency [`94e5e51`](https://git.odit.services/lfk/document-server/commit/94e5e51f8d421ea7fd64ded2281b89ff4a252b29) -- Added templates folder [`8a30265`](https://git.odit.services/lfk/document-server/commit/8a30265fc600dad17f584f95dd51db976945d4c5) +### Changelog + +All notable changes to this project will be documented in this file. Dates are displayed in UTC. + +#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.2...v0.1.2) + +- Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) +- Added new env vars to config [`3bb322e`](https://git.odit.services/lfk/document-server/commit/3bb322ede5db15a147c0d7a8db2a68ccb7fa2112) +- Added new env vars to readme [`b77bb3a`](https://git.odit.services/lfk/document-server/commit/b77bb3ad9dba9d73c2c81215ba57936192155a9a) +- Now loading interpolation vars from config/env [`b4ebae2`](https://git.odit.services/lfk/document-server/commit/b4ebae283b472b2f0c6e28caed49b30edb119585) +- 🧾New changelog file version [CI SKIP] [skip ci] [`a306009`](https://git.odit.services/lfk/document-server/commit/a30600943d01116b99e946cb705a16d0372b5095) + +#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.1...v0.1.2) + +> 7 February 2021 + +- Merge pull request 'Alpha Release 0.1.2 - Hotfix release' (#15) from dev into main [`123cf8a`](https://git.odit.services/lfk/document-server/commit/123cf8ad48a45fa10dcd5208215a6e525f31115a) +- 🧾New changelog file version [CI SKIP] [skip ci] [`22b1e00`](https://git.odit.services/lfk/document-server/commit/22b1e0097efc865de9cc150cb0d0b99bf789b519) +- 🚀Bumped version to v0.1.2 [`7e507d4`](https://git.odit.services/lfk/document-server/commit/7e507d4cc415877ac0b25503dc0ff9ecdceabf42) +- PAtch: Copy locales [`f7dfd6d`](https://git.odit.services/lfk/document-server/commit/f7dfd6d0c3c69881338bc1f66d5d33ae9abff628) + +#### [v0.1.1](https://git.odit.services/lfk/document-server/compare/v0.1.0...v0.1.1) + +> 7 February 2021 + +- Merge pull request 'Alpha Release 0.1.1 - Hotfix release' (#12) from dev into main [`cbff307`](https://git.odit.services/lfk/document-server/commit/cbff3074d10110dbb64dda1ed516d2a18402eeca) +- 🧾New changelog file version [CI SKIP] [skip ci] [`4fca5af`](https://git.odit.services/lfk/document-server/commit/4fca5afdfa15d3260ac28c1feb89d50221b1f03f) +- Updated dockerfile & build for dockerized puppeteer [`ea8028d`](https://git.odit.services/lfk/document-server/commit/ea8028dfd54861335e9752334db335ad21e75cf2) +- 📖New license file version [CI SKIP] [skip ci] [`8d4e7a1`](https://git.odit.services/lfk/document-server/commit/8d4e7a16d1ebae6976ec183b761ca3e6a8946629) +- Revert "Now only using our mirror to build" [`fe0f45e`](https://git.odit.services/lfk/document-server/commit/fe0f45ea92099a65d998e342ef885af39d06915f) +- Now only using our mirror to build [`b07c5a9`](https://git.odit.services/lfk/document-server/commit/b07c5a96f2a670f2279a6575b03f9c553b59e0a9) +- 🧾New changelog file version [CI SKIP] [skip ci] [`9755e43`](https://git.odit.services/lfk/document-server/commit/9755e437c2b68c09e9b0ffa47c6bc1729e6bee14) +- 🧾New changelog file version [CI SKIP] [skip ci] [`603a814`](https://git.odit.services/lfk/document-server/commit/603a814ad4783c0b29c1f6a1db638f269b29f775) +- Switched to using our mirrored images for buildi [`dba765c`](https://git.odit.services/lfk/document-server/commit/dba765cb017998ad636f3f91fb00a8a277d3b225) +- 🚀Bumped version to v0.1.1 [`d1b07f3`](https://git.odit.services/lfk/document-server/commit/d1b07f39fd7e3c282a631924bf45367e866e667a) +- Pinned alpine version [`6ab3946`](https://git.odit.services/lfk/document-server/commit/6ab3946c31a7716d1c42fb217b0a0f7be8172dba) + +#### v0.1.0 + +> 7 February 2021 + +- Merge pull request 'Alpha Release 0.1.0 - Contract generation' (#11) from dev into main [`bc2b6fa`](https://git.odit.services/lfk/document-server/commit/bc2b6fadd912f275bc05be29c6fbd87367d617df) +- 📖New license file version [CI SKIP] [skip ci] [`ee19efa`](https://git.odit.services/lfk/document-server/commit/ee19efa0e63f21a10fed1cf24beb16118bbe6cde) +- 🚀Bumped version to v0.0.2 [`de432c4`](https://git.odit.services/lfk/document-server/commit/de432c448129a8acb36fef6b40ef920eeb2f7887) +- First working (TM) template code [`a9e3360`](https://git.odit.services/lfk/document-server/commit/a9e3360ee258e4d48c8dbe3a55468409bb6ee0f7) +- Working Styleing [`c617c40`](https://git.odit.services/lfk/document-server/commit/c617c40e9d7e03382f647eafde9ff458db3c6c15) +- Removed base64 image [`e401d0e`](https://git.odit.services/lfk/document-server/commit/e401d0ec7219e88fbb277b2dcf456a22dae0d1e5) +- Updated the contract template to use external css [`6121b1e`](https://git.odit.services/lfk/document-server/commit/6121b1e3bfcf6fc9f88e0589205044c59859b4a7) +- Sorted locales [`1962499`](https://git.odit.services/lfk/document-server/commit/1962499d18685347302fd7d8491c6e3e7a355fcb) +- Switched to puppeteer for pdf generation [`5afd26e`](https://git.odit.services/lfk/document-server/commit/5afd26ea22cff3b8a339cf658ed37d2053db24ba) +- Added a coupple of real replacement strings to the sponsoring template [`041c0ed`](https://git.odit.services/lfk/document-server/commit/041c0ed6bbe5f8645e4e96b57c02d4e45b445402) +- Added automatic img to base64 conversion [`42443af`](https://git.odit.services/lfk/document-server/commit/42443af734ccc9ce202aec045a07775f4a054b92) +- Added i18n strings [`e345c36`](https://git.odit.services/lfk/document-server/commit/e345c36dd0b03f276259521aebf423853a81a04d) +- first working pdf generation from class 🎉 [`3af76a5`](https://git.odit.services/lfk/document-server/commit/3af76a53e3156bdc2d1d3ade6ff940db9d7b24b5) +- Added a bunch of english and german translations 🌎 [`784d7c6`](https://git.odit.services/lfk/document-server/commit/784d7c656fd2dfc726722459f3ccb7612021b882) +- Added translations using i18next [`75eb925`](https://git.odit.services/lfk/document-server/commit/75eb9252672883f7b6f89a812a37d2b96f9f626e) +- Switched to handlebars for templateing [`4acf3e3`](https://git.odit.services/lfk/document-server/commit/4acf3e39ce55c0ad9e697cf9598569ec1c1dcb44) +- Moved pdf creatior initialization to new function [`47a05fa`](https://git.odit.services/lfk/document-server/commit/47a05facb33c178e9bf3f99c25049abc010361c4) +- 🧾New changelog file version [CI SKIP] [skip ci] [`f3de80a`](https://git.odit.services/lfk/document-server/commit/f3de80af78c96bd697715a30dee7cae6806f9f9f) +- 🚀Bumped version to v0.1.0 [`6a42fe3`](https://git.odit.services/lfk/document-server/commit/6a42fe37d053a6a00005e3c5781edfcefe61183e) +- Merge pull request 'Sponsoring contract generation feature/5-sponsoring_contracts' (#10) from feature/5-sponsoring_contracts into dev [`84259d3`](https://git.odit.services/lfk/document-server/commit/84259d37d42234e1be75f3a5c95f4b442a9e5844) +- Added optimization args [`140fda1`](https://git.odit.services/lfk/document-server/commit/140fda11cc88cb93218116d4cbdbf13c014a659d) +- Added first parts of template [`13776d1`](https://git.odit.services/lfk/document-server/commit/13776d1ecb2db03f19dd0c01a930d4c98222cf6b) +- Added pdf merging for big requests (over 100 runners) [`785544c`](https://git.odit.services/lfk/document-server/commit/785544ca16cd4907a378eb2d48e4269778e3dccc) +- Fixed file broken in merge [`c07c6ae`](https://git.odit.services/lfk/document-server/commit/c07c6aeeab70589a4e1ddf025a07bde96c68ef6e) +- Now with workin i18n-ally config🥳 [`7c3813b`](https://git.odit.services/lfk/document-server/commit/7c3813b94d06ca38b83db90b7f9fba6c33716a05) +- Now with workin i18n-ally config🥳 [`b4232e5`](https://git.odit.services/lfk/document-server/commit/b4232e51e084f491d1a7fb4f929327e88f3b4c00) +- Now accepting arrays for sponsoring contract generation [`f833ae2`](https://git.odit.services/lfk/document-server/commit/f833ae222e68b7df9b8f8a8ec7ce17d679a9710f) +- Added full interpolation support to the i18n [`f755f4f`](https://git.odit.services/lfk/document-server/commit/f755f4f9fb1463af6bec3cf73b7fabf95ef3fb2e) +- Added option to generate empty sponsoring contracts [`1ced0e3`](https://git.odit.services/lfk/document-server/commit/1ced0e317544217599a42c6b270c9136dc73676d) +- Added translation sorting secript [`1e67672`](https://git.odit.services/lfk/document-server/commit/1e67672ef0d28f94a50b0377cca8e8ff2a87e983) +- Removed the example data from the fill-in fields [`5e12525`](https://git.odit.services/lfk/document-server/commit/5e1252545b7eafeee6c3a1d67567d00e5d615d85) +- Edited html template [`d58453f`](https://git.odit.services/lfk/document-server/commit/d58453faf9840037c583e029c41ef1b31a0bafa8) +- PDF Creator now accepts single instances of class [`78205ee`](https://git.odit.services/lfk/document-server/commit/78205ee8c7659ae0dc2e4a184554b042251d9271) +- PDF Creator now accepts single instances of class [`ba7cedd`](https://git.odit.services/lfk/document-server/commit/ba7cedd187dbc51a53ba169889d8e0ca22a97b5d) +- Updated template for i18n [`a596188`](https://git.odit.services/lfk/document-server/commit/a596188c00444c285565eecbb1f0bc668bb4706c) +- Parellized the chunks [`e92820e`](https://git.odit.services/lfk/document-server/commit/e92820e12f289b4fd28b4ebc985b5b711777fc35) +- Fixed the controller not waiting for initialization [`ee8ba99`](https://git.odit.services/lfk/document-server/commit/ee8ba99cc7778f89a8bb99400c7d1cf1a12898f7) +- Implemented language selection by query param [`6f81566`](https://git.odit.services/lfk/document-server/commit/6f81566cb82a0801a20523a7177996ea40cb3968) +- Added comments [`cd51e78`](https://git.odit.services/lfk/document-server/commit/cd51e78282278cae6cb86bd0c9616746612a97e3) +- Added example locales [`1969769`](https://git.odit.services/lfk/document-server/commit/19697692bcb6c0c1c978918916caccd95a8f2035) +- Fixed data validation problem [`bd6ec62`](https://git.odit.services/lfk/document-server/commit/bd6ec6215d362325c510611e4545b7643b918200) +- Removed fullname from groups (to be renabled later) [`388d8a2`](https://git.odit.services/lfk/document-server/commit/388d8a2dc6ee06d39e621e1e45ae595dae587483) +- Updated comments [`119102a`](https://git.odit.services/lfk/document-server/commit/119102aef8f43a68f537e7542c2f2cd3b41cd28e) +- Updated readme for handlebars [`05e4718`](https://git.odit.services/lfk/document-server/commit/05e471878f2321a1873b21730ae85ad6b8af5766) +- Updated readme [`f69e777`](https://git.odit.services/lfk/document-server/commit/f69e7779e42f18df7ec3ccb1cdf9dcf7fa845ee6) +- 🧾New changelog file version [CI SKIP] [skip ci] [`f4a34dd`](https://git.odit.services/lfk/document-server/commit/f4a34dd36b57bd122a650f2de4ea8e00816276ed) +- Typos [`95b882a`](https://git.odit.services/lfk/document-server/commit/95b882aceded275ad89446ad92a10cf36b166ab7) +- Added sentence about large requests to the /contracts openapi description [`4773a5f`](https://git.odit.services/lfk/document-server/commit/4773a5f18c866b6e9d50b421d7917416860cb6b5) +- Removed puppeteer args [`06dedc0`](https://git.odit.services/lfk/document-server/commit/06dedc0797b649f3fa8934f0d774ccae2b062849) +- Expanded max request body size to 500mb [`4f191dc`](https://git.odit.services/lfk/document-server/commit/4f191dcb52cd727e34770ab4304937cd1e7e480d) +- Now awaiting language change [`c07319b`](https://git.odit.services/lfk/document-server/commit/c07319b250db9452f6122e797b6059151031e2a9) +- 🧾New changelog file version [CI SKIP] [skip ci] [`42d6c40`](https://git.odit.services/lfk/document-server/commit/42d6c40d0c673f39c27e3d5a6484f01a4da77266) +- Formatting [`2d0b7ce`](https://git.odit.services/lfk/document-server/commit/2d0b7ce79ed47d4827096a2bbccfe3bbcd061810) +- Removed useless await [`4cd437b`](https://git.odit.services/lfk/document-server/commit/4cd437b6afe40e4c09027c0e2004a1130bc51870) +- Updated comments [`cf9cd29`](https://git.odit.services/lfk/document-server/commit/cf9cd298b638012e079be0a04d1b48efea20026f) +- Merge pull request 'Patch 0.0.2' (#9) from dev into main [`4585a83`](https://git.odit.services/lfk/document-server/commit/4585a83838b80552160c9d9e5be0af891eae39c8) +- Merge pull request 'Basic documentation feature/6-documentation' (#8) from feature/6-documentation into dev [`73915da`](https://git.odit.services/lfk/document-server/commit/73915da20321940e22145b4c5d830b9f700be566) +- 📖New license file version [CI SKIP] [skip ci] [`465efe0`](https://git.odit.services/lfk/document-server/commit/465efe03000ecc00d14479ac38710ffdba2cafb5) +- Typos [`68e34a9`](https://git.odit.services/lfk/document-server/commit/68e34a9054a195545b0bd10ce888f7274854fae6) +- Merge pull request 'Implemented the basics for templateing feature/3-pdf_templateing' (#4) from feature/3-pdf_templateing into dev [`15f1641`](https://git.odit.services/lfk/document-server/commit/15f16415c0ac5012df8126c8df6bd4da93ad0a20) +- Merge pull request 'Implemented the basic request classes feature/1-input_classes' (#2) from feature/1-input_classes into dev [`b5e79e5`](https://git.odit.services/lfk/document-server/commit/b5e79e51ef5d751a67e7a1763809ece91a7627f2) +- Added openapi viewers [`6435c8a`](https://git.odit.services/lfk/document-server/commit/6435c8a88e2ea3f4417ad5d8be9a07b9c043b41b) +- 📖New license file version [CI SKIP] [skip ci] [`d493e74`](https://git.odit.services/lfk/document-server/commit/d493e74bf39bc85de842ac7cd3e3d37ba8797a04) +- Initial commit [`0908bcd`](https://git.odit.services/lfk/document-server/commit/0908bcd63529b44463bc57ad7d6b8785564e4ddc) +- Added address class and errors [`d291cf0`](https://git.odit.services/lfk/document-server/commit/d291cf0d1bf375e96fda822543d5ceb29dc67010) +- Added drone file [`48d7cad`](https://git.odit.services/lfk/document-server/commit/48d7cad9f37485656cfb1c70abef158b5dd8d847) +- Added the donation classes [`1d73e4e`](https://git.odit.services/lfk/document-server/commit/1d73e4ed9ccb3dfb7709cb89957ed5bbcefad870) +- Added openapi related classes [`9d62225`](https://git.odit.services/lfk/document-server/commit/9d6222547811fd3c94b91496d9917b7df5115fc6) +- Added a bs example template [`f726a6e`](https://git.odit.services/lfk/document-server/commit/f726a6e699575b839d332c15e61c9008fe996fa9) +- Added a basic donor class [`cfa65e8`](https://git.odit.services/lfk/document-server/commit/cfa65e83cafcefbd6261a99ab7a4eaf099665a81) +- Added input class for contract generation [`63f9523`](https://git.odit.services/lfk/document-server/commit/63f952376698c3561754bfb206a64c58c1ae86f1) +- Initialized package [`b0427a6`](https://git.odit.services/lfk/document-server/commit/b0427a6d810656096c467881a302eef244f86d29) +- Added a simplified runnergroup class [`e29c17a`](https://git.odit.services/lfk/document-server/commit/e29c17a29a6ee84944f8d67d7b6f3c4292763c10) +- Resolved fun issues with promises [`4617f2c`](https://git.odit.services/lfk/document-server/commit/4617f2c5bdcb29534b46865ebe21d15e2b1cd72f) +- Added a runnercard class [`cb7325b`](https://git.odit.services/lfk/document-server/commit/cb7325bbf906b405955bd81e199abae5edc27d91) +- Added a basic readme [`df94b1b`](https://git.odit.services/lfk/document-server/commit/df94b1b750922989d870546150ff8d9ff8af4102) +- Added base app [`915ff92`](https://git.odit.services/lfk/document-server/commit/915ff92418a2859c11e0ce58b79220fb5ea06c7f) +- Added vscode workspace config [`ae466b4`](https://git.odit.services/lfk/document-server/commit/ae466b4d7e5b67c5cd1bc440214f477d15f768a2) +- Created a pdf class that takes care of the pdf wrapping [`7d5b575`](https://git.odit.services/lfk/document-server/commit/7d5b5750ad78fd979cb1b647d8b318a84513532a) +- Added editor and stageing infos to the README [`56b7227`](https://git.odit.services/lfk/document-server/commit/56b72275aca57b227c775c4a61e91fd03471f987) +- Added dockerfile and docker-compose [`b9d4cc3`](https://git.odit.services/lfk/document-server/commit/b9d4cc36199b8f0090d555e961a3454bf35f4bd6) +- Added loaders [`57afbd4`](https://git.odit.services/lfk/document-server/commit/57afbd4b6c48cf641b69a2fcbb28783ff84e1cfd) +- Added a certificaterunner class [`d08bdfd`](https://git.odit.services/lfk/document-server/commit/d08bdfd961f4128981b969cf149df7397a257193) +- Added a template section to the readme [`8141269`](https://git.odit.services/lfk/document-server/commit/8141269dd99f03b33019e5a8f4a010954c4fc44a) +- Created a barebones pdf controller [`64bd1ff`](https://git.odit.services/lfk/document-server/commit/64bd1ffc3ad8459c13154e2cd9a568f27baa2bf2) +- Moved distance to the main runner object [`1d1fa50`](https://git.odit.services/lfk/document-server/commit/1d1fa50327927328ce77af33c1abbf994df9ac8b) +- Added tsconfig [`e1f0378`](https://git.odit.services/lfk/document-server/commit/e1f03788dbdddcb1cb138556c1fed4da9ca104a8) +- Added basic dependencies [`43bb728`](https://git.odit.services/lfk/document-server/commit/43bb728d0d8b75239f1db765071d28a839300102) +- Added typeing to the buffer and stream conversion [`3fb8be2`](https://git.odit.services/lfk/document-server/commit/3fb8be22b74204accabed8a8c8fb5161c5ad7504) +- Added basic dependencies [`d450cea`](https://git.odit.services/lfk/document-server/commit/d450ceac74959bdfb694f9b12fb1fd14ff85b598) +- Added release-it config [`185e66f`](https://git.odit.services/lfk/document-server/commit/185e66fb5b2e4330233ff2e74101c4447c317b5a) +- Added config class [`278c563`](https://git.odit.services/lfk/document-server/commit/278c56386b0e9079a71d3339b40d08f046255a3e) +- Added Barebones pdf creator class [`557cc26`](https://git.odit.services/lfk/document-server/commit/557cc26f281da0b47621dff667435a788c42c103) +- Added a simple status controller [`1d62e7f`](https://git.odit.services/lfk/document-server/commit/1d62e7f14c8d6219607ed6ecf774ae152e362cc1) +- Added errorhandler middleware [`6539fd7`](https://git.odit.services/lfk/document-server/commit/6539fd785568971330639fb7055827417424c81a) +- Runners now use the runnergroup class instead of strings [`aae4f50`](https://git.odit.services/lfk/document-server/commit/aae4f507eafbfd51cd9972cf0fac4c5afafbb45a) +- Added files to gitignore [`66134c0`](https://git.odit.services/lfk/document-server/commit/66134c0e1e5dce2ebd9eae3f88a6ad893bad0283) +- Switched to the splitted functions [`3ca38ab`](https://git.odit.services/lfk/document-server/commit/3ca38abe9359e436fe0f80400ad0308ad9d64a4f) +- Cleaned up openapi stuff [`4efb629`](https://git.odit.services/lfk/document-server/commit/4efb62921bced79c817499b48bbc55b05e6371e5) +- Updated apidoc viewer settings [`36396af`](https://git.odit.services/lfk/document-server/commit/36396af50a1f7d1842effbd24e08a8d34946a375) +- Updated apidoc viewer settings [`4d45e0f`](https://git.odit.services/lfk/document-server/commit/4d45e0f80d5721c91de0b25334d040448d92e01d) +- 🧾New changelog file version [CI SKIP] [skip ci] [`8f250f7`](https://git.odit.services/lfk/document-server/commit/8f250f747a95feb246b1698a7c9be9ee19a1be12) +- Added missing dependencies [`c2d7141`](https://git.odit.services/lfk/document-server/commit/c2d714116e02bb4c2ff6501ba32417cd998e2f3e) +- Added license export and release scripts [`0c4e5a1`](https://git.odit.services/lfk/document-server/commit/0c4e5a182c91b99a657c83f2c24f4cfaae1ef48d) +- Added build script [`cbc421c`](https://git.odit.services/lfk/document-server/commit/cbc421cd838b6c874fbe50556350edeb08a7b882) +- Added dev script [`814b564`](https://git.odit.services/lfk/document-server/commit/814b564752aa95ed2c034a9a98c800b43452bf88) +- Adjusted template font styleing [`2c7b025`](https://git.odit.services/lfk/document-server/commit/2c7b0254ec7e49c31f8f33eed334ab4156052fb6) +- Added html-pdf package [`a7d4001`](https://git.odit.services/lfk/document-server/commit/a7d4001ad992d60e2af69e9bbed53366bc0a46d3) +- Added PDFs to gitignore [`9f3758d`](https://git.odit.services/lfk/document-server/commit/9f3758de39ef1d5b591a24868eb683caa742f694) +- Added version to config [`b1747f6`](https://git.odit.services/lfk/document-server/commit/b1747f6374c029e1e9c3a87584ea54b9d3714d92) +- fixed license-exporter call [`83c4bd6`](https://git.odit.services/lfk/document-server/commit/83c4bd62cbbb13ae33a790baa45cc15a77d99e41) +- Added version to config [`cff7011`](https://git.odit.services/lfk/document-server/commit/cff70110fde72c7fede0625872acdc0666703fa1) +- Added openapi dependency [`94e5e51`](https://git.odit.services/lfk/document-server/commit/94e5e51f8d421ea7fd64ded2281b89ff4a252b29) +- Added templates folder [`8a30265`](https://git.odit.services/lfk/document-server/commit/8a30265fc600dad17f584f95dd51db976945d4c5) diff --git a/README.md b/README.md index 34fcd1a..91dea08 100644 --- a/README.md +++ b/README.md @@ -1,78 +1,78 @@ -# @lfk/document-server - -The document generation server responsible for creating pdfs for sponsoring contracts, certificates and more. -This server doesn't interact with any database and can therefor be deployed on it's own. -The basic generation mechanism makes the templates and routes interchangeable (if you want to expand or modify it). - -## Quickstart 🐳 -> Use this to run the document server in docker. - -1. Clone the repo or copy the docker-compose -2. Run in the folder that contains the docker-compose file: `docker-compose up -d` -3. Visit http://127.0.0.1:4010/docs to check if the server is running - -## Dev Setup 🛠 -> Local dev setup - -1. Rename the .env.example file to .env (you can adjust app port and other settings, if needed) -2. Install Dependencies - ```bash - yarn - ``` -3. Start the server - ```bash - yarn dev - ``` - -## ENV Vars -> You can provide them via .env file or docker env vars. - -| Name | Type | Default | Description -| - | - | - | - -| APP_PORT | Number | 4010 | The port the backend server listens on. Is optional. -| NODE_ENV | String | dev | The apps env - influences debug info. -| EVENT_NAME | String | "Please set the event name" | The event's name - used to generate pdf text. -| CURRENCY_SYMBOL | String | "€" | The your currency's symbol - used to generate pdf text. -| SPONSORING_RECEIPT_MINIMUM_AMOUNT | String | "10" | The mimimum total donation amount a sponsor has to donate to be able to receive a donation receipt - used to generate pdf text. - -## Templates -> The document server uses html templates to generate various pdf documents. -> The templates are stored in src/templates by default. - -We provide a set of default templates that we use for the ["Lauf für Kaya!" charity run](https://lauf-fuer-kaya.de). -We use handlebars for templateing utilizing i18next for translation - the i18n string format in the templates is : `{{__ "string"}}` -You can provide your own templates by replacing the ones we provided before compiling the project or by simply mounting your custom templates into the docker container. - -The server currently needs the following templates to work: -* sponsoring_contract.html - -### Sponsoring Contracts - -| Template Data | Type | Optional | Description -| - | - | - | - -| runners | array(Runner) | ❌ | The runner objects. We generate a contract for each runner on a new DIN-A5 page. - - -## Recommended Editor - -[Visual Studio Code](https://code.visualstudio.com/) - -### Recommended Extensions - -* will be automatically recommended via ./vscode/extensions.json -* we also provide a config for i18n-ally in the .vscode folder - -## Staging -### Branches & Tags -* vX.Y.Z: Release tags created from the main branch - * The version numbers follow the semver standard - * A new release tag automaticly triggers the release ci pipeline -* main: Protected "release" branch - * The latest tag of the docker image get's build from this - * New releases get created as tags from this -* dev: Current dev branch for merging the different feature branches and bugfixes - * The dev tag of the docker image get's build from this - * Only push minor changes to this branch! - * To merge a feature branch into this please create a pull request -* feature/xyz: Feature branches - nameing scheme: `feature/issueid-title` +# @lfk/document-server + +The document generation server responsible for creating pdfs for sponsoring contracts, certificates and more. +This server doesn't interact with any database and can therefor be deployed on it's own. +The basic generation mechanism makes the templates and routes interchangeable (if you want to expand or modify it). + +## Quickstart 🐳 +> Use this to run the document server in docker. + +1. Clone the repo or copy the docker-compose +2. Run in the folder that contains the docker-compose file: `docker-compose up -d` +3. Visit http://127.0.0.1:4010/docs to check if the server is running + +## Dev Setup 🛠 +> Local dev setup + +1. Rename the .env.example file to .env (you can adjust app port and other settings, if needed) +2. Install Dependencies + ```bash + yarn + ``` +3. Start the server + ```bash + yarn dev + ``` + +## ENV Vars +> You can provide them via .env file or docker env vars. + +| Name | Type | Default | Description +| - | - | - | - +| APP_PORT | Number | 4010 | The port the backend server listens on. Is optional. +| NODE_ENV | String | dev | The apps env - influences debug info. +| EVENT_NAME | String | "Please set the event name" | The event's name - used to generate pdf text. +| CURRENCY_SYMBOL | String | "€" | The your currency's symbol - used to generate pdf text. +| SPONSORING_RECEIPT_MINIMUM_AMOUNT | String | "10" | The mimimum total donation amount a sponsor has to donate to be able to receive a donation receipt - used to generate pdf text. + +## Templates +> The document server uses html templates to generate various pdf documents. +> The templates are stored in src/templates by default. + +We provide a set of default templates that we use for the ["Lauf für Kaya!" charity run](https://lauf-fuer-kaya.de). +We use handlebars for templateing utilizing i18next for translation - the i18n string format in the templates is : `{{__ "string"}}` +You can provide your own templates by replacing the ones we provided before compiling the project or by simply mounting your custom templates into the docker container. + +The server currently needs the following templates to work: +* sponsoring_contract.html + +### Sponsoring Contracts + +| Template Data | Type | Optional | Description +| - | - | - | - +| runners | array(Runner) | ❌ | The runner objects. We generate a contract for each runner on a new DIN-A5 page. + + +## Recommended Editor + +[Visual Studio Code](https://code.visualstudio.com/) + +### Recommended Extensions + +* will be automatically recommended via ./vscode/extensions.json +* we also provide a config for i18n-ally in the .vscode folder + +## Staging +### Branches & Tags +* vX.Y.Z: Release tags created from the main branch + * The version numbers follow the semver standard + * A new release tag automaticly triggers the release ci pipeline +* main: Protected "release" branch + * The latest tag of the docker image get's build from this + * New releases get created as tags from this +* dev: Current dev branch for merging the different feature branches and bugfixes + * The dev tag of the docker image get's build from this + * Only push minor changes to this branch! + * To merge a feature branch into this please create a pull request +* feature/xyz: Feature branches - nameing scheme: `feature/issueid-title` * bugfix/xyz: Branches for bugfixes - nameing scheme:`bugfix/issueid-title` \ No newline at end of file diff --git a/package.json b/package.json index 90132ef..8ff778f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@odit/lfk-document-server", - "version": "0.1.2", + "version": "0.1.3", "description": "The document generation server for the LfK! runner system. This generates certificates, sponsoring aggreements and more", "main": "src/app.ts", "scripts": { diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index baeed0b..b236380 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -1,199 +1,199 @@ -import axios from 'axios'; -import cheerio from "cheerio"; -import fs from "fs"; -import Handlebars from 'handlebars'; -import i18next from "i18next"; -import Backend from 'i18next-fs-backend'; -import mime from "mime-types"; -import path from 'path'; -import { PDFDocument } from 'pdf-lib'; -import puppeteer from "puppeteer"; -import { config } from './config'; -import { Runner } from './models/Runner'; -import { RunnerGroup } from './models/RunnerGroup'; -/** - * This class is responsible for all things pdf creation. - * This uses the html templates from src/templates. - */ -export class PdfCreator { - private templateDir = path.join(__dirname, '/templates'); - private browser; - private static interpolations = { eventname: config.eventname, sponsoring_receipt_minimum_amount: config.sponsoring_receipt_minimum_amount, currency_symbol: config.currency_symbol } - - /** - * Main constructor. - * Initializes i18n(ext), Handlebars and puppeteer. - */ - constructor() { - this.init(); - } - - /** - * Main constructor. - * Initializes i18n(ext), Handlebars and puppeteer. - */ - public async init() { - const minimal_args = [ - '--autoplay-policy=user-gesture-required', - '--disable-background-networking', - '--disable-background-timer-throttling', - '--disable-backgrounding-occluded-windows', - '--disable-breakpad', - '--disable-client-side-phishing-detection', - '--disable-component-update', - '--disable-default-apps', - '--disable-dev-shm-usage', - '--disable-domain-reliability', - '--disable-extensions', - '--disable-features=AudioServiceOutOfProcess', - '--disable-hang-monitor', - '--disable-ipc-flooding-protection', - '--disable-notifications', - '--disable-offer-store-unmasked-wallet-cards', - '--disable-popup-blocking', - '--disable-print-preview', - '--disable-prompt-on-repost', - '--disable-renderer-backgrounding', - '--disable-speech-api', - '--disable-sync', - '--hide-scrollbars', - '--ignore-gpu-blacklist', - '--metrics-recording-only', - '--mute-audio', - '--no-default-browser-check', - '--no-first-run', - '--no-pings', - '--no-zygote', - '--password-store=basic', - '--use-gl=swiftshader', - '--no-sandbox' - ]; - - await i18next - .use(Backend) - .init({ - fallbackLng: 'en', - lng: 'en', - backend: { - loadPath: path.join(__dirname, '/locales/{{lng}}.json') - } - }); - await Handlebars.registerHelper('__', - function (str) { - return i18next.t(str, PdfCreator.interpolations).toString(); - } - ); - this.browser = await puppeteer.launch({ headless: true, args: minimal_args }); - } - - /** - * Generate sponsoring contract pdfs. - * @param runner The runner you want to generate the contracts for. - * @param locale The locale used for the contracts (default:en) - */ - public async generateSponsoringContract(runners: Runner[], locale: string = "en"): Promise { - if (runners.length == 1 && Object.keys(runners[0]).length == 0) { - runners[0] = this.generateEmptyRunner(); - } - if (runners.length > 50) { - let pdf_promises = new Array>(); - let i, j; - for (i = 0, j = runners.length; i < j; i += 50) { - let chunk = runners.slice(i, i + 50); - pdf_promises.push(this.generateSponsoringContract(chunk, locale)); - } - const pdfs = await Promise.all(pdf_promises); - return await this.mergePdfs(pdfs); - } - await i18next.changeLanguage(locale); - const template_source = fs.readFileSync(`${this.templateDir}/sponsoring_contract.html`, 'utf8'); - const template = Handlebars.compile(template_source); - const result = template({ runners }) - const pdf = await this.renderPdf(result, { format: "A5", landscape: true }); - return pdf - } - - /** - * Converts all images in html to base64. - * Works with image files in the template directory or images from urls. - * @param html The html string whoms images shall get replaced. - */ - public async imgToBase64(html): Promise { - const $ = cheerio.load(html) - $('img').each(async (index, element) => { - let imgsrc = $(element).attr("src"); - const img_type = mime.lookup(imgsrc); - - if (!(img_type.includes("image"))) { - throw new Error("File is not image mime type"); - } - - let image; - if (imgsrc.startsWith("http")) { - image = (await axios.get(imgsrc)).data; - image = Buffer.from(image).toString('base64'); - } - else { - if (imgsrc.startsWith("./")) { - imgsrc = imgsrc.replace("./", ""); - } - image = fs.readFileSync(`${this.templateDir}/${imgsrc}`, { encoding: "base64" }); - } - - image = `data:${img_type};base64,${image}` - $(element).attr("src", image) - }) - - return $.html(); - } - - /** - * This method manages the creation of pdfs via puppeteer. - * @param html The HTML that should get rendered. - * @param options Puppeteer PDF option (eg: {format: "A4"}) - */ - public async renderPdf(html: string, options): Promise { - html = await this.imgToBase64(html); - let page = await this.browser.newPage(); - await page.setContent(html); - const pdf = await page.pdf(options); - await page.close(); - return pdf; - } - - /** - * Merges multiple pdfs into one. - * @param pdfs The pdfs you want to merge as an buffer array. - * @returns The merged pdf as a buffer. - */ - private async mergePdfs(pdfs: Buffer[]): Promise { - const mergedPdf = await PDFDocument.create(); - - for (const pdfBuffer of pdfs) { - const pdf = await PDFDocument.load(pdfBuffer); - const copiedPages = await mergedPdf.copyPages(pdf, pdf.getPageIndices()); - copiedPages.forEach((page) => { - mergedPdf.addPage(page); - }); - } - - return (await mergedPdf.save()); - } - - /** - * Generates a new dummy runner with halfspaces for all strings. - * Can be used to generate empty sponsoring contracts. - * @returns A new runner object that apears to be empty. - */ - private generateEmptyRunner(): Runner { - let group = new RunnerGroup(); - group.id = 0; - group.name = " "; - let runner = new Runner(); - runner.id = 0; - runner.firstname = " "; - runner.lastname = " "; - runner.group = group; - return runner; - } +import axios from 'axios'; +import cheerio from "cheerio"; +import fs from "fs"; +import Handlebars from 'handlebars'; +import i18next from "i18next"; +import Backend from 'i18next-fs-backend'; +import mime from "mime-types"; +import path from 'path'; +import { PDFDocument } from 'pdf-lib'; +import puppeteer from "puppeteer"; +import { config } from './config'; +import { Runner } from './models/Runner'; +import { RunnerGroup } from './models/RunnerGroup'; +/** + * This class is responsible for all things pdf creation. + * This uses the html templates from src/templates. + */ +export class PdfCreator { + private templateDir = path.join(__dirname, '/templates'); + private browser; + private static interpolations = { eventname: config.eventname, sponsoring_receipt_minimum_amount: config.sponsoring_receipt_minimum_amount, currency_symbol: config.currency_symbol } + + /** + * Main constructor. + * Initializes i18n(ext), Handlebars and puppeteer. + */ + constructor() { + this.init(); + } + + /** + * Main constructor. + * Initializes i18n(ext), Handlebars and puppeteer. + */ + public async init() { + const minimal_args = [ + '--autoplay-policy=user-gesture-required', + '--disable-background-networking', + '--disable-background-timer-throttling', + '--disable-backgrounding-occluded-windows', + '--disable-breakpad', + '--disable-client-side-phishing-detection', + '--disable-component-update', + '--disable-default-apps', + '--disable-dev-shm-usage', + '--disable-domain-reliability', + '--disable-extensions', + '--disable-features=AudioServiceOutOfProcess', + '--disable-hang-monitor', + '--disable-ipc-flooding-protection', + '--disable-notifications', + '--disable-offer-store-unmasked-wallet-cards', + '--disable-popup-blocking', + '--disable-print-preview', + '--disable-prompt-on-repost', + '--disable-renderer-backgrounding', + '--disable-speech-api', + '--disable-sync', + '--hide-scrollbars', + '--ignore-gpu-blacklist', + '--metrics-recording-only', + '--mute-audio', + '--no-default-browser-check', + '--no-first-run', + '--no-pings', + '--no-zygote', + '--password-store=basic', + '--use-gl=swiftshader', + '--no-sandbox' + ]; + + await i18next + .use(Backend) + .init({ + fallbackLng: 'en', + lng: 'en', + backend: { + loadPath: path.join(__dirname, '/locales/{{lng}}.json') + } + }); + await Handlebars.registerHelper('__', + function (str) { + return i18next.t(str, PdfCreator.interpolations).toString(); + } + ); + this.browser = await puppeteer.launch({ headless: true, args: minimal_args }); + } + + /** + * Generate sponsoring contract pdfs. + * @param runner The runner you want to generate the contracts for. + * @param locale The locale used for the contracts (default:en) + */ + public async generateSponsoringContract(runners: Runner[], locale: string = "en"): Promise { + if (runners.length == 1 && Object.keys(runners[0]).length == 0) { + runners[0] = this.generateEmptyRunner(); + } + if (runners.length > 50) { + let pdf_promises = new Array>(); + let i, j; + for (i = 0, j = runners.length; i < j; i += 50) { + let chunk = runners.slice(i, i + 50); + pdf_promises.push(this.generateSponsoringContract(chunk, locale)); + } + const pdfs = await Promise.all(pdf_promises); + return await this.mergePdfs(pdfs); + } + await i18next.changeLanguage(locale); + const template_source = fs.readFileSync(`${this.templateDir}/sponsoring_contract.html`, 'utf8'); + const template = Handlebars.compile(template_source); + const result = template({ runners }) + const pdf = await this.renderPdf(result, { format: "A5", landscape: true }); + return pdf + } + + /** + * Converts all images in html to base64. + * Works with image files in the template directory or images from urls. + * @param html The html string whoms images shall get replaced. + */ + public async imgToBase64(html): Promise { + const $ = cheerio.load(html) + $('img').each(async (index, element) => { + let imgsrc = $(element).attr("src"); + const img_type = mime.lookup(imgsrc); + + if (!(img_type.includes("image"))) { + throw new Error("File is not image mime type"); + } + + let image; + if (imgsrc.startsWith("http")) { + image = (await axios.get(imgsrc)).data; + image = Buffer.from(image).toString('base64'); + } + else { + if (imgsrc.startsWith("./")) { + imgsrc = imgsrc.replace("./", ""); + } + image = fs.readFileSync(`${this.templateDir}/${imgsrc}`, { encoding: "base64" }); + } + + image = `data:${img_type};base64,${image}` + $(element).attr("src", image) + }) + + return $.html(); + } + + /** + * This method manages the creation of pdfs via puppeteer. + * @param html The HTML that should get rendered. + * @param options Puppeteer PDF option (eg: {format: "A4"}) + */ + public async renderPdf(html: string, options): Promise { + html = await this.imgToBase64(html); + let page = await this.browser.newPage(); + await page.setContent(html); + const pdf = await page.pdf(options); + await page.close(); + return pdf; + } + + /** + * Merges multiple pdfs into one. + * @param pdfs The pdfs you want to merge as an buffer array. + * @returns The merged pdf as a buffer. + */ + private async mergePdfs(pdfs: Buffer[]): Promise { + const mergedPdf = await PDFDocument.create(); + + for (const pdfBuffer of pdfs) { + const pdf = await PDFDocument.load(pdfBuffer); + const copiedPages = await mergedPdf.copyPages(pdf, pdf.getPageIndices()); + copiedPages.forEach((page) => { + mergedPdf.addPage(page); + }); + } + + return (await mergedPdf.save()); + } + + /** + * Generates a new dummy runner with halfspaces for all strings. + * Can be used to generate empty sponsoring contracts. + * @returns A new runner object that apears to be empty. + */ + private generateEmptyRunner(): Runner { + let group = new RunnerGroup(); + group.id = 0; + group.name = " "; + let runner = new Runner(); + runner.id = 0; + runner.firstname = " "; + runner.lastname = " "; + runner.group = group; + return runner; + } } \ No newline at end of file diff --git a/src/config.ts b/src/config.ts index 0a94d8e..1dfbca0 100644 --- a/src/config.ts +++ b/src/config.ts @@ -1,19 +1,19 @@ -import { config as configDotenv } from 'dotenv'; - -configDotenv(); -export const config = { - internal_port: parseInt(process.env.APP_PORT) || 4010, - development: process.env.NODE_ENV === "production", - version: process.env.VERSION || require('../package.json').version, - eventname: process.env.EVENT_NAME || "Please set the event name", - currency_symbol: process.env.CURRENCY_SYMBOL || "€", - sponsoring_receipt_minimum_amount: process.env.SPONSORING_RECEIPT_MINIMUM_AMOUNT || "10" -} -let errors = 0 -if (typeof config.internal_port !== "number") { - errors++ -} -if (typeof config.development !== "boolean") { - errors++ -} +import { config as configDotenv } from 'dotenv'; + +configDotenv(); +export const config = { + internal_port: parseInt(process.env.APP_PORT) || 4010, + development: process.env.NODE_ENV === "production", + version: process.env.VERSION || require('../package.json').version, + eventname: process.env.EVENT_NAME || "Please set the event name", + currency_symbol: process.env.CURRENCY_SYMBOL || "€", + sponsoring_receipt_minimum_amount: process.env.SPONSORING_RECEIPT_MINIMUM_AMOUNT || "10" +} +let errors = 0 +if (typeof config.internal_port !== "number") { + errors++ +} +if (typeof config.development !== "boolean") { + errors++ +} export let e = errors \ No newline at end of file From ad9a8a4fe0649d48db924771be8ecb4cbf5c162a Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 16:39:08 +0000 Subject: [PATCH 12/21] =?UTF-8?q?=F0=9F=A7=BENew=20changelog=20file=20vers?= =?UTF-8?q?ion=20[CI=20SKIP]=20[skip=20ci]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 312 ++++++++++++++++++++++++++------------------------- 1 file changed, 157 insertions(+), 155 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e6bd92a..b815a53 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,155 +1,157 @@ -### Changelog - -All notable changes to this project will be documented in this file. Dates are displayed in UTC. - -#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.2...v0.1.2) - -- Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) -- Added new env vars to config [`3bb322e`](https://git.odit.services/lfk/document-server/commit/3bb322ede5db15a147c0d7a8db2a68ccb7fa2112) -- Added new env vars to readme [`b77bb3a`](https://git.odit.services/lfk/document-server/commit/b77bb3ad9dba9d73c2c81215ba57936192155a9a) -- Now loading interpolation vars from config/env [`b4ebae2`](https://git.odit.services/lfk/document-server/commit/b4ebae283b472b2f0c6e28caed49b30edb119585) -- 🧾New changelog file version [CI SKIP] [skip ci] [`a306009`](https://git.odit.services/lfk/document-server/commit/a30600943d01116b99e946cb705a16d0372b5095) - -#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.1...v0.1.2) - -> 7 February 2021 - -- Merge pull request 'Alpha Release 0.1.2 - Hotfix release' (#15) from dev into main [`123cf8a`](https://git.odit.services/lfk/document-server/commit/123cf8ad48a45fa10dcd5208215a6e525f31115a) -- 🧾New changelog file version [CI SKIP] [skip ci] [`22b1e00`](https://git.odit.services/lfk/document-server/commit/22b1e0097efc865de9cc150cb0d0b99bf789b519) -- 🚀Bumped version to v0.1.2 [`7e507d4`](https://git.odit.services/lfk/document-server/commit/7e507d4cc415877ac0b25503dc0ff9ecdceabf42) -- PAtch: Copy locales [`f7dfd6d`](https://git.odit.services/lfk/document-server/commit/f7dfd6d0c3c69881338bc1f66d5d33ae9abff628) - -#### [v0.1.1](https://git.odit.services/lfk/document-server/compare/v0.1.0...v0.1.1) - -> 7 February 2021 - -- Merge pull request 'Alpha Release 0.1.1 - Hotfix release' (#12) from dev into main [`cbff307`](https://git.odit.services/lfk/document-server/commit/cbff3074d10110dbb64dda1ed516d2a18402eeca) -- 🧾New changelog file version [CI SKIP] [skip ci] [`4fca5af`](https://git.odit.services/lfk/document-server/commit/4fca5afdfa15d3260ac28c1feb89d50221b1f03f) -- Updated dockerfile & build for dockerized puppeteer [`ea8028d`](https://git.odit.services/lfk/document-server/commit/ea8028dfd54861335e9752334db335ad21e75cf2) -- 📖New license file version [CI SKIP] [skip ci] [`8d4e7a1`](https://git.odit.services/lfk/document-server/commit/8d4e7a16d1ebae6976ec183b761ca3e6a8946629) -- Revert "Now only using our mirror to build" [`fe0f45e`](https://git.odit.services/lfk/document-server/commit/fe0f45ea92099a65d998e342ef885af39d06915f) -- Now only using our mirror to build [`b07c5a9`](https://git.odit.services/lfk/document-server/commit/b07c5a96f2a670f2279a6575b03f9c553b59e0a9) -- 🧾New changelog file version [CI SKIP] [skip ci] [`9755e43`](https://git.odit.services/lfk/document-server/commit/9755e437c2b68c09e9b0ffa47c6bc1729e6bee14) -- 🧾New changelog file version [CI SKIP] [skip ci] [`603a814`](https://git.odit.services/lfk/document-server/commit/603a814ad4783c0b29c1f6a1db638f269b29f775) -- Switched to using our mirrored images for buildi [`dba765c`](https://git.odit.services/lfk/document-server/commit/dba765cb017998ad636f3f91fb00a8a277d3b225) -- 🚀Bumped version to v0.1.1 [`d1b07f3`](https://git.odit.services/lfk/document-server/commit/d1b07f39fd7e3c282a631924bf45367e866e667a) -- Pinned alpine version [`6ab3946`](https://git.odit.services/lfk/document-server/commit/6ab3946c31a7716d1c42fb217b0a0f7be8172dba) - -#### v0.1.0 - -> 7 February 2021 - -- Merge pull request 'Alpha Release 0.1.0 - Contract generation' (#11) from dev into main [`bc2b6fa`](https://git.odit.services/lfk/document-server/commit/bc2b6fadd912f275bc05be29c6fbd87367d617df) -- 📖New license file version [CI SKIP] [skip ci] [`ee19efa`](https://git.odit.services/lfk/document-server/commit/ee19efa0e63f21a10fed1cf24beb16118bbe6cde) -- 🚀Bumped version to v0.0.2 [`de432c4`](https://git.odit.services/lfk/document-server/commit/de432c448129a8acb36fef6b40ef920eeb2f7887) -- First working (TM) template code [`a9e3360`](https://git.odit.services/lfk/document-server/commit/a9e3360ee258e4d48c8dbe3a55468409bb6ee0f7) -- Working Styleing [`c617c40`](https://git.odit.services/lfk/document-server/commit/c617c40e9d7e03382f647eafde9ff458db3c6c15) -- Removed base64 image [`e401d0e`](https://git.odit.services/lfk/document-server/commit/e401d0ec7219e88fbb277b2dcf456a22dae0d1e5) -- Updated the contract template to use external css [`6121b1e`](https://git.odit.services/lfk/document-server/commit/6121b1e3bfcf6fc9f88e0589205044c59859b4a7) -- Sorted locales [`1962499`](https://git.odit.services/lfk/document-server/commit/1962499d18685347302fd7d8491c6e3e7a355fcb) -- Switched to puppeteer for pdf generation [`5afd26e`](https://git.odit.services/lfk/document-server/commit/5afd26ea22cff3b8a339cf658ed37d2053db24ba) -- Added a coupple of real replacement strings to the sponsoring template [`041c0ed`](https://git.odit.services/lfk/document-server/commit/041c0ed6bbe5f8645e4e96b57c02d4e45b445402) -- Added automatic img to base64 conversion [`42443af`](https://git.odit.services/lfk/document-server/commit/42443af734ccc9ce202aec045a07775f4a054b92) -- Added i18n strings [`e345c36`](https://git.odit.services/lfk/document-server/commit/e345c36dd0b03f276259521aebf423853a81a04d) -- first working pdf generation from class 🎉 [`3af76a5`](https://git.odit.services/lfk/document-server/commit/3af76a53e3156bdc2d1d3ade6ff940db9d7b24b5) -- Added a bunch of english and german translations 🌎 [`784d7c6`](https://git.odit.services/lfk/document-server/commit/784d7c656fd2dfc726722459f3ccb7612021b882) -- Added translations using i18next [`75eb925`](https://git.odit.services/lfk/document-server/commit/75eb9252672883f7b6f89a812a37d2b96f9f626e) -- Switched to handlebars for templateing [`4acf3e3`](https://git.odit.services/lfk/document-server/commit/4acf3e39ce55c0ad9e697cf9598569ec1c1dcb44) -- Moved pdf creatior initialization to new function [`47a05fa`](https://git.odit.services/lfk/document-server/commit/47a05facb33c178e9bf3f99c25049abc010361c4) -- 🧾New changelog file version [CI SKIP] [skip ci] [`f3de80a`](https://git.odit.services/lfk/document-server/commit/f3de80af78c96bd697715a30dee7cae6806f9f9f) -- 🚀Bumped version to v0.1.0 [`6a42fe3`](https://git.odit.services/lfk/document-server/commit/6a42fe37d053a6a00005e3c5781edfcefe61183e) -- Merge pull request 'Sponsoring contract generation feature/5-sponsoring_contracts' (#10) from feature/5-sponsoring_contracts into dev [`84259d3`](https://git.odit.services/lfk/document-server/commit/84259d37d42234e1be75f3a5c95f4b442a9e5844) -- Added optimization args [`140fda1`](https://git.odit.services/lfk/document-server/commit/140fda11cc88cb93218116d4cbdbf13c014a659d) -- Added first parts of template [`13776d1`](https://git.odit.services/lfk/document-server/commit/13776d1ecb2db03f19dd0c01a930d4c98222cf6b) -- Added pdf merging for big requests (over 100 runners) [`785544c`](https://git.odit.services/lfk/document-server/commit/785544ca16cd4907a378eb2d48e4269778e3dccc) -- Fixed file broken in merge [`c07c6ae`](https://git.odit.services/lfk/document-server/commit/c07c6aeeab70589a4e1ddf025a07bde96c68ef6e) -- Now with workin i18n-ally config🥳 [`7c3813b`](https://git.odit.services/lfk/document-server/commit/7c3813b94d06ca38b83db90b7f9fba6c33716a05) -- Now with workin i18n-ally config🥳 [`b4232e5`](https://git.odit.services/lfk/document-server/commit/b4232e51e084f491d1a7fb4f929327e88f3b4c00) -- Now accepting arrays for sponsoring contract generation [`f833ae2`](https://git.odit.services/lfk/document-server/commit/f833ae222e68b7df9b8f8a8ec7ce17d679a9710f) -- Added full interpolation support to the i18n [`f755f4f`](https://git.odit.services/lfk/document-server/commit/f755f4f9fb1463af6bec3cf73b7fabf95ef3fb2e) -- Added option to generate empty sponsoring contracts [`1ced0e3`](https://git.odit.services/lfk/document-server/commit/1ced0e317544217599a42c6b270c9136dc73676d) -- Added translation sorting secript [`1e67672`](https://git.odit.services/lfk/document-server/commit/1e67672ef0d28f94a50b0377cca8e8ff2a87e983) -- Removed the example data from the fill-in fields [`5e12525`](https://git.odit.services/lfk/document-server/commit/5e1252545b7eafeee6c3a1d67567d00e5d615d85) -- Edited html template [`d58453f`](https://git.odit.services/lfk/document-server/commit/d58453faf9840037c583e029c41ef1b31a0bafa8) -- PDF Creator now accepts single instances of class [`78205ee`](https://git.odit.services/lfk/document-server/commit/78205ee8c7659ae0dc2e4a184554b042251d9271) -- PDF Creator now accepts single instances of class [`ba7cedd`](https://git.odit.services/lfk/document-server/commit/ba7cedd187dbc51a53ba169889d8e0ca22a97b5d) -- Updated template for i18n [`a596188`](https://git.odit.services/lfk/document-server/commit/a596188c00444c285565eecbb1f0bc668bb4706c) -- Parellized the chunks [`e92820e`](https://git.odit.services/lfk/document-server/commit/e92820e12f289b4fd28b4ebc985b5b711777fc35) -- Fixed the controller not waiting for initialization [`ee8ba99`](https://git.odit.services/lfk/document-server/commit/ee8ba99cc7778f89a8bb99400c7d1cf1a12898f7) -- Implemented language selection by query param [`6f81566`](https://git.odit.services/lfk/document-server/commit/6f81566cb82a0801a20523a7177996ea40cb3968) -- Added comments [`cd51e78`](https://git.odit.services/lfk/document-server/commit/cd51e78282278cae6cb86bd0c9616746612a97e3) -- Added example locales [`1969769`](https://git.odit.services/lfk/document-server/commit/19697692bcb6c0c1c978918916caccd95a8f2035) -- Fixed data validation problem [`bd6ec62`](https://git.odit.services/lfk/document-server/commit/bd6ec6215d362325c510611e4545b7643b918200) -- Removed fullname from groups (to be renabled later) [`388d8a2`](https://git.odit.services/lfk/document-server/commit/388d8a2dc6ee06d39e621e1e45ae595dae587483) -- Updated comments [`119102a`](https://git.odit.services/lfk/document-server/commit/119102aef8f43a68f537e7542c2f2cd3b41cd28e) -- Updated readme for handlebars [`05e4718`](https://git.odit.services/lfk/document-server/commit/05e471878f2321a1873b21730ae85ad6b8af5766) -- Updated readme [`f69e777`](https://git.odit.services/lfk/document-server/commit/f69e7779e42f18df7ec3ccb1cdf9dcf7fa845ee6) -- 🧾New changelog file version [CI SKIP] [skip ci] [`f4a34dd`](https://git.odit.services/lfk/document-server/commit/f4a34dd36b57bd122a650f2de4ea8e00816276ed) -- Typos [`95b882a`](https://git.odit.services/lfk/document-server/commit/95b882aceded275ad89446ad92a10cf36b166ab7) -- Added sentence about large requests to the /contracts openapi description [`4773a5f`](https://git.odit.services/lfk/document-server/commit/4773a5f18c866b6e9d50b421d7917416860cb6b5) -- Removed puppeteer args [`06dedc0`](https://git.odit.services/lfk/document-server/commit/06dedc0797b649f3fa8934f0d774ccae2b062849) -- Expanded max request body size to 500mb [`4f191dc`](https://git.odit.services/lfk/document-server/commit/4f191dcb52cd727e34770ab4304937cd1e7e480d) -- Now awaiting language change [`c07319b`](https://git.odit.services/lfk/document-server/commit/c07319b250db9452f6122e797b6059151031e2a9) -- 🧾New changelog file version [CI SKIP] [skip ci] [`42d6c40`](https://git.odit.services/lfk/document-server/commit/42d6c40d0c673f39c27e3d5a6484f01a4da77266) -- Formatting [`2d0b7ce`](https://git.odit.services/lfk/document-server/commit/2d0b7ce79ed47d4827096a2bbccfe3bbcd061810) -- Removed useless await [`4cd437b`](https://git.odit.services/lfk/document-server/commit/4cd437b6afe40e4c09027c0e2004a1130bc51870) -- Updated comments [`cf9cd29`](https://git.odit.services/lfk/document-server/commit/cf9cd298b638012e079be0a04d1b48efea20026f) -- Merge pull request 'Patch 0.0.2' (#9) from dev into main [`4585a83`](https://git.odit.services/lfk/document-server/commit/4585a83838b80552160c9d9e5be0af891eae39c8) -- Merge pull request 'Basic documentation feature/6-documentation' (#8) from feature/6-documentation into dev [`73915da`](https://git.odit.services/lfk/document-server/commit/73915da20321940e22145b4c5d830b9f700be566) -- 📖New license file version [CI SKIP] [skip ci] [`465efe0`](https://git.odit.services/lfk/document-server/commit/465efe03000ecc00d14479ac38710ffdba2cafb5) -- Typos [`68e34a9`](https://git.odit.services/lfk/document-server/commit/68e34a9054a195545b0bd10ce888f7274854fae6) -- Merge pull request 'Implemented the basics for templateing feature/3-pdf_templateing' (#4) from feature/3-pdf_templateing into dev [`15f1641`](https://git.odit.services/lfk/document-server/commit/15f16415c0ac5012df8126c8df6bd4da93ad0a20) -- Merge pull request 'Implemented the basic request classes feature/1-input_classes' (#2) from feature/1-input_classes into dev [`b5e79e5`](https://git.odit.services/lfk/document-server/commit/b5e79e51ef5d751a67e7a1763809ece91a7627f2) -- Added openapi viewers [`6435c8a`](https://git.odit.services/lfk/document-server/commit/6435c8a88e2ea3f4417ad5d8be9a07b9c043b41b) -- 📖New license file version [CI SKIP] [skip ci] [`d493e74`](https://git.odit.services/lfk/document-server/commit/d493e74bf39bc85de842ac7cd3e3d37ba8797a04) -- Initial commit [`0908bcd`](https://git.odit.services/lfk/document-server/commit/0908bcd63529b44463bc57ad7d6b8785564e4ddc) -- Added address class and errors [`d291cf0`](https://git.odit.services/lfk/document-server/commit/d291cf0d1bf375e96fda822543d5ceb29dc67010) -- Added drone file [`48d7cad`](https://git.odit.services/lfk/document-server/commit/48d7cad9f37485656cfb1c70abef158b5dd8d847) -- Added the donation classes [`1d73e4e`](https://git.odit.services/lfk/document-server/commit/1d73e4ed9ccb3dfb7709cb89957ed5bbcefad870) -- Added openapi related classes [`9d62225`](https://git.odit.services/lfk/document-server/commit/9d6222547811fd3c94b91496d9917b7df5115fc6) -- Added a bs example template [`f726a6e`](https://git.odit.services/lfk/document-server/commit/f726a6e699575b839d332c15e61c9008fe996fa9) -- Added a basic donor class [`cfa65e8`](https://git.odit.services/lfk/document-server/commit/cfa65e83cafcefbd6261a99ab7a4eaf099665a81) -- Added input class for contract generation [`63f9523`](https://git.odit.services/lfk/document-server/commit/63f952376698c3561754bfb206a64c58c1ae86f1) -- Initialized package [`b0427a6`](https://git.odit.services/lfk/document-server/commit/b0427a6d810656096c467881a302eef244f86d29) -- Added a simplified runnergroup class [`e29c17a`](https://git.odit.services/lfk/document-server/commit/e29c17a29a6ee84944f8d67d7b6f3c4292763c10) -- Resolved fun issues with promises [`4617f2c`](https://git.odit.services/lfk/document-server/commit/4617f2c5bdcb29534b46865ebe21d15e2b1cd72f) -- Added a runnercard class [`cb7325b`](https://git.odit.services/lfk/document-server/commit/cb7325bbf906b405955bd81e199abae5edc27d91) -- Added a basic readme [`df94b1b`](https://git.odit.services/lfk/document-server/commit/df94b1b750922989d870546150ff8d9ff8af4102) -- Added base app [`915ff92`](https://git.odit.services/lfk/document-server/commit/915ff92418a2859c11e0ce58b79220fb5ea06c7f) -- Added vscode workspace config [`ae466b4`](https://git.odit.services/lfk/document-server/commit/ae466b4d7e5b67c5cd1bc440214f477d15f768a2) -- Created a pdf class that takes care of the pdf wrapping [`7d5b575`](https://git.odit.services/lfk/document-server/commit/7d5b5750ad78fd979cb1b647d8b318a84513532a) -- Added editor and stageing infos to the README [`56b7227`](https://git.odit.services/lfk/document-server/commit/56b72275aca57b227c775c4a61e91fd03471f987) -- Added dockerfile and docker-compose [`b9d4cc3`](https://git.odit.services/lfk/document-server/commit/b9d4cc36199b8f0090d555e961a3454bf35f4bd6) -- Added loaders [`57afbd4`](https://git.odit.services/lfk/document-server/commit/57afbd4b6c48cf641b69a2fcbb28783ff84e1cfd) -- Added a certificaterunner class [`d08bdfd`](https://git.odit.services/lfk/document-server/commit/d08bdfd961f4128981b969cf149df7397a257193) -- Added a template section to the readme [`8141269`](https://git.odit.services/lfk/document-server/commit/8141269dd99f03b33019e5a8f4a010954c4fc44a) -- Created a barebones pdf controller [`64bd1ff`](https://git.odit.services/lfk/document-server/commit/64bd1ffc3ad8459c13154e2cd9a568f27baa2bf2) -- Moved distance to the main runner object [`1d1fa50`](https://git.odit.services/lfk/document-server/commit/1d1fa50327927328ce77af33c1abbf994df9ac8b) -- Added tsconfig [`e1f0378`](https://git.odit.services/lfk/document-server/commit/e1f03788dbdddcb1cb138556c1fed4da9ca104a8) -- Added basic dependencies [`43bb728`](https://git.odit.services/lfk/document-server/commit/43bb728d0d8b75239f1db765071d28a839300102) -- Added typeing to the buffer and stream conversion [`3fb8be2`](https://git.odit.services/lfk/document-server/commit/3fb8be22b74204accabed8a8c8fb5161c5ad7504) -- Added basic dependencies [`d450cea`](https://git.odit.services/lfk/document-server/commit/d450ceac74959bdfb694f9b12fb1fd14ff85b598) -- Added release-it config [`185e66f`](https://git.odit.services/lfk/document-server/commit/185e66fb5b2e4330233ff2e74101c4447c317b5a) -- Added config class [`278c563`](https://git.odit.services/lfk/document-server/commit/278c56386b0e9079a71d3339b40d08f046255a3e) -- Added Barebones pdf creator class [`557cc26`](https://git.odit.services/lfk/document-server/commit/557cc26f281da0b47621dff667435a788c42c103) -- Added a simple status controller [`1d62e7f`](https://git.odit.services/lfk/document-server/commit/1d62e7f14c8d6219607ed6ecf774ae152e362cc1) -- Added errorhandler middleware [`6539fd7`](https://git.odit.services/lfk/document-server/commit/6539fd785568971330639fb7055827417424c81a) -- Runners now use the runnergroup class instead of strings [`aae4f50`](https://git.odit.services/lfk/document-server/commit/aae4f507eafbfd51cd9972cf0fac4c5afafbb45a) -- Added files to gitignore [`66134c0`](https://git.odit.services/lfk/document-server/commit/66134c0e1e5dce2ebd9eae3f88a6ad893bad0283) -- Switched to the splitted functions [`3ca38ab`](https://git.odit.services/lfk/document-server/commit/3ca38abe9359e436fe0f80400ad0308ad9d64a4f) -- Cleaned up openapi stuff [`4efb629`](https://git.odit.services/lfk/document-server/commit/4efb62921bced79c817499b48bbc55b05e6371e5) -- Updated apidoc viewer settings [`36396af`](https://git.odit.services/lfk/document-server/commit/36396af50a1f7d1842effbd24e08a8d34946a375) -- Updated apidoc viewer settings [`4d45e0f`](https://git.odit.services/lfk/document-server/commit/4d45e0f80d5721c91de0b25334d040448d92e01d) -- 🧾New changelog file version [CI SKIP] [skip ci] [`8f250f7`](https://git.odit.services/lfk/document-server/commit/8f250f747a95feb246b1698a7c9be9ee19a1be12) -- Added missing dependencies [`c2d7141`](https://git.odit.services/lfk/document-server/commit/c2d714116e02bb4c2ff6501ba32417cd998e2f3e) -- Added license export and release scripts [`0c4e5a1`](https://git.odit.services/lfk/document-server/commit/0c4e5a182c91b99a657c83f2c24f4cfaae1ef48d) -- Added build script [`cbc421c`](https://git.odit.services/lfk/document-server/commit/cbc421cd838b6c874fbe50556350edeb08a7b882) -- Added dev script [`814b564`](https://git.odit.services/lfk/document-server/commit/814b564752aa95ed2c034a9a98c800b43452bf88) -- Adjusted template font styleing [`2c7b025`](https://git.odit.services/lfk/document-server/commit/2c7b0254ec7e49c31f8f33eed334ab4156052fb6) -- Added html-pdf package [`a7d4001`](https://git.odit.services/lfk/document-server/commit/a7d4001ad992d60e2af69e9bbed53366bc0a46d3) -- Added PDFs to gitignore [`9f3758d`](https://git.odit.services/lfk/document-server/commit/9f3758de39ef1d5b591a24868eb683caa742f694) -- Added version to config [`b1747f6`](https://git.odit.services/lfk/document-server/commit/b1747f6374c029e1e9c3a87584ea54b9d3714d92) -- fixed license-exporter call [`83c4bd6`](https://git.odit.services/lfk/document-server/commit/83c4bd62cbbb13ae33a790baa45cc15a77d99e41) -- Added version to config [`cff7011`](https://git.odit.services/lfk/document-server/commit/cff70110fde72c7fede0625872acdc0666703fa1) -- Added openapi dependency [`94e5e51`](https://git.odit.services/lfk/document-server/commit/94e5e51f8d421ea7fd64ded2281b89ff4a252b29) -- Added templates folder [`8a30265`](https://git.odit.services/lfk/document-server/commit/8a30265fc600dad17f584f95dd51db976945d4c5) +### Changelog + +All notable changes to this project will be documented in this file. Dates are displayed in UTC. + +#### [v0.1.3](https://git.odit.services/lfk/document-server/compare/v0.1.2...v0.1.3) + +- 🚀Bumped version to v0.1.3 [`6a14232`](https://git.odit.services/lfk/document-server/commit/6a142328898d5b89fa11eaf033372971d1093b0c) +- 🧾New changelog file version [CI SKIP] [skip ci] [`b6296b8`](https://git.odit.services/lfk/document-server/commit/b6296b8d97cda943dfb5e11bc9dfbb2f363f5b81) +- Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) +- Added new env vars to config [`3bb322e`](https://git.odit.services/lfk/document-server/commit/3bb322ede5db15a147c0d7a8db2a68ccb7fa2112) +- Added new env vars to readme [`b77bb3a`](https://git.odit.services/lfk/document-server/commit/b77bb3ad9dba9d73c2c81215ba57936192155a9a) +- Now loading interpolation vars from config/env [`b4ebae2`](https://git.odit.services/lfk/document-server/commit/b4ebae283b472b2f0c6e28caed49b30edb119585) +- 🧾New changelog file version [CI SKIP] [skip ci] [`a306009`](https://git.odit.services/lfk/document-server/commit/a30600943d01116b99e946cb705a16d0372b5095) + +#### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.1...v0.1.2) + +> 7 February 2021 + +- Merge pull request 'Alpha Release 0.1.2 - Hotfix release' (#15) from dev into main [`123cf8a`](https://git.odit.services/lfk/document-server/commit/123cf8ad48a45fa10dcd5208215a6e525f31115a) +- 🧾New changelog file version [CI SKIP] [skip ci] [`22b1e00`](https://git.odit.services/lfk/document-server/commit/22b1e0097efc865de9cc150cb0d0b99bf789b519) +- 🚀Bumped version to v0.1.2 [`7e507d4`](https://git.odit.services/lfk/document-server/commit/7e507d4cc415877ac0b25503dc0ff9ecdceabf42) +- PAtch: Copy locales [`f7dfd6d`](https://git.odit.services/lfk/document-server/commit/f7dfd6d0c3c69881338bc1f66d5d33ae9abff628) + +#### [v0.1.1](https://git.odit.services/lfk/document-server/compare/v0.1.0...v0.1.1) + +> 7 February 2021 + +- Merge pull request 'Alpha Release 0.1.1 - Hotfix release' (#12) from dev into main [`cbff307`](https://git.odit.services/lfk/document-server/commit/cbff3074d10110dbb64dda1ed516d2a18402eeca) +- 🧾New changelog file version [CI SKIP] [skip ci] [`4fca5af`](https://git.odit.services/lfk/document-server/commit/4fca5afdfa15d3260ac28c1feb89d50221b1f03f) +- Updated dockerfile & build for dockerized puppeteer [`ea8028d`](https://git.odit.services/lfk/document-server/commit/ea8028dfd54861335e9752334db335ad21e75cf2) +- 📖New license file version [CI SKIP] [skip ci] [`8d4e7a1`](https://git.odit.services/lfk/document-server/commit/8d4e7a16d1ebae6976ec183b761ca3e6a8946629) +- Revert "Now only using our mirror to build" [`fe0f45e`](https://git.odit.services/lfk/document-server/commit/fe0f45ea92099a65d998e342ef885af39d06915f) +- Now only using our mirror to build [`b07c5a9`](https://git.odit.services/lfk/document-server/commit/b07c5a96f2a670f2279a6575b03f9c553b59e0a9) +- 🧾New changelog file version [CI SKIP] [skip ci] [`9755e43`](https://git.odit.services/lfk/document-server/commit/9755e437c2b68c09e9b0ffa47c6bc1729e6bee14) +- 🧾New changelog file version [CI SKIP] [skip ci] [`603a814`](https://git.odit.services/lfk/document-server/commit/603a814ad4783c0b29c1f6a1db638f269b29f775) +- Switched to using our mirrored images for buildi [`dba765c`](https://git.odit.services/lfk/document-server/commit/dba765cb017998ad636f3f91fb00a8a277d3b225) +- 🚀Bumped version to v0.1.1 [`d1b07f3`](https://git.odit.services/lfk/document-server/commit/d1b07f39fd7e3c282a631924bf45367e866e667a) +- Pinned alpine version [`6ab3946`](https://git.odit.services/lfk/document-server/commit/6ab3946c31a7716d1c42fb217b0a0f7be8172dba) + +#### v0.1.0 + +> 7 February 2021 + +- Merge pull request 'Alpha Release 0.1.0 - Contract generation' (#11) from dev into main [`bc2b6fa`](https://git.odit.services/lfk/document-server/commit/bc2b6fadd912f275bc05be29c6fbd87367d617df) +- 📖New license file version [CI SKIP] [skip ci] [`ee19efa`](https://git.odit.services/lfk/document-server/commit/ee19efa0e63f21a10fed1cf24beb16118bbe6cde) +- 🚀Bumped version to v0.0.2 [`de432c4`](https://git.odit.services/lfk/document-server/commit/de432c448129a8acb36fef6b40ef920eeb2f7887) +- First working (TM) template code [`a9e3360`](https://git.odit.services/lfk/document-server/commit/a9e3360ee258e4d48c8dbe3a55468409bb6ee0f7) +- Working Styleing [`c617c40`](https://git.odit.services/lfk/document-server/commit/c617c40e9d7e03382f647eafde9ff458db3c6c15) +- Removed base64 image [`e401d0e`](https://git.odit.services/lfk/document-server/commit/e401d0ec7219e88fbb277b2dcf456a22dae0d1e5) +- Updated the contract template to use external css [`6121b1e`](https://git.odit.services/lfk/document-server/commit/6121b1e3bfcf6fc9f88e0589205044c59859b4a7) +- Sorted locales [`1962499`](https://git.odit.services/lfk/document-server/commit/1962499d18685347302fd7d8491c6e3e7a355fcb) +- Switched to puppeteer for pdf generation [`5afd26e`](https://git.odit.services/lfk/document-server/commit/5afd26ea22cff3b8a339cf658ed37d2053db24ba) +- Added a coupple of real replacement strings to the sponsoring template [`041c0ed`](https://git.odit.services/lfk/document-server/commit/041c0ed6bbe5f8645e4e96b57c02d4e45b445402) +- Added automatic img to base64 conversion [`42443af`](https://git.odit.services/lfk/document-server/commit/42443af734ccc9ce202aec045a07775f4a054b92) +- Added i18n strings [`e345c36`](https://git.odit.services/lfk/document-server/commit/e345c36dd0b03f276259521aebf423853a81a04d) +- first working pdf generation from class 🎉 [`3af76a5`](https://git.odit.services/lfk/document-server/commit/3af76a53e3156bdc2d1d3ade6ff940db9d7b24b5) +- Added a bunch of english and german translations 🌎 [`784d7c6`](https://git.odit.services/lfk/document-server/commit/784d7c656fd2dfc726722459f3ccb7612021b882) +- Added translations using i18next [`75eb925`](https://git.odit.services/lfk/document-server/commit/75eb9252672883f7b6f89a812a37d2b96f9f626e) +- Switched to handlebars for templateing [`4acf3e3`](https://git.odit.services/lfk/document-server/commit/4acf3e39ce55c0ad9e697cf9598569ec1c1dcb44) +- Moved pdf creatior initialization to new function [`47a05fa`](https://git.odit.services/lfk/document-server/commit/47a05facb33c178e9bf3f99c25049abc010361c4) +- 🧾New changelog file version [CI SKIP] [skip ci] [`f3de80a`](https://git.odit.services/lfk/document-server/commit/f3de80af78c96bd697715a30dee7cae6806f9f9f) +- 🚀Bumped version to v0.1.0 [`6a42fe3`](https://git.odit.services/lfk/document-server/commit/6a42fe37d053a6a00005e3c5781edfcefe61183e) +- Merge pull request 'Sponsoring contract generation feature/5-sponsoring_contracts' (#10) from feature/5-sponsoring_contracts into dev [`84259d3`](https://git.odit.services/lfk/document-server/commit/84259d37d42234e1be75f3a5c95f4b442a9e5844) +- Added optimization args [`140fda1`](https://git.odit.services/lfk/document-server/commit/140fda11cc88cb93218116d4cbdbf13c014a659d) +- Added first parts of template [`13776d1`](https://git.odit.services/lfk/document-server/commit/13776d1ecb2db03f19dd0c01a930d4c98222cf6b) +- Added pdf merging for big requests (over 100 runners) [`785544c`](https://git.odit.services/lfk/document-server/commit/785544ca16cd4907a378eb2d48e4269778e3dccc) +- Fixed file broken in merge [`c07c6ae`](https://git.odit.services/lfk/document-server/commit/c07c6aeeab70589a4e1ddf025a07bde96c68ef6e) +- Now with workin i18n-ally config🥳 [`7c3813b`](https://git.odit.services/lfk/document-server/commit/7c3813b94d06ca38b83db90b7f9fba6c33716a05) +- Now with workin i18n-ally config🥳 [`b4232e5`](https://git.odit.services/lfk/document-server/commit/b4232e51e084f491d1a7fb4f929327e88f3b4c00) +- Now accepting arrays for sponsoring contract generation [`f833ae2`](https://git.odit.services/lfk/document-server/commit/f833ae222e68b7df9b8f8a8ec7ce17d679a9710f) +- Added full interpolation support to the i18n [`f755f4f`](https://git.odit.services/lfk/document-server/commit/f755f4f9fb1463af6bec3cf73b7fabf95ef3fb2e) +- Added option to generate empty sponsoring contracts [`1ced0e3`](https://git.odit.services/lfk/document-server/commit/1ced0e317544217599a42c6b270c9136dc73676d) +- Added translation sorting secript [`1e67672`](https://git.odit.services/lfk/document-server/commit/1e67672ef0d28f94a50b0377cca8e8ff2a87e983) +- Removed the example data from the fill-in fields [`5e12525`](https://git.odit.services/lfk/document-server/commit/5e1252545b7eafeee6c3a1d67567d00e5d615d85) +- Edited html template [`d58453f`](https://git.odit.services/lfk/document-server/commit/d58453faf9840037c583e029c41ef1b31a0bafa8) +- PDF Creator now accepts single instances of class [`78205ee`](https://git.odit.services/lfk/document-server/commit/78205ee8c7659ae0dc2e4a184554b042251d9271) +- PDF Creator now accepts single instances of class [`ba7cedd`](https://git.odit.services/lfk/document-server/commit/ba7cedd187dbc51a53ba169889d8e0ca22a97b5d) +- Updated template for i18n [`a596188`](https://git.odit.services/lfk/document-server/commit/a596188c00444c285565eecbb1f0bc668bb4706c) +- Parellized the chunks [`e92820e`](https://git.odit.services/lfk/document-server/commit/e92820e12f289b4fd28b4ebc985b5b711777fc35) +- Fixed the controller not waiting for initialization [`ee8ba99`](https://git.odit.services/lfk/document-server/commit/ee8ba99cc7778f89a8bb99400c7d1cf1a12898f7) +- Implemented language selection by query param [`6f81566`](https://git.odit.services/lfk/document-server/commit/6f81566cb82a0801a20523a7177996ea40cb3968) +- Added comments [`cd51e78`](https://git.odit.services/lfk/document-server/commit/cd51e78282278cae6cb86bd0c9616746612a97e3) +- Added example locales [`1969769`](https://git.odit.services/lfk/document-server/commit/19697692bcb6c0c1c978918916caccd95a8f2035) +- Fixed data validation problem [`bd6ec62`](https://git.odit.services/lfk/document-server/commit/bd6ec6215d362325c510611e4545b7643b918200) +- Removed fullname from groups (to be renabled later) [`388d8a2`](https://git.odit.services/lfk/document-server/commit/388d8a2dc6ee06d39e621e1e45ae595dae587483) +- Updated comments [`119102a`](https://git.odit.services/lfk/document-server/commit/119102aef8f43a68f537e7542c2f2cd3b41cd28e) +- Updated readme for handlebars [`05e4718`](https://git.odit.services/lfk/document-server/commit/05e471878f2321a1873b21730ae85ad6b8af5766) +- Updated readme [`f69e777`](https://git.odit.services/lfk/document-server/commit/f69e7779e42f18df7ec3ccb1cdf9dcf7fa845ee6) +- 🧾New changelog file version [CI SKIP] [skip ci] [`f4a34dd`](https://git.odit.services/lfk/document-server/commit/f4a34dd36b57bd122a650f2de4ea8e00816276ed) +- Typos [`95b882a`](https://git.odit.services/lfk/document-server/commit/95b882aceded275ad89446ad92a10cf36b166ab7) +- Added sentence about large requests to the /contracts openapi description [`4773a5f`](https://git.odit.services/lfk/document-server/commit/4773a5f18c866b6e9d50b421d7917416860cb6b5) +- Removed puppeteer args [`06dedc0`](https://git.odit.services/lfk/document-server/commit/06dedc0797b649f3fa8934f0d774ccae2b062849) +- Expanded max request body size to 500mb [`4f191dc`](https://git.odit.services/lfk/document-server/commit/4f191dcb52cd727e34770ab4304937cd1e7e480d) +- Now awaiting language change [`c07319b`](https://git.odit.services/lfk/document-server/commit/c07319b250db9452f6122e797b6059151031e2a9) +- 🧾New changelog file version [CI SKIP] [skip ci] [`42d6c40`](https://git.odit.services/lfk/document-server/commit/42d6c40d0c673f39c27e3d5a6484f01a4da77266) +- Formatting [`2d0b7ce`](https://git.odit.services/lfk/document-server/commit/2d0b7ce79ed47d4827096a2bbccfe3bbcd061810) +- Removed useless await [`4cd437b`](https://git.odit.services/lfk/document-server/commit/4cd437b6afe40e4c09027c0e2004a1130bc51870) +- Updated comments [`cf9cd29`](https://git.odit.services/lfk/document-server/commit/cf9cd298b638012e079be0a04d1b48efea20026f) +- Merge pull request 'Patch 0.0.2' (#9) from dev into main [`4585a83`](https://git.odit.services/lfk/document-server/commit/4585a83838b80552160c9d9e5be0af891eae39c8) +- Merge pull request 'Basic documentation feature/6-documentation' (#8) from feature/6-documentation into dev [`73915da`](https://git.odit.services/lfk/document-server/commit/73915da20321940e22145b4c5d830b9f700be566) +- 📖New license file version [CI SKIP] [skip ci] [`465efe0`](https://git.odit.services/lfk/document-server/commit/465efe03000ecc00d14479ac38710ffdba2cafb5) +- Typos [`68e34a9`](https://git.odit.services/lfk/document-server/commit/68e34a9054a195545b0bd10ce888f7274854fae6) +- Merge pull request 'Implemented the basics for templateing feature/3-pdf_templateing' (#4) from feature/3-pdf_templateing into dev [`15f1641`](https://git.odit.services/lfk/document-server/commit/15f16415c0ac5012df8126c8df6bd4da93ad0a20) +- Merge pull request 'Implemented the basic request classes feature/1-input_classes' (#2) from feature/1-input_classes into dev [`b5e79e5`](https://git.odit.services/lfk/document-server/commit/b5e79e51ef5d751a67e7a1763809ece91a7627f2) +- Added openapi viewers [`6435c8a`](https://git.odit.services/lfk/document-server/commit/6435c8a88e2ea3f4417ad5d8be9a07b9c043b41b) +- 📖New license file version [CI SKIP] [skip ci] [`d493e74`](https://git.odit.services/lfk/document-server/commit/d493e74bf39bc85de842ac7cd3e3d37ba8797a04) +- Initial commit [`0908bcd`](https://git.odit.services/lfk/document-server/commit/0908bcd63529b44463bc57ad7d6b8785564e4ddc) +- Added address class and errors [`d291cf0`](https://git.odit.services/lfk/document-server/commit/d291cf0d1bf375e96fda822543d5ceb29dc67010) +- Added drone file [`48d7cad`](https://git.odit.services/lfk/document-server/commit/48d7cad9f37485656cfb1c70abef158b5dd8d847) +- Added the donation classes [`1d73e4e`](https://git.odit.services/lfk/document-server/commit/1d73e4ed9ccb3dfb7709cb89957ed5bbcefad870) +- Added openapi related classes [`9d62225`](https://git.odit.services/lfk/document-server/commit/9d6222547811fd3c94b91496d9917b7df5115fc6) +- Added a bs example template [`f726a6e`](https://git.odit.services/lfk/document-server/commit/f726a6e699575b839d332c15e61c9008fe996fa9) +- Added a basic donor class [`cfa65e8`](https://git.odit.services/lfk/document-server/commit/cfa65e83cafcefbd6261a99ab7a4eaf099665a81) +- Added input class for contract generation [`63f9523`](https://git.odit.services/lfk/document-server/commit/63f952376698c3561754bfb206a64c58c1ae86f1) +- Initialized package [`b0427a6`](https://git.odit.services/lfk/document-server/commit/b0427a6d810656096c467881a302eef244f86d29) +- Added a simplified runnergroup class [`e29c17a`](https://git.odit.services/lfk/document-server/commit/e29c17a29a6ee84944f8d67d7b6f3c4292763c10) +- Resolved fun issues with promises [`4617f2c`](https://git.odit.services/lfk/document-server/commit/4617f2c5bdcb29534b46865ebe21d15e2b1cd72f) +- Added a runnercard class [`cb7325b`](https://git.odit.services/lfk/document-server/commit/cb7325bbf906b405955bd81e199abae5edc27d91) +- Added a basic readme [`df94b1b`](https://git.odit.services/lfk/document-server/commit/df94b1b750922989d870546150ff8d9ff8af4102) +- Added base app [`915ff92`](https://git.odit.services/lfk/document-server/commit/915ff92418a2859c11e0ce58b79220fb5ea06c7f) +- Added vscode workspace config [`ae466b4`](https://git.odit.services/lfk/document-server/commit/ae466b4d7e5b67c5cd1bc440214f477d15f768a2) +- Created a pdf class that takes care of the pdf wrapping [`7d5b575`](https://git.odit.services/lfk/document-server/commit/7d5b5750ad78fd979cb1b647d8b318a84513532a) +- Added editor and stageing infos to the README [`56b7227`](https://git.odit.services/lfk/document-server/commit/56b72275aca57b227c775c4a61e91fd03471f987) +- Added dockerfile and docker-compose [`b9d4cc3`](https://git.odit.services/lfk/document-server/commit/b9d4cc36199b8f0090d555e961a3454bf35f4bd6) +- Added loaders [`57afbd4`](https://git.odit.services/lfk/document-server/commit/57afbd4b6c48cf641b69a2fcbb28783ff84e1cfd) +- Added a certificaterunner class [`d08bdfd`](https://git.odit.services/lfk/document-server/commit/d08bdfd961f4128981b969cf149df7397a257193) +- Added a template section to the readme [`8141269`](https://git.odit.services/lfk/document-server/commit/8141269dd99f03b33019e5a8f4a010954c4fc44a) +- Created a barebones pdf controller [`64bd1ff`](https://git.odit.services/lfk/document-server/commit/64bd1ffc3ad8459c13154e2cd9a568f27baa2bf2) +- Moved distance to the main runner object [`1d1fa50`](https://git.odit.services/lfk/document-server/commit/1d1fa50327927328ce77af33c1abbf994df9ac8b) +- Added tsconfig [`e1f0378`](https://git.odit.services/lfk/document-server/commit/e1f03788dbdddcb1cb138556c1fed4da9ca104a8) +- Added basic dependencies [`43bb728`](https://git.odit.services/lfk/document-server/commit/43bb728d0d8b75239f1db765071d28a839300102) +- Added typeing to the buffer and stream conversion [`3fb8be2`](https://git.odit.services/lfk/document-server/commit/3fb8be22b74204accabed8a8c8fb5161c5ad7504) +- Added basic dependencies [`d450cea`](https://git.odit.services/lfk/document-server/commit/d450ceac74959bdfb694f9b12fb1fd14ff85b598) +- Added release-it config [`185e66f`](https://git.odit.services/lfk/document-server/commit/185e66fb5b2e4330233ff2e74101c4447c317b5a) +- Added config class [`278c563`](https://git.odit.services/lfk/document-server/commit/278c56386b0e9079a71d3339b40d08f046255a3e) +- Added Barebones pdf creator class [`557cc26`](https://git.odit.services/lfk/document-server/commit/557cc26f281da0b47621dff667435a788c42c103) +- Added a simple status controller [`1d62e7f`](https://git.odit.services/lfk/document-server/commit/1d62e7f14c8d6219607ed6ecf774ae152e362cc1) +- Added errorhandler middleware [`6539fd7`](https://git.odit.services/lfk/document-server/commit/6539fd785568971330639fb7055827417424c81a) +- Runners now use the runnergroup class instead of strings [`aae4f50`](https://git.odit.services/lfk/document-server/commit/aae4f507eafbfd51cd9972cf0fac4c5afafbb45a) +- Added files to gitignore [`66134c0`](https://git.odit.services/lfk/document-server/commit/66134c0e1e5dce2ebd9eae3f88a6ad893bad0283) +- Switched to the splitted functions [`3ca38ab`](https://git.odit.services/lfk/document-server/commit/3ca38abe9359e436fe0f80400ad0308ad9d64a4f) +- Cleaned up openapi stuff [`4efb629`](https://git.odit.services/lfk/document-server/commit/4efb62921bced79c817499b48bbc55b05e6371e5) +- Updated apidoc viewer settings [`36396af`](https://git.odit.services/lfk/document-server/commit/36396af50a1f7d1842effbd24e08a8d34946a375) +- Updated apidoc viewer settings [`4d45e0f`](https://git.odit.services/lfk/document-server/commit/4d45e0f80d5721c91de0b25334d040448d92e01d) +- 🧾New changelog file version [CI SKIP] [skip ci] [`8f250f7`](https://git.odit.services/lfk/document-server/commit/8f250f747a95feb246b1698a7c9be9ee19a1be12) +- Added missing dependencies [`c2d7141`](https://git.odit.services/lfk/document-server/commit/c2d714116e02bb4c2ff6501ba32417cd998e2f3e) +- Added license export and release scripts [`0c4e5a1`](https://git.odit.services/lfk/document-server/commit/0c4e5a182c91b99a657c83f2c24f4cfaae1ef48d) +- Added build script [`cbc421c`](https://git.odit.services/lfk/document-server/commit/cbc421cd838b6c874fbe50556350edeb08a7b882) +- Added dev script [`814b564`](https://git.odit.services/lfk/document-server/commit/814b564752aa95ed2c034a9a98c800b43452bf88) +- Adjusted template font styleing [`2c7b025`](https://git.odit.services/lfk/document-server/commit/2c7b0254ec7e49c31f8f33eed334ab4156052fb6) +- Added html-pdf package [`a7d4001`](https://git.odit.services/lfk/document-server/commit/a7d4001ad992d60e2af69e9bbed53366bc0a46d3) +- Added PDFs to gitignore [`9f3758d`](https://git.odit.services/lfk/document-server/commit/9f3758de39ef1d5b591a24868eb683caa742f694) +- Added version to config [`b1747f6`](https://git.odit.services/lfk/document-server/commit/b1747f6374c029e1e9c3a87584ea54b9d3714d92) +- fixed license-exporter call [`83c4bd6`](https://git.odit.services/lfk/document-server/commit/83c4bd62cbbb13ae33a790baa45cc15a77d99e41) +- Added version to config [`cff7011`](https://git.odit.services/lfk/document-server/commit/cff70110fde72c7fede0625872acdc0666703fa1) +- Added openapi dependency [`94e5e51`](https://git.odit.services/lfk/document-server/commit/94e5e51f8d421ea7fd64ded2281b89ff4a252b29) +- Added templates folder [`8a30265`](https://git.odit.services/lfk/document-server/commit/8a30265fc600dad17f584f95dd51db976945d4c5) From e1ec193a4ff1cd618da90f5f2d029ec848a6f669 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 17:48:09 +0100 Subject: [PATCH 13/21] Removed promise ref #13 --- src/PdfCreator.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index 2014fb7..4978602 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -2,18 +2,16 @@ import axios from 'axios'; import bwipjs from "bwip-js"; import cheerio from "cheerio"; import fs from "fs"; -import handlebars from 'handlebars'; +import Handlebars from 'handlebars'; import i18next from "i18next"; import Backend from 'i18next-fs-backend'; import mime from "mime-types"; import path from 'path'; import { PDFDocument } from 'pdf-lib'; -import promisedHandlebars from "promised-handlebars"; import puppeteer from "puppeteer"; import { Runner } from './models/Runner'; import { RunnerGroup } from './models/RunnerGroup'; -const Handlebars = promisedHandlebars(handlebars); /** * This class is responsible for all things pdf creation. * This uses the html templates from src/templates. @@ -88,6 +86,7 @@ export class PdfCreator { await Handlebars.registerHelper('--bc', function (str) { //TODO: Fix the async behaviour + return "data:image" return PdfCreator.generateBarcode("code39", str.toString()); } ); From 4187a8e82015495c0e0362e957e236ed6935a908 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Mon, 8 Feb 2021 17:52:04 +0100 Subject: [PATCH 14/21] Fixed broken mime-type ref #13 --- src/PdfCreator.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index 4978602..d93a928 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -206,7 +206,7 @@ export class PdfCreator { includetext: true, textxalign: 'center', }); - return `data:$image/png;base64,${barcode.toString('base64')}`; + return `data:image/png;base64,${barcode.toString('base64')}`; } /** From edc846ab05319a4e60422625678f204bc145884c Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 9 Feb 2021 16:38:18 +0100 Subject: [PATCH 15/21] Implemented async barcode generation using async helpers ref #13 --- package.json | 1 + src/PdfCreator.ts | 33 ++++---------------------- src/asyncHelpers.ts | 32 +++++++++++++++++++++++++ src/templates/sponsoring_contract.html | 2 +- 4 files changed, 39 insertions(+), 29 deletions(-) create mode 100644 src/asyncHelpers.ts diff --git a/package.json b/package.json index effbbb9..61facc7 100644 --- a/package.json +++ b/package.json @@ -40,6 +40,7 @@ "license": "CC-BY-NC-SA-4.0", "dependencies": { "@odit/class-validator-jsonschema": "^2.1.1", + "async-helpers": "^0.3.17", "axios": "^0.21.1", "bwip-js": "^2.0.12", "cheerio": "^1.0.0-rc.5", diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index d93a928..67ae4f8 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -1,5 +1,4 @@ import axios from 'axios'; -import bwipjs from "bwip-js"; import cheerio from "cheerio"; import fs from "fs"; import Handlebars from 'handlebars'; @@ -9,6 +8,7 @@ import mime from "mime-types"; import path from 'path'; import { PDFDocument } from 'pdf-lib'; import puppeteer from "puppeteer"; +import { awaitAsyncHandlebarHelpers, helpers } from './asyncHelpers'; import { Runner } from './models/Runner'; import { RunnerGroup } from './models/RunnerGroup'; @@ -78,18 +78,13 @@ export class PdfCreator { loadPath: path.join(__dirname, '/locales/{{lng}}.json') } }); + + await Handlebars.registerHelper(helpers); await Handlebars.registerHelper('__', function (str) { return i18next.t(str, PdfCreator.interpolations).toString(); } ); - await Handlebars.registerHelper('--bc', - function (str) { - //TODO: Fix the async behaviour - return "data:image" - return PdfCreator.generateBarcode("code39", str.toString()); - } - ); this.browser = await puppeteer.launch({ headless: true, args: minimal_args }); } @@ -115,7 +110,8 @@ export class PdfCreator { await i18next.changeLanguage(locale); const template_source = fs.readFileSync(`${this.templateDir}/sponsoring_contract.html`, 'utf8'); const template = Handlebars.compile(template_source); - const result = template({ runners }) + let result = template({ runners }); + result = await awaitAsyncHandlebarHelpers(result); const pdf = await this.renderPdf(result, { format: "A5", landscape: true }); return pdf } @@ -190,25 +186,6 @@ export class PdfCreator { return (await mergedPdf.save()); } - /** - * A simple barcode generation function using default params suitable for usage in pdfs. - * Generates the barcodes as base64-encoded png. - * @param type Barcode type according to this list: https://github.com/metafloor/bwip-js/wiki/BWIPP-Barcode-Types - * @param content Barcode content/text - please remember that some formats only support certain input types. - * @returns Barcode image as base64 encoded png string. - */ - public static async generateBarcode(type: string, content: string): Promise { - let barcode: Buffer = await bwipjs.toBuffer({ - bcid: type, - text: content, - scale: 3, - height: 10, - includetext: true, - textxalign: 'center', - }); - return `data:image/png;base64,${barcode.toString('base64')}`; - } - /** * Generates a new dummy runner with halfspaces for all strings. * Can be used to generate empty sponsoring contracts. diff --git a/src/asyncHelpers.ts b/src/asyncHelpers.ts new file mode 100644 index 0000000..fa00f97 --- /dev/null +++ b/src/asyncHelpers.ts @@ -0,0 +1,32 @@ +import AsyncHelpers from "async-helpers"; +import bwipjs from "bwip-js"; + +export const asyncHelpers = new AsyncHelpers(); +async function generateBarcode(str, options, emtpy, cb) { + let res = await generateBase64Barcode(options.toString(), str.toString()); + cb(null, res); +} +generateBarcode.async = true; +asyncHelpers.set('--bc', generateBarcode); +export const helpers = asyncHelpers.get({ wrap: true }); + +export async function generateBase64Barcode(type: string, content: string): Promise { + let barcode: Buffer = await bwipjs.toBuffer({ + bcid: type, + text: content, + scale: 3, + height: 10, + includetext: true, + textxalign: 'center', + }); + return `data:image/png;base64,${barcode.toString('base64')}`; +} + +export async function awaitAsyncHandlebarHelpers(input: string): Promise { + return await new Promise((resolve, reject) => { + asyncHelpers.resolveIds(input, (err, data) => { + if (err) { reject(err) } + resolve(data) + }); + }); +} \ No newline at end of file diff --git a/src/templates/sponsoring_contract.html b/src/templates/sponsoring_contract.html index b6e8e64..29e6b22 100644 --- a/src/templates/sponsoring_contract.html +++ b/src/templates/sponsoring_contract.html @@ -54,7 +54,7 @@
- +
From 4b79b29ee6319559c9d68ddb11f831d25f12b3da Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 9 Feb 2021 17:02:02 +0100 Subject: [PATCH 16/21] Now with working code scaleing ref #13 --- src/asyncHelpers.ts | 11 ++++++++--- src/templates/sponsoring_contract.html | 21 +++++++++++---------- 2 files changed, 19 insertions(+), 13 deletions(-) diff --git a/src/asyncHelpers.ts b/src/asyncHelpers.ts index fa00f97..9dc1f34 100644 --- a/src/asyncHelpers.ts +++ b/src/asyncHelpers.ts @@ -11,14 +11,19 @@ asyncHelpers.set('--bc', generateBarcode); export const helpers = asyncHelpers.get({ wrap: true }); export async function generateBase64Barcode(type: string, content: string): Promise { - let barcode: Buffer = await bwipjs.toBuffer({ + let options = { bcid: type, text: content, - scale: 3, + scale: 4, height: 10, + width: 10, includetext: true, textxalign: 'center', - }); + } + if (type != "qrcode") { + delete options.width; + } + const barcode: Buffer = await bwipjs.toBuffer(options); return `data:image/png;base64,${barcode.toString('base64')}`; } diff --git a/src/templates/sponsoring_contract.html b/src/templates/sponsoring_contract.html index 29e6b22..c22eb5e 100644 --- a/src/templates/sponsoring_contract.html +++ b/src/templates/sponsoring_contract.html @@ -29,17 +29,17 @@
-
-
-

{{__ "sponsoring_title"}}

-
-
-

{{__ "please_use_blockletters"}} -

-
-
+
+
+

{{__ "sponsoring_title"}}

+
+
+

{{__ "please_use_blockletters"}} +

+
+

{{__ "sponsoring_subtitle"}}

@@ -54,7 +54,8 @@
- +
From 9a7c1d64fdbdadbd104739133a87773e4d2bca01 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 9 Feb 2021 17:28:04 +0100 Subject: [PATCH 17/21] Now loading barcode format from env with overwrite via query param ref #13 --- src/PdfCreator.ts | 5 +++-- src/config.ts | 3 ++- src/controllers/PdfController.ts | 4 ++-- src/templates/sponsoring_contract.html | 2 +- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/PdfCreator.ts b/src/PdfCreator.ts index 67ae4f8..81f1463 100644 --- a/src/PdfCreator.ts +++ b/src/PdfCreator.ts @@ -9,6 +9,7 @@ import path from 'path'; import { PDFDocument } from 'pdf-lib'; import puppeteer from "puppeteer"; import { awaitAsyncHandlebarHelpers, helpers } from './asyncHelpers'; +import { config } from './config'; import { Runner } from './models/Runner'; import { RunnerGroup } from './models/RunnerGroup'; @@ -93,7 +94,7 @@ export class PdfCreator { * @param runner The runner you want to generate the contracts for. * @param locale The locale used for the contracts (default:en) */ - public async generateSponsoringContract(runners: Runner[], locale: string = "en"): Promise { + public async generateSponsoringContract(runners: Runner[], locale: string = "en", codeformat: string = config.codeformat): Promise { if (runners.length == 1 && Object.keys(runners[0]).length == 0) { runners[0] = this.generateEmptyRunner(); } @@ -110,7 +111,7 @@ export class PdfCreator { await i18next.changeLanguage(locale); const template_source = fs.readFileSync(`${this.templateDir}/sponsoring_contract.html`, 'utf8'); const template = Handlebars.compile(template_source); - let result = template({ runners }); + let result = template({ runners, codeformat }); result = await awaitAsyncHandlebarHelpers(result); const pdf = await this.renderPdf(result, { format: "A5", landscape: true }); return pdf diff --git a/src/config.ts b/src/config.ts index 3b95934..00e6d6d 100644 --- a/src/config.ts +++ b/src/config.ts @@ -4,7 +4,8 @@ configDotenv(); export const config = { internal_port: parseInt(process.env.APP_PORT) || 4010, development: process.env.NODE_ENV === "production", - version: process.env.VERSION || require('../package.json').version + version: process.env.VERSION || require('../package.json').version, + codeformat: process.env.CODEFORMAT || "qrcode" } let errors = 0 if (typeof config.internal_port !== "number") { diff --git a/src/controllers/PdfController.ts b/src/controllers/PdfController.ts index affc7a4..2518692 100644 --- a/src/controllers/PdfController.ts +++ b/src/controllers/PdfController.ts @@ -15,7 +15,7 @@ export class PdfController { @Post('/contracts') @OpenAPI({ description: "Generate Sponsoring contract pdfs from runner objects.
You can choose your prefered locale by passing the 'locale' query-param.
If you provide more than 100 runenrs this could take a moment or two (we tested up to 1000 runners in about 70sec so far)." }) - async generateContracts(@Body({ validate: true, options: { limit: "500mb" } }) runners: Runner | Runner[], @Res() res: any, @QueryParam("locale") locale: string) { + async generateContracts(@Body({ validate: true, options: { limit: "500mb" } }) runners: Runner | Runner[], @Res() res: any, @QueryParam("locale") locale: string, @QueryParam("codeformat") codeformat: string) { if (!this.initialized) { await this.pdf.init(); this.initialized = true; @@ -23,7 +23,7 @@ export class PdfController { if (!Array.isArray(runners)) { runners = [runners]; } - const contracts = await this.pdf.generateSponsoringContract(runners, locale); + const contracts = await this.pdf.generateSponsoringContract(runners, locale, codeformat); res.setHeader('content-type', 'application/pdf'); return contracts; } diff --git a/src/templates/sponsoring_contract.html b/src/templates/sponsoring_contract.html index c22eb5e..b75d7f2 100644 --- a/src/templates/sponsoring_contract.html +++ b/src/templates/sponsoring_contract.html @@ -55,7 +55,7 @@
+ src="{{--bc this.id ../codeformat}}" />
From 502345782f26895ccf3089d15c3817709b62dfcc Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 9 Feb 2021 17:28:21 +0100 Subject: [PATCH 18/21] Added fallback error image ref #13 --- src/asyncHelpers.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/asyncHelpers.ts b/src/asyncHelpers.ts index 9dc1f34..881bbe6 100644 --- a/src/asyncHelpers.ts +++ b/src/asyncHelpers.ts @@ -23,8 +23,13 @@ export async function generateBase64Barcode(type: string, content: string): Prom if (type != "qrcode") { delete options.width; } - const barcode: Buffer = await bwipjs.toBuffer(options); - return `data:image/png;base64,${barcode.toString('base64')}`; + try { + const barcode: Buffer = await bwipjs.toBuffer(options); + return `data:image/png;base64,${barcode.toString('base64')}`; + } + catch { + return errorimage; + } } export async function awaitAsyncHandlebarHelpers(input: string): Promise { @@ -34,4 +39,6 @@ export async function awaitAsyncHandlebarHelpers(input: string): Promise resolve(data) }); }); -} \ No newline at end of file +} + +const errorimage = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAXkAAAFRCAMAAACmIi1UAAABS2lUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4KPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS42LWMxNDIgNzkuMT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bYqNA0iQl6sgJfImCfJ9bS5Hel47B1ls3yRcUeIuKfUqC+U7+sj9LohNShAgL1tBSuQLpMjHt9Zc6b6LuNjoTFAc+iL0SMo0cKPXIjWSil3mkPudQ3QkJVtBSuRzJMlbBk83VuTlowBdbHSuKzZFZkLPDuQMfMkqcftomMLsQV6MjX7y8hWkRL6/BgjysQGFBexwVlxR4mKLEm855SJrmzsIDv33vhZRID8xVEyKvHwF6ZAfqIFsm0dPIQ9cgkCxeQm3nJCzwNmxDl0O8kdhwpklLiBFXr6CFGeJCyTP8/kDjVh0m8Ya1xUGxfad6nPiGYrvjOTHFWkGN8Qx7oxkxZ2IdZNXqCCdOyMDNYDkCwbvYqM6hrmxPicsNvE2LOJuYG58vYrgswiKdwNz44+tbvIKFaRCfrAGsD9vHvg9I6+RceeQPPRN8Vhd+u72xkooyE+8EhSL74BnR7c9OFUK7x/nJjycoZe8UgVp3AGP1UBEPruPRqFkvy/6YymUvck4WJm+3o4tv68jaSkU9RwG+3SWor6pznzRBxI3YO0vIDaHrZe8UgVJk0+sgRn5nJgVMZSOb9aSQ8zE/k1BlsJzSIWyD5HlKTzDJvGUkQ2XvFIFxeRRT0rJ74NcDcySf8pG3cGO750gO6tRlqKRbfzeZiuMIQut8pOh8U+J6CSvWEE65AdqgCCfZxIPWUBLMUtPSmQlNuwcM3ImM/b5YjVPtCbOYOskr1hBGuRjNTCL/2CBd6IlbrWiJ+JyxI/wZfc/0yb5FHeOxYz1FHeh+BlxfeSVK0icfHwN/h87gK/3ae4GIwAAAABJRU5ErkJggg==" \ No newline at end of file From 03f63e3777381a4475910e6fa4a3986f87b73f39 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 9 Feb 2021 16:43:32 +0000 Subject: [PATCH 19/21] =?UTF-8?q?=F0=9F=A7=BENew=20changelog=20file=20vers?= =?UTF-8?q?ion=20[CI=20SKIP]=20[skip=20ci]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b815a53..1d7ef81 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,9 @@ All notable changes to this project will be documented in this file. Dates are d #### [v0.1.3](https://git.odit.services/lfk/document-server/compare/v0.1.2...v0.1.3) +- Merge pull request 'Alpha Release 0.1.3 - More env vars' (#20) from dev into main [`ecd02a1`](https://git.odit.services/lfk/document-server/commit/ecd02a1af7431d0bf615c4ec064f64e023946e49) - 🚀Bumped version to v0.1.3 [`6a14232`](https://git.odit.services/lfk/document-server/commit/6a142328898d5b89fa11eaf033372971d1093b0c) +- 🧾New changelog file version [CI SKIP] [skip ci] [`ad9a8a4`](https://git.odit.services/lfk/document-server/commit/ad9a8a4fe0649d48db924771be8ecb4cbf5c162a) - 🧾New changelog file version [CI SKIP] [skip ci] [`b6296b8`](https://git.odit.services/lfk/document-server/commit/b6296b8d97cda943dfb5e11bc9dfbb2f363f5b81) - Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) - Added new env vars to config [`3bb322e`](https://git.odit.services/lfk/document-server/commit/3bb322ede5db15a147c0d7a8db2a68ccb7fa2112) From 7122fe7dbe3fae64806492636255147078eb03c8 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 9 Feb 2021 16:44:09 +0000 Subject: [PATCH 20/21] =?UTF-8?q?=F0=9F=A7=BENew=20changelog=20file=20vers?= =?UTF-8?q?ion=20[CI=20SKIP]=20[skip=20ci]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1d7ef81..682f51e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,14 +4,28 @@ All notable changes to this project will be documented in this file. Dates are d #### [v0.1.3](https://git.odit.services/lfk/document-server/compare/v0.1.2...v0.1.3) -- Merge pull request 'Alpha Release 0.1.3 - More env vars' (#20) from dev into main [`ecd02a1`](https://git.odit.services/lfk/document-server/commit/ecd02a1af7431d0bf615c4ec064f64e023946e49) +- Merge pull request 'Barcode generation feature/13-barcode_generation' (#21) from feature/13-barcode_generation into dev [`ff36b48`](https://git.odit.services/lfk/document-server/commit/ff36b4871f2d696c0b86883d529365ee8f1c6132) - 🚀Bumped version to v0.1.3 [`6a14232`](https://git.odit.services/lfk/document-server/commit/6a142328898d5b89fa11eaf033372971d1093b0c) - 🧾New changelog file version [CI SKIP] [skip ci] [`ad9a8a4`](https://git.odit.services/lfk/document-server/commit/ad9a8a4fe0649d48db924771be8ecb4cbf5c162a) +- Implemented async barcode generation using async helpers [`edc846a`](https://git.odit.services/lfk/document-server/commit/edc846ab05319a4e60422625678f204bc145884c) +- Reworked template layout for barcode [`1c06689`](https://git.odit.services/lfk/document-server/commit/1c066898009883f510fa204c66800e5f6228a15d) +- Added basic barcode generation [`8072d0b`](https://git.odit.services/lfk/document-server/commit/8072d0b1940ef6f316ce78dcbcb9e5af5bab04e7) +- 🧾New changelog file version [CI SKIP] [skip ci] [`03f63e3`](https://git.odit.services/lfk/document-server/commit/03f63e3777381a4475910e6fa4a3986f87b73f39) +- Merge pull request 'Alpha Release 0.1.3 - More env vars' (#20) from dev into main [`ecd02a1`](https://git.odit.services/lfk/document-server/commit/ecd02a1af7431d0bf615c4ec064f64e023946e49) +- Now with working code scaleing [`4b79b29`](https://git.odit.services/lfk/document-server/commit/4b79b29ee6319559c9d68ddb11f831d25f12b3da) +- Now loading barcode format from env with overwrite via query param [`9a7c1d6`](https://git.odit.services/lfk/document-server/commit/9a7c1d64fdbdadbd104739133a87773e4d2bca01) +- Added fallback error image [`5023457`](https://git.odit.services/lfk/document-server/commit/502345782f26895ccf3089d15c3817709b62dfcc) +- First part of the handlebars barcode generation [`a35f8cf`](https://git.odit.services/lfk/document-server/commit/a35f8cfd3aa94923968fd77425c074844d28ec0d) - 🧾New changelog file version [CI SKIP] [skip ci] [`b6296b8`](https://git.odit.services/lfk/document-server/commit/b6296b8d97cda943dfb5e11bc9dfbb2f363f5b81) -- Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) +- Added todo [`75d2ac3`](https://git.odit.services/lfk/document-server/commit/75d2ac3c5f80f8440b6d48c33b15ef17565559b3) +- Removed promise [`e1ec193`](https://git.odit.services/lfk/document-server/commit/e1ec193a4ff1cd618da90f5f2d029ec848a6f669) - Added new env vars to config [`3bb322e`](https://git.odit.services/lfk/document-server/commit/3bb322ede5db15a147c0d7a8db2a68ccb7fa2112) -- Added new env vars to readme [`b77bb3a`](https://git.odit.services/lfk/document-server/commit/b77bb3ad9dba9d73c2c81215ba57936192155a9a) - Now loading interpolation vars from config/env [`b4ebae2`](https://git.odit.services/lfk/document-server/commit/b4ebae283b472b2f0c6e28caed49b30edb119585) +- Fixed broken mime-type [`4187a8e`](https://git.odit.services/lfk/document-server/commit/4187a8e82015495c0e0362e957e236ed6935a908) +- Merge pull request 'Load more stuff from env feature/16-env_vars' (#17) from feature/16-env_vars into dev [`bc4d16e`](https://git.odit.services/lfk/document-server/commit/bc4d16e6f8959ed35d7e87647de84584cdfddd7b) +- Added new env vars to readme [`b77bb3a`](https://git.odit.services/lfk/document-server/commit/b77bb3ad9dba9d73c2c81215ba57936192155a9a) +- Switched to using the current runner's id as the barcode text [`3e2b011`](https://git.odit.services/lfk/document-server/commit/3e2b011d2887d261fb9c36820982095d6dd6d847) +- Added barcode field to template [`27d1d69`](https://git.odit.services/lfk/document-server/commit/27d1d69360c8513079abcfe3a6fc2a50309a2b61) - 🧾New changelog file version [CI SKIP] [skip ci] [`a306009`](https://git.odit.services/lfk/document-server/commit/a30600943d01116b99e946cb705a16d0372b5095) #### [v0.1.2](https://git.odit.services/lfk/document-server/compare/v0.1.1...v0.1.2) From fea0b1dc0582d2906bad22f2ff5e5aad90a1c885 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 9 Feb 2021 16:45:18 +0000 Subject: [PATCH 21/21] =?UTF-8?q?=F0=9F=93=96New=20license=20file=20versio?= =?UTF-8?q?n=20[CI=20SKIP]=20[skip=20ci]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- licenses.md | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/licenses.md b/licenses.md index 5fd0cbf..ed35937 100644 --- a/licenses.md +++ b/licenses.md @@ -27,6 +27,35 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +# async-helpers +**Author**: Brian Woodward (https://github.com/doowb) +**Repo**: doowb/async-helpers +**License**: MIT +**Description**: Use async helpers in templates with engines that typically only handle sync helpers. Handlebars and Lodash have been tested. +## License Text +The MIT License (MIT) + +Copyright (c) 2015-2017, Brian Woodward. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + + # axios **Author**: Matt Zabriskie **Repo**: [object Object] @@ -54,6 +83,38 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +# bwip-js +**Author**: Mark Warren +**Repo**: [object Object] +**License**: MIT +**Description**: JavaScript barcode generator supporting over 100 types and standards. +## License Text +bwip-js : Barcode Writer in Pure JavaScript + +Copyright (c) 2011-2019 Mark Warren + +The MIT License + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + + + # cheerio **Author**: Matt Mueller (mat.io) **Repo**: [object Object]