mas-rad_core 0.0.76 → 0.0.77
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/firm.rb +12 -1
- data/db/migrate/20150825090822_move_firm_address_to_office.rb +1 -1
- data/lib/mas/rad_core/version.rb +1 -1
- data/spec/dummy/db/schema.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1ce2c832ccb2b7146d8c893c7a7cd9cfd0ab451b
|
4
|
+
data.tar.gz: 0e8f302e984d65ffde86ddf830f1c88972f5804c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4a6c4d7168bd7a8419861846ab8c2e94039d015b798c3ca9f7bdd6d89e5abbbc6ec0073377ec05ef208f05268f5cf520dc55d3ab8c862915756654b5cd916568
|
7
|
+
data.tar.gz: 149e15ca2be11ea3dddf33af11136a598d7f9656d7032b1de29191dedaf14603b0ba45bc97c6ee767e57cf9e2e54a4f03ce30dc2083fe297dec381efa1cd5bae
|
data/app/models/firm.rb
CHANGED
@@ -72,7 +72,11 @@ class Firm < ActiveRecord::Base
|
|
72
72
|
|
73
73
|
validates :minimum_fixed_fee,
|
74
74
|
allow_blank: true,
|
75
|
-
numericality: {
|
75
|
+
numericality: {
|
76
|
+
only_integer: true,
|
77
|
+
greater_than_or_equal_to: 0,
|
78
|
+
less_than: 2147483648 # max value for postgres integer type
|
79
|
+
}
|
76
80
|
|
77
81
|
validates :in_person_advice_methods,
|
78
82
|
presence: true,
|
@@ -149,6 +153,13 @@ class Firm < ActiveRecord::Base
|
|
149
153
|
[
|
150
154
|
:email_address,
|
151
155
|
:telephone_number,
|
156
|
+
:website_address,
|
157
|
+
:address_line_one,
|
158
|
+
:address_line_two,
|
159
|
+
:address_town,
|
160
|
+
:address_county,
|
161
|
+
:address_postcode,
|
162
|
+
:primary_advice_method,
|
152
163
|
:in_person_advice_methods,
|
153
164
|
:other_advice_methods,
|
154
165
|
:free_initial_meeting,
|
@@ -6,7 +6,7 @@ class MoveFirmAddressToOffice < ActiveRecord::Migration
|
|
6
6
|
class Office < ActiveRecord::Base; belongs_to :firm; end
|
7
7
|
|
8
8
|
def up
|
9
|
-
Firm.where.not(address_line_one: nil) do |firm|
|
9
|
+
Firm.where.not(address_line_one: nil).each do |firm|
|
10
10
|
next if firm.offices.any?
|
11
11
|
|
12
12
|
firm.offices.create!(
|
data/lib/mas/rad_core/version.rb
CHANGED
data/spec/dummy/db/schema.rb
CHANGED
@@ -99,8 +99,8 @@ ActiveRecord::Schema.define(version: 20150825090822) do
|
|
99
99
|
t.string "website_address"
|
100
100
|
t.boolean "ethical_investing_flag", default: false, null: false
|
101
101
|
t.boolean "sharia_investing_flag", default: false, null: false
|
102
|
-
t.integer "status"
|
103
102
|
t.text "languages", default: [], null: false, array: true
|
103
|
+
t.integer "status"
|
104
104
|
end
|
105
105
|
|
106
106
|
add_index "firms", ["initial_meeting_duration_id"], name: "index_firms_on_initial_meeting_duration_id", using: :btree
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mas-rad_core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.77
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ben Lovell
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-09-
|
11
|
+
date: 2015-09-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|