[Seaside] TwitterBootstrap dropdowns and submitting on change

Mariano Martinez Peck marianopeck at gmail.com
Thu Oct 17 14:48:49 UTC 2013


Hi guys,

In my application I have many many places in which I need to submit the
surrounding form once an item has been selected from a list or things like
that. For example, for a "html select", I am relying on #beSubmitOnChange
(which is deprecated....).

I am now using #tbsButtonGroup and #tbsDropdownMenu (they are inside a form
with another html selects) and I want to achieve the same. I added a

onClick: 'submit()';

to the tbsDropdownMenu. The form seems to be submitted, but the callbacks
of my anchors never get called:

Reduced example:

html form: [
html tbsButtonGroup: [
html tbsDropdownButton beDefault;  beExtraSmall; with: [html text: 'Filter
'; tbsCaret].
html tbsDropdownMenu
onClick: 'submit()';
with: [
html tbsDropdownMenuItem: [
html anchor
text: 'Selected';
callback: [self halt. ]. ].
html tbsDropdownMenuItem: [
html anchor
text: 'Unselected';
callback: [self halt. ]. ].
]
]

]

Any ideas?

Thanks

-- 
Mariano
http://marianopeck.wordpress.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20131017/d5aa7eae/attachment.htm


More information about the seaside mailing list