Rendered tab from component menu

Forum rules
Please note that response time for technical support is within 3-5 business days.
Post Reply
neimar.avila
Posts: 1
Joined: 03 Mar 2015, 20:34

29 Mar 2017, 19:31

If I put a specific tab to not render according to a condition only the menu icon is not rendered and disrupts the rest of the menu operation.

mert.sincan
Posts: 5281
Joined: 29 Jun 2013, 12:38

11 Apr 2017, 09:24

Sorry for my late reply. Fixed for next version; https://github.com/primefaces/barcelona/issues/1

fauzifouad
Posts: 5
Joined: 20 Jan 2017, 05:01

07 May 2017, 12:47

Dear aragorn,

When is the release date of jsf barcelona-1.0.1? Because I also stuck on this issue and in tigh schedule. Or maybe you can suggest any workaround?

regards.

mert.sincan
Posts: 5281
Joined: 29 Jun 2013, 12:38

08 May 2017, 08:55

When is the release date of jsf barcelona-1.0.1?
- We think about releasing it in this month.
maybe you can suggest any workaround
- Please add the following lines into TabMenuRenderer.java

Code: Select all

...

public class TabMenuRenderer extends CoreRenderer {
    
    @Override
    public void encodeEnd(FacesContext context, UIComponent component) throws IOException {
        ...
        
        writer.startElement("div", tabMenu);
        writer.writeAttribute("class", "layout-tabmenu-contents", null);
        for(int i = 0; i < children.size(); i++) {
            Tab tab = (Tab) children.get(i);
            
            if(tab.isRendered()) {                        // ADDED THIS LINE (line 67)
                writer.startElement("div", tabMenu);
                ...
                writer.endElement("div");
            }                                          // ADDED THIS LINE (line 107)
        }
        writer.endElement("div");
        
        writer.endElement("div");
        
        WidgetBuilder wb = getWidgetBuilder(context);
        wb.init("Barcelona", tabMenu.resolveWidgetVar(), clientId).finish();
    }
    
    ...

Post Reply

Return to “Barcelona - PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 3 guests