eco-helpers 3.0.4 → 3.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +2 -0
- data/CHANGELOG.md +55 -4
- data/eco-helpers.gemspec +1 -1
- data/lib/eco/api/common/class_helpers.rb +24 -23
- data/lib/eco/api/common/class_meta_basics.rb +0 -2
- data/lib/eco/api/common/loaders/use_case.rb +1 -0
- data/lib/eco/api/common/people/entry_factory.rb +6 -4
- data/lib/eco/api/common/people/person_entry.rb +4 -6
- data/lib/eco/api/common/people/person_entry_attribute_mapper.rb +25 -12
- data/lib/eco/api/common/people/person_parser.rb +8 -0
- data/lib/eco/api/common/session/base_session.rb +1 -1
- data/lib/eco/api/common/session/environment.rb +7 -0
- data/lib/eco/api/common/session/file_manager.rb +15 -8
- data/lib/eco/api/common/session/logger/cache.rb +14 -10
- data/lib/eco/api/common/session/logger/log.rb +8 -7
- data/lib/eco/api/common/session/mailer.rb +22 -13
- data/lib/eco/api/common/session/s3_uploader.rb +29 -20
- data/lib/eco/api/microcases/people_search.rb +1 -1
- data/lib/eco/api/organization/login_providers.rb +11 -4
- data/lib/eco/api/organization/node_classifications.rb +3 -0
- data/lib/eco/api/organization/presets_factory.rb +37 -31
- data/lib/eco/api/organization/tag_tree.rb +14 -5
- data/lib/eco/api/policies/default_policies/99_user_access_policy.rb +28 -18
- data/lib/eco/api/session/batch/errors.rb +38 -20
- data/lib/eco/api/session/batch/job.rb +252 -135
- data/lib/eco/api/session/batch/status.rb +55 -36
- data/lib/eco/api/session/batch.rb +2 -2
- data/lib/eco/api/session/config/base_config.rb +12 -11
- data/lib/eco/api/session/config/tagtree.rb +10 -14
- data/lib/eco/api/session/config/workflow.rb +15 -3
- data/lib/eco/api/session/config.rb +19 -26
- data/lib/eco/api/session.rb +13 -4
- data/lib/eco/api/usecases/cli.rb +4 -0
- data/lib/eco/api/usecases/default/locations/cli/codes_to_tags_cli.rb +18 -0
- data/lib/eco/api/usecases/default/locations/cli/csv_to_tree_cli.rb +12 -0
- data/lib/eco/api/usecases/default/locations/cli/tagtree_paths_cli.rb +12 -0
- data/lib/eco/api/usecases/default/locations/codes_to_tags_case.rb +32 -13
- data/lib/eco/api/usecases/default/locations/csv_to_tree_case.rb +15 -5
- data/lib/eco/api/usecases/default/locations/tagtree_extract_case.rb +6 -0
- data/lib/eco/api/usecases/default/locations/tagtree_paths_case.rb +51 -0
- data/lib/eco/api/usecases/default/locations.rb +1 -1
- data/lib/eco/api/usecases/default/people/amend/cli/reinvite_sync_cli.rb +8 -0
- data/lib/eco/api/usecases/default/people/amend/cli/reinvite_trans_cli.rb +11 -0
- data/lib/eco/api/usecases/default/people/amend/cli/restore_db_cli.rb +26 -0
- data/lib/eco/api/usecases/default/people/amend/reinvite_sync_case.rb +2 -0
- data/lib/eco/api/usecases/default/people/amend/reinvite_trans_case.rb +2 -0
- data/lib/eco/api/usecases/default/people/amend/restore_db_case.rb +3 -0
- data/lib/eco/api/usecases/default/people/treat/analyse_people_case.rb +15 -5
- data/lib/eco/api/usecases/default/people/treat/cli/analyse_people_cli.rb +66 -0
- data/lib/eco/api/usecases/default/people/treat/cli/org_data_convert_cli.rb +35 -0
- data/lib/eco/api/usecases/default/people/treat/cli/supers_cyclic_identify_cli.rb +15 -0
- data/lib/eco/api/usecases/default/people/treat/cli/supers_hierachy_cli.rb +15 -0
- data/lib/eco/api/usecases/default/people/treat/org_data_convert_case.rb +11 -5
- data/lib/eco/api/usecases/default/people/treat/supers_cyclic_identify_case.rb +28 -7
- data/lib/eco/api/usecases/default/people/treat/supers_hierarchy_case.rb +32 -9
- data/lib/eco/api/usecases/default/people/utils/set_default_tag_case.rb +2 -1
- data/lib/eco/api/usecases/default_cases/to_csv_case.rb +2 -2
- data/lib/eco/api/usecases/graphql/helpers/base/case_env.rb +1 -0
- data/lib/eco/api/usecases/graphql/helpers/base/error_handling.rb +52 -0
- data/lib/eco/api/usecases/graphql/helpers/base.rb +1 -0
- data/lib/eco/api/usecases/graphql/helpers/location/base/classifications_parser.rb +5 -0
- data/lib/eco/api/usecases/graphql/helpers/location/command/diffs/stages/commandable.rb +2 -0
- data/lib/eco/api/usecases/graphql/helpers/location/command/diffs/stages/diff_sortable.rb +2 -0
- data/lib/eco/api/usecases/graphql/helpers/location/command/result.rb +2 -1
- data/lib/eco/api/usecases/graphql/helpers/location/command/results.rb +3 -0
- data/lib/eco/api/usecases/graphql/helpers/location/command.rb +1 -0
- data/lib/eco/api/usecases/graphql/helpers/location/tags_remap.rb +3 -0
- data/lib/eco/api/usecases/graphql/samples/location/command/dsl.rb +19 -18
- data/lib/eco/api/usecases/graphql/samples/location/command/results.rb +1 -7
- data/lib/eco/api/usecases/graphql/samples/location/command/service/tree_update.rb +11 -6
- data/lib/eco/api/usecases/graphql/samples/location/command/track_changed_ids.rb +3 -8
- data/lib/eco/api/usecases/graphql/samples/location/service/tree_diff/convertible/parsing/classifications.rb +2 -0
- data/lib/eco/api/usecases/graphql/samples/location/service/tree_diff/convertible.rb +5 -2
- data/lib/eco/api/usecases/graphql/samples/location/service/tree_diff.rb +10 -4
- data/lib/eco/api/usecases/graphql/samples/location/service/tree_to_list/converter/parser.rb +6 -2
- data/lib/eco/api/usecases/graphql/samples/location/service/tree_to_list/converter.rb +2 -0
- data/lib/eco/api/usecases/graphql/samples/location/service/tree_to_list.rb +5 -3
- data/lib/eco/api/usecases/ooze_cases/export_register_case.rb +1 -0
- data/lib/eco/api/usecases/ooze_samples/helpers_migration/copying.rb +66 -29
- data/lib/eco/api/usecases/ooze_samples/ooze_base_case.rb +25 -3
- data/lib/eco/api/usecases/ooze_samples/register_update_case.rb +10 -0
- data/lib/eco/api/usecases/use_case.rb +3 -1
- data/lib/eco/cli/config/use_cases.rb +4 -0
- data/lib/eco/cli/scripting/args_helpers.rb +3 -2
- data/lib/eco/cli/scripting/argument.rb +2 -2
- data/lib/eco/cli_default/input.rb +49 -45
- data/lib/eco/cli_default/input_filters.rb +32 -17
- data/lib/eco/cli_default/options.rb +8 -4
- data/lib/eco/cli_default/people.rb +1 -1
- data/lib/eco/cli_default/people_filters.rb +32 -24
- data/lib/eco/cli_default/usecases.rb +8 -121
- data/lib/eco/cli_default/workflow.rb +6 -4
- data/lib/eco/csv/split.rb +2 -0
- data/lib/eco/csv/table.rb +13 -0
- data/lib/eco/data/files/encoding.rb +15 -8
- data/lib/eco/data/files/helpers.rb +6 -2
- data/lib/eco/data/hashes/diff_result.rb +5 -0
- data/lib/eco/data/locations/node_diff/nodes_diff.rb +13 -0
- data/lib/eco/data/locations/node_diff.rb +4 -0
- data/lib/eco/data/locations/node_level.rb +6 -0
- data/lib/eco/language/auxiliar_logger.rb +2 -0
- data/lib/eco/version.rb +1 -1
- data/lib/eco-helpers.rb +1 -1
- metadata +16 -6
- data/lib/eco/api/usecases/default/locations/create_tag_paths_case.rb +0 -25
- data/lib/eco/api/usecases/default/people/amend/reinvite_trans_cli.rb +0 -4
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: eco-helpers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Oscar Segura
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-08-
|
11
|
+
date: 2024-08-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -269,7 +269,7 @@ dependencies:
|
|
269
269
|
version: '2.0'
|
270
270
|
- - ">="
|
271
271
|
- !ruby/object:Gem::Version
|
272
|
-
version: 2.0.
|
272
|
+
version: 2.0.9
|
273
273
|
type: :runtime
|
274
274
|
prerelease: false
|
275
275
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -279,7 +279,7 @@ dependencies:
|
|
279
279
|
version: '2.0'
|
280
280
|
- - ">="
|
281
281
|
- !ruby/object:Gem::Version
|
282
|
-
version: 2.0.
|
282
|
+
version: 2.0.9
|
283
283
|
- !ruby/object:Gem::Dependency
|
284
284
|
name: ed25519
|
285
285
|
requirement: !ruby/object:Gem::Requirement
|
@@ -663,12 +663,15 @@ files:
|
|
663
663
|
- lib/eco/api/usecases/cli/option.rb
|
664
664
|
- lib/eco/api/usecases/default.rb
|
665
665
|
- lib/eco/api/usecases/default/locations.rb
|
666
|
+
- lib/eco/api/usecases/default/locations/cli/codes_to_tags_cli.rb
|
667
|
+
- lib/eco/api/usecases/default/locations/cli/csv_to_tree_cli.rb
|
666
668
|
- lib/eco/api/usecases/default/locations/cli/tagtree_extract_cli.rb
|
669
|
+
- lib/eco/api/usecases/default/locations/cli/tagtree_paths_cli.rb
|
667
670
|
- lib/eco/api/usecases/default/locations/cli/tagtree_upload_cli.rb
|
668
671
|
- lib/eco/api/usecases/default/locations/codes_to_tags_case.rb
|
669
|
-
- lib/eco/api/usecases/default/locations/create_tag_paths_case.rb
|
670
672
|
- lib/eco/api/usecases/default/locations/csv_to_tree_case.rb
|
671
673
|
- lib/eco/api/usecases/default/locations/tagtree_extract_case.rb
|
674
|
+
- lib/eco/api/usecases/default/locations/tagtree_paths_case.rb
|
672
675
|
- lib/eco/api/usecases/default/locations/tagtree_upload_case.rb
|
673
676
|
- lib/eco/api/usecases/default/meta.rb
|
674
677
|
- lib/eco/api/usecases/default/meta/cli/graphql_schema_cli.rb
|
@@ -678,16 +681,22 @@ files:
|
|
678
681
|
- lib/eco/api/usecases/default/people/amend/clean_unknown_tags_case.rb
|
679
682
|
- lib/eco/api/usecases/default/people/amend/clear_abilities_case.rb
|
680
683
|
- lib/eco/api/usecases/default/people/amend/cli/clean_unknown_tags_cli.rb
|
684
|
+
- lib/eco/api/usecases/default/people/amend/cli/reinvite_sync_cli.rb
|
685
|
+
- lib/eco/api/usecases/default/people/amend/cli/reinvite_trans_cli.rb
|
686
|
+
- lib/eco/api/usecases/default/people/amend/cli/restore_db_cli.rb
|
681
687
|
- lib/eco/api/usecases/default/people/amend/refresh_case.rb
|
682
688
|
- lib/eco/api/usecases/default/people/amend/reinvite_sync_case.rb
|
683
689
|
- lib/eco/api/usecases/default/people/amend/reinvite_trans_case.rb
|
684
|
-
- lib/eco/api/usecases/default/people/amend/reinvite_trans_cli.rb
|
685
690
|
- lib/eco/api/usecases/default/people/amend/restore_db_case.rb
|
686
691
|
- lib/eco/api/usecases/default/people/migrate.rb
|
687
692
|
- lib/eco/api/usecases/default/people/migrate/cli/remap_tags_cli.rb
|
688
693
|
- lib/eco/api/usecases/default/people/migrate/remap_tags_case.rb
|
689
694
|
- lib/eco/api/usecases/default/people/treat.rb
|
690
695
|
- lib/eco/api/usecases/default/people/treat/analyse_people_case.rb
|
696
|
+
- lib/eco/api/usecases/default/people/treat/cli/analyse_people_cli.rb
|
697
|
+
- lib/eco/api/usecases/default/people/treat/cli/org_data_convert_cli.rb
|
698
|
+
- lib/eco/api/usecases/default/people/treat/cli/supers_cyclic_identify_cli.rb
|
699
|
+
- lib/eco/api/usecases/default/people/treat/cli/supers_hierachy_cli.rb
|
691
700
|
- lib/eco/api/usecases/default/people/treat/org_data_convert_case.rb
|
692
701
|
- lib/eco/api/usecases/default/people/treat/supers_cyclic_identify_case.rb
|
693
702
|
- lib/eco/api/usecases/default/people/treat/supers_hierarchy_case.rb
|
@@ -717,6 +726,7 @@ files:
|
|
717
726
|
- lib/eco/api/usecases/graphql/helpers.rb
|
718
727
|
- lib/eco/api/usecases/graphql/helpers/base.rb
|
719
728
|
- lib/eco/api/usecases/graphql/helpers/base/case_env.rb
|
729
|
+
- lib/eco/api/usecases/graphql/helpers/base/error_handling.rb
|
720
730
|
- lib/eco/api/usecases/graphql/helpers/base/graphql_env.rb
|
721
731
|
- lib/eco/api/usecases/graphql/helpers/location.rb
|
722
732
|
- lib/eco/api/usecases/graphql/helpers/location/base.rb
|
@@ -1,25 +0,0 @@
|
|
1
|
-
class Eco::API::UseCases::Default::Locations::TagPaths < Eco::API::Common::Loaders::UseCase
|
2
|
-
name "create-tag-paths"
|
3
|
-
type :other
|
4
|
-
|
5
|
-
def main(session, options, usecase)
|
6
|
-
CSV.open("tag_paths.csv", "w") do |csv|
|
7
|
-
csv << ["Tag", "Path"]
|
8
|
-
tag_paths.each do |values|
|
9
|
-
csv << values
|
10
|
-
end
|
11
|
-
end
|
12
|
-
end
|
13
|
-
|
14
|
-
private
|
15
|
-
|
16
|
-
def tag_paths
|
17
|
-
@tag_paths ||= tagtree.tags.reverse.map do |tag|
|
18
|
-
[tag, tagtree.path(tag).join("|")]
|
19
|
-
end
|
20
|
-
end
|
21
|
-
|
22
|
-
def tagtree
|
23
|
-
session.tagtree
|
24
|
-
end
|
25
|
-
end
|