Django: Ticket #11367: Use settings instead of defaults for forms.DateField and similars <p> There's already two settings used by the template <tt>date</tt> and <tt>time</tt> filters (<tt>DATE_FORMAT</tt> and <tt>TIME_FORMAT</tt>), used for formatting in similar way as PHP's <tt>date()</tt>. Form fields like Date and Time, OTH, use <tt>strftime()</tt> formatting strings, and have hardcoded defaults. </p> <p> It's common to inherit from those fields just for changing default formats and avoid boilerplate code (e.g, having to set <tt>date_format=</tt> in every form). </p> <p> Those fields could, instead, make use of the DATE_FORMAT and TIME_FORMAT settings as defaults, if those are present. </p> en-us Django Trac 1.0 hcarvalhoalves Wed, 24 Jun 2009 20:09:50 GMT status changed; needs_better_patch, resolution, needs_tests, needs_docs set <ul> <li><strong>status</strong> changed from <em>new</em> to <em>closed</em> </li> <li><strong>needs_better_patch</strong> unset </li> <li><strong>resolution</strong> set to <em>duplicate</em> </li> <li><strong>needs_tests</strong> unset </li> <li><strong>needs_docs</strong> unset </li> </ul> <p> <a class="closed ticket" href="" title="Localized Date/DateTime fields proposal (closed: fixed)">#5526</a> is an even better approach to solve this on a locale-aware way. Might consider discussing this for 1.2? </p> Ticket