myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zied Hamdi (JIRA)" <>
Subject [jira] Commented: (TOBAGO-424) possibility to have a onclick event on a sheet column
Date Thu, 14 Jun 2007 09:14:27 GMT


Zied Hamdi commented on TOBAGO-424:

I've found a "cross around" solution that still doesn't really match my needs: 

	<tc:column sortable="false">
		<tc:button id="editButton" action="#{personCtrl.edit}" image="image/edit_icon.gif">
			<tc:attribute name="rowIndex" value="#{rowIndexNotAvailable}"/>

The bad things are: 
 - The selection doesn't change when I click a button: I've tried to call onclick="Tobago.clearSelection();"
but that removes any associated action intead of appending it to: onclick="Tobago.submitAction('page:personForm:table:personData:0:editButton',
 - I don't have access to the index used in the javascript call eg. personData:0:editButton,
so I can't send my self an attribute with the row index (where the button was pressed)

> possibility to have a onclick event on a sheet column
> -----------------------------------------------------
>                 Key: TOBAGO-424
>                 URL:
>             Project: MyFaces Tobago
>          Issue Type: Improvement
>    Affects Versions: 1.0.10
>         Environment: not applicable: on checking the generated source I don't have the
text onclick="alert('clicked');"
>            Reporter: Zied Hamdi
>            Priority: Blocker
> I'm trying to react on user clicks in the sheet, I don't have any access to the javascript,
maybe a shorcut solution could be to add an attribute 'onclick' to UIColumn.
> If there's a way to react on row selection I'm sorry for the inconvenience, but seen
that I refer to your demo (I'm new to Tobago) I don't really have another source of information.
Thanks anyway.
> This is the code that doesn't work : <tc:command > doesn't generate any code and
doesn't throw any excpetion
> <tc:sheet id="personData" value="#{personCtrl.current.beanList}"
> 	var="currentPerson" state="#{personCtrl.sheetState}" showHeader="true"
> 	columns="1*;4*;4*;3*;6*;18*" showPageRange="center" showRowRange="right">
> 	<tc:column sortable="false">
> 		<tc:command onclick="alert('clicked');">
> 			<tc:image value="image/edit_icon.gif" border="0"
> 				alt="#{i18n.element_select}" height="16" width="12" />
> 			<f:param name="selectedRowIndex" value="#{rowIndex}" />
> 		</tc:command>
> 	</tc:column>
> ...

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message