Skip to content

Instantly share code, notes, and snippets.

@bjoerntx
Created March 25, 2024 16:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bjoerntx/8ce824558449a74bde1fe5b2f2b1824c to your computer and use it in GitHub Desktop.
Save bjoerntx/8ce824558449a74bde1fe5b2f2b1824c to your computer and use it in GitHub Desktop.
@HostListener('window:documentViewerLoaded', ['$event'])
onDocumentViewerLoaded() {
var signatureSettings = {
showSignatureBar: true,
redirectUrlAfterSignature: 'https://localhost:7122/document/customsign',
ownerName: 'Paul',
signerName: 'Jacob',
signerInitials: 'PK',
signatureBoxes: [{ name: 'txsign', signingRequired: true, style: 0 }]
};
this.http.get<DocumentData>('/document/prepare').subscribe(
(result) => {
this.documentData = result;
console.log(this.documentData);
TXDocumentViewer.loadDocument(this.documentData.document, this.documentData.name, signatureSettings);
}
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment