[aida] The greatest thing since sliced bread

Janko Mivšek janko.mivsek at eranova.si
Sat Jan 24 11:36:02 CET 2009


Eli Green pravi:

>> This is a quick idea from my head, maybe not the most elegant, but one
>> of possibilities how to proceed towards the goal to have a fully
>> ajaxified entry to your list.

> I've just had a moment to sit down and take a look at how this is done and from what I'm seeing there's no way to integrate the current action methods into this setup. What I would ideally like is to be able to say this:
> 
> (e addButtonText: 'Add' action #addObject) onClickUpdate: objectList.
> 
> Ideally, what the Ajax handler should do is to still call the normal actionMainAddObject before refreshing the objectList component. If we return "false" in the onClick javascript handler, the page will not actually be submitted normally. It's not a big issue but it would be nice to be able to code this consistently. It has the added benefit of being able to work whether the user's browser supports javascript or not but to be perfectly honest I'm not sure how many lynx/links users I need to worry about.
> 
> Oh, another benefit is that the form data gets posted all at once when the user has finished editing it, saving us the round-trips to and from the server.
> 
> Anyway, not a major complaint, just a suggestion!

Current action methods work nicely and follow MVC faithfully for views
in your Apps. But for standalone ajaxified components, which can be
reusable among different Apps and not only among views on the same App,
well, here we have a problem.

Where to put action methods in this case? To a component itself? To
every App where this component runs?

I have not yet a good answer, every suggestion or thought is therefore
welcome.

Janko


-- 
Janko Mivšek
AIDA/Web
Smalltalk Web Application Server
http://www.aidaweb.si


More information about the Aida mailing list