Skip to content

SudoSOS Back-end API / internal/pdf/transfer-pdf-service / TransferPdfService

Class: TransferPdfService ​

Turns an entity into HTML and PDF bytes. One subclass per document type.

Extends ​

Constructors ​

Constructor ​

ts
new TransferPdfService(manager?): TransferPdfService;

Parameters ​

ParameterType
manager?EntityManager

Returns ​

TransferPdfService

Inherited from ​

PdfService.constructor

Properties ​

PropertyModifierTypeDefault valueOverridesInherited from
managerprotectedEntityManagerundefined-PdfService.manager
renderpublic(options) => stringcreateTransferPdfPdfService.render-

Methods ​

compile() ​

ts
protected compile(params): Promise<Buffer<ArrayBufferLike>>;

Parameters ​

ParameterType
paramsITransferPdf

Returns ​

Promise<Buffer<ArrayBufferLike>>

Inherited from ​

PdfService.compile


configureLogger() ​

ts
protected configureLogger(logger): void;

Parameters ​

ParameterType
loggerLogger

Returns ​

void

Inherited from ​

PdfService.configureLogger


getParameters() ​

ts
getParameters(entity): Promise<ITransferPdf>;

Parameters ​

ParameterType
entityTransfer

Returns ​

Promise<ITransferPdf>

Overrides ​

PdfService.getParameters


html() ​

ts
html(entity): Promise<Buffer<ArrayBufferLike>>;

Parameters ​

ParameterType
entityTransfer

Returns ​

Promise<Buffer<ArrayBufferLike>>

Inherited from ​

PdfService.html


output() ​

ts
output(entity, fileType): Promise<Buffer<ArrayBufferLike>>;

Parameters ​

ParameterType
entityTransfer
fileTypeReturnFileType

Returns ​

Promise<Buffer<ArrayBufferLike>>

Inherited from ​

PdfService.output


pdf() ​

ts
pdf(entity): Promise<Buffer<ArrayBufferLike>>;

Parameters ​

ParameterType
entityTransfer

Returns ​

Promise<Buffer<ArrayBufferLike>>

Inherited from ​

PdfService.pdf