Sha256: 236786f5381da9d39030a87164c603854ceba2bc97cbdbb4953fc32310ca0edc

Contents?: true

Size: 835 Bytes

Versions: 29

Compression:

Stored size: 835 Bytes

Contents

- class_name = ""
- if botao[:campo].present?
  - class_name = presenter.classes_css(botao[:campo], item)
- if botao[:remote].present? and botao[:remote]
  - id_name = "#{item.class.name}_#{item.id}"
  - link = send("#{botao[:link]}_path", item)
  - if !botao[:success].present?
    - botao[:success] = "\'\'"
  - if !botao[:error].present?
    - botao[:error] = "\'\'"
  %a{href:"#", :class => "editar #{class_name}", onclick: "vizirApplication.remoteFunction('#{link}', #{botao[:success]}, #{botao[:error]}, '#{botao[:method]}')", :id => id_name}
    = botao[:nome]

- else
  - link = send("#{botao[:link]}_path", item)
  - if botao[:link] == "historico"
    - class_name = "popup"
    - link = send("#{botao[:link]}_path", "#{item.class.to_s.downcase}_#{item.id}")

  = link_to botao[:nome], link, :class => "editar #{class_name}"

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
carnival-0.0.59 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.58 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.57 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.56 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.55 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.54 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.53 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.52 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.51 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.50 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.49 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.48 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.47 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.45 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.44 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.43 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.42 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.41 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.40 app/views/carnival/shared/_extra_item.html.haml
carnival-0.0.39 app/views/carnival/shared/_extra_item.html.haml