activerecord_sqlserver_crm 4.2.12 → 4.2.13
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/config/initializers/extensions.rb +1 -0
- data/lib/active_record_extension.rb +2 -5
- data/lib/activerecord_sqlserver_crm/version.rb +1 -1
- data/lib/odata/operation.rb +3 -3
- data/lib/odata_config.rb +7 -0
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a4dba663e872c9ef4153973c83178423c2250520
|
4
|
+
data.tar.gz: 835916f3da928a34f7882e175d90f2969a8e29cd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5e41196b0dbfead53bfb93059479d1f140909b8dadbf7dcf856ec128e4254c96fe916b1a87cb15aee4e944cc5c57c83665e06d72ac2c0b9a0fb670a77867eb95
|
7
|
+
data.tar.gz: e8ff7d012eaa019fe1e128b55a40895dd89ce4c7046239cbc05c948c8eae8994cc8ffc6012df66866e7950626bf5346cdcaf9ec6f3fc5c6c8d1fec0dc836eae8
|
@@ -1,4 +1,5 @@
|
|
1
1
|
require 'odata/model'
|
2
|
+
require 'odata_config'
|
2
3
|
|
3
4
|
module ActiveRecordExtension
|
4
5
|
|
@@ -112,12 +113,8 @@ module ActiveRecordExtension
|
|
112
113
|
end
|
113
114
|
end
|
114
115
|
|
115
|
-
def odata_config
|
116
|
-
@odata_config ||= YAML.load_file(Rails.root.join('config', 'odata.yml'))
|
117
|
-
end
|
118
|
-
|
119
116
|
# You can switch OData off by setting param: 'odata_enabled' to false
|
120
|
-
unless odata_config[Rails.env]['odata_enabled'] == false
|
117
|
+
unless OdataConfig.odata_config[Rails.env]['odata_enabled'] == false
|
121
118
|
# include the extension
|
122
119
|
ActiveRecord::Base.send(:include, ActiveRecordExtension)
|
123
120
|
|
data/lib/odata/operation.rb
CHANGED
@@ -10,7 +10,7 @@ module OData
|
|
10
10
|
end
|
11
11
|
|
12
12
|
def base_url
|
13
|
-
|
13
|
+
OdataConfig.odata_config[Rails.env]['data_url']
|
14
14
|
end
|
15
15
|
|
16
16
|
def check_response_errors(response)
|
@@ -79,7 +79,7 @@ module OData
|
|
79
79
|
end
|
80
80
|
|
81
81
|
def operation_password
|
82
|
-
|
82
|
+
OdataConfig.odata_config[Rails.env]['password']
|
83
83
|
end
|
84
84
|
|
85
85
|
def operation_url
|
@@ -87,7 +87,7 @@ module OData
|
|
87
87
|
end
|
88
88
|
|
89
89
|
def operation_username
|
90
|
-
|
90
|
+
OdataConfig.odata_config[Rails.env]['username']
|
91
91
|
end
|
92
92
|
|
93
93
|
def table_pluralize(name)
|
data/lib/odata_config.rb
ADDED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord_sqlserver_crm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.2.
|
4
|
+
version: 4.2.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rolf Lawrenz
|
@@ -163,6 +163,7 @@ files:
|
|
163
163
|
- lib/odata/model.rb
|
164
164
|
- lib/odata/operation.rb
|
165
165
|
- lib/odata/update_operation.rb
|
166
|
+
- lib/odata_config.rb
|
166
167
|
- lib/sql_server_adapter.rb
|
167
168
|
- lib/tasks/activerecord_sqlserver_crm_tasks.rake
|
168
169
|
homepage: https://github.com/RolfLawrenz/activerecord_sqlserver_crm
|