зеркало из
https://github.com/rs-pro/activeadmin-quill_editor.git
synced 2026-09-03 18:25:51 +03:00
chore: update tests config
Этот коммит содержится в:
@@ -23,4 +23,8 @@ class Author < ApplicationRecord
|
||||
def to_s
|
||||
"#{name} (#{age})"
|
||||
end
|
||||
|
||||
def self.ransackable_attributes(auth_object = nil)
|
||||
%w[age created_at email id name updated_at]
|
||||
end
|
||||
end
|
||||
|
||||
@@ -26,4 +26,12 @@ class Post < ApplicationRecord
|
||||
def upper_title
|
||||
title.upcase
|
||||
end
|
||||
|
||||
def self.ransackable_attributes(auth_object = nil)
|
||||
%w[author_id category created_at description dt id position published summary title updated_at]
|
||||
end
|
||||
|
||||
def self.ransackable_associations(auth_object = nil)
|
||||
%w[author author_profile images_attachments images_blobs post_tags tags]
|
||||
end
|
||||
end
|
||||
|
||||
@@ -6,4 +6,8 @@ class PostTag < ApplicationRecord
|
||||
|
||||
validates :post, presence: true
|
||||
validates :tag, presence: true
|
||||
|
||||
def self.ransackable_attributes(auth_object = nil)
|
||||
%w[created_at id post_id tag_id updated_at]
|
||||
end
|
||||
end
|
||||
|
||||
@@ -6,4 +6,8 @@ class Profile < ApplicationRecord
|
||||
def to_s
|
||||
description
|
||||
end
|
||||
|
||||
def self.ransackable_attributes(auth_object = nil)
|
||||
%w[author_id created_at description id updated_at]
|
||||
end
|
||||
end
|
||||
|
||||
7
spec/dummy/config/initializers/active_storage.rb
Обычный файл
7
spec/dummy/config/initializers/active_storage.rb
Обычный файл
@@ -0,0 +1,7 @@
|
||||
ActiveSupport::Reloader.to_prepare do
|
||||
ActiveStorage::Attachment.class_eval do
|
||||
def self.ransackable_attributes(auth_object = nil)
|
||||
%w[blob_id created_at id name record_id record_type]
|
||||
end
|
||||
end
|
||||
end
|
||||
Ссылка в новой задаче
Block a user