PDF Time Eval Corrections
This commit is contained in:
@@ -922,7 +922,19 @@ export const createTimeSheetPDF = async (server: FastifyInstance, returnMode, da
|
|||||||
opacity: 1
|
opacity: 1
|
||||||
})*/
|
})*/
|
||||||
console.log(input)
|
console.log(input)
|
||||||
|
pages[pageCounter - 1].drawText(`Anwesenheitsauswertung`,{
|
||||||
|
x: getCoordinatesForPDFLib(20,40,pages[pageCounter -1]).x,
|
||||||
|
y: getCoordinatesForPDFLib(20,40,pages[pageCounter -1]).y,
|
||||||
|
size: 15,
|
||||||
|
font: fontBold
|
||||||
|
})
|
||||||
|
|
||||||
pages[pageCounter - 1].drawText(`Mitarbeiter: ${input.full_name}`,{
|
pages[pageCounter - 1].drawText(`Mitarbeiter: ${input.full_name}`,{
|
||||||
|
x: getCoordinatesForPDFLib(20,50,pages[pageCounter -1]).x,
|
||||||
|
y: getCoordinatesForPDFLib(20,50,pages[pageCounter -1]).y,
|
||||||
|
size: 10,
|
||||||
|
})
|
||||||
|
pages[pageCounter - 1].drawText(`Nummer: ${input.employee_number}`,{
|
||||||
x: getCoordinatesForPDFLib(20,55,pages[pageCounter -1]).x,
|
x: getCoordinatesForPDFLib(20,55,pages[pageCounter -1]).x,
|
||||||
y: getCoordinatesForPDFLib(20,55,pages[pageCounter -1]).y,
|
y: getCoordinatesForPDFLib(20,55,pages[pageCounter -1]).y,
|
||||||
size: 10,
|
size: 10,
|
||||||
@@ -1005,7 +1017,9 @@ export const createTimeSheetPDF = async (server: FastifyInstance, returnMode, da
|
|||||||
lastIndex = lastIndex + (i + 1) * 40 + 1
|
lastIndex = lastIndex + (i + 1) * 40 + 1
|
||||||
}
|
}
|
||||||
|
|
||||||
splitted.push(reversedInput.slice(lastIndex, reversedInput.length))
|
if(reversedInput.slice(lastIndex, reversedInput.length).length > 0) splitted.push(reversedInput.slice(lastIndex, reversedInput.length))
|
||||||
|
|
||||||
|
console.log(splitted )
|
||||||
|
|
||||||
|
|
||||||
splitted.forEach((chunk,index) => {
|
splitted.forEach((chunk,index) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user