0
有人可以rails-haml專家翻譯,請問這個haml代碼是如何翻譯成html的? 該頁面源自此url。我爲只在線路1和12感興趣的我已經使用的各種工具,上線CON變頻器則,但似乎沒有工作:(haml到html翻譯
%table.table.table-bordered.table-striped#sortable{:data => {update_url:
sort_admin_things_path}}
%thead
%tr
%th= Title
%th= Description
%th
%tbody
- @things.each do |thing|
# make the <tr>'s draggable by adding the expected '.item' class
# pass the item id into params[:id]
%tr{data: {item_id: "#{thing.id}"}, class: 'item'}
%td= thing.title
%td= thing.description.truncate(20)
%td
= link_to 'show', admin_thing_path(thing), :class => 'btn'
= link_to 'edit', edit_admin_thing_path(thing), :class => 'btn btn-primary'
= link_to 'destroy', admin_thing_path(thing), method: :delete, confirm: "Are you sure?", :class => 'btn btn-danger'
感謝您的回答 – user3172824