DEV Community

Discussion on: Angular Architecture: How to use Command Pattern to manage large amount of context menu actions

Collapse
 
diegotesch profile image
Diego Tesch Gramelich

Hello Maciej Sawicki.
I really liked the post and I'm implemented in a project with some adaptations to use primeng and when I thought everything was fine I came across a problem.
The menu actions are being created correctly and displayed according to the condition entered.
Just to contextualize:
I have 3 Items on my list.
each may have 1 to 3 shares;
the menu items are being displayed according to the last item.
so if the first had 1st and the 2nd had 1 action each and the 3rd 3, all context menus display according to the last item in the list.
Could you help me with this lose use.

Collapse
 
humberd profile image
Maciej Sawicki

Hey Diego,
I don't think I quite understand the problem. Can you provide some source code and/or gif with the issue?

Collapse
 
diegotesch profile image
Diego Tesch Gramelich

Hello Maciej. thanks for the feedback. but I found where the error was occurring.