egov_utils 1.4.3 → 1.5.0.alpha1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/egov_utils/iszr_controller.rb +37 -0
  3. data/app/models/concerns/types.rb +3 -0
  4. data/app/models/egov_utils/abstract_person.rb +0 -2
  5. data/app/models/egov_utils/natural_person.rb +1 -1
  6. data/app/models/egov_utils/person.rb +46 -1
  7. data/app/models/egov_utils/services/iszr/legal_people.rb +11 -0
  8. data/app/models/egov_utils/services/iszr/natural_people.rb +13 -0
  9. data/app/modules/envelope.rb +22 -0
  10. data/app/services/egov_utils/iszr/addresses/fetch.rb +27 -0
  11. data/app/services/egov_utils/iszr/addresses/fetch_for_legal_person/from_sample_data.rb +31 -0
  12. data/app/services/egov_utils/iszr/addresses/fetch_for_legal_person.rb +23 -0
  13. data/app/services/egov_utils/iszr/addresses/fetch_for_natural_person/from_sample_data.rb +31 -0
  14. data/app/services/egov_utils/iszr/addresses/fetch_for_natural_person.rb +23 -0
  15. data/app/services/egov_utils/iszr/legal_people/create_request.rb +48 -0
  16. data/app/services/egov_utils/iszr/legal_people/dev_search.rb +39 -0
  17. data/app/services/egov_utils/iszr/legal_people/prod_search.rb +47 -0
  18. data/app/services/egov_utils/iszr/legal_people/search.rb +30 -0
  19. data/app/services/egov_utils/iszr/legal_people/search_by_remote_id.rb +39 -0
  20. data/app/services/egov_utils/iszr/natural_people/create_request.rb +97 -0
  21. data/app/services/egov_utils/iszr/natural_people/dev_search.rb +87 -0
  22. data/app/services/egov_utils/iszr/natural_people/prod_search.rb +91 -0
  23. data/app/services/egov_utils/iszr/natural_people/search.rb +31 -0
  24. data/app/services/egov_utils/iszr/natural_people/search_by_remote_id.rb +39 -0
  25. data/app/services/egov_utils/iszr/request.rb +36 -0
  26. data/app/services/egov_utils/registration_requests/check_auto_accept.rb +1 -1
  27. data/app/views/egov_utils/people/_new_form.html.haml +127 -0
  28. data/config/locales/cs.yml +8 -0
  29. data/config/locales/en.yml +7 -0
  30. data/config/routes.rb +1 -1
  31. data/lib/egov_utils/engine.rb +3 -0
  32. data/lib/egov_utils/iszr/e05_osoby_response.xml +87 -0
  33. data/lib/egov_utils/iszr/e20_ico_response.xml +70 -0
  34. data/lib/egov_utils/iszr/lp_addresses.json +112 -0
  35. data/lib/egov_utils/iszr/lp_results.json +52 -0
  36. data/lib/egov_utils/iszr/np_addresses.json +90 -0
  37. data/lib/egov_utils/iszr/np_results.json +58 -0
  38. data/lib/egov_utils/version.rb +1 -1
  39. metadata +102 -3
@@ -0,0 +1,112 @@
1
+ [
2
+ {
3
+ "remote_id": "22",
4
+ "street": "Vzorová",
5
+ "house_number": "1234",
6
+ "orientation_number": "1",
7
+ "city": "Praha",
8
+ "postcode": "13000",
9
+ "district": "Hlavní město Praha",
10
+ "region": "Hlavní město Praha",
11
+ "country": 203
12
+ },
13
+ {
14
+ "remote_id": "1",
15
+ "street": "Vzorová",
16
+ "house_number": "123",
17
+ "orientation_number": "1",
18
+ "city": "Praha",
19
+ "postcode": "13000",
20
+ "district": "Hlavní město Praha",
21
+ "region": "Hlavní město Praha",
22
+ "country": 203
23
+ },
24
+ {
25
+ "remote_id": "15",
26
+ "street": "Vzorová",
27
+ "house_number": "123",
28
+ "orientation_number": "1",
29
+ "city": "Praha",
30
+ "postcode": "13000",
31
+ "district": "Hlavní město Praha",
32
+ "region": "Hlavní město Praha",
33
+ "country": 203
34
+ },
35
+ {
36
+ "remote_id": "35",
37
+ "street": "Vzorová",
38
+ "house_number": "123",
39
+ "orientation_number": "1",
40
+ "city": "Praha",
41
+ "postcode": "13000",
42
+ "district": "Hlavní město Praha",
43
+ "region": "Hlavní město Praha",
44
+ "country": 203
45
+ },
46
+ {
47
+ "remote_id": "74",
48
+ "street": "Vzorová",
49
+ "house_number": "123",
50
+ "orientation_number": "1",
51
+ "city": "Praha",
52
+ "postcode": "13000",
53
+ "district": "Hlavní město Praha",
54
+ "region": "Hlavní město Praha",
55
+ "country": 203
56
+ },
57
+ {
58
+ "remote_id": "12",
59
+ "street": "Vzorová",
60
+ "house_number": "123",
61
+ "orientation_number": "1",
62
+ "city": "Praha",
63
+ "postcode": "13000",
64
+ "district": "Hlavní město Praha",
65
+ "region": "Hlavní město Praha",
66
+ "country": 203
67
+ },
68
+ {
69
+ "remote_id": "79",
70
+ "street": "Vzorová",
71
+ "house_number": "123",
72
+ "orientation_number": "1",
73
+ "city": "Praha",
74
+ "postcode": "13000",
75
+ "district": "Hlavní město Praha",
76
+ "region": "Hlavní město Praha",
77
+ "country": 203
78
+ },
79
+ {
80
+ "remote_id": "88",
81
+ "street": "Vzorová",
82
+ "house_number": "123",
83
+ "orientation_number": "1",
84
+ "city": "Praha",
85
+ "postcode": "13000",
86
+ "district": "Hlavní město Praha",
87
+ "region": "Hlavní město Praha",
88
+ "country": 203
89
+ },
90
+ {
91
+ "remote_id": "53",
92
+ "street": "Vzorová",
93
+ "house_number": "123",
94
+ "orientation_number": "1",
95
+ "city": "Praha",
96
+ "postcode": "13000",
97
+ "district": "Hlavní město Praha",
98
+ "region": "Hlavní město Praha",
99
+ "country": 203
100
+ },
101
+ {
102
+ "remote_id": "46",
103
+ "street": "Vzorová",
104
+ "house_number": "123",
105
+ "orientation_number": "1",
106
+ "city": "Praha",
107
+ "postcode": "13000",
108
+ "district": "Hlavní město Praha",
109
+ "region": "Hlavní město Praha",
110
+ "country": 203
111
+ }
112
+ ]
@@ -0,0 +1,52 @@
1
+ [
2
+ {
3
+ "name": "Alfréd Tračník",
4
+ "ico": "1234567890",
5
+ "remote_id": "22"
6
+ },
7
+ {
8
+ "name": "Havelock Vetinari",
9
+ "ico": "0987654321",
10
+ "remote_id": "1"
11
+ },
12
+ {
13
+ "name": "Jonatán Časnačaj",
14
+ "ico": "6666666666",
15
+ "remote_id": "15"
16
+ },
17
+ {
18
+ "name": "Bábi Zlopočasná",
19
+ "ico": "00000000",
20
+ "remote_id": "35"
21
+ },
22
+ {
23
+ "name": "Barbar Cohen",
24
+ "ico": "80020008",
25
+ "remote_id": "74"
26
+ },
27
+ {
28
+ "name": "Stařenka Oggová",
29
+ "ico": "00000002",
30
+ "remote_id": "12"
31
+ },
32
+ {
33
+ "name": "Zatracený Hlupec",
34
+ "ico": "20010007",
35
+ "remote_id": "79"
36
+ },
37
+ {
38
+ "name": "Lu Tze",
39
+ "ico": "999999952",
40
+ "remote_id": "88"
41
+ },
42
+ {
43
+ "name": "Noby Nóblhóch",
44
+ "ico": "70005003",
45
+ "remote_id": "53"
46
+ },
47
+ {
48
+ "name": "Kolík Aťsepicnu",
49
+ "ico": "30000021",
50
+ "remote_id": "46"
51
+ }
52
+ ]
@@ -0,0 +1,90 @@
1
+ [
2
+ {
3
+ "remote_id": "123",
4
+ "street": "Vzorová",
5
+ "house_number": "1234",
6
+ "orientation_number": "1",
7
+ "city": "Praha",
8
+ "postcode": "13000",
9
+ "district": "Hlavní město Praha",
10
+ "region": "Hlavní město Praha",
11
+ "country": 203
12
+ },
13
+ {
14
+ "remote_id": "808",
15
+ "street": "Vzorová",
16
+ "house_number": "123",
17
+ "orientation_number": "1",
18
+ "city": "Praha",
19
+ "postcode": "13000",
20
+ "district": "Hlavní město Praha",
21
+ "region": "Hlavní město Praha",
22
+ "country": 203
23
+ },
24
+ {
25
+ "remote_id": "2",
26
+ "street": "Vzorová",
27
+ "house_number": "123",
28
+ "orientation_number": "1",
29
+ "city": "Praha",
30
+ "postcode": "13000",
31
+ "district": "Hlavní město Praha",
32
+ "region": "Hlavní město Praha",
33
+ "country": 203
34
+ },
35
+ {
36
+ "remote_id": "3",
37
+ "street": "Vzorová",
38
+ "house_number": "123",
39
+ "orientation_number": "1",
40
+ "city": "Praha",
41
+ "postcode": "13000",
42
+ "district": "Hlavní město Praha",
43
+ "region": "Hlavní město Praha",
44
+ "country": 203
45
+ },
46
+ {
47
+ "remote_id": "1",
48
+ "street": "Vzorová",
49
+ "house_number": "123",
50
+ "orientation_number": "1",
51
+ "city": "Praha",
52
+ "postcode": "13000",
53
+ "district": "Hlavní město Praha",
54
+ "region": "Hlavní město Praha",
55
+ "country": 203
56
+ },
57
+ {
58
+ "remote_id": "53",
59
+ "street": "Vzorová",
60
+ "house_number": "123",
61
+ "orientation_number": "1",
62
+ "city": "Praha",
63
+ "postcode": "13000",
64
+ "district": "Hlavní město Praha",
65
+ "region": "Hlavní město Praha",
66
+ "country": 203
67
+ },
68
+ {
69
+ "remote_id": "666",
70
+ "street": "Vzorová",
71
+ "house_number": "123",
72
+ "orientation_number": "1",
73
+ "city": "Praha",
74
+ "postcode": "13000",
75
+ "district": "Hlavní město Praha",
76
+ "region": "Hlavní město Praha",
77
+ "country": 203
78
+ },
79
+ {
80
+ "remote_id": "0",
81
+ "street": "Vzorová",
82
+ "house_number": "123",
83
+ "orientation_number": "1",
84
+ "city": "Praha",
85
+ "postcode": "13000",
86
+ "district": "Hlavní město Praha",
87
+ "region": "Hlavní město Praha",
88
+ "country": 203
89
+ }
90
+ ]
@@ -0,0 +1,58 @@
1
+ [
2
+ {
3
+ "firstname": "Tomáš",
4
+ "lastname": "Dundáček",
5
+ "birth_date": "1990-10-01",
6
+ "birth_place": "Ankh-Morpork",
7
+ "remote_id": "123"
8
+ },
9
+ {
10
+ "firstname": "Vzoromil",
11
+ "lastname": "Výsměšek",
12
+ "birth_date": "1988-01-01",
13
+ "birth_place": "Ankh-Morpork",
14
+ "remote_id": "808"
15
+ },
16
+ {
17
+ "firstname": "Starší",
18
+ "lastname": "Pasák",
19
+ "birth_date": "1968-01-12",
20
+ "birth_place": "Čtyřiks",
21
+ "remote_id": "2"
22
+ },
23
+ {
24
+ "firstname": "Starší",
25
+ "lastname": "Pasák",
26
+ "birth_date": "1968-01-13",
27
+ "birth_place": "Klač",
28
+ "remote_id": "3"
29
+ },
30
+ {
31
+ "firstname": "Rob",
32
+ "lastname": "Kterýten",
33
+ "birth_date": "1910-05-31",
34
+ "birth_place": "Lancre",
35
+ "remote_id": "1"
36
+ },
37
+ {
38
+ "firstname": "Rob",
39
+ "lastname": "Kterýten",
40
+ "birth_date": "1910-05-31",
41
+ "birth_place": "Lancre",
42
+ "remote_id": "53"
43
+ },
44
+ {
45
+ "firstname": "Samuel",
46
+ "lastname": "Elánius",
47
+ "birth_date": "1984-01-27",
48
+ "birth_place": "Praha",
49
+ "remote_id": "666"
50
+ },
51
+ {
52
+ "firstname": "Samuel",
53
+ "lastname": "Elánius",
54
+ "birth_date": "1984-01-27",
55
+ "birth_place": "Ankh-Morpork",
56
+ "remote_id": "789"
57
+ }
58
+ ]
@@ -1,3 +1,3 @@
1
1
  module EgovUtils
2
- VERSION = '1.4.3'
2
+ VERSION = '1.5.0.alpha1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: egov_utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.3
4
+ version: 1.5.0.alpha1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ondřej Ezr
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-17 00:00:00.000000000 Z
11
+ date: 2024-07-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -388,6 +388,34 @@ dependencies:
388
388
  - - "~>"
389
389
  - !ruby/object:Gem::Version
390
390
  version: '2.5'
391
+ - !ruby/object:Gem::Dependency
392
+ name: dry-struct
393
+ requirement: !ruby/object:Gem::Requirement
394
+ requirements:
395
+ - - "~>"
396
+ - !ruby/object:Gem::Version
397
+ version: 1.6.0
398
+ type: :runtime
399
+ prerelease: false
400
+ version_requirements: !ruby/object:Gem::Requirement
401
+ requirements:
402
+ - - "~>"
403
+ - !ruby/object:Gem::Version
404
+ version: 1.6.0
405
+ - !ruby/object:Gem::Dependency
406
+ name: dry-types
407
+ requirement: !ruby/object:Gem::Requirement
408
+ requirements:
409
+ - - ">="
410
+ - !ruby/object:Gem::Version
411
+ version: '0'
412
+ type: :runtime
413
+ prerelease: false
414
+ version_requirements: !ruby/object:Gem::Requirement
415
+ requirements:
416
+ - - ">="
417
+ - !ruby/object:Gem::Version
418
+ version: '0'
391
419
  - !ruby/object:Gem::Dependency
392
420
  name: azahara_schema
393
421
  requirement: !ruby/object:Gem::Requirement
@@ -500,6 +528,48 @@ dependencies:
500
528
  - - '='
501
529
  - !ruby/object:Gem::Version
502
530
  version: 1.6.9
531
+ - !ruby/object:Gem::Dependency
532
+ name: shoulda-matchers
533
+ requirement: !ruby/object:Gem::Requirement
534
+ requirements:
535
+ - - "~>"
536
+ - !ruby/object:Gem::Version
537
+ version: 6.1.0
538
+ type: :development
539
+ prerelease: false
540
+ version_requirements: !ruby/object:Gem::Requirement
541
+ requirements:
542
+ - - "~>"
543
+ - !ruby/object:Gem::Version
544
+ version: 6.1.0
545
+ - !ruby/object:Gem::Dependency
546
+ name: json
547
+ requirement: !ruby/object:Gem::Requirement
548
+ requirements:
549
+ - - '='
550
+ - !ruby/object:Gem::Version
551
+ version: 2.7.1
552
+ type: :development
553
+ prerelease: false
554
+ version_requirements: !ruby/object:Gem::Requirement
555
+ requirements:
556
+ - - '='
557
+ - !ruby/object:Gem::Version
558
+ version: 2.7.1
559
+ - !ruby/object:Gem::Dependency
560
+ name: gyoku
561
+ requirement: !ruby/object:Gem::Requirement
562
+ requirements:
563
+ - - "~>"
564
+ - !ruby/object:Gem::Version
565
+ version: '1.0'
566
+ type: :development
567
+ prerelease: false
568
+ version_requirements: !ruby/object:Gem::Requirement
569
+ requirements:
570
+ - - "~>"
571
+ - !ruby/object:Gem::Version
572
+ version: '1.0'
503
573
  description: We hope it will help create better systems for all the eGoverment. In
504
574
  Czech Republic and maybe further.
505
575
  email:
@@ -534,6 +604,7 @@ files:
534
604
  - app/controllers/egov_utils/application_controller.rb
535
605
  - app/controllers/egov_utils/current_users_controller.rb
536
606
  - app/controllers/egov_utils/groups_controller.rb
607
+ - app/controllers/egov_utils/iszr_controller.rb
537
608
  - app/controllers/egov_utils/organizations_controller.rb
538
609
  - app/controllers/egov_utils/passwords_controller.rb
539
610
  - app/controllers/egov_utils/people_controller.rb
@@ -554,6 +625,7 @@ files:
554
625
  - app/mailers/egov_utils/registration_request_mailer.rb
555
626
  - app/mailers/egov_utils/user_mailer.rb
556
627
  - app/models/ability.rb
628
+ - app/models/concerns/types.rb
557
629
  - app/models/egov_utils/abstract_person.rb
558
630
  - app/models/egov_utils/address.rb
559
631
  - app/models/egov_utils/application_record.rb
@@ -565,7 +637,10 @@ files:
565
637
  - app/models/egov_utils/person.rb
566
638
  - app/models/egov_utils/principal.rb
567
639
  - app/models/egov_utils/registration_request.rb
640
+ - app/models/egov_utils/services/iszr/legal_people.rb
641
+ - app/models/egov_utils/services/iszr/natural_people.rb
568
642
  - app/models/egov_utils/user.rb
643
+ - app/modules/envelope.rb
569
644
  - app/resources/egov_utils/legal_form.rb
570
645
  - app/resources/egov_utils/love.rb
571
646
  - app/resources/egov_utils/organization.rb
@@ -577,6 +652,22 @@ files:
577
652
  - app/schemas/egov_utils/person_schema.rb
578
653
  - app/schemas/egov_utils/user_schema.rb
579
654
  - app/services/egov_utils/archive_users.rb
655
+ - app/services/egov_utils/iszr/addresses/fetch.rb
656
+ - app/services/egov_utils/iszr/addresses/fetch_for_legal_person.rb
657
+ - app/services/egov_utils/iszr/addresses/fetch_for_legal_person/from_sample_data.rb
658
+ - app/services/egov_utils/iszr/addresses/fetch_for_natural_person.rb
659
+ - app/services/egov_utils/iszr/addresses/fetch_for_natural_person/from_sample_data.rb
660
+ - app/services/egov_utils/iszr/legal_people/create_request.rb
661
+ - app/services/egov_utils/iszr/legal_people/dev_search.rb
662
+ - app/services/egov_utils/iszr/legal_people/prod_search.rb
663
+ - app/services/egov_utils/iszr/legal_people/search.rb
664
+ - app/services/egov_utils/iszr/legal_people/search_by_remote_id.rb
665
+ - app/services/egov_utils/iszr/natural_people/create_request.rb
666
+ - app/services/egov_utils/iszr/natural_people/dev_search.rb
667
+ - app/services/egov_utils/iszr/natural_people/prod_search.rb
668
+ - app/services/egov_utils/iszr/natural_people/search.rb
669
+ - app/services/egov_utils/iszr/natural_people/search_by_remote_id.rb
670
+ - app/services/egov_utils/iszr/request.rb
580
671
  - app/services/egov_utils/refresh_groups.rb
581
672
  - app/services/egov_utils/refresh_user_groups.rb
582
673
  - app/services/egov_utils/registration_requests/check_auto_accept.rb
@@ -603,6 +694,7 @@ files:
603
694
  - app/views/egov_utils/passwords/new.html.haml
604
695
  - app/views/egov_utils/passwords/reset.html.haml
605
696
  - app/views/egov_utils/people/_form.html.haml
697
+ - app/views/egov_utils/people/_new_form.html.haml
606
698
  - app/views/egov_utils/redmine/issues/index.html.haml
607
699
  - app/views/egov_utils/registration_request_mailer/accepted.html.erb
608
700
  - app/views/egov_utils/registration_request_mailer/auto_accepted.html.erb
@@ -637,6 +729,7 @@ files:
637
729
  - config/countries.csv
638
730
  - config/kraj.csv
639
731
  - config/locales/cs.yml
732
+ - config/locales/en.yml
640
733
  - config/okres.csv
641
734
  - config/routes.rb
642
735
  - db/migrate/20170313100505_create_egov_utils_addresses.rb
@@ -684,6 +777,12 @@ files:
684
777
  - lib/egov_utils/helpers/form_helper.rb
685
778
  - lib/egov_utils/helpers/tags/datetime_field_patch.rb
686
779
  - lib/egov_utils/helpers/tags/fileuid_field.rb
780
+ - lib/egov_utils/iszr/e05_osoby_response.xml
781
+ - lib/egov_utils/iszr/e20_ico_response.xml
782
+ - lib/egov_utils/iszr/lp_addresses.json
783
+ - lib/egov_utils/iszr/lp_results.json
784
+ - lib/egov_utils/iszr/np_addresses.json
785
+ - lib/egov_utils/iszr/np_results.json
687
786
  - lib/egov_utils/model_permissions.rb
688
787
  - lib/egov_utils/redmine/issue.rb
689
788
  - lib/egov_utils/routes/admin_constraint.rb
@@ -820,7 +919,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
820
919
  - !ruby/object:Gem::Version
821
920
  version: '0'
822
921
  requirements: []
823
- rubygems_version: 3.5.3
922
+ rubygems_version: 3.5.11
824
923
  signing_key:
825
924
  specification_version: 4
826
925
  summary: The eGoverment utilities is set of functionalities to support basic eGoverment