I have a navmenu component as under:
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown"><span class='glyphicon glyphicon-wrench'></span> Configuration<span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li class="dropdown-header">Options</li>
<li [routerLinkActive]="['link-active']">
<a [routerLink]="['config']" [queryParams]="{optionFilter: 'LOB' }">
<span class='glyphicon glyphicon-arrow-right'></span> Line of Business
</a>
</li>
<li [routerLinkActive]="['link-active']">
<a [routerLink]="['config']" [queryParams]="{optionFilter: 'RG' }">
<span class='glyphicon glyphicon-arrow-right'></span> Report Groups
</a>
</li>
</ul>
</li>
There are dropdown menus under Configuration. All menus lead to the same component 'config'. However, based on the routerLink selected I need to write logic. How can I pass the param 'Line of Business', or 'Report Group' to the config component and retrieve in ngOnInit?