npm install ng-fad-acceptance-signature-express-desktop
Add the folder provided by the technical team within the project assets (images and js)
In the file necessary example.module.ts import the module.
In this case app.module.ts
import { NgFadAcceptanceSignatureDesktopModule } from 'ng-fad-acceptance-signature-express-desktop';
.
.
.
... imports: [
...,
BrowserAnimationsModule
NgFadAcceptanceSignatureDesktopModule
]...
Note: BrowserAnimationsModule is required.
Add the selector inside some component and configure the input parameters:
<ng-fad-acceptance-signature-express-desktop
[configuration]="configuration"
[pdfSrc]="pdfSrc"
[signatures]="signatures"
[moreInformation]="moreInformation"
(onerror)="onerror($event)"
(oncontinue)="oncontinue()"
(onmoreinformation)="onmoreinformation()">
</ng-fad-acceptance-signature-express-desktop>
Listen to the events and execute methods:
public pdfSrc = 'pdf resource';
public moreInformation = false;
onerror(error) {
alert(JSON.stringify(error));
}
oncontinue() {
alert('next step');
}
onmoreinformation() {
alert('more information clicked')
}
Name | Type | Required | Default | Description |
---|---|---|---|---|
configuration | object | false | {} | module data to be configured |
pdfSrc | string | true | undefined | pdf resource |
signatures | object | true | undefined | signature coordinates |
moreInformation | boolean | false | false | view to see more information text |
Name | Return | Description |
---|---|---|
onerror | object | Is called when an error happens |
oncontinue | void | Is called when the user finishes the process |
onmoreinformation | void | Is called when the user clicks on the text of more information |