mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
add message incase document link is not a valida link
This commit is contained in:
@@ -76,14 +76,17 @@ export class ViewerAttachmentPage implements OnInit {
|
|||||||
|
|
||||||
// Optionally, you can add new content or recreate the iframe
|
// Optionally, you can add new content or recreate the iframe
|
||||||
var newIframe = document.createElement('iframe');
|
var newIframe = document.createElement('iframe');
|
||||||
newIframe.src = linkRequest.value;
|
if(linkRequest.value.includes("http")) {
|
||||||
|
newIframe.src = linkRequest.value;
|
||||||
|
|
||||||
newIframe.width = '100%'
|
newIframe.width = '100%'
|
||||||
newIframe.height = '100%'
|
newIframe.height = '100%'
|
||||||
|
this.iframeContainer.nativeElement.innerHTML = ""
|
||||||
|
this.iframeContainer.nativeElement.appendChild(newIframe)
|
||||||
|
|
||||||
this.iframeContainer.nativeElement.innerHTML = ""
|
} else {
|
||||||
this.iframeContainer
|
this.iframeContainer.nativeElement.innerHTML = "Sem documento"
|
||||||
this.iframeContainer.nativeElement.appendChild(newIframe)
|
}
|
||||||
|
|
||||||
this.iframeContainer.nativeElement.style.display = 'flex'
|
this.iframeContainer.nativeElement.style.display = 'flex'
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user