<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'>Mm, this is a lot to look at on my cell phone ;)<br><br>Here's my suggestion for now:<br><br>Simplify what you're doing by making a little test app or something. Say, ok, I want to display different items, but I want an action associated with them, and I want them in a table as rows.<br><br>Write all the rendering methods separate from your data model, so when you're rendering a list of items, you simply call a render method on it, ie:<br><br>#renderItem: anItem on: html<br><br>So, you would end up with:<br><br>items do: [:ea | self renderItem: ea on: html ].<br><br>Yay, so now my items are displayed. My renderItem method has a little checkbox that serializes the object that the row represents to, say, #selectedItems, so now I can do whatever with those.<br><br>Hopefully that's not too oversimplified and helps hehe.<br><br>RS<br><br><hr>From&#58; abalonpe@ulb.ac.be<br>Date&#58; Fri, 3 Dec 2010 19&#58;14&#58;39 +0100<br>Subject&#58; Re&#58; [Seaside] WATableReport Checkbox<br>To&#58; seaside@lists.squeakfoundation.org<br><br>I got the right row when displaying the checkbox but when I click on the checkbox nothing appears in the transcript.<div>The submitButton fails when I add the following line --&gt; bibliTableListExport drawOn&#58; canvas.</div>

<div><br></div><div>bibliTableList is a list of different tables (Articles, Books, Conferences,...)</div><div>Here is what does drawOn&#58;canvas&#58;</div><div><br></div><div><div>drawOn&#58; canvas</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">        </span>biblis size = 0</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                </span>ifFalse&#58; [&nbsp;</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                        </span>self renderBibteXOn&#58; canvas.</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                        </span>bibType = 'All'</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>ifTrue&#58; [&nbsp;</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                        </span>self</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                </span>do&#58; [ &#58;eachTable |&nbsp;</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                        </span>eachTable</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>removeActionColumn;<span class=ecxApple-tab-span style="white-space&#58;pre">        </span></div>

</div><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px">

<blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px">

<div>&nbsp;&nbsp; &nbsp;rows&#58; (biblis select&#58; [ &#58;eachBibli | (eachBibli dico at&#58; 'BibteX Type') data = eachTable &nbsp; &nbsp; &nbsp; bibType ]);</div></blockquote></blockquote></blockquote></blockquote></blockquote></blockquote><div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>addActionColumn;</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>drawOn&#58; canvas ] ]</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>ifFalse&#58; [&nbsp;</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                        </span>(self select&#58; [ &#58;eachTable | eachTable bibType = bibType ])</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                </span>do&#58; [ &#58;eachSelectedTable |&nbsp;</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                        </span>eachSelectedTable</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>removeActionColumn;</div>

</div><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px">

<blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px"><blockquote class=ecxwebkit-indent-blockquote style="border&#58;none;padding&#58;0px">

<div>&nbsp;&nbsp; &nbsp;rows&#58; (biblis select&#58; [ &#58;eachBibli | (eachBibli dico at&#58; 'BibteX Type') data = &nbsp; &nbsp;eachSelectedTable bibType ]);</div></blockquote></blockquote></blockquote></blockquote></blockquote></blockquote><div><div>

<span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>addActionColumn;</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>drawOn&#58; canvas ] ] ].</div><div><br></div><div>For eachTable the method calls another drawOn&#58;canvas which draw the table depending on its type (Article, Book,...)</div>

<div><br></div><div><div>drawOn&#58; canvas</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">        </span></div><div><span class=ecxApple-tab-span style="white-space&#58;pre">        </span>rows size = 0</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                </span>ifFalse&#58; [&nbsp;</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                </span></div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                        </span>(canvas div)</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>class&#58; 'inTitle';</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>with&#58; [&nbsp;</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                        </span>(canvas heading)</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>level&#58; 3;</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                                </span>with&#58; self bibType ].</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                        </span>(canvas div)</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>class&#58; 'bibliTable';</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>with&#58; [ canvas render&#58; super ].</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                        </span>(canvas div)</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>class&#58; 'controlLink';</div>

<div><span class=ecxApple-tab-span style="white-space&#58;pre">                                </span>with&#58; [&nbsp;</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                        </span>self renderOptionalAnchorOn&#58; canvas.</div><div><span class=ecxApple-tab-span style="white-space&#58;pre">                                                        </span>self renderUserAnchorOn&#58; canvas ]]&nbsp;</div>

</div><div><br></div><div>I hope this can clarify the sequence of action.</div><div>Thx very much for your help.</div><div>alex</div><br><div class="ecxgmail_quote">2010/12/3 Robert Sirois <span dir=ltr>&lt;<a href="mailto&#58;watchlala@hotmail.com">watchlala@hotmail.com</a>&gt;</span><br>

<blockquote class="ecxgmail_quote" style="border-left&#58;1px #ccc solid;padding-left&#58;1ex">



