magic_addresses 0.0.39 → 0.0.40

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
  SHA1:
3
- metadata.gz: 830afeda0ac60394e1514d65d94974626070d4a5
4
- data.tar.gz: 6ef4c457f5cbdf71dd7423128a86b939bc5322ab
3
+ metadata.gz: 8735fd4ae4de78e2439288776253de6119c03987
4
+ data.tar.gz: 0ff658497d0649f3304daedc45be6a5f8813bf56
5
5
  SHA512:
6
- metadata.gz: d273b26e2cc604b08b30b9cad7b53336ddf15b1769a6794f81937f7b5b61fcd8ec36ab2c9b0727151ab63c3ccb2fd77701269d8fa35d14af47e2932dc010a8f2
7
- data.tar.gz: 10d141de7ff184e84490ffd9828256ad61739ec13b989b4de707f55857417cafb515377744a468d84b7daec54ab0da521f4a003203543f85148e154a12148efa
6
+ metadata.gz: 05db027c18081cc99d48070336e6e4d128d0d74b9b9dd994b1969c2a8933b88251e77a7ef48430d5fbe626af341561f0eb8f3c040429bd18ad288aeebae12fd3
7
+ data.tar.gz: 5286851a43b31cb85798f64d1630b349bf58ec10ec2f1dab23add2938ec5b3856a532b09cd5747b9a240d512de0376e8ed05d6ef8504cd2d3da3ae0ffa1fb225
@@ -22,8 +22,7 @@ class AddMagicAddresses < ActiveRecord::Migration
22
22
  t.string :street_additional
23
23
  t.integer :zipcode
24
24
 
25
- # => t.string :visibility
26
- t.boolean :default
25
+ t.string :status, default: "new"
27
26
 
28
27
  t.float :longitude
29
28
  t.float :latitude
@@ -34,8 +33,6 @@ class AddMagicAddresses < ActiveRecord::Migration
34
33
  t.references :state
35
34
  t.references :country
36
35
 
37
- t.references :owner, polymorphic: true
38
-
39
36
  t.timestamps null: false
40
37
  end
41
38
 
@@ -44,7 +41,6 @@ class AddMagicAddresses < ActiveRecord::Migration
44
41
  add_index :mgca_addresses, :city_id
45
42
  add_index :mgca_addresses, :state_id
46
43
  add_index :mgca_addresses, :country_id
47
- add_index :mgca_addresses, [:owner_type, :owner_id]
48
44
 
49
45
  # when use postgres earthdistance
50
46
  if MagicAddresses.configuration.earthdistance
@@ -54,6 +50,21 @@ class AddMagicAddresses < ActiveRecord::Migration
54
50
  MagicAddresses::Address.create_translation_table! :street_name => :string
55
51
 
56
52
 
53
+ #############################################################################################################
54
+ ##### Addressibles
55
+ #####
56
+ create_table :mgca_addressibles do |t|
57
+ t.boolean :default # is default address ?
58
+ t.string :name # address name (home | office | ..)
59
+ t.references :owner, polymorphic: true
60
+ t.references :address
61
+ t.timestamps null: false
62
+ end
63
+
64
+ add_index :mgca_addressibles, [:owner_type, :owner_id]
65
+ add_index :mgca_addressibles, :address_id
66
+
67
+
57
68
  #############################################################################################################
58
69
  ##### Country
59
70
  #####
@@ -1,3 +1,3 @@
1
1
  module MagicAddresses
2
- VERSION = "0.0.39"
2
+ VERSION = "0.0.40"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: magic_addresses
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.39
4
+ version: 0.0.40
5
5
  platform: ruby
6
6
  authors:
7
7
  - Torsten Wetzel
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-17 00:00:00.000000000 Z
11
+ date: 2016-05-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -1111,7 +1111,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
1111
1111
  version: '0'
1112
1112
  requirements: []
1113
1113
  rubyforge_project:
1114
- rubygems_version: 2.4.5
1114
+ rubygems_version: 2.5.0
1115
1115
  signing_key:
1116
1116
  specification_version: 4
1117
1117
  summary: A really nice address plugin we offten use.