This project is archived and is in readonly mode.
Adding Proc support on validation messages
Reported by Kieran P | November 27th, 2009 @ 01:29 AM
Things like I18n.t and Time.now in the models within validation messages get cached on application load. Support proc helps things a bit.
Patch attached for 2-3-stable.
Comments and changes to this ticket
-
Kieran P January 11th, 2010 @ 08:39 PM
- Tag changed from message, proc, validations to bug, bugmash, message, proc, validations
-
Lenary January 17th, 2010 @ 11:25 AM
- Tag changed from bug, bugmash, message, proc, validations to bug, bugmash, message, patch, proc, validations
I think the following patch should apply to rails 3, on top of commit afd0c06dfa
I have altered the message to put more emphasis on the fact that this makes it dynamic, rather than allows us to use I18n, as now I18n is possible using activemodel validations.
-
José Valim January 17th, 2010 @ 01:12 PM
- State changed from new to open
- Assigned user set to José Valim
-
Repository January 17th, 2010 @ 01:56 PM
(from [31ea83eb898786f853bd7ce7075986fa120f949d]) Adding Proc support to validation messages so that they can become a little more dynamic, allowing for customisations during the request [#3514 status:resolved].
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/31ea83eb898786f853bd7ce7075986... -
José Valim January 17th, 2010 @ 01:59 PM
- State changed from open to committed
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>
People watching this ticket
Attachments
Referenced by
- 3514 Adding Proc support on validation messages (from [31ea83eb898786f853bd7ce7075986fa120f949d]) Adding ...