Просмотр исходного кода

Merge branch 'fix/smapsso.addQuery' into 'wrdp'

Merge of fix/smapsso.addQuery 移动端增加pagehide事件,smapsso.html增加nav参数 to wrdp

See merge request o2oa/o2oa!2445
蔡祥熠 5 лет назад
Родитель
Сommit
b70c4a7ad0
2 измененных файлов с 10 добавлено и 3 удалено
  1. 6 3
      o2web/source/x_component_Common/Main.js
  2. 4 0
      o2web/source/x_desktop/smapsso.html

+ 6 - 3
o2web/source/x_component_Common/Main.js

@@ -268,9 +268,12 @@ MWF.xApplication.Common.Main = new Class({
 		window.addEventListener("beforeunload", function (e) {
 		window.addEventListener("beforeunload", function (e) {
 			this.fireAppEvent("queryClose");
 			this.fireAppEvent("queryClose");
 		}.bind(this));
 		}.bind(this));
-		// window.addEventListener("pagehide", function (e) {
-		// 	this.fireAppEvent("queryClose");
-		// }.bind(this));
+
+		if(layout.mobile){
+			window.addEventListener("pagehide", function (e) {
+				this.fireAppEvent("queryClose");
+			}.bind(this));
+		}
 
 
 		// window.onbeforeunload = function(e){
 		// window.onbeforeunload = function(e){
 		//     this.fireAppEvent("queryClose");
 		//     this.fireAppEvent("queryClose");

+ 4 - 0
o2web/source/x_desktop/smapsso.html

@@ -25,6 +25,10 @@
                     }
                     }
                     var redirect = uri.getData("redirect");
                     var redirect = uri.getData("redirect");
                     redirect = redirect + "&uniqueId=" + uniqueId + "&flushPortalUrl="+flushPortalUrl;
                     redirect = redirect + "&uniqueId=" + uniqueId + "&flushPortalUrl="+flushPortalUrl;
+
+                    var nav = uri.getData("nav");
+                    if(nav)redirect = redirect + "&nav=" + nav;
+
                     if (xtoken){
                     if (xtoken){
                         var res = new Request.JSON({
                         var res = new Request.JSON({
                             url: o2.filterUrl(address+"?SMAP_SESSION_DATA="+encodeURIComponent(xtoken)+"&appID="+appID+"&date="+(new Date()).getTime()),
                             url: o2.filterUrl(address+"?SMAP_SESSION_DATA="+encodeURIComponent(xtoken)+"&appID="+appID+"&date="+(new Date()).getTime()),