فهرست منبع

修复路径转发bug

huqi 5 سال پیش
والد
کامیت
8aad121849
2فایلهای تغییر یافته به همراه16 افزوده شده و 14 حذف شده
  1. 13 13
      o2web/source/o2_core/o2.js
  2. 3 1
      o2web/source/x_desktop/sso.html

+ 13 - 13
o2web/source/o2_core/o2.js

@@ -273,19 +273,19 @@
             }
         }
 
-        if (!window.layout) window.layout = {};
-        if (!window.layout.config){
-            new Request.JSON({
-                url: "../x_desktop/res/config/config.json",
-                secure: false,
-                method: "get",
-                noCache: true,
-                async: false,
-                onSuccess: function(responseJSON, responseText){
-                    window.layout.config = responseJSON;
-                }.bind(this),
-            }).send();
-        }
+        // if (!window.layout) window.layout = {};
+        // if (!window.layout.config){
+        //     new Request.JSON({
+        //         url: "../x_desktop/res/config/config.json",
+        //         secure: false,
+        //         method: "get",
+        //         noCache: true,
+        //         async: false,
+        //         onSuccess: function(responseJSON, responseText){
+        //             window.layout.config = responseJSON;
+        //         }.bind(this),
+        //     }).send();
+        // }
 
         if (window.layout && layout.config && layout.config.urlMapping){
             for (var k in layout.config.urlMapping){

+ 3 - 1
o2web/source/x_desktop/sso.html

@@ -71,6 +71,8 @@
 
         o2.addReady(function(){
             o2.JSON.get("res/config/config.json", function(config){
+                if (!window.layout) window.layout = {};
+                window.layout.config = config;
                 getServiceAddress(config, function(address){
                     var uri = new URI(window.location.toString());
                     var xtoken = uri.getData("xtoken");
@@ -79,7 +81,7 @@
                     if (xtoken){
                         var res = new Request.JSON({
                             //url: "http://hbxa01.bf.ctc.com:20080/x_organization_assemble_authentication/jaxrs/sso",
-                            url: address+"/jaxrs/sso",
+                            url: o2.filterUrl(address+"/jaxrs/sso"),
                             secure: false,
                             method: "POST",
                             noCache: true,