Here is another template for JAG.
It is for Tomcat5/Struts1.2/Hibernate3
Few words about this template:
This is simplified version of standard jag template even
though it is compleately refactored. As it does not
provide EJB functionality - service layer has been
removed compleately.
Also it does not use session beans.
For each entity bean it generates everything is needed
for application: Hibernate mapping (generated with jag
template - not with doclets), entity classes, Struts forms
and actions, JSP pages and all necessary configuration
files.
It takes into account only two paths: Hibernate dir and
JSP dir;
It uses only log4j (does not matter what you select).
Initialy project shows all debug information - edit
log4j.properties to your needs.
It does not use library checkout functionality provided
with JAG - honestly - i haven't got clear picture how it
works. So all necessary jars are included into template.
It allows to create composite primary keys, but to
handle it in you have to replace displaytag-1.0.jar with
displaytag-2.0.jar which can be downloaded from
http://jira.codehaus.org/browse/DISPL-120 . This version
is patched so that it accepts multiple id values.
In web.xml filter from displaytag is commented out and
export features in displaytag does not work. It is done
because it ruins UTF-8 encoding - even though this bug
in displaytag marked as solved - it did not work for me. If
anyone has any ideas how to fix it - you are welcome.
In validator-rules.xml files it is included new validation
method - dateTime - it allows to validate date and time.
IMPORTANT: after generation of the application
validation.xml must be edited: in field declaration
followed by comment 'TODO: !!! remove REQUIRED
dependency manualy' you must remove validation
dependency 'reuired '. I haven't found a way how to do it
in JAG template. These forms are used for filtering
records. DO NOT DELETE 'reuired ' in other fields not
marked with comment.
Instalation is simple - just unzip it to
JAG_HOME/templates directory.
Then in JAG Application/Configuration/Select generation
template and you are ready to go.
Any comments and fixes are welcome at email:
an@systemtier.com
Best regards,
Aleksandras Novikovas
Logged In: YES
user_id=1263985
Sorry guys - file do not go in.
Maybe beacause it is too big ~ 6 MB.
Is there any other way to upload this file ?
Logged In: YES
user_id=1263985
Another try - now with jars removed.
here is list of jars which must be in
hibernate3_struts12_tomcat5/src/web/WEB-INF/lib/
antlr-2.7.4.jar
cglib-full-2.0.2.jar
commons-beanutils.jar
commons-collections-3.1.jar
commons-digester.jar
commons-fileupload-1.0.jar
commons-lang-2.0.jar
commons-logging.jar
commons-validator-1.1.4.jar
displaytag-1.0.jar
dom4j-1.4.jar
ehcache-0.9.jar
hibernate3.jar
itext-1.3.jar
jakarta-oro-2.0.8.jar
jsp-api.jar
jta.jar
log4j-1.2.9.jar
servlet-api.jar
struts.jar
I hope - you will be able to download these files from their
original locations.
Regards,
Alius
Logged In: YES
user_id=1263985
Hi,
Here is a bit updated template:
Filter form now has new property: filterOn - so filtering is done
only when this property is set.
dateTime validator now accepts empty string.
Regards,
Alius
Logged In: YES
user_id=1263985
Hi,
Now template saves filter into session - so it remembers filter
settings.
Regards,
Alius
Logged In: YES
user_id=1263985
Hi,
Oops - once you set filter it was not possible to clean it.
Now it is corrected.
Regards,
Alius