eco-helpers 1.3.19 → 1.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -2
- data/eco-helpers.gemspec +1 -1
- data/lib/eco/api/common/version_patches/ecoportal_api.rb +0 -2
- data/lib/eco/api/common/version_patches/ecoportal_api/external_person.rb +0 -4
- data/lib/eco/api/common/version_patches/exception.rb +2 -2
- data/lib/eco/api/organization/presets_reference.json +12 -3
- data/lib/eco/api/organization/presets_values.json +3 -1
- data/lib/eco/data/files/helpers.rb +1 -1
- data/lib/eco/version.rb +1 -1
- metadata +3 -5
- data/lib/eco/api/common/version_patches/ecoportal_api/account_preferences.rb +0 -32
- data/lib/eco/api/common/version_patches/ecoportal_api/base_model.rb +0 -27
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 28d9f5ad6037a8160ea1d39873a0b1c6769be63865267d159dd6fa71ae329d60
|
4
|
+
data.tar.gz: ba968ce7525e5fb289ff5b210f3c79692b05dfc74ae6af6cf8c729640bb1cf4a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a7bda8f0a427b7a93d42230c32226c578b4ae4aab9b2974bf1095d1f77d368faa8c409e41375cf5d378ed4a915b359ce12e74559c7f963a2a9d791a165f3232
|
7
|
+
data.tar.gz: ba9adb7220623345536d5080e658a524daebd914f3c64d94f83652e3d42fbdb240da9a08367ee42dde196adfc2152553b4133bd330d3a007052bba42b156aed5
|
data/CHANGELOG.md
CHANGED
@@ -1,12 +1,15 @@
|
|
1
1
|
# Change Log
|
2
2
|
All notable changes to this project will be documented in this file.
|
3
3
|
|
4
|
-
## [1.
|
4
|
+
## [1.4.0] - 2020-07-xx
|
5
5
|
|
6
6
|
### Added
|
7
7
|
### Changed
|
8
|
+
- change abilities to align with ecoPortal release `1.5.0`
|
9
|
+
- remove some patches on `ecoportal-api`
|
10
|
+
- removed patch method `Ecoportal::API::V1::Person#sync`
|
8
11
|
### Fixed
|
9
|
-
-
|
12
|
+
- `Eco::CSV#parse` and `Eco::CSV#read` should use the proper `:encoding` when it's `bom`
|
10
13
|
|
11
14
|
## [1.3.18] - 2020-07-08
|
12
15
|
|
data/eco-helpers.gemspec
CHANGED
@@ -28,7 +28,7 @@ Gem::Specification.new do |s|
|
|
28
28
|
s.add_development_dependency "yard", "~> 0.9", ">= 0.9.18"
|
29
29
|
s.add_development_dependency "redcarpet", "~> 3.5", ">= 3.5.0"
|
30
30
|
|
31
|
-
s.add_dependency 'ecoportal-api', '~> 0.5', '>= 0.5.
|
31
|
+
s.add_dependency 'ecoportal-api', '~> 0.5', '>= 0.5.9'
|
32
32
|
s.add_dependency 'aws-sdk-s3', '~> 1', '>= 1.64.0'
|
33
33
|
s.add_dependency 'aws-sdk-ses', '~> 1', '>= 1.29.0'
|
34
34
|
s.add_dependency 'dotenv', '~> 2.7', '>= 2.7.0'
|
@@ -1,8 +1,8 @@
|
|
1
1
|
class ::Exception
|
2
2
|
def patch_full_message
|
3
3
|
msg = []
|
4
|
-
msg << "
|
5
|
-
backtrace
|
4
|
+
msg << "#{backtrace.shift} #{message} (#{self.class.to_s})"
|
5
|
+
backtrace.each {|bt| msg << "#{" "*8}from #{bt}"}
|
6
6
|
msg.join("\n")
|
7
7
|
end
|
8
8
|
end
|
@@ -5,6 +5,9 @@
|
|
5
5
|
"reports": "view",
|
6
6
|
"organization": null,
|
7
7
|
"people": null,
|
8
|
+
"person_core": null,
|
9
|
+
"person_account": null,
|
10
|
+
"person_details": null,
|
8
11
|
"pages": "view",
|
9
12
|
"page_editor": null,
|
10
13
|
"registers": "view"
|
@@ -14,7 +17,9 @@
|
|
14
17
|
"data": "view",
|
15
18
|
"reports": "view",
|
16
19
|
"organization": null,
|
17
|
-
"
|
20
|
+
"person_core": "attach",
|
21
|
+
"person_account": null,
|
22
|
+
"person_details": "view",
|
18
23
|
"pages": "create",
|
19
24
|
"page_editor": "basic",
|
20
25
|
"registers": "view"
|
@@ -24,7 +29,9 @@
|
|
24
29
|
"data": "update",
|
25
30
|
"reports": "edit",
|
26
31
|
"organization": "view",
|
27
|
-
"
|
32
|
+
"person_core": "view_people_manager",
|
33
|
+
"person_account": "view",
|
34
|
+
"person_details": "view",
|
28
35
|
"pages": "create",
|
29
36
|
"page_editor": "intermediate",
|
30
37
|
"registers": "view"
|
@@ -34,7 +41,9 @@
|
|
34
41
|
"data": "administrate",
|
35
42
|
"reports": "administrate",
|
36
43
|
"organization": "administrate",
|
37
|
-
"
|
44
|
+
"person_core": "edit",
|
45
|
+
"person_account": "edit",
|
46
|
+
"person_details": "edit_private",
|
38
47
|
"pages": "administrate",
|
39
48
|
"page_editor": "advanced",
|
40
49
|
"registers": "dashboard"
|
@@ -3,7 +3,9 @@
|
|
3
3
|
"data": [null, "view", "update", "administrate", "implement"],
|
4
4
|
"reports": [null, "view", "edit", "administrate"],
|
5
5
|
"organization": [null, "view", "administrate", "implement"],
|
6
|
-
"
|
6
|
+
"person_core": [null, "attach", "view_people_manager", "create", "edit", "dashboard"],
|
7
|
+
"person_account": [null, "view", "create", "edit"],
|
8
|
+
"person_details": [null, "view", "edit_public", "view_private", "edit_private"],
|
7
9
|
"pages": [null, "view", "update", "create", "administrate"],
|
8
10
|
"page_editor": [null, "basic", "intermediate", "advanced", "implement"],
|
9
11
|
"registers": [null, "view", "dashboard", "administrate", "implement"]
|
data/lib/eco/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: eco-helpers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Oscar Segura
|
@@ -113,7 +113,7 @@ dependencies:
|
|
113
113
|
version: '0.5'
|
114
114
|
- - ">="
|
115
115
|
- !ruby/object:Gem::Version
|
116
|
-
version: 0.5.
|
116
|
+
version: 0.5.9
|
117
117
|
type: :runtime
|
118
118
|
prerelease: false
|
119
119
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -123,7 +123,7 @@ dependencies:
|
|
123
123
|
version: '0.5'
|
124
124
|
- - ">="
|
125
125
|
- !ruby/object:Gem::Version
|
126
|
-
version: 0.5.
|
126
|
+
version: 0.5.9
|
127
127
|
- !ruby/object:Gem::Dependency
|
128
128
|
name: aws-sdk-s3
|
129
129
|
requirement: !ruby/object:Gem::Requirement
|
@@ -253,8 +253,6 @@ files:
|
|
253
253
|
- lib/eco/api/common/session/sftp.rb
|
254
254
|
- lib/eco/api/common/version_patches.rb
|
255
255
|
- lib/eco/api/common/version_patches/ecoportal_api.rb
|
256
|
-
- lib/eco/api/common/version_patches/ecoportal_api/account_preferences.rb
|
257
|
-
- lib/eco/api/common/version_patches/ecoportal_api/base_model.rb
|
258
256
|
- lib/eco/api/common/version_patches/ecoportal_api/external_person.rb
|
259
257
|
- lib/eco/api/common/version_patches/ecoportal_api/internal_person.rb
|
260
258
|
- lib/eco/api/common/version_patches/exception.rb
|
@@ -1,32 +0,0 @@
|
|
1
|
-
module Ecoportal
|
2
|
-
module API
|
3
|
-
class Internal
|
4
|
-
class Preferences < Common::BaseModel
|
5
|
-
passthrough :kiosk_enabled, :kiosk_workflow_message, :kiosk_create_button_label,
|
6
|
-
:kiosk_create_button_help, :kiosk_return_button_label, :kiosk_return_button_help,
|
7
|
-
:kiosk_dashboard_button_label, :kiosk_dashboard_button_help
|
8
|
-
|
9
|
-
[
|
10
|
-
:show_sidebar,
|
11
|
-
:show_shortcuts,
|
12
|
-
:show_coming_soon,
|
13
|
-
:show_recently_visited_forms,
|
14
|
-
:show_tasks,
|
15
|
-
:show_task_bubbles
|
16
|
-
].map(&:to_s).each do |field|
|
17
|
-
define_method(field) do
|
18
|
-
if doc.key?(field)
|
19
|
-
doc[field]
|
20
|
-
else
|
21
|
-
true
|
22
|
-
end
|
23
|
-
end
|
24
|
-
define_method("#{field}=") do |value|
|
25
|
-
doc[field] = !!value
|
26
|
-
end
|
27
|
-
end
|
28
|
-
|
29
|
-
end
|
30
|
-
end
|
31
|
-
end
|
32
|
-
end
|
@@ -1,27 +0,0 @@
|
|
1
|
-
module Ecoportal
|
2
|
-
module API
|
3
|
-
module Common
|
4
|
-
class BaseModel
|
5
|
-
|
6
|
-
attr_reader :initial_doc
|
7
|
-
|
8
|
-
def initialize(doc = {}, parent: self, key: nil)
|
9
|
-
@_parent = parent
|
10
|
-
@_key = key
|
11
|
-
if !_parent || !_key
|
12
|
-
@doc = doc
|
13
|
-
@original_doc = JSON.parse(@doc.to_json)
|
14
|
-
@initial_doc = JSON.parse(@doc.to_json)
|
15
|
-
end
|
16
|
-
end
|
17
|
-
|
18
|
-
def initial_doc
|
19
|
-
raise UnlinkedModel.new unless linked?
|
20
|
-
return @initial_doc if is_root?
|
21
|
-
_parent.initial_doc.dig(*[_key].flatten)
|
22
|
-
end
|
23
|
-
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|