Sha256: 350de4207725e5b9f2bd4acaeb26cfcfa859686defb8d2f50d96ef375bf2927c

Contents?: true

Size: 721 Bytes

Versions: 13

Compression:

Stored size: 721 Bytes

Contents

= form_tag(account_roles_update_path(@account, :user_id => @account_user.user)) do

  - if current_user.is?(:owner, @account)
    - APP_ROLES['roles'].each do |role|
      %div
        = check_box_tag "roles[]", role, @account_user.is?(role), :id => "#{role}_checkbox"
        = label_tag "#{role}_checkbox", I18n.t("iugu.#{role}")

  - elsif current_user.is?(:admin, @account)
    - APP_ROLES['roles'].each do |role|
      - unless role == APP_ROLES['owner_role'] || role == APP_ROLES['admin_role']
        %div
          = check_box_tag "roles[]", role, @account_user.is?(role), :id => "#{role}_checkbox"
          = label_tag "#{role}_checkbox", I18n.t("iugu.#{role}")
    
  %div
    = submit_tag I18n.t("iugu.save")

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
iugusdk-1.0.0.alpha.21 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.20 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.19 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.18 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.17 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.16 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.14 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.13 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.12 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.11 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.10 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.9 app/views/iugu/account_roles/edit.html.haml
iugusdk-1.0.0.alpha.7 app/views/iugu/account_roles/edit.html.haml