ecoportal-api-oozes 0.7.0 → 0.7.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +103 -1
- data/README.md +2 -0
- data/ecoportal-api-oozes.gemspec +13 -6
- data/lib/ecoportal/api/common/content/class_helpers.rb +35 -0
- data/lib/ecoportal/api/common/content/collection_model.rb +25 -3
- data/lib/ecoportal/api/common/content/double_model.rb +27 -12
- data/lib/ecoportal/api/common/content/hash_diff_patch.rb +8 -2
- data/lib/ecoportal/api/common/content/wrapped_response.rb +1 -1
- data/lib/ecoportal/api/v2.rb +38 -3
- data/lib/ecoportal/api/v2/page.rb +3 -3
- data/lib/ecoportal/api/v2/page/component.rb +24 -7
- data/lib/ecoportal/api/v2/page/component/action.rb +14 -3
- data/lib/ecoportal/api/v2/page/component/action_field.rb +40 -2
- data/lib/ecoportal/api/v2/page/component/chart_field.rb +54 -0
- data/lib/ecoportal/api/v2/page/component/chart_field/frequency.rb +29 -0
- data/lib/ecoportal/api/v2/page/component/chart_field/heatmap.rb +27 -0
- data/lib/ecoportal/api/v2/page/component/chart_field/indicator.rb +26 -0
- data/lib/ecoportal/api/v2/page/component/chart_field/multiseries.rb +31 -0
- data/lib/ecoportal/api/v2/page/component/chart_field/sankey.rb +27 -0
- data/lib/ecoportal/api/v2/page/component/chart_field/serie.rb +26 -0
- data/lib/ecoportal/api/v2/page/component/chart_field/series_config.rb +23 -0
- data/lib/ecoportal/api/v2/page/component/chart_fr_field.rb +32 -0
- data/lib/ecoportal/api/v2/page/component/checklist_field.rb +35 -2
- data/lib/ecoportal/api/v2/page/component/checklist_item.rb +10 -0
- data/lib/ecoportal/api/v2/page/component/date_field.rb +21 -0
- data/lib/ecoportal/api/v2/page/component/files_field.rb +1 -2
- data/lib/ecoportal/api/v2/page/component/gauge_field.rb +24 -1
- data/lib/ecoportal/api/v2/page/component/gauge_stop.rb +88 -0
- data/lib/ecoportal/api/v2/page/component/images_field.rb +11 -2
- data/lib/ecoportal/api/v2/page/component/people_field.rb +8 -1
- data/lib/ecoportal/api/v2/page/component/plain_text_field.rb +2 -0
- data/lib/ecoportal/api/v2/page/component/reference_field.rb +4 -0
- data/lib/ecoportal/api/v2/page/component/selection_field.rb +4 -5
- data/lib/ecoportal/api/v2/page/component/selection_option.rb +1 -0
- data/lib/ecoportal/api/v2/page/component/signature_field.rb +12 -1
- data/lib/ecoportal/api/v2/page/component/tag_field.rb +2 -0
- data/lib/ecoportal/api/v2/page/components.rb +2 -2
- data/lib/ecoportal/api/v2/page/section.rb +1 -0
- data/lib/ecoportal/api/v2/page/sections.rb +1 -1
- data/lib/ecoportal/api/v2/page/stages.rb +6 -0
- data/lib/ecoportal/api/v2/pages.rb +17 -15
- data/lib/ecoportal/api/v2/pages/page_stage.rb +6 -1
- data/lib/ecoportal/api/v2/pages/stages.rb +4 -1
- data/lib/ecoportal/api/v2/people.rb +31 -0
- data/lib/ecoportal/api/v2/registers.rb +60 -6
- data/lib/ecoportal/api/v2/registers/page_result.rb +21 -0
- data/lib/ecoportal/api/v2/registers/register.rb +37 -0
- data/lib/ecoportal/api/v2/registers/stage_result.rb +14 -0
- data/lib/ecoportal/api/v2/registers/stages_result.rb +13 -0
- data/lib/ecoportal/api/v2/registers/template.rb +12 -0
- data/lib/ecoportal/api/v2/version.rb +1 -1
- metadata +70 -36
- data/lib/ecoportal/api/v2/register.rb +0 -36
- data/lib/ecoportal/api/v2/template.rb +0 -10
@@ -1,36 +0,0 @@
|
|
1
|
-
module Ecoportal
|
2
|
-
module API
|
3
|
-
class V2
|
4
|
-
class Register < Common::Content::DoubleModel
|
5
|
-
passkey :id
|
6
|
-
passthrough :name
|
7
|
-
|
8
|
-
class_resolver :template_class, "Ecoportal::API::V2::Template"
|
9
|
-
|
10
|
-
def templates_by_id
|
11
|
-
@templates_by_id or index_templates
|
12
|
-
@templates_by_id
|
13
|
-
end
|
14
|
-
|
15
|
-
def [](id)
|
16
|
-
templates_by_id[id]
|
17
|
-
end
|
18
|
-
|
19
|
-
def templates
|
20
|
-
templates_by_id.values
|
21
|
-
end
|
22
|
-
|
23
|
-
def index_templates
|
24
|
-
@templates_by_id = {}
|
25
|
-
doc["templates"].each do |template_doc|
|
26
|
-
template = template_class.new(template_doc)
|
27
|
-
@templates_by_id[template.id] = template
|
28
|
-
end
|
29
|
-
end
|
30
|
-
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|
35
|
-
|
36
|
-
require 'ecoportal/api/v2/template'
|