Hi.

Well, probably I'm missing something.
Here's a simple example. I have a documentDao with the possibility to load document and give back the document list. I want to display a table, where rows correspond to the documents returned by the dao. In every row, I'd like to have a "Load" button to load the corresponding document. With JS in EL it is as easy as #{[documentDao.load(document)]} as a button action.

What would be the easiest way to implement this with standard EL, without JS?

Guess you brought up the classical example of having to fight with the table element, due to el limitations, I worked around that by setting command links and passing parameters down to that, but it is not as compact as having a direct method call.

Right. My idea was to extend data model so that row objects have non-parameterized processAction() methods that will be triggered by the command, quasi #{myRowObject.load}. But in any case, with non-parameterizable method binding you result with a much greater coupling of services, for instance, row objects must be aware of DAOs and so on. I think, this is MUCH worse than "mixing" the controller and presentation logic. Anyway, isn't it already "mixed", when we have #{myObject.myAction}? When we have the possibility to specify action listeners in tags? How much implementing java.util.Map in object to allow #{root.myObject[whatever]} is better than simply calling #{root.getMyObject('whatever')}?
And so on.

I don't think that simple EL helps the simplicity of application.

Bye.
/lexi

Reply via email to