[SOLVED] Show Dynamic Fields for specific groups

Moderator: crythias

Post Reply
scottbean
Znuny newbie
Posts: 14
Joined: 30 Jan 2013, 21:08
Znuny Version: 2.4.7
Real Name: Scott Bean

[SOLVED] Show Dynamic Fields for specific groups

Post by scottbean »

Currently we have OTRS 2.4.7 in production. There are three groups of agents that have unique Free Text Fields (dropdown lists) that are only visible to agents in the group associated with the dropdown. This is done by adding the information into a Theme set up for each of the three groups. This way each group’s users can see only their dropdown, and the default theme users can’t see any of them.

Our test box has been upgraded to 3.2.1 and I am attempting to replicate the above using dynamic fields. I have been able to hide ALL dynamic fields from the default users via theme, but cannot seem to get the individual themes to only see the dynamic field related to that group. It seems to be all or none as far as dynamic fields go.

I have found ways to show dynamic fields to specific queues, but these three groups have multiple queues, and it would be very cumbersome to set this up per queue/sub-queue.
Anyone have any ideas on how I can accomplish my goal by using themes? Is there another way to do this?

Thanks,

Scott
Last edited by scottbean on 12 Feb 2013, 00:52, edited 1 time in total.
OTRS 2.4.7/RHEL 5.9/MySQL 5.0.95 Production -- OTRS 3.2.2/RHEL 5.9/MySQL 5.0.95 Dev/Test
crythias
Moderator
Posts: 10169
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Show Dynamic Fields for specific groups

Post by crythias »

There's no inherent information that the interface has to know what group applies, though ACL would certainly help for the values.

Think about it, though. OTRS only checks if you're allowed to view the page. Once you're there, it doesn't really matter *how* you're allowed to view the page. You can only view a [ticket from a] queue if you are a member of that queue's group. So, if you're in the queue, the only group that matters is the Queue's group, and because this is a one-to-one relationship (one queue to one group) why would any other group matter?

(Because I have permissions on groups for Dynamic Fields!)
You're probably thinking about this the wrong way, then. There are no permissions on whether or not a Dynamic field is displayed. It isn't for you. It's for the ticket.

(But it worked before!)
What can I say? It's not supposed to. Optionally, you can group enable "Free Fields" module or its equivalent and allow only the members of the "Free Fields" group to have access to those private fields, and disable them from being accessed via other screens.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
scottbean
Znuny newbie
Posts: 14
Joined: 30 Jan 2013, 21:08
Znuny Version: 2.4.7
Real Name: Scott Bean

Re: Show Dynamic Fields for specific groups

Post by scottbean »

Just to clarify - this is not for "groups" as OTRS sees them. We currently have agents that are in three different departments that each have a dropdown box that only they need to see when creating a new ticket. In the view screens (zoom, overview medium, and preview) they are the only ones who would need to see that field as well. Currently those agents have their own custom theme that is set in preferences. The rest of our agents are set to the default view, which is set to not show the fields.

I have created new themes for the three sets of agents as well as a default theme. The default theme is not showing the dynamic field (as intended). Is there a way in a theme to show/hide individual dynamic fields or is it really show ALL dynamic fields or none? The .dtl files do have commented out text that is an "example of how to use fixed dynamic field blocks for customizations". Not sure if that is what I need to go from or not. I haven't found any details about that in my searches.
OTRS 2.4.7/RHEL 5.9/MySQL 5.0.95 Production -- OTRS 3.2.2/RHEL 5.9/MySQL 5.0.95 Dev/Test
crythias
Moderator
Posts: 10169
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Show Dynamic Fields for specific groups

Post by crythias »

Yes, you need to include all dynamic fields that are enabled for the screen.
HOWEVER, you only (I think) need to enable the blocks (start and end) for each one. You don't necessarily have to put display information in blocks, though.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
scottbean
Znuny newbie
Posts: 14
Joined: 30 Jan 2013, 21:08
Znuny Version: 2.4.7
Real Name: Scott Bean

Re: Show Dynamic Fields for specific groups

Post by scottbean »

Solved my own problem. I just needed to add the Dynamic Field Key in the dtl:block statement.

<!-- dtl:block:DynamicField_FieldKey -->
other info
<!-- dtl:block:DynamicField_FieldKey -->

Should have known it would be that easy.

Scott
OTRS 2.4.7/RHEL 5.9/MySQL 5.0.95 Production -- OTRS 3.2.2/RHEL 5.9/MySQL 5.0.95 Dev/Test
brianmark2
Znuny newbie
Posts: 13
Joined: 01 Sep 2014, 05:52
Znuny Version: 3.3.8
Real Name: Brian
Company: none

Re: Show Dynamic Fields for specific groups

Post by brianmark2 »

Hi Sir have you done this to the latest version of OTRS? If yes kindly teach us how to do it step by step? Newbie here. I'm using OTRS 5.x

Any update on this Please. :(

Thank you
Post Reply