<div>Check out what row is in the callback by exploring or using the Transcript.<br><br>You might be losing pointers to the objects somewhere in there.<div class=ecxim><br><br>RS<br><br><hr>From&#58; <a href="mailto&#58;abalonpe@ulb.ac.be">abalonpe@ulb.ac.be</a><br>

</div>Date&#58; Fri, 3 Dec 2010 18&#58;30&#58;27 +0100<br>Subject&#58; Re&#58; [Seaside] WATableReport Checkbox<div><div></div><div class=h5><br>To&#58; <a href="mailto&#58;seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>

<br>I have a submitButton also in the form with an empty callback.<div>I just want the button to trigger all the callbacks of the checkboxes.</div><div>However it doesn't seem to work at all.</div><div><br></div><div>

Alex<br>

<br><div>2010/12/3 Robert Sirois <span dir=ltr>&lt;<a href="mailto&#58;watchlala@hotmail.com">watchlala@hotmail.com</a>&gt;</span><br><blockquote style="border-left&#58;1px #ccc solid;padding-left&#58;1ex">





<div>How are you submitting the data?<br><br>Either they need to be in a form, or if you're serializing via ajax, remember to use #serializeWithHidden I think it's called.<br><br>RS<br><br><hr>From&#58; <a href="mailto&#58;abalonpe@ulb.ac.be">abalonpe@ulb.ac.be</a><br>



Date&#58; Fri, 3 Dec 2010 17&#58;02&#58;02 +0100<br>Subject&#58; Fwd&#58; [Seaside] WATableReport + Checkbox<br>To&#58; <a href="mailto&#58;seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br><br><div>Hi,<div>



<br></div><div>I have a problem with checkboxes. I'm trying to add a checkbox at each line of a table.</div><div>I have tried several things(the last tries are in comments)&#58;&nbsp;</div><div>

<br></div><div><div>addActionColumn</div>
<div><span style="white-space&#58;pre-wrap">        </span></div><div><span style="white-space&#58;pre-wrap">        </span>columns</div><div><span style="white-space&#58;pre-wrap">                </span>add&#58;</div>
<div><span style="white-space&#58;pre-wrap">                        </span>((WAReportColumn new)</div><div><span style="white-space&#58;pre-wrap">                                </span>title&#58; '';</div><div><span style="white-space&#58;pre-wrap">                                </span>valueBlock&#58; [ &#58;row &#58;html |&nbsp;</div>






<div><span style="white-space&#58;pre-wrap">                                                                </span>html span</div><div><span style="white-space&#58;pre-wrap">                                                                        </span>with&#58;[</div></div><blockquote style="border&#58;none;padding&#58;0px">
<blockquote style="border&#58;none;padding&#58;0px"><blockquote style="border&#58;none;padding&#58;0px"><blockquote style="border&#58;none;padding&#58;0px">
<blockquote style="border&#58;none;padding&#58;0px"><blockquote style="border&#58;none;padding&#58;0px"><blockquote style="border&#58;none;padding&#58;0px">
<div><div>&nbsp;&nbsp;&quot;checked ifTrue&#58;[BibliList bibliCollection add&#58; row].&quot;</div></div></blockquote></blockquote></blockquote></blockquote></blockquote></blockquote></blockquote><div><div><span style="white-space&#58;pre-wrap">                                                                        </span>html checkbox</div>






<div><span style="white-space&#58;pre-wrap">                                                                                </span>value&#58; checked;</div><div><span style="white-space&#58;pre-wrap">                                                                                </span>onTrue&#58;[BibliList bibliCollection add&#58; row]</div><div>
<span style="white-space&#58;pre-wrap">                                                                                </span>onFalse&#58;[].</div><div><span style="white-space&#58;pre-wrap">                                                                                </span>&quot;onClick&#58; [checked &#58;= true]&quot;</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&quot;callback&#58;[&#58;value | value ifTrue&#58; [BibliList bibliCollection add&#58; row]]&quot;</div>






<div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;]]).</div></div><div><br></div><div>Unfortunately, nothing seems to work...when I click on the checkbox, nothing happen and my list bibliCollection (which is an OrderedCollection) is still empty.</div>






<div>Thx for your help</div><div>alex</div>
</div><br>
<br>_______________________________________________
seaside mailing list
<a href="mailto&#58;seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a>
<a href="http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a>                                               </div>
<br>_______________________________________________<br>
seaside mailing list<br>
<a href="mailto&#58;seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>
<a href="http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________
seaside mailing list
<a href="mailto&#58;seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a>
<a href="http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a>                                               </div></div></div>
<br>_______________________________________________<br>
seaside mailing list<br>
<a href="mailto&#58;seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>
<a href="http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________
seaside mailing list
seaside@lists.squeakfoundation.org
http&#58;//lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside                                               </body>
</html>