Sha256: 5f8504fec012e2d0d72ceb14619bf46585023071ed5c03d86b440fece880e9c9

Contents?: true

Size: 646 Bytes

Versions: 19

Compression:

Stored size: 646 Bytes

Contents

module RestFtpDaemon
  module API
    module Entities

      class JobPresenter < Grape::Entity
        # Job ID
        expose :id

        # Job specific attributes and flags
        Job::FIELDS.each { |name| expose name }

        # Technical fields
        expose :wid, unless: lambda { |object, options| object.wid.nil? }

        expose :error
        expose :status
        expose :queued_at
        expose :updated_at
        expose :started_at
        expose :finished_at

        # Computed fields
        expose :age
        expose :exectime

        # Params
        expose :params, unless: :hide_params

      end

    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
rest-ftp-daemon-0.221.2 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.221.1 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.221 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.220.4 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.220.3 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.220.1 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.220.0 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.214.0 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.213.0 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.212.0 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.210.2 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.210.1 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.210.0 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.202.2 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.202.1 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.202 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.200 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.104.5 lib/rest-ftp-daemon/api/job_presenter.rb
rest-ftp-daemon-0.103.1 lib/rest-ftp-daemon/api/job_presenter.rb