Note that there are some explanatory texts on larger screens.

plurals
  1. POPrimefaces resizable containment
    primarykey
    data
    text
    <p>I am using primefaces resizable in my application. i know if we set containment=true the containment would be the parent of the component. but i want my component to be contained with in the grandparent below is the code :</p> <pre><code> &lt;p:dataTable id="tab" value="#{listOfDays}"&gt; &lt;p:column&gt; &lt;h:outputText value="#{day}"/&gt; //from MON to SUN &lt;/p:column&gt; &lt;p:column&gt; &lt;p:outputPanel id="pnl"&gt; &lt;ui:repeat id="loop" value="somelist"&gt; &lt;p:commandLink id="link"/&gt; &lt;p:resizable for="link" listener="#{calllistener}" containment="true"/&gt; &lt;/ui:repeat&gt; &lt;/p:outputPanel&gt; &lt;/p:column&gt; &lt;/p:dataTable&gt; </code></pre> <p>i want commandlink to be restricted to outputPanel when resized. as i set containment to true it is restricted to ui:repeat as it is the closet parent of the commandlink. so, is there any way that i can restrict the commandlink to the grandparent i.e., outputPanel in this case when commandlink is resized??</p> <p><strong>EDIT</strong> I am able to set the components parent in the backing bean like this </p> <pre><code> public void handleResize(ResizeEvent event){ if(first time) { resizable =(Resizable)(event.getComponenet()); resizable.setParent(event.getParent().getParent()); } sysout(resizable.getClientId()); } </code></pre> <p>i can print the client id of the parent on resize but it is not being contained within the grandparent. any help is greatly appreciated. </p> <p><strong>edit</strong> lemme make it clear what i am trying to achieve. i am trying to create a time scheduler (not the scheduler component in prime faces)</p> <p>in the code, the outputpanel has an image which represents time from 00:00 to 23:59 the outputpanel can have any number of commandLinks thus ui:repeat. commandlink represent time interval say for instance from 12:00 to 20:00 and we can also change the time interval thus resizable. i dont want the timeinterval(commandlink) to go out of outputPanel.</p> <p>thanks in advance :)</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload