Class: Panda::Core::FileCategory
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- Panda::Core::FileCategory
- Defined in:
- app/models/panda/core/file_category.rb
Instance Method Summary collapse
-
#all_blob_ids ⇒ Object
Returns all blob IDs for this category and its children.
Instance Method Details
#all_blob_ids ⇒ Object
Returns all blob IDs for this category and its children
26 27 28 29 |
# File 'app/models/panda/core/file_category.rb', line 26 def all_blob_ids category_ids = [id] + children.pluck(:id) Panda::Core::FileCategorization.where(file_category_id: category_ids).pluck(:blob_id) end |