solidus_bling 3.2.2 → 3.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ae80bd91f11e2d5f6ca3840d7a82084895e6fd0d3ef54854a7e90c2dde0c8e4e
4
- data.tar.gz: 3c4e0f0daf58c61519b7a833b05dc8626245d6fb69c85b5c5f187e255670b7c6
3
+ metadata.gz: a4aa45ed6e6e0de0c843e2909ed2261a4cfa8787a689a786eb893e0f04e458f0
4
+ data.tar.gz: 256d6b46f98c5115cec394e9aaec7f04da4e7ca50350cd9cd19c816142d6a7d7
5
5
  SHA512:
6
- metadata.gz: 0d26c4977d8dcc1e90a6d4aa129a76e37e0a9177d06bd9e43adf0fef839a496845710f75a817effb74d07097fbc5047c20a2a4adc8b75bd2b9e408a2805868b7
7
- data.tar.gz: 7fdb1ba7e8d50d51daa3c72e14c2768e60168847a30fb72953e4e3dee292f0827bdda5988abb0ddbd22465d8d6182b4b8fccab664f10eb2e5191a887d1cd3765
6
+ metadata.gz: 3742f7bbbfaf953267336de35150d59d98cb22f3dd2a17f34c6a26a3341a6df32491d7c8b96cc711a68dfc82cf89b4eb2b8d4327d20aa356268cc65307125c5d
7
+ data.tar.gz: dde195d7b304c01260330591d538e66c7f103a9b91bc1607a3870b907b3c543afdae4346bff680dcf0ebfd1dca9ff47a4e278d26b6ac80e67088eaf6ee4b3ebf
@@ -7,7 +7,7 @@ module SolidusBling
7
7
  def send
8
8
  @account = SolidusBling::Account.first
9
9
  @account.check_token
10
- BlingApi.configuration.access_token = @account.access_token
10
+ BlingApi.configure { |config| config.access_token = @account.access_token }
11
11
 
12
12
  contato = costumer
13
13
  items = products
@@ -17,6 +17,8 @@ module SolidusBling
17
17
 
18
18
  bling_order = BlingApi::Order.new(
19
19
  id_contato: contato.id,
20
+ pessoa_juridica: @order.tax_id.length > 14,
21
+ numero_documento: @order.tax_id,
20
22
  items: items,
21
23
  parcelas: parcelas,
22
24
  numero_loja: @order.number,
@@ -10,19 +10,10 @@ module SolidusBling
10
10
  true
11
11
  end
12
12
 
13
- def copy_initializer
14
- template "initializer.rb", "config/initializers/solidus_bling.rb"
15
- end
16
-
17
13
  def add_migrations
18
14
  run "bin/rails railties:install:migrations FROM=solidus_bling"
19
15
  end
20
16
 
21
- def install_bling_api
22
- puts 'Installing bling_api gem...'
23
- run 'bin/rails g bling_api:install'
24
- end
25
-
26
17
  def run_migrations
27
18
  run_migrations = options[:auto_run_migrations] || ["", "y", "Y"].include?(ask("Would you like to run the migrations now? [Y/n]")) # rubocop:disable Layout/LineLength
28
19
  if run_migrations
@@ -1,6 +1,2 @@
1
- # frozen_string_literal: true
2
-
3
1
  SolidusBling.configure do |config|
4
- # TODO: Remember to change this with the actual preferences you have implemented!
5
- # config.sample_preference = 'sample_value'
6
2
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SolidusBling
4
- VERSION = "3.2.2"
4
+ VERSION = "3.2.4"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solidus_bling
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.2
4
+ version: 3.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hamilton Tumenas Borges
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-12-07 00:00:00.000000000 Z
11
+ date: 2024-01-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: solidus_core
@@ -172,7 +172,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
172
172
  - !ruby/object:Gem::Version
173
173
  version: '0'
174
174
  requirements: []
175
- rubygems_version: 3.4.20
175
+ rubygems_version: 3.4.10
176
176
  signing_key:
177
177
  specification_version: 4
178
178
  summary: Solidus extension to integrate with the Bling