Sha256: fb69f29234adbc02b98514f7f1f943ef75dad8efeffe7111ad8194bd97bf1047

Contents?: true

Size: 324 Bytes

Versions: 5

Compression:

Stored size: 324 Bytes

Contents

# frozen_string_literal: true

require 'csv'

class Db
  def fetch_cmdb_assets
    fetch_view('utr_asset_view') do |row|
      CmdbAsset.from_csv(row)
    end
  end

  def fetch_out_of_vm_scope_asset_ids
    ids = []
    fetch_view('asset_out_of_vm_scope_view') do |row|
      ids << row[:id].to_i
    end
    ids
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
avs-0.1.3 lib/domain/asset/db.rb
avs-0.1.2 lib/domain/asset/db.rb
avs-0.1.1 lib/domain/asset/db.rb
avs-0.1.0 lib/domain/asset/db.rb
avs-0.0.9 lib/domain/asset/db.rb