solidus_bling 3.1.1 → 3.2.1

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: d36d88a6fcf16e213530123368d8b5c5fc321abb205febe6359ae2c6b01a95ad
4
- data.tar.gz: c21379540afe76b1da77f06b047969b1d77ccefdf8869c4239bd6f9336e42e13
3
+ metadata.gz: 95fd463fb884618048fb434ce521f2eec483f574a2cc5339668120b68799ba5a
4
+ data.tar.gz: 7350781e7dcae39a19c3208a89d99d12c2fd1077c5a8caad559758fed584a430
5
5
  SHA512:
6
- metadata.gz: 7fa4995f1cd64d553f4a48fd4978055595e7967ffcf11853b163fa692f208e54d103ad353763d5744dd82cdc05ebe9fd8f1512b4386fbff024169f79fad6533e
7
- data.tar.gz: 2e5abb9964ae48c90be1065dce1d28526d46dbb850396efc0c24586134c1df693a32a5af98a0b2e919b56a29fffec41b83c2d38b8e7bd1185754a187a494a655
6
+ metadata.gz: 6a2543a423de1bd16db4b95b15b2cb28ca2817d1ae8e59cec5fe3eb997dbb1bbe0953ea99ebe66df64d4617395c91eeaea1f58cd14f3716e6a3ae5f55a21624b
7
+ data.tar.gz: d1065bc21e470c2663bc9e2786533569cf5975d97e6520fe787d63c429ce3537543f08e31242d2752cc731bff3853360a826c2db7ef0132ad1607a60de723ffa
@@ -15,7 +15,7 @@ module SolidusBling
15
15
  observacoes_internas = internal_observations
16
16
  transporte = shipment
17
17
 
18
- BlingApi::Order.new(
18
+ bling_order = BlingApi::Order.new(
19
19
  id_contato: contato.id,
20
20
  items: items,
21
21
  parcelas: parcelas,
@@ -31,6 +31,10 @@ module SolidusBling
31
31
  transporte: transporte,
32
32
  id_vendedor: @account.sellers.first.external_id
33
33
  ).create
34
+
35
+ if bling_order
36
+ @order.update(bling_order_id: bling_order.id)
37
+ end
34
38
  end
35
39
 
36
40
  def costumer
@@ -1,8 +1,8 @@
1
1
  <div>
2
2
  <div>
3
- Nome do aplicativo:
4
- <span><%= @bling_account.app_name %></span>
3
+ ID do aplicativo:
4
+ <span><%= @bling_account.id %></span>
5
5
  </div>
6
- <%= link_to "Editar", edit_admin_account_path(@bling_account.id) %>
7
- <%= link_to "Excluir", admin_account_path(@bling_account.id), method: :delete %>
6
+ <%= link_to "Editar", edit_admin_solidus_bling_account_path(@bling_account.id) %>
7
+ <%= link_to "Excluir", admin_solidus_bling_account_path(@bling_account.id), method: :delete %>
8
8
  </div>
@@ -18,6 +18,11 @@ module SolidusBling
18
18
  run "bin/rails railties:install:migrations FROM=solidus_bling"
19
19
  end
20
20
 
21
+ def install_bling_api
22
+ puts 'Installing bling_api gem...'
23
+ run 'bin/rails g bling_api:install'
24
+ end
25
+
21
26
  def run_migrations
22
27
  run_migrations = options[:auto_run_migrations] || ["", "y", "Y"].include?(ask("Would you like to run the migrations now? [Y/n]")) # rubocop:disable Layout/LineLength
23
28
  if run_migrations
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SolidusBling
4
- VERSION = "3.1.1"
4
+ VERSION = "3.2.1"
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.1.1
4
+ version: 3.2.1
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-11-29 00:00:00.000000000 Z
11
+ date: 2023-12-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: solidus_core