Skip to content
Snippets Groups Projects
Commit 738ed9e8 authored by juanf's avatar juanf
Browse files

SSDM-7228 : IOS fix, notifications to have relative screen with

parent 7508cd7e
No related branches found
No related tags found
No related merge requests found
...@@ -156,9 +156,7 @@ var Util = new function() { ...@@ -156,9 +156,7 @@ var Util = new function() {
this.showError(withHTML, andCallback, noBlock, true, false, true); this.showError(withHTML, andCallback, noBlock, true, false, true);
} }
this.showError = function(withHTML, andCallback, noBlock, isUserError, isEnvironmentError, disableReport) { this.showError = function(withHTML, andCallback, noBlock, isUserError, isEnvironmentError, disableReport) {
var withHTMLToShow = null;
var userErrorWarning = ""; var userErrorWarning = "";
if(isUserError) { if(isUserError) {
userErrorWarning = "<b>This error looks like a user error:</b>" + "<br>"; userErrorWarning = "<b>This error looks like a user error:</b>" + "<br>";
...@@ -177,15 +175,16 @@ var Util = new function() { ...@@ -177,15 +175,16 @@ var Util = new function() {
"href: " + location.href.replace(new RegExp("&", 'g'), " - ") + "%0D%0A" + "href: " + location.href.replace(new RegExp("&", 'g'), " - ") + "%0D%0A" +
"error: " + withHTML; "error: " + withHTML;
var withHTMLToShow = ""; var withHTMLToShow = "<div style=\"width:100%;\">";
if(disableReport) { if(disableReport) {
withHTMLToShow += "<textarea style=\"background: transparent; border: none;\" rows=\"1\" cols=\"170\">" + withHTML + "</textarea><br>"; withHTMLToShow += "<textarea style=\"background: transparent; border: none; width:100%;\" rows=\"1\">" + withHTML + "</textarea><br>";
withHTMLToShow += "<a id='jNotifyDismiss' class='btn btn-default'>Dismiss</a>"; withHTMLToShow += "<a id='jNotifyDismiss' class='btn btn-default'>Dismiss</a>";
} else { } else {
withHTMLToShow += userErrorWarning + "<br><br><textarea style=\"background: transparent;\" rows=\"8\" cols=\"170\">" + withHTML + "</textarea>" + "<br><br>" + warning + "<br><br>"; withHTMLToShow += userErrorWarning + "<br><br><textarea style=\"background: transparent; width:100%;\" rows=\"8\">" + withHTML + "</textarea>" + "<br><br>" + warning + "<br><br>";
withHTMLToShow += "<a id='jNotifyDismiss' class='btn btn-default'>Dismiss</a>" + "<a class='btn btn-default' href='mailto:" + profile.devEmail + "?subject=ELN Error Report [" + location.hostname +"] ["+ mainController.serverFacade.openbisServer.getSession() + "]&body=" + report +"'>Send error report</a>"; withHTMLToShow += "<a id='jNotifyDismiss' class='btn btn-default'>Dismiss</a>" + "<a class='btn btn-default' href='mailto:" + profile.devEmail + "?subject=ELN Error Report [" + location.hostname +"] ["+ mainController.serverFacade.openbisServer.getSession() + "]&body=" + report +"'>Send error report</a>";
} }
withHTMLToShow += "</div>";
if(!noBlock) { if(!noBlock) {
this.blockUINoMessage(); this.blockUINoMessage();
} }
...@@ -196,7 +195,7 @@ var Util = new function() { ...@@ -196,7 +195,7 @@ var Util = new function() {
{ {
autoHide : false, autoHide : false,
clickOverlay : false, clickOverlay : false,
MinWidth : 250, MinWidth : '80%',
TimeShown : 2000, TimeShown : 2000,
ShowTimeEffect : 200, ShowTimeEffect : 200,
HideTimeEffect : 200, HideTimeEffect : 200,
...@@ -222,7 +221,7 @@ var Util = new function() { ...@@ -222,7 +221,7 @@ var Util = new function() {
{ {
autoHide : true, autoHide : true,
clickOverlay : true, clickOverlay : true,
MinWidth : 250, MinWidth : '80%',
TimeShown : 2000, TimeShown : 2000,
ShowTimeEffect : 200, ShowTimeEffect : 200,
HideTimeEffect : 200, HideTimeEffect : 200,
...@@ -249,7 +248,7 @@ var Util = new function() { ...@@ -249,7 +248,7 @@ var Util = new function() {
{ {
autoHide : false, autoHide : false,
clickOverlay : false, clickOverlay : false,
MinWidth : 250, MinWidth : '80%',
TimeShown : 2000, TimeShown : 2000,
ShowTimeEffect : 200, ShowTimeEffect : 200,
HideTimeEffect : 200, HideTimeEffect : 200,
...@@ -411,7 +410,7 @@ var Util = new function() { ...@@ -411,7 +410,7 @@ var Util = new function() {
{ {
autoHide : false, autoHide : false,
clickOverlay : false, clickOverlay : false,
MinWidth : 250, // MinWidth : '80%',
TimeShown : 2000, TimeShown : 2000,
ShowTimeEffect : 200, ShowTimeEffect : 200,
HideTimeEffect : 200, HideTimeEffect : 200,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment