diff --git a/assets/js/common/page.js b/assets/js/common/page.js index 4b5a5fb5..d3863b0d 100644 --- a/assets/js/common/page.js +++ b/assets/js/common/page.js @@ -198,6 +198,12 @@ ComunicWeb.common.page = { var mainContainerElem = this.emptyPage(true); } + //Check if the page requires user login + if(pageInfos.needLogin){ + if(!signed_in()) + openPage("login"); + } + //We check if the page is a full screen page or not if(pageInfos.disableMenus){ //We force the screen to be cleaned diff --git a/assets/js/pagesList.js b/assets/js/pagesList.js index 314815c7..126012f2 100644 --- a/assets/js/pagesList.js +++ b/assets/js/pagesList.js @@ -47,7 +47,8 @@ ComunicWeb.pagesList = { conversations: { pageTitle: "Conversations", methodHandler: "ComunicWeb.pages.conversations.main.open", - disableMenus: false + disableMenus: false, + needLogin: true }, /**