Class: PageDecorator
- Inherits:
-
Draper::Decorator
- Object
- Draper::Decorator
- PageDecorator
- Defined in:
- app/decorators/page_decorator.rb
Instance Method Summary collapse
Instance Method Details
#link_to_editar ⇒ Object
14 15 16 17 18 19 20 21 22 |
# File 'app/decorators/page_decorator.rb', line 14 def link_to_editar h.link_to h.edit_page_path(id: self.permalink), :class => 'tn btn-warning btn-sm', :title => "Alterar", :style => "color: #FFF; float: none;" do h.content_tag :span, class: 'fa fa-pencil' do end end end |
#link_to_excluir ⇒ Object
24 25 26 27 28 29 30 31 32 33 34 |
# File 'app/decorators/page_decorator.rb', line 24 def link_to_excluir h.link_to h.page_path(id: self.permalink), :method => 'delete', :class => 'tn btn-danger btn-sm', :title => "Excluir", :confirm => 'Deseja realmente excluir o registro?', :style => "color: #FFF; float: none;" do h.content_tag :span, class: 'fa fa-trash-o' do end end end |
#link_to_visualizar ⇒ Object
4 5 6 7 8 9 10 11 12 |
# File 'app/decorators/page_decorator.rb', line 4 def link_to_visualizar h.link_to h.page_path(id: self.permalink), :class => 'tn btn-info btn-sm', :title => "Visualizar", :style => "color: #FFF; float: none;" do h.content_tag :span, class: 'fa fa-search' do end end end |