plataformatec/simple_form — Issue #358: attribute_based error_notifications
Author: kenan-memis
Created: 2011-11-01 14:49:18+00:00
State: open

In my Rails app, I have a teacher model. While creating a new teacher there is a collection named program which has a belongs_to association with teacher. But, from out of 3 programs I want only one of them(let say the program with name 'X') be selectable or when someone try to select any other program than X, the simple_form should display an error message. But this should not be the default error_notification message, because it is an attribute-based error.

Am I should change some code on simple_form locale file, or write a custom validation.

Can someone help me about this issue.