change the logout function , make it ok.
authorzhouruiyu <zhouruiyu@huawei.com>
Tue, 1 Nov 2016 08:01:00 +0000 (16:01 +0800)
committerzhouruiyu <zhouruiyu@huawei.com>
Tue, 1 Nov 2016 08:01:00 +0000 (16:01 +0800)
https://jira.open-o.org/browse/OCS-145

Change-Id: I064bc94b435e0254578b69a56aff14cf4001d92a
Signed-off-by: zhouruiyu <zhouruiyu@huawei.com>
openo-portal/portal-common/src/main/webapp/common/default.html
openo-portal/portal-common/src/main/webapp/common/js/core/const.js
openo-portal/portal-common/src/main/webapp/common/js/core/openoFrameWork.js

index 643c5db..498c0e1 100644 (file)
                        jQuery(document).ready(function() {
                                openoFrameWork.init();
                                $("#pageLoading").setToHide();
+                               $('#trigger_logout').click(function(){
+                       bootbox.confirm($.i18n.prop('com_zte_ums_ict_framework_ui_confirmlogout'), function(result) { //你确认要注销吗?
+                          if(result){
+                            doLogout();
+                           }
+                       }); 
+                   });
                        });
                </script>
        </body>
index 429f2d0..e022439 100644 (file)
@@ -36,7 +36,7 @@ FrameConst.REST_HEARTBEAT = "../../api/uiframe/v1/heartbeat";
 FrameConst.REST_GETLICENSEINFO = "../../api/uiframe/v1/licensevalueinfo";
 FrameConst.REST_CHECKRIGHT = "../../api/uiframe/v1/checkRight";
 FrameConst.REST_LOGIN = "../../api/uiframe/v1/login";
-FrameConst.REST_LOGOUT = "../../api/uiframe/v1/loginOut?SSOAction=SSOLogout";
+FrameConst.REST_LOGOUT = "/openoui/common/logout.html";
 FrameConst.REST_GET_FRAME_MENUDIRECTION = "../../api/uiframe/v1/confByKey?key=usf.mainframe.web.navigation.direction";
 FrameConst.REST_GET_USERNAME = "../../api/uiframe/v1/userName";
 
index 95ea913..0ce09df 100644 (file)
@@ -1952,7 +1952,7 @@ var openoFrameWork = function () {
                return "Already disabled!";
        };      
        window.doLogout = function(){
-               window.location=FrameConst.REST_LOGOUT;
+               top.window.document.location.href=FrameConst.REST_LOGOUT;
        };
     //处理ict注销确认
     $('#trigger_logout').click(function(){
@@ -3169,7 +3169,6 @@ var openoFrameWork = function () {
             return null; //返回参数值
                }
     };
-    
 }();
 
 //抽取html片段中任意位置的script标签(包括代码是内嵌的情况)逐个运行(不会在单个script加载不到的时候停下来)