Custom Links on Home by USER

Wish to see a specific feature/change in future releases? Feel free to post it here, and if it gets enough "likes", we'd definitely include it in future releases!
Post Reply
User avatar
Veteran Member
Posts: 39
Joined: 2014-07-07 18:47
Location: Cluj-Napoca

Custom Links on Home by USER

Post by naturick » 2018-08-06 15:28

Hello. pböttcher just solved me a problem. I think that it can be implemented on Appgini core.

I needed to restrict visability of some custom links in home page to a specific USER.

USER is memmebr of a GROUP that I didn't want to show links to.

Actually Appgini allow this restriction by GROUP.

Solution is very easy:

What you can do, if you need this, you can add

Code: Select all

'users' => array('user1', 'users'), // array of users allowed to see the custom link
in the links-home.php

and change the following in the incCommon.php file (get_home_links function // arround line 1300)

Code: Select all

if($memberInfo['admin'] || @in_array($memberInfo['group'], $link['groups']) || @in_array('*', $link['groups'])){

Code: Select all

if($memberInfo['admin'] || @in_array($memberInfo['group'], $link['groups']) || @in_array('*', $link['groups']) || @in_array($memberInfo['username'], $link['users'])){

Of course this change will be overwritten every time application is recreated/published.

User avatar
Site Admin
Posts: 1135
Joined: 2012-09-27 14:46

Re: Custom Links on Home by USER

Post by a.gneady » 2018-08-23 14:16

Thanks for sharing, @naturick. I've added this to our backlog to implement it in future releases :)
:idea: Calendar plugin: Organize your data into beautiful calendars.
:arrow: Mass Update plugin: Update multiple records at once and improve your workflow efficiency.
:arrow: Summary Reports plugin: Build powerful reports and charts for your AppGini apps.
:arrow: Search Page Maker: Compose user-friendly yet powerful search pages for your AppGini apps.

Post Reply