Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Portlet implementation problem

    Greetings,

    I'm using version 8. I'm using a portalLayout object with portlet objects in it. There's quite a bit of code, so I'm just including a few snippets. I doubt they will be helpful in helping me find the problem. I'm hopeful just describing the symptoms might be enough for you to tell me what I might be doing wrong. I think the problem may be in my implementation.

    I have about 6 portlets inside the portalLayout. The issue is that if I don't include a height attribute for the Portlet, it all works exactly as expected. But the portlets aren't big enough (vertically) to show the listgrid I've got inside them. So I set a height attribute, forcing the portlet to be large enough to show the entire listgrid it contains. When I use the height attribute, that's when I get odd behaviors. The primary behavior is that each of the portlets overlap each other. In other words, the bottom of each portlet is cut off and overlapped by the portlet underneath it. If I remove some of the portlets, then the remaining ones have uneven spacing, no matter how many times I reload the page. They also behave odd when I drag-reposition them. This only happens when I have the height set for the portlet. If I set the PortalLayout to be extremely large (vertically), then I get uneven spacing and odd drag-positioning behaviors.

    Do you have any idea why this might happen?

    Thanks,
    S

    Code:
    isc.Portlet.create({
    	ID:"<%=UserInterface.PORTLET_PRODUCTNEWS %>",title:"Product News",
        numColumns: 1,
        keepInParentRect:true,
        showCloseButton:false,
        layoutAlign:"top",
        canDragResize:true,
        width:800,
        //height:portletHeight,
        items: [
                industrySegmentForm,
                 productNewsList
    	],
    	autoDraw:false
    });
    
    isc.PortalLayout.create({
    	ID:"portalLayout",
        numColumns: 1,
        canResizeColumns:false,
        showColumnMenus:false,
        vertical:true,
        height:"100%",
        width:portletWidth+35,
        defaultLayoutAlign:"left",
        columnBorder:"1px solid black"
    });

    #2
    Not really... overlapping should really only be possible if there's a JavaScript error (which you'd see in the Developer Console), or you've set memberOverlap. The only thing we can suggest is that maybe the portletHeight you're setting is actually some kind of String value or a large negative number, something like that?

    Comment


      #3
      There were no errors in the logs (just warnings), and the height value is indeed a real number. I did however discover the problem. I was inadvertently putting single quotes around the object name when using portalLayout.addPortlet(), instead of just using the object reference:

      Code:
      portalLayout.addPortlet('<%=UserInterface.PORTLET_TOPGAINERS%>',0,1);
      Once I took out the quotes, it worked perfectly.

      Thanks,
      S

      Comment

      Working...
      X