Sha256: a202c3ef0e3afa6417ed26865796f7334b0cd3f849fd58fa3850988ae1cda512

Contents?: true

Size: 1.02 KB

Versions: 14

Compression:

Stored size: 1.02 KB

Contents

# frozen_string_literal: true

# generado con pg_rails

module Tenant
  class UserAccountsController < PgEngine::TenantController
    include PgEngine::Resource

    self.clase_modelo = UserAccount
    self.skip_default_breadcrumb = true

    before_action do
      @sidebar = false
      unless modal_targeted? || frame_embedded?
        add_breadcrumb Account.nombre_plural, ->(h) { h.users_accounts_path(tid: nil) }
        add_breadcrumb ActsAsTenant.current_tenant, users_account_path(Current.account, tid: nil)
      end
      unless modal_targeted?
        add_breadcrumb UserAccount.nombre_plural, tenant_user_accounts_path
      end
    end

    def default_sort
      'id asc'
    end

    private

    def atributos_permitidos
      [
        :membership_status, { profiles: [] }
      ]
    end

    def atributos_para_buscar
      []
    end

    def atributos_para_listar
      if Current.user_account_owner?
        %i[user user_email_f profiles_f estado_f]
      else
        %i[user user_email_f]
      end
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
pg_rails-7.6.28 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.27 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.26 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.25 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.24 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.24.pre.5 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.24.pre.4 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.24.pre.3 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.23 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.22 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.22.pre.3 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.22.pre.2 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.22.pre.1 pg_engine/app/controllers/tenant/user_accounts_controller.rb
pg_rails-7.6.21 pg_engine/app/controllers/tenant/user_accounts_controller.rb