eco-helpers 1.3.18 → 1.4.0

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
  SHA256:
3
- metadata.gz: a61c411db84db417e4d9004d2e8f9359b423cb91ac31b40eaf390e9b3e7a4f0a
4
- data.tar.gz: 3431111bd4259b33a8c6ac38ad5ce67226c4e2a8c9c95b311142d7896f9d68f1
3
+ metadata.gz: 28d9f5ad6037a8160ea1d39873a0b1c6769be63865267d159dd6fa71ae329d60
4
+ data.tar.gz: ba968ce7525e5fb289ff5b210f3c79692b05dfc74ae6af6cf8c729640bb1cf4a
5
5
  SHA512:
6
- metadata.gz: afae206900769f68a8733dbe72d3277cf610fd4d7e92a1adda5197685889511fb80c9a424987f59306c59fa251b79a6f929d0dfc566c301cd3703c5fc6c5a2bf
7
- data.tar.gz: 19d0d4c7c3a24c194b02faee98bd2ad2c55d8a8d7522681f2d1918594207cf673b827e4a510646c1f21b302105290b7b31da41be98a80112ff6d8c0c6e398826
6
+ metadata.gz: 2a7bda8f0a427b7a93d42230c32226c578b4ae4aab9b2974bf1095d1f77d368faa8c409e41375cf5d378ed4a915b359ce12e74559c7f963a2a9d791a165f3232
7
+ data.tar.gz: ba9adb7220623345536d5080e658a524daebd914f3c64d94f83652e3d42fbdb240da9a08367ee42dde196adfc2152553b4133bd330d3a007052bba42b156aed5
@@ -1,7 +1,17 @@
1
1
  # Change Log
2
2
  All notable changes to this project will be documented in this file.
3
3
 
4
- ## [1.3.18] - 2020-07-xx
4
+ ## [1.4.0] - 2020-07-xx
5
+
6
+ ### Added
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`
11
+ ### Fixed
12
+ - `Eco::CSV#parse` and `Eco::CSV#read` should use the proper `:encoding` when it's `bom`
13
+
14
+ ## [1.3.18] - 2020-07-08
5
15
 
6
16
  ### Added
7
17
  ### 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.8'
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,4 +1,2 @@
1
- require_relative 'ecoportal_api/base_model'
2
1
  require_relative 'ecoportal_api/external_person'
3
2
  require_relative 'ecoportal_api/internal_person'
4
- require_relative 'ecoportal_api/account_preferences'
@@ -3,10 +3,6 @@ module Ecoportal
3
3
  class V1
4
4
  class Person
5
5
 
6
- def sync
7
- consolidate!
8
- end
9
-
10
6
  def reset_details!
11
7
  doc["details"] = JSON.parse(original_doc["details"])
12
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
- "people": "attach",
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
- "people": "view",
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
- "people": "edit",
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
- "people": [null, "attach", "view", "view_private", "edit", "dashboard"],
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"]
@@ -71,7 +71,7 @@ module Eco
71
71
  end
72
72
 
73
73
  def encoding(path)
74
- has_bom?(path) ? "bom|utf-8" : "utf-8"
74
+ has_bom?(path) ? "bom" : "utf-8"
75
75
  end
76
76
 
77
77
  def script_subfolder
@@ -1,3 +1,3 @@
1
1
  module Eco
2
- VERSION = "1.3.18"
2
+ VERSION = "1.4.0"
3
3
  end
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.3.18
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.8
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.8
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