summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2017-03-15 16:42:10 +0100
committeremkael <emkael@tlen.pl>2017-03-15 16:47:25 +0100
commit40da59a0c5f9fa2f1cf840bc64161861ef6a818f (patch)
tree260e296de63cad0eabaa54e34d07df1d400f1861
parent44149fc7916ab129e626441d2d81cd8ec7a8ec9f (diff)
* registration open to public
-rw-r--r--app/frontend/controls/HeaderMenu.tpl8
-rw-r--r--app/frontend/pages/config.xml4
2 files changed, 9 insertions, 3 deletions
diff --git a/app/frontend/controls/HeaderMenu.tpl b/app/frontend/controls/HeaderMenu.tpl
index 265d29e..c93ac85 100644
--- a/app/frontend/controls/HeaderMenu.tpl
+++ b/app/frontend/controls/HeaderMenu.tpl
@@ -3,21 +3,25 @@
<prop:Text><%[ Home ]%></prop:Text>
<prop:NavigateUrl><%= $this->Service->constructUrl(NULL) %></prop:NavigateUrl>
</com:THyperLink>
+
<com:TActiveLinkButton OnCommand="loginUser">
<prop:Text><%[ Login ]%></prop:Text>
<prop:Visible><%= $this->User->IsGuest %></prop:Visible>
<prop:ClientSide.OnFailure>window.location.replace('<%= $this->Service->constructUrl('Login') %>')</prop:ClientSide.OnFailure>
<prop:ClientSide.OnException>window.location.replace('<%= $this->Service->constructUrl('Login') %>')</prop:ClientSide.OnException>
</com:TActiveLinkButton>
+
<com:THyperLink>
<prop:Text><%[ Profile ]%></prop:Text>
<prop:NavigateUrl><%= $this->Service->constructUrl('Profile') %></prop:NavigateUrl>
<prop:Visible><%= !$this->User->IsGuest %></prop:Visible>
</com:THyperLink>
+
<com:THyperLink>
<prop:Text><%[ Calendar list ]%></prop:Text>
<prop:NavigateUrl><%= $this->Service->constructUrl('Select') %></prop:NavigateUrl>
</com:THyperLink>
+
<com:TActiveLinkButton OnCommand="logoutUser">
<com:TTranslate>
Logout ({name})
@@ -27,11 +31,13 @@
<prop:ClientSide.OnFailure>window.location.reload()</prop:ClientSide.OnFailure>
<prop:ClientSide.OnException>window.location.reload()</prop:ClientSide.OnException>
</com:TActiveLinkButton>
+
<com:THyperLink>
<prop:Text><%[ New user ]%></prop:Text>
<prop:NavigateUrl><%= $this->Service->constructUrl('Signup') %></prop:NavigateUrl>
- <prop:Visible><%= $this->User->getIsAdmin() %></prop:Visible>
+ <prop:Visible><%= $this->User->getIsGuest() %></prop:Visible>
</com:THyperLink>
+
<com:THyperLink>
<prop:Text><%[ Admin calendars ]%></prop:Text>
<prop:NavigateUrl><%= $this->Service->constructUrl('Admin') %></prop:NavigateUrl>
diff --git a/app/frontend/pages/config.xml b/app/frontend/pages/config.xml
index 305651e..379e643 100644
--- a/app/frontend/pages/config.xml
+++ b/app/frontend/pages/config.xml
@@ -20,8 +20,8 @@
StatePersister.CacheTimeout="3600" />
<authorization>
- <allow pages="Admin,Signup" roles="Admin" />
- <deny pages="Admin,Signup" />
+ <allow pages="Admin" roles="Admin" />
+ <deny pages="Admin" />
<deny pages="Profile" users="?" />
</authorization>