This commit is contained in:
Pascal 2024-12-19 11:08:21 +01:00
parent 17208b5855
commit 62c8d95ea3

View File

@ -1399,7 +1399,7 @@ class SignatureElement extends HTMLElement {
private submitNewDocument(event: Event) { private submitNewDocument(event: Event) {
event.preventDefault(); event.preventDefault();
const form = document.getElementById('newDocumentForm') as HTMLFormElement; const form = this.shadowRoot?.getElementById('newDocumentForm') as HTMLFormElement;
if (!form) { if (!form) {
this.showAlert('Form not found'); this.showAlert('Form not found');
return; return;
@ -1507,7 +1507,7 @@ class SignatureElement extends HTMLElement {
private submitCommonDocument(event: Event) { private submitCommonDocument(event: Event) {
event.preventDefault(); event.preventDefault();
const form = document.getElementById('newDocumentForm') as HTMLFormElement; const form = this.shadowRoot?.getElementById('newDocumentForm') as HTMLFormElement;
if (!form) { if (!form) {
this.showAlert('Form not found'); this.showAlert('Form not found');
return; return;