Sha256: 81a423667371f96024ae6098d0ce9b482f71863664fe0bf41d1574f4f21fa680

Contents?: true

Size: 404 Bytes

Versions: 8

Compression:

Stored size: 404 Bytes

Contents

module Killbill
  module CurrencyPlugin

    class CurrencyRate < ActiveRecord::Base

      belongs_to :currency_update

      attr_accessible :target_currency,
                      :rate,
                      :currency_update_id

      scope :latest_rates_for_base_currency, ->(currency_update_id) { where("currency_update_id = ?", currency_update_id).order("target_currency ASC") }
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
killbill-currency-plugin-1.2.0 lib/currency_plugin/models/currency_rate.rb
killbill-currency-plugin-1.1.4 lib/currency_plugin/models/currency_rate.rb
killbill-currency-plugin-1.1.3 lib/currency_plugin/models/currency_rate.rb
killbill-currency-plugin-1.1.2 lib/currency_plugin/models/currency_rate.rb
killbill-currency-plugin-1.1.1 lib/currency_plugin/models/currency_rate.rb
killbill-currency-plugin-1.1.0 lib/currency_plugin/models/currency_rate.rb
killbill-currency-plugin-1.0.1 lib/currency_plugin/models/currency_rate.rb
killbill-currency-plugin-1.0.0 lib/currency_plugin/models/currency_rate.rb