How to Display Different Groups Based on Selected Value?

YummyAmericano
Tera Contributor

Hello, 

I am having trouble setting up the logic for the Assignment Group in the Project Task form
I have created a custom field called 'PPM Group Type' with two options:
(PPM Agile Group) and (PPM Work Center).
ProjectTaskFormAssignmentGroup.PNG

I want the 'Assignment Group' to show all the Groups associate with the (Agile Team AND PPM Work Center) type when (PPM Agile Group) is selected.
Query: 
active=true^typeLIKEe350a0be2ff31110bd13a85df699b69b^typeLIKE1c5064fe2ff31110bd13a85df699b60b
ConditionsForPPMAgileGroup.PNG


I want the 'Assignment Group' to show all the Groups associate with the (PPM Work Center) type when (PPM Work Center) is selected. 
Query:
active=true^typeNOT LIKEe350a0be2ff31110bd13a85df699b69b^typeLIKE1c5064fe2ff31110bd13a85df699b60b
ConditionsForPPMWorkCenter.PNG


Currently, the 'Assignment Group' has a reference qual condition in place. 
ReferenceQualAssignmentGroup.PNG

Thank you for your help with this.

 
1 ACCEPTED SOLUTION

Hey ,

 

1. Whenever in reference qualifier if you write script first put javascript :  and then write the logic.

2. Kindly check in the dictionary override tab, the table is there or not on which you want this assignment group to to show records. We need to make changes in child table's reference qualifier and leave the parent table field (assignment_group) as it is.

 

e.g. - below assignment_group is on task table but i want to change reference qualifier on pm_project_task table which is child table of 'task' table.

KartikChoudha1_0-1672337529077.png

 

So, I'll do the change in child table (pm_project_task) of override reference qualifier.

 

KartikChoudha1_1-1672337600605.png

 

After javascript followed by colon sign , you can write your logic.

 

Hope this helps!

Kindly mark my responses helpful if it guides you to solutions or help you to understand.

 

Regards,

Kartik

 

 

View solution in original post

16 REPLIES 16

Check like below, it's working for me.

KartikChoudha1_0-1672339477208.png

 

Give me sometime, I need to replicate your scenario. 

 

Regards,

Kartik

 

Hi Kartik, thank you so much for all your time. It works. I re-wrote the script include and the Overrides Reference Qualifier and it works. 

Here is the script include I wrote:
ScriptIncludeGroupFilter.PNG

 

Then under the 'Assignment Group' > Dictionary Overrides > 'pm_project_task' table > Override reference qualifier I apply this script below:
OverridesRefQualpm_project_taskTable.PNG

 

and here is the results:
PPMAgileGroup.PNGPPMWorkCenter.PNG


Thanks again, Kartik, you saved my day.

Great work mate!

Happy to see the solution.

 

I have also replicated the same in PDI. 

Note - you can remove the modifications from reference qualifier of Parent Table (task table) and make it like earlier.

Making changes in Parent table field will affect all the child tables. 

 

Regards,

Kartik Choudhary

Thanks. Yes, I already did remove the script from the Parent Table's reference qualifier. Now, in that reference qualifier has this query: ParentTableRefQual.PNG

I have replicated the same (without PPM group condition for now). Have a look for future reference.

 

KartikChoudha1_0-1672343480487.png

 

Script Include method -

KartikChoudha1_1-1672343539800.png

 

Reference Qua-

KartikChoudha1_2-1672343577588.png

 

Assignment Group-

KartikChoudha1_3-1672343666683.png

 

______________________________________________________________________________________

 

I want to understand one point, when I use the same filter with AND condition for TYPE field.

I don't get any records.

KartikChoudha1_4-1672343813511.png

 

Regards,

Kartik Choudhary