Sha256: 62b08074e0c766d304ccc28d9654a6dbe636e1a50941df86a38a3d465f92347b
Contents?: true
Size: 1.82 KB
Versions: 1
Compression:
Stored size: 1.82 KB
Contents
<div class="form_container callback_simple_form"> <%= form_for :cmessage, :url => '/callback_message_simple', :remote => true, html: { :role => :form, :id => 'form_callback_simple', :data => { :model => 'cmessage' } } do |f| %> <div class="form-group"> <%= f.text_field :name, :class => 'form-control', :maxlength => 30, :placeholder => 'Ваше имя' %> </div> <div class="form-group"> <%= f.text_field :mobile, :class => 'form-control', :maxlength => 30, :placeholder => 'Номер телефона' %> </div> <div class="form-group kapcha"> <%= f.label :kapcha, "Капча: сколько будет 2+2?", class: 'control-label' %><br /> <%= f.text_field :kapcha, class: 'form-control' %> </div> <div class="actions"> <%= f.submit 'Перезвоните мне', class: 'btn_blue', data: { disable_with: 'Отправляется...' } %> </div> <% end %> <script> $(document).ready(function(){ var $form = $("form#form_callback_simple"); $form.bind("ajax:error",function(event, data, status, xhr){ console.log('!'); $form.render_form_errors( $.parseJSON(data.responseText) ); }); $form.modal_success(); $form.find("input").each(function() { $(this).blur(); }) }); </script> </div>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
c80_callback-0.1.0.2 | app/views/c80_callback/shared/_callback_simple_form.html.erb |