Class CharactersVocabularyList
In: app/models/characters_vocabulary_list.rb
Parent: ActiveRecord::Base

Methods

Public Instance methods

[Source]

    # File app/models/characters_vocabulary_list.rb, line 15
15:   def character_meanings
16:     character.character_meanings
17:   end

[Source]

    # File app/models/characters_vocabulary_list.rb, line 11
11:   def character_readings
12:     character.character_readings
13:   end

[Source]

   # File app/models/characters_vocabulary_list.rb, line 7
7:   def stroke_count
8:     character.stroke_count
9:   end

[Source]

    # File app/models/characters_vocabulary_list.rb, line 19
19:   def to_label
20:     character.to_label
21:   end

Protected Instance methods

[Source]

    # File app/models/characters_vocabulary_list.rb, line 25
25:   def authorized_for_create?
26:     return Authorize.is_role_allowed_for_user?(current_user, UserRole::USER_ROLE_ADMIN) || is_current_user_member?
27:   end

[Source]

    # File app/models/characters_vocabulary_list.rb, line 33
33:   def authorized_for_destroy?
34:     return Authorize.is_role_allowed_for_user?(current_user, UserRole::USER_ROLE_ADMIN) || is_current_user_member?
35:   end

[Source]

    # File app/models/characters_vocabulary_list.rb, line 37
37:   def authorized_for_read?
38:     return Authorize.is_role_allowed_for_user?(current_user, UserRole::USER_ROLE_USER)
39:   end

[Source]

    # File app/models/characters_vocabulary_list.rb, line 29
29:   def authorized_for_update?
30:     return Authorize.is_role_allowed_for_user?(current_user, UserRole::USER_ROLE_ADMIN) || is_current_user_member?
31:   end

[Validate]