mongoid_money_field 5.1.0 → 5.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +3 -3
- data/gemfiles/money6-mongoid31.gemfile +0 -1
- data/gemfiles/money6-mongoid4.gemfile +0 -1
- data/lib/mongoid_money_field/rails_admin.rb +16 -8
- data/lib/mongoid_money_field/version.rb +1 -1
- metadata +2 -4
- data/gemfiles/money51-mongoid31.gemfile +0 -6
- data/gemfiles/money51-mongoid4.gemfile +0 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 24b9899833c2b5c8039757b9cee3964333e3883a
|
4
|
+
data.tar.gz: e6350015be4ed57d7a5e9e5d052fc6ad0f83ed29
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0dd93ee6e9400cb2322a3273c2a7a1d55a1aab5828d08825c521c910d75245ef01b1cef6a3a4a5b1fef0930e28343677237b04bc3b7226b261e4ec19bb821b81
|
7
|
+
data.tar.gz: d3a185d812fa39e31740faeffd10530630502541969be1d0accee20d2fe8c376184e95c286a5f4237baae653c1666c9d927997a148f7609ef3cb4dc94726ccd2
|
data/.travis.yml
CHANGED
@@ -1,19 +1,28 @@
|
|
1
1
|
require 'rails_admin/adapters/mongoid'
|
2
|
-
|
2
|
+
begin
|
3
|
+
require 'rails_admin/adapters/mongoid/property'
|
4
|
+
rescue Exception => e
|
5
|
+
end
|
6
|
+
|
3
7
|
module RailsAdmin
|
4
8
|
module Adapters
|
5
9
|
module Mongoid
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
10
|
+
class Property
|
11
|
+
alias_method :type_without_money_field, :type
|
12
|
+
def type
|
13
|
+
if property.type.to_s == 'Money' || property.type.class.name == 'MoneyType'
|
14
|
+
:money_field
|
15
|
+
else
|
16
|
+
type_without_money_field
|
17
|
+
end
|
12
18
|
end
|
13
19
|
end
|
14
20
|
end
|
15
21
|
end
|
22
|
+
end
|
16
23
|
|
24
|
+
require 'rails_admin/config/fields/types/string'
|
25
|
+
module RailsAdmin
|
17
26
|
module Config
|
18
27
|
module Fields
|
19
28
|
module Types
|
@@ -39,4 +48,3 @@ module RailsAdmin
|
|
39
48
|
end
|
40
49
|
end
|
41
50
|
end
|
42
|
-
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mongoid_money_field
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.
|
4
|
+
version: 5.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gleb Tv
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-04-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mongoid
|
@@ -168,8 +168,6 @@ files:
|
|
168
168
|
- LICENSE.txt
|
169
169
|
- README.rdoc
|
170
170
|
- Rakefile
|
171
|
-
- gemfiles/money51-mongoid31.gemfile
|
172
|
-
- gemfiles/money51-mongoid4.gemfile
|
173
171
|
- gemfiles/money6-mongoid31.gemfile
|
174
172
|
- gemfiles/money6-mongoid4.gemfile
|
175
173
|
- lib/mongoid_money_field.rb
|