Sha256: 29a3a85e5c24e355cde79a2ed8d3647b84b284ddaf8952b83c7008ea3bc8758b

Contents?: true

Size: 1.32 KB

Versions: 34

Compression:

Stored size: 1.32 KB

Contents

- entity = controller.entity
- if controller.actions.any?
  .action_controller
    %ul.controls

      %li.reload
        %a.reload_action(href="#")
          %i.general.foundicon-refresh

      %li.parameters
        %a(href="#")
          %i.general.foundicon-settings

      %li.pin
        %a(href="#")
          %i.general.foundicon-paper-clip

      %li.url
        %a(href="#")
          %i.general.foundicon-flag

    %ul.actions
      - last_resource = nil
      - controller.actions.each do |action, text, resource, params|
        %li(class="#{last_resource and last_resource != resource ? "new_resource" : ""}" attr-resource="#{resource}")
          - case
          - when AnnotatedArray === entity
            - id = params.delete :id if Hash === params
            - id = controller.id if id.nil?
            = entity.list_action_link action, text, id, params.merge(:reuse => true)
          - when TSV === entity
            - id = params.delete :id if Hash === params
            - id = controller.id if id.nil?
            - type = page_entity_type
            - column = page_entity_map_column
            %a.entity_map_action(href="#{Entity::REST.entity_map_action_url id, type, column, action}")= text 
          - else
            = entity.action_link action, text, params
        - last_resource = resource

  .action_loader

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
rbbt-rest-1.2.13 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.12 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.11 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.10 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.9 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.8 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.7 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.6 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.5 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.4 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.3 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.2 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.1 share/views/entity_partials/action_controller.haml
rbbt-rest-1.2.0 share/views/entity_partials/action_controller.haml