Sha256: d7e8c988a7fec26b30e4d9c1d2e168e2ba4b2afbe5afffe521e58d5f9df48635

Contents?: true

Size: 486 Bytes

Versions: 3

Compression:

Stored size: 486 Bytes

Contents

# frozen_string_literal: true

class SolidusAdmin::Roles::New::Component < SolidusAdmin::BaseComponent
  include SolidusAdmin::PermissionSetsHelper

  def initialize(page:, role:)
    @page = page
    @role = role
  end

  def form_id
    dom_id(@role, "#{stimulus_id}_new_role_form")
  end

  private

  def permission_set_options
    @permission_set_options ||= organize_permissions(permission_sets: Spree::PermissionSet.all, view_label: t(".view"), edit_label: t(".edit"))
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
solidus_admin-0.3.2 app/components/solidus_admin/roles/new/component.rb
solidus_admin-0.3.1 app/components/solidus_admin/roles/new/component.rb
solidus_admin-0.3.0 app/components/solidus_admin/roles/new/component.rb