Date-String Input angelegt

This commit is contained in:
Andreas Stephanides
2013-08-10 14:27:15 +02:00
parent a6b4501d2d
commit 5f7bad1004
2 changed files with 7 additions and 1 deletions

View File

@@ -0,0 +1,6 @@
class DateStringInput < FormtasticBootstrap::Inputs::StringInput
def input_html_options
super.merge(:class => "datetext", :onclick =>"beep", :value=>I18n.l(@object.send(method.to_sym)))
end
end

View File

@@ -1,6 +1,6 @@
<%= semantic_form_for @calentry do |f| %> <%= semantic_form_for @calentry do |f| %>
<%= f.inputs do %> <%= f.inputs do %>
<%= f.input :start %> <%= f.input :start , :as => :date_string %>
<%= f.input :ende %> <%= f.input :ende %>
<%= f.input :summary %> <%= f.input :summary %>
<%= f.input :calendar, :as=> :radio %> <%= f.input :calendar, :as=> :radio %>