upgrade rails and allow blank iens profile

This commit is contained in:
2013-01-13 12:53:45 +01:00
parent f08d19a50b
commit afe7f9d2fc
4 changed files with 58 additions and 62 deletions
+1 -1
View File
@@ -34,7 +34,7 @@ class Supplier
view :by_email, key: :email
validates :name, presence: true
validates :iens_profile, numericality: true
validates :iens_profile, numericality: {allow_blank: true}
def location=(val)
lat, lng = val.strip.split(/[ ,]+/).map(&:to_f)