effective_addresses 1.8.6 → 1.9.0

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: 16c334b39d46959ee4075c80627675a6a65ef8cc7810bfbcd887fc3a6746803a
4
- data.tar.gz: 1dc9024d1f07d0b6d9b0ab998d9433cc5332c554026c47a5bc70c858f4532f4b
3
+ metadata.gz: 6e4cebe029705cfa2fc3fac6410655ea554da3bf8fc8357426cc049ea396f2bb
4
+ data.tar.gz: eef2302fd40877ef498480bc5feed15dd95132b2a1418092fac5570abb53d051
5
5
  SHA512:
6
- metadata.gz: 90da29758f3cde3766a4d0000b04e586ba4796e647cfabe3cfd6429dadf21ff87fd05a4a8cc907da22951865dd7e3c45651cbae7661d5ea3677ef5fd849b0ae0
7
- data.tar.gz: 7b36d586e4e89ac1af6a485a4389e347b4f6df9e72a2131541f866d39bb7af24f5343b33f67b6de5cde899b35282fedfa1e738b2a20dbfb5ce1dd4abdaa66b16
6
+ metadata.gz: cf9a8e89489de644ef11dab8bc03d71b5e823d2ccaff796acd748e73addd8c27ff9cc77f60e9be107f3d88b45dff324e3a774b53939f3f401503747eb88829c6
7
+ data.tar.gz: 759f04f06a56c966462a76810a2bd61c9e704326ee076beba956ff7b5ff3188c8044b5d4a362c23f5a17ab0230623184485992d39c1e32b900e627fd937d84b0
@@ -63,8 +63,5 @@ module EffectiveAddressesHelper
63
63
 
64
64
  countries
65
65
  end
66
- alias_method :effective_address_countries_collection, :effective_address_regions_collection
67
- alias_method :region_options_for_simple_form_select, :effective_address_regions_collection
68
-
69
66
  end
70
67
 
@@ -41,7 +41,7 @@
41
41
 
42
42
  .row
43
43
  .col-md-4
44
- = fa.select :country_code, effective_address_countries_collection(),
44
+ = fa.select :country_code, effective_address_regions_collection(),
45
45
  label: 'Country',
46
46
  required: required,
47
47
  disabled: same_as_billing,
@@ -29,7 +29,7 @@
29
29
  :as => (defined?(EffectiveFormInputs) ? :effective_select : :select),
30
30
  :label => 'Country',
31
31
  :prompt => 'Country...',
32
- :collection => region_options_for_select(EffectiveAddresses.country_codes == :all ? Carmen::Country.all : Carmen::Country.all.select{ |c| EffectiveAddresses.country_codes.include?(c.code) rescue true}, fa.object.country_code, :priority => EffectiveAddresses.country_codes_priority),
32
+ :collection => options_for_select(effective_address_regions_collection()),
33
33
  :input_html => { 'data-effective-address-country' => uuid },
34
34
  :input_js => { placeholder: 'Please choose' }
35
35
 
@@ -38,7 +38,7 @@
38
38
  = fa.input :state_code,
39
39
  :as => (defined?(EffectiveFormInputs) ? :effective_select : :select),
40
40
  :label => 'Province / State',
41
- :collection => region_options_for_select(Carmen::Country.coded(fa.object.country_code).subregions, fa.object.state_code),
41
+ :collection => options_for_select(effective_address_regions_collection(Carmen::Country.coded(fa.object.country_code).subregions)),
42
42
  :prompt => 'please select a country',
43
43
  :input_html => { 'data-effective-address-state' => uuid },
44
44
  :input_js => { :placeholder => 'Please choose' }
@@ -41,7 +41,7 @@
41
41
  = fa.input :country_code,
42
42
  as: (defined?(EffectiveFormInputs) ? :effective_select : :select),
43
43
  required: required,
44
- collection: effective_address_countries_collection(),
44
+ collection: effective_address_regions_collection(),
45
45
  input_html: {'data-effective-address-country' => uuid},
46
46
  disabled: shipping_address_same_as_billing,
47
47
  wrapper_html: { style: ('display: none;' if shipping_address_same_as_billing) }
@@ -1 +1 @@
1
- = region_options_for_select(@subregions)
1
+ = options_for_select(effective_address_regions_collection(@subregions))
@@ -1,5 +1,4 @@
1
1
  require 'carmen'
2
- require 'carmen-rails'
3
2
  require 'effective_addresses/engine'
4
3
  require 'effective_addresses/version'
5
4
 
@@ -1,3 +1,3 @@
1
1
  module EffectiveAddresses
2
- VERSION = '1.8.6'.freeze
2
+ VERSION = '1.9.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: effective_addresses
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.6
4
+ version: 1.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Code and Effect
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-31 00:00:00.000000000 Z
11
+ date: 2020-03-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -25,7 +25,7 @@ dependencies:
25
25
  - !ruby/object:Gem::Version
26
26
  version: 3.2.0
27
27
  - !ruby/object:Gem::Dependency
28
- name: carmen-rails
28
+ name: carmen
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - ">="