[Seaside] Update table row with ajax

dtrussardi at tiscali.it dtrussardi at tiscali.it
Wed Mar 19 17:46:59 UTC 2014


Hi,

	i have a table with some rows.

	Any row is composed by some table data with some anchor , input field ecc....

	Now my objective is to update the specific table row when the user click and change some relative data.

	For example i have a table row with a  table data defined as:

	html tableData:[ 
 		html anchor 			
			onClick: ( (html jQuery ajax script: [ :script |
						script add: ((( script jQuery: 'tr' ) last )
							 html:[ :renderer |
								self renderDataBaseTableDataFor: anItem value: aValue  on: renderer ])])]


	With this code the last table row is right update when i click the anchor.


	But when specific the table row index 	with: 

	html tableData:[ 
 		html anchor 			
			onClick: ( (html jQuery ajax script: [ :script |
						script add: ((( script jQuery: 'tr' ) at: index )
							 html:[ :renderer |
								self renderDataBaseTableDataFor: anItem value: aValue  on: renderer ])])]


	the browser report an	 ajax jq error   as management  by my code:

	 html document addLoadScript: (html jQuery ajaxSetup
       		 onError: ( html javascript
          					alert: 'The session erase a jq error.';
								refresh ))

	
	What i wrong ?  Because the	 at: index   generate the error?

	Anyone have some idea how i can manage the ajax row updating ?

	Thanks for any consideration.

	Dario


	
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20140319/bbb128d2/attachment.htm


More information about the seaside mailing list