ruby on rails + best_in_place + datatables + haml -


datatables editing example (using best_in_place)

this example shows how create editable tables using datatables.net , best_in_place.

currently datatables.net has example using jeditables jquery plugin.

gemfile:

gem "best_in_place" 

app/assets/javascripts/application.js:

//= require jquery //= require jquery-ui //= require jquery.purr //= require best_in_place 

app/views/schedules/index.html.haml:

%table   - @schedules.each |s|     %tr       %td= best_in_place s, :name :javascript $(document).ready(function() {   /* activating best in place */   jquery(".best_in_place").best_in_place(); }); 

Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -