[Seaside] Subclass MAReport (in Magritte) to get clickable
(selectable) rows
John Chludzinski
john.chludzinski at gmail.com
Tue Oct 13 21:44:49 UTC 2009
I'm trying to subclass MAReport (in Magritte) to get clickable (selectable)
rows. I modified #renderTableBodyOn: in MAReport as shown below but, while
the callback code is surely executed (the #editEvent: method is executed),
nothing appears in the browser.
renderTableBodyOn: html
self visible isEmpty
ifTrue: [...] ifFalse: [
self visible keysAndValuesDo: [ :index :row |
html tableRow
class: (self rowStyleForNumber: index);
onClick: (html scriptaculous evaluator
callback: [ :script | component editEvent: row ];
return: false);
with: [
self visibleColumns do: [ :col |
col
renderCell: row
index: index
on: html ] ] ] ]
where:
editEvent: event
| task |
task := self call: (event descriptionEdit asComponentOn: event)
addValidatedForm.
task ifNotNil: [
self session database save: event.
self refreshReport ]
---John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20091013/bae85efc/attachment.htm
More information about the seaside
mailing list