Skip to content
Snippets Groups Projects
Commit 7d09507c authored by Reiter, Christoph's avatar Reiter, Christoph :snake:
Browse files

Update toolkit and port to new jsonld API

parent 6170c8a9
No related branches found
No related tags found
No related merge requests found
Pipeline #18255 passed with warnings
......@@ -296,7 +296,7 @@ class OfficialSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitElem
i18n.changeLanguage(this.lang);
break;
case "entryPointUrl":
JSONLD.initialize(this.entryPointUrl, (jsonld) => {
JSONLD.getInstance(this.entryPointUrl).then((jsonld) => {
let apiUrlBase = jsonld.getApiUrlForEntityName("AdvancedlySignedDocument");
this.fileSourceUrl = apiUrlBase;
});
......
......@@ -314,7 +314,7 @@ class QualifiedSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitEle
const fileName = this.currentFileName === "" ? "mydoc.pdf" : this.currentFileName;
// fetch pdf from api gateway with sessionId
JSONLD.initialize(this.entryPointUrl, (jsonld) => {
JSONLD.getInstance(this.entryPointUrl).then((jsonld) => {
const apiUrl = jsonld.getApiUrlForEntityName("QualifiedlySignedDocument") + '/' + encodeURIComponent(sessionId) + '?fileName=' +
encodeURIComponent(fileName);
......@@ -417,7 +417,7 @@ class QualifiedSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitEle
i18n.changeLanguage(this.lang);
break;
case "entryPointUrl":
JSONLD.initialize(this.entryPointUrl, (jsonld) => {
JSONLD.getInstance(this.entryPointUrl).then((jsonld) => {
const apiUrlBase = jsonld.getApiUrlForEntityName("QualifiedSigningRequest");
this.fileSourceUrl = apiUrlBase ;
});
......
......@@ -39,7 +39,6 @@ export class DBPSignatureBaseLitElement extends AdapterLitElement {
changedProperties.forEach((oldValue, propName) => {
switch (propName) {
case "auth":
JSONLD.doInitializationOnce(this.entryPointUrl, this.auth.token);
this._updateAuth();
break;
}
......
......@@ -209,7 +209,7 @@ class SignatureVerificationFull extends ScopedElementsMixin(DBPSignatureLitEleme
i18n.changeLanguage(this.lang);
break;
case "entryPointUrl":
JSONLD.initialize(this.entryPointUrl, (jsonld) => {
JSONLD.getInstance(this.entryPointUrl).then((jsonld) => {
const apiUrlBase = jsonld.getApiUrlForEntityName("ElectronicSignatureVerificationReport");
this.fileSourceUrl = apiUrlBase;
});
......
Subproject commit a8ab1f7220f86eea76e5f601c080da066496f7df
Subproject commit ed92bea5e24a3f52ce5582723cf0c16d303d221b
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment