Tapestry has excellent error reporting ... use it. Don't vaguely tell us
about an exeption, cut and paste it. And tell us exactly what you were
doing and what you expected to happen.
On 5/27/07, Eko S.W. <[EMAIL PROTECTED]> wrote:
Hi all,
I have a problem on using BeanEditForm. I create a page called
SharedCrud<T>, that will do CRUD for a bean. This way, I can make quick
progress on developing prototype of web application.
Using Generic on JDK 5, the result quite good.
For example. To create 3 Crud Page for a bean, I just define this :
// in HomePage.java
SharedCrud<Journal> _sharedJournalCrud;
SharedCrud<Reference> _sharedReferenceCrud;
SharedCrud<Team> _sharedTeamCrud;
IReferenceDao referenceDao;
IJournalDao journalDao;
ITeamDao teamDao;
@OnEvent(component="OnNewReference")
public SharedCrud onNewReference(int id)
{
_sharedReferenceCrud.preparePage(referenceDao, referenceDao.findById
(id));
return _sharedReferenceCrud.
}
// in SharedCrud
T data;
IDao<T> dao;
@OnEvent(component="onSave")
void onSave()
{ // .. kinda
dao.save(data);
}
But the problem is, in HomePage, the link to SharedCrud, if changing Model
(for example if entering Reference, and then switch to entering Journal),
it
will fire error. Some sort like ... "error on reading bean type" (sort
of).
I must click it twice to get it working..
So, what is wrong?
If one would like to see the code completely, I will gladly attach it.
Sorry can't do it right now, I am on public internet cafe here (and don't
bring my Laptop)
Imho, I think BeanEditForm is the most important corner where T5 should
focus on, in order to get a real fast framework (agile) on quick starting
a
web application.
--
Best wishes,
Eko SW
http://swdev.blogs.friendster.com/my_blog/
--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind
Professional Tapestry training, mentoring, support
and project work. http://howardlewisship.com