From 60293014154ecc37bd71618f810a271bfa4ed438 Mon Sep 17 00:00:00 2001 From: echarp Date: Tue, 1 Jul 2014 21:25:48 +0200 Subject: [PATCH] =?UTF-8?q?Une=20liste=20de=20villes=20est=20propos=C3=A9e?= =?UTF-8?q?=20quand=20on=20cr=C3=A9e=20un=20=C3=A9v=C3=A9nement?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/assets/stylesheets/all.css.sass | 1 + app/views/events/_form.html.haml | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/assets/stylesheets/all.css.sass b/app/assets/stylesheets/all.css.sass index f9c385e9..3ab06872 100644 --- a/app/assets/stylesheets/all.css.sass +++ b/app/assets/stylesheets/all.css.sass @@ -125,6 +125,7 @@ main margin: 3px 0 border: 1px solid #868686 font-family: georgia, serif + background-color: white @include border-radius(0.1em) &:focus background-color: #F0F8FF diff --git a/app/views/events/_form.html.haml b/app/views/events/_form.html.haml index 9a7329cc..065ad846 100644 --- a/app/views/events/_form.html.haml +++ b/app/views/events/_form.html.haml @@ -37,7 +37,10 @@ .field = f.label Event.human_attribute_name :city - = f.text_field :city, required: true, size: 70 + = f.text_field :city, required: true, size: 70, list: :cities + %datalist#cities + - City.all.each do |city| + %option= city.name .field = f.label Event.human_attribute_name :related_region = f.select :region,