Hello!
Nothing happened when I push button. My full code is (sorry for some
russian symbols):
<ui:composition template="template.xhtml"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:tc="http://myfaces.apache.org/tobago/component"
xmlns:tx="http://myfaces.apache.org/tobago/facelet-extension">
<ui:define name="body">
<tc:panel>
<f:facet name="layout">
<tc:gridLayout border="0" margin="10px" rows="fixed;20px;1*"/>
</f:facet>
<tc:box label="Найти пользователя" id="maBox">
<f:facet name="layout">
<tc:gridLayout/>
</f:facet>
<tx:in label="ФИО" value="#{maSearchForm.cn}"/>
<tx:in label="Таб. номер" value="#{maSearchForm.employeeNumber}">
<f:validateLength maximum="10"/>
</tx:in>
<tx:in label="Отдел" value="#{maSearchForm.ou}"/>
<tx:in label="E-mail" value="#{maSearchForm.mail}"/>
<tc:panel>
<f:facet name="layout">
<tc:gridLayout columns="*;fixed;fixed"/>
</f:facet>
<tc:cell/>
<tc:button label=" Новый пользователь "/>
<tc:button label=" Поиск " action="#{maSearchForm.searchMA}"/>
</tc:panel>
</tc:box>
<tc:cell/>
<tc:sheet id="sheet"
value="#{maSearchForm.mailAccounts}" var="row"
state="#{maSearchForm.sheetState}"
selectable="none"
first="0" rows="10"
showRowRange="left"
showPageRange="right"
columns="1*;1*;1*;1*;1*"
>
<tc:column label="Фио" sortable="false">
<tc:out value="#{row.cn}"/>
</tc:column>
<tc:column label="Таб. номер" sortable="false" align="right">
<tc:out value="#{row.employeeNumber}"/>
</tc:column>
<tc:column label="Отдел" sortable="false">
<tc:out value="#{row.ou}"/>
</tc:column>
<tc:column label="E-mail" sortable="false">
<tc:out value="#{row.mail}"/>
</tc:column>
<tc:column label="Действие" sortable="false">
<tc:button label="Click Here" id="buttonId">
<tc:attribute name="renderedPartially" value="sheetConfigPopup"/>
<f:facet name="popup">
<tc:popup width="400px" height="400px" id="sheetConfigPopup">
<tc:box label="Popup">
<tc:out value="test"/>
</tc:box>
</tc:popup>
</f:facet>
</tc:button> </tc:column>
</tc:sheet>
</tc:panel>
</ui:define>
</ui:composition>
Hi Boris,
inside the <tc:button/> , place the popup related code and u ll be
getting the popup when the button is clicked.
Hope this code snippet helps you
<tc:sheet>
<tc:column label="Click Button" >
<tc:button label="Click Here" id="buttonId">
<tc:attribute name="renderedPartially" value="sheetConfigPopup"/>
<f:facet name="popup">
<tc:popup width="400px" height="400px" id="sheetConfigPopup">
<tc:box label="Popup">
<%-- Your contents goes here --%>
</tc:box>
</tc:popup>
</f:facet>
</tc:attribute>
</tc:button>
</tc:column>
</tc:sheet>
Regards,
Madan
----- Original Message ----
From: Boris Kovalenko <[EMAIL PROTECTED]>
To: MyFaces Discussion <[email protected]>
Sent: Friday, 6 April, 2007 2:16:30 PM
Subject: [Tobago] More popup example
Hello!
How to use tc:popup? I looked into sheet example but can't
understand how to implement with my code. What I wan to do:
I have a sheet where rows are displayed. Each row has a column with
tc:button. I want when user press the button the popup open with edit
form. Thanks in advance.
With respect,
Boris
------------------------------------------------------------------------
Here’s a new way to find what you're looking for - Yahoo! Answers
<http://us.rd.yahoo.com/mail/in/yanswers/*http://in.answers.yahoo.com/>