Requirement:
veg pepper
veg bell red yellow pepper
veg bell red pepper
veg bell yellow pepper
Model:
container veg {
tailf:cli-sequence-commands;
tailf:cli-compact-syntax;
container bell {
tailf:cli-flatten-container;
tailf:cli-optional-in-sequence;
leaf red {
tailf:cli-optional-in-sequence;
type empty;
}
leaf yellow {
tailf:cli-optional-in-sequence;
type empty;
}
}
leaf pepper {
tailf:cli-optional-in-sequence;
type empty;
}
}
Problem :
Supports
veg pepper
veg bell red yellow pepper
Due to presence of tailf:cli-flatten-container; it currenlty bell leaf is accepted only when both red & yellow are filled. Not any one.
Console logs:
(config)# veg ?
Possible completions:
bell pepper
config)# veg bell ?
Possible completions:
red yellow
(config)# veg bell red ?
Possible completions:
yellow <cr>
(config)# veg bell red yellow ?
Possible completions:
pepper <cr>
Is there any way to achive the requirement without actually deprecating (remodelling making all nodes inside veg as leaf)