haul 2002/10/18 08:59:08 Modified: src/java/org/apache/cocoon/components/modules/input DateInputModule.java Log: Use configuration data obtained on module declaration. Revision Changes Path 1.4 +6 -3 xml-cocoon2/src/java/org/apache/cocoon/components/modules/input/DateInputModule.java Index: DateInputModule.java =================================================================== RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/components/modules/input/DateInputModule.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- DateInputModule.java 11 Aug 2002 18:17:15 -0000 1.3 +++ DateInputModule.java 18 Oct 2002 15:59:08 -0000 1.4 @@ -66,7 +66,7 @@ /** * DateInputModule returns current date, optionally formated as * string. Format given through attribute "format" of configuration - * root node. + * root node or nested <format/> tag on module declaration. * * @author <a href="mailto:haul@;apache.org">Christian Haul</a> * @version CVS $Id$ @@ -78,7 +78,10 @@ public Object getAttribute( String name, Configuration modeConf, Map objectModel ) throws ConfigurationException { - String format = (modeConf != null? modeConf.getAttribute("format",null) : null); + String format = (modeConf != null? + modeConf.getAttribute("format", (String) this.settings.get("format",null)) + : + (String) this.settings.get("format",null)); if (format==null) { return new Date();
---------------------------------------------------------------------- In case of troubles, e-mail: [EMAIL PROTECTED] To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]