Initial work on support for multiple editors

This commit is contained in:
Matt Amos 2010-11-14 12:40:44 +00:00 committed by Tom Hughes
parent 7f955a4aca
commit cd66a5db99
13 changed files with 140 additions and 72 deletions

View file

@ -33,6 +33,7 @@ class User < ActiveRecord::Base
validates_numericality_of :home_lat, :allow_nil => true
validates_numericality_of :home_lon, :allow_nil => true
validates_numericality_of :home_zoom, :only_integer => true, :allow_nil => true
validates_inclusion_of :preferred_editor, :in => Editors::ALL_EDITORS, :allow_nil => true
before_save :encrypt_password