How to add same set of cmds both inside and outside the parent command


I have to model the following cli command in yang.

if we do a “l2vpn member ?” say we see 3 options


Now if i enter the identifier i.e. l2vpn member 5, i the below two options


So the problem is the template and group are two options which are both outside and inside identifier. Please help

It is difficult to judge without knowing how your data model looks like.

From what I see, I’m guessing template and group are elements (leafs ?) on the same level as identifier element. When you fill in identifier, then other elements are prompted that can be filled as well .

Please, paste part of the YANG datamodel.