You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

14 lines
379 B

  1. # frozen_string_literal: true
  2. class Import < ApplicationRecord
  3. self.inheritance_column = false
  4. enum type: [:following, :blocking]
  5. belongs_to :account
  6. FILE_TYPES = ['text/plain', 'text/csv'].freeze
  7. has_attached_file :data, url: '/system/:hash.:extension', hash_secret: ENV['PAPERCLIP_SECRET']
  8. validates_attachment_content_type :data, content_type: FILE_TYPES
  9. end