Limit custom fields by user?

Discussion forum about Anuko Time Tracker
Post Reply
5circles
Posts: 7
Joined: Fri Jan 25, 2013 10:54 pm

Limit custom fields by user?

Post by 5circles » Thu Feb 22, 2018 1:08 am

Is it possible to limit custom fields to that only a subset of users can see them?

Thanks
Mike

Nik
Posts: 440
Joined: Wed May 26, 2010 5:55 pm

Re: Limit custom fields by user?

Post by Nik » Thu Feb 22, 2018 1:56 pm

Current code works like this:

Code: Select all

// Use custom fields plugin if it is enabled.
if ($user->isPluginEnabled('cf')) {
  require_once('plugins/CustomFields.class.php');
  $custom_fields = new CustomFields($user->team_id);
}
The isPluginEnabled part is from a group (team), not user, so there is (currently) no distinction whether to show the controls for a specific user or not.

wrc
Posts: 251
Joined: Tue May 25, 2010 8:30 pm

Re: Limit custom fields by user?

Post by wrc » Thu Feb 22, 2018 2:44 pm

What could probably work is a customization along the following lines:

- Allow users to customize something. Perhaps on the Profile page, or a separate Options page.
- If a custom field is not a required field as set in group - allow users to switch it off from display completely.

Makes sense?

5circles
Posts: 7
Joined: Fri Jan 25, 2013 10:54 pm

Re: Limit custom fields by user?

Post by 5circles » Thu Feb 22, 2018 5:04 pm

I think I have a basic misunderstanding of teams and/or I didn't set things up correctly in the first place - many versions ago. And it looks like if teams are set up correctly several issues - including custom fields - will be resolved.

It appears that I have one team only - with just me as the manager, and no other users. No, that's not true. Everyone is part of the same team.

Is it possible to:
* Create a new team with a single manager responsible for multiple teams? If this isn't possible, using two logins should be OK (I just did this)
* Have team members be part of more than one team? I'm not sure I need this, but it's possible that something like this will be helpful for the future.
* Move or copy users to another team? I just did this with one inactive user using phpmyadmin, and that approach might be sufficient.

Thanks
Mike

Nik
Posts: 440
Joined: Wed May 26, 2010 5:55 pm

Re: Limit custom fields by user?

Post by Nik » Thu Feb 22, 2018 10:02 pm

5circles wrote: Is it possible to:
* Create a new team with a single manager responsible for multiple teams?
Subgroups are currently not available but we are working on this...
5circles wrote: * Have team members be part of more than one team?
No.
5circles wrote: * Move or copy users to another team? I just did this with one inactive user using phpmyadmin, and that approach might be sufficient.
No, not implemented. If you do it with other tools, there are issue to consider:

1) User to project binds will become broken for user, as projects are from the old team. So you need to rebuild / reassign them.
2) tt_log (time records) and tt_expenses entries (expense records) - are still there with old team projects, tasks, clients, etc.
3) tt_fav_reports (if there were any) for user will have bogus entries because of the same reason.

Hope it helps.

5circles
Posts: 7
Joined: Fri Jan 25, 2013 10:54 pm

Re: Limit custom fields by user?

Post by 5circles » Thu Feb 22, 2018 10:15 pm

Thanks - that helps. I thought the project binds might still be there. Oh well

Post Reply