![]() ![]()
#Track active tab primefaces tabview code#Notice that this code uses properties from managed beans we registered in the faces-config.xml, in order to display content in dynamic tabs. You can use the same template, or adjust him to your needs, but this part of the code must be present. The page is based on /WEB-INF/templates/masterLayout.xhtml template, containing code which allows the application module to be displayed in dynamics tabs: The Single Page and launching the application module via the menu itemĪs you can see, the only facelet page in demo application is a dyntab_master_layout.xhtml. The managed bean class will be the same: dyntabs.DynTab, we will only adjust properties described above. IMPORTANT : in the value, keep DynTab as a sufix, the tool uses this assumption in order to find the managed bean, and launch new tab based on bean properties which we are just talking about.Īnd this is a way: for each menu item in the application, which needs to launch some application module in the new tab (working area), we need to register one managed bean, in the manner described above. - uniqueIdentifier - a value (String, you can choose whatever you want) that uniquely identifies one application module. ![]() - closeable – with this property, we configure whether the tab can be closed or not.- title – will be used for title of the tab.Usually, we place the JSF fragment in the /WEB-INF/ folder of the application, so value for that property will be something like that: /WEB-INF/include/home/home.xhtml #Track active tab primefaces tabview full#Because we are in the Single Page App, it is clear that the content can only be a JSF fragment, ie, part of full JSF page.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |