dolar-bna 1.2.6 → 1.2.6.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3a5ee0e822588ab6a2953797cb21c2e828fd00d2693ef0a597e942c1720abf44
4
- data.tar.gz: f1d44673bcdf075ab1f77c77f7c360055caf65a872e45a8de59e96ee564c227a
3
+ metadata.gz: 1508742d762682e9d193f513eb5d05d4e08ae55fc49f72164afdb146a08787ef
4
+ data.tar.gz: 54c32301dc25df4ce5aba9ef1a4bca0a11135299622856ba39fcf3b5458b4a8c
5
5
  SHA512:
6
- metadata.gz: f0cfb28dcc754e6f79eb97f24e5ddb6aa1b970a03f67c5f6b362c8685b7418ed52348e9694833227e7dab0e44736e03bbe58af4fc7e1386019d881d128355147
7
- data.tar.gz: b3b404f210d48ca266302fab94838fc88358295c9d92604a05381035fd36fffbac2d6a21399c599a5a79fa49e662fc103299772e7880a2746fcec5faa7a0cbc0
6
+ metadata.gz: 970d64eebc0fcdcc326c1a5a8d5001c567c18aff43bdf5ede6490f2ccae127daf1fb55f174c7372f025f3fe8f1cca2070dbc865183cfc62ed3dbd974d21908e7
7
+ data.tar.gz: d307b912ee82f8a08c957e2d30459b1ba78f83fe68a2b10af2ae6c5f80250966606b5ed3c682449f3df2d42991ba1c26b59db04cdfbf2cacfb0beb96d1cb7732
@@ -52,7 +52,7 @@ module Dolar
52
52
  if other_dolar_to_calc
53
53
  dolar_buy_average = ((self.dolar_buy.to_f * first_dolar_multiplier) + (other_dolar_to_calc.dolar_buy.to_f * second_dolar_multiplier)).round(2)
54
54
  dolar_sell_average = ((self.dolar_sell.to_f * first_dolar_multiplier) + (other_dolar_to_calc.dolar_sell.to_f * second_dolar_multiplier)).round(2)
55
- Dolar::Bna::DolarCotization.create(dolar_type: 'Agro', dolar_buy: dolar_buy_average, dolar_sell: dolar_sell_average, date: self.date)
55
+ Dolar::Bna::DolarCotization.where(dolar_type: 'Agro', dolar_buy: dolar_buy_average, dolar_sell: dolar_sell_average, date: self.date).first_or_create
56
56
  end
57
57
  end
58
58
  end
@@ -1,5 +1,5 @@
1
1
  module Dolar
2
2
  module Bna
3
- VERSION = "1.2.6"
3
+ VERSION = "1.2.6.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dolar-bna
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.6
4
+ version: 1.2.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - LITECODE
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-02-29 00:00:00.000000000 Z
11
+ date: 2024-03-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: factory_bot