Class: Document

Inherits:
ApplicationRecord
  • Object
show all
Defined in:
api/app/models/document.rb

Overview

Used to wrap export jobs. The serializer also includes a fully qualified download_url, which will return the file when status is completed.

  • [Integer] owner_id, null: false
  • [Integer] status, default: 0, null: false
    • pending - not worked
    • building - we have begun the export
    • completed - success! The file should now be available at the download_url
  • [String] key, null: false
  • [String] document_file_name
  • [String] document_content_type
  • [Integer] document_file_size
  • [DateTime] document_updated_at
  • [Json] data
  • [DateTime] created_at
  • [DateTime] updated_at
  • [String] owner_type, default: User, null: false

Class Method Summary collapse

Class Method Details

.search(term) ⇒ Object