geoblacklight_admin 0.0.1 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +59 -36
- data/Rakefile +47 -14
- data/app/assets/javascripts/geoblacklight_admin.js +2 -1
- data/app/assets/stylesheets/geoblacklight_admin/_core.scss +5 -0
- data/app/assets/stylesheets/geoblacklight_admin/modules/_chosen.scss +425 -0
- data/app/assets/stylesheets/geoblacklight_admin/modules/_forms.scss +108 -0
- data/app/controllers/admin/admin_controller.rb +4 -2
- data/app/controllers/admin/advanced_search_controller.rb +123 -103
- data/app/controllers/admin/api_controller.rb +123 -108
- data/app/controllers/admin/bookmarks_controller.rb +4 -4
- data/app/controllers/admin/bulk_actions_controller.rb +9 -4
- data/app/controllers/admin/concerns/upload_util.rb +2 -0
- data/app/controllers/admin/document_accesses_controller.rb +10 -4
- data/app/controllers/admin/document_assets_controller.rb +14 -11
- data/app/controllers/admin/document_downloads_controller.rb +12 -10
- data/app/controllers/admin/documents_controller.rb +32 -15
- data/app/controllers/admin/elements_controller.rb +6 -5
- data/app/controllers/admin/form_elements_controller.rb +4 -4
- data/app/controllers/admin/ids_controller.rb +107 -87
- data/app/controllers/admin/import_documents_controller.rb +1 -1
- data/app/controllers/admin/imports_controller.rb +7 -3
- data/app/controllers/admin/mappings_controller.rb +6 -4
- data/app/controllers/admin/notifications_controller.rb +1 -1
- data/app/controllers/admin/search_controller.rb +3 -2
- data/app/controllers/admin/users_controller.rb +2 -2
- data/app/helpers/form_input_helper.rb +4 -4
- data/app/helpers/geoblacklight_admin_helper.rb +1 -1
- data/app/indexers/document_indexer.rb +1 -1
- data/app/jobs/export_job.rb +9 -6
- data/app/jobs/export_json_bulk_job.rb +95 -0
- data/app/jobs/export_json_job.rb +14 -12
- data/app/models/admin/bookmark.rb +18 -0
- data/app/models/api_search_builder.rb +3 -1
- data/app/models/blacklight_api.rb +6 -6
- data/app/models/blacklight_api_facets.rb +7 -2
- data/app/models/blacklight_api_ids.rb +3 -4
- data/app/models/bulk_action.rb +1 -1
- data/app/models/document/bbox_validator.rb +9 -5
- data/app/models/document/date_range_validator.rb +13 -10
- data/app/models/document/geom_validator.rb +4 -2
- data/app/models/document.rb +15 -7
- data/app/models/element.rb +9 -7
- data/app/models/form_control.rb +2 -0
- data/app/models/form_element.rb +2 -0
- data/app/models/form_feature.rb +2 -0
- data/app/models/form_group.rb +2 -0
- data/app/models/form_header.rb +2 -0
- data/app/models/geoblacklight_admin/schema.rb +5 -2
- data/app/models/geoblacklight_admin.rb +2 -0
- data/app/models/import/csv_duplicates_validator.rb +2 -1
- data/app/models/import/csv_header_validator.rb +2 -1
- data/app/models/import.rb +4 -7
- data/app/models/user.rb +1 -1
- data/app/services/export_csv_service.rb +5 -1
- data/app/views/admin/advanced_search/facets.json.jbuilder +9 -8
- data/app/views/admin/advanced_search/index.json.jbuilder +8 -7
- data/app/views/admin/api/_field.json.jbuilder +1 -1
- data/app/views/admin/api/fetch.json.jbuilder +8 -7
- data/app/views/admin/api/index.json.jbuilder +8 -7
- data/app/views/admin/bookmarks/index.html.erb +2 -2
- data/app/views/admin/bulk_actions/index.html.erb +3 -3
- data/app/views/admin/bulk_actions/show.html.erb +1 -1
- data/app/views/admin/document_accesses/_form.html.erb +1 -1
- data/app/views/admin/document_accesses/destroy_all.html.erb +3 -3
- data/app/views/admin/document_accesses/edit.html.erb +1 -1
- data/app/views/admin/document_accesses/import.html.erb +2 -2
- data/app/views/admin/document_accesses/index.html.erb +9 -9
- data/app/views/admin/document_accesses/new.html.erb +1 -1
- data/app/views/admin/document_downloads/_form.html.erb +1 -1
- data/app/views/admin/document_downloads/destroy_all.html.erb +2 -2
- data/app/views/admin/document_downloads/edit.html.erb +2 -3
- data/app/views/admin/document_downloads/import.html.erb +1 -1
- data/app/views/admin/document_downloads/index.html.erb +9 -9
- data/app/views/admin/document_downloads/new.html.erb +1 -1
- data/app/views/admin/document_downloads/show.html.erb +2 -2
- data/app/views/admin/documents/_document_bookmark.html.erb +1 -1
- data/app/views/admin/documents/_form_nav.html.erb +3 -1
- data/app/views/admin/documents/_json_btaa_aardvark.jbuilder +1 -3
- data/app/views/admin/documents/_json_file.jbuilder +14 -0
- data/app/views/admin/documents/_result_selected_options.html.erb +3 -1
- data/app/views/admin/documents/edit.html.erb +1 -1
- data/app/views/admin/documents/features/_multiple_download_links.html.erb +2 -2
- data/app/views/admin/documents/fetch.json_file.jbuilder +9 -0
- data/app/views/admin/documents/index.html.erb +2 -4
- data/app/views/admin/documents/index.json_file.jbuilder +9 -0
- data/app/views/admin/documents/versions.html.erb +1 -1
- data/app/views/admin/elements/_element.json.jbuilder +4 -1
- data/app/views/admin/elements/_form.html.erb +1 -1
- data/app/views/admin/elements/edit.html.erb +2 -2
- data/app/views/admin/elements/index.html.erb +4 -4
- data/app/views/admin/elements/index.json.jbuilder +2 -0
- data/app/views/admin/elements/new.html.erb +1 -1
- data/app/views/admin/elements/show.html.erb +6 -6
- data/app/views/admin/elements/show.json.jbuilder +2 -0
- data/app/views/admin/form_elements/_form.html.erb +1 -1
- data/app/views/admin/form_elements/_form_element.json.jbuilder +2 -0
- data/app/views/admin/form_elements/edit.html.erb +2 -2
- data/app/views/admin/form_elements/index.html.erb +2 -2
- data/app/views/admin/form_elements/index.json.jbuilder +2 -0
- data/app/views/admin/form_elements/new.html.erb +1 -1
- data/app/views/admin/form_elements/show.html.erb +2 -2
- data/app/views/admin/form_elements/show.json.jbuilder +2 -0
- data/app/views/admin/ids/fetch.json.jbuilder +8 -7
- data/app/views/admin/ids/index.json.jbuilder +3 -2
- data/app/views/admin/import_documents/show.html.haml +1 -1
- data/app/views/admin/imports/_import.json.jbuilder +2 -1
- data/app/views/admin/imports/_show_failed_tab.html.erb +2 -2
- data/app/views/admin/imports/_show_success_tab.html.erb +1 -1
- data/app/views/admin/imports/edit.html.erb +3 -3
- data/app/views/admin/imports/index.html.erb +3 -3
- data/app/views/admin/layouts/application.html.erb +4 -4
- data/app/views/admin/mappings/_form.html.erb +1 -1
- data/app/views/admin/mappings/_mapping.json.jbuilder +2 -1
- data/app/views/admin/mappings/edit.html.erb +2 -2
- data/app/views/admin/mappings/new.html.erb +1 -1
- data/app/views/admin/mappings/show.html.erb +2 -2
- data/app/views/admin/notifications/index.html.erb +3 -3
- data/app/views/admin/search/index.html.erb +2 -2
- data/app/views/admin/shared/_navbar.html.erb +11 -6
- data/app/views/admin/shared/_toast.html.erb +1 -1
- data/app/views/admin/users/index.html.erb +1 -1
- data/app/views/catalog/_show_gbl_admin.html.erb +3 -0
- data/config/locales/documents.en.yml +3 -0
- data/config/routes.rb +37 -33
- data/db/migrate/20230316183001_add_geoblacklight_admin_gem.rb +409 -0
- data/db/seeds.rb +7 -6
- data/db/seeds_elements.csv +56 -55
- data/db/seeds_elements.numbers +0 -0
- data/db/seeds_form_elements.csv +65 -64
- data/db/seeds_form_elements.numbers +0 -0
- data/lib/generators/geoblacklight_admin/config_generator.rb +61 -94
- data/lib/generators/geoblacklight_admin/install_generator.rb +3 -12
- data/lib/generators/geoblacklight_admin/jobs_generator.rb +3 -2
- data/lib/generators/geoblacklight_admin/models_generator.rb +0 -1
- data/lib/generators/geoblacklight_admin/templates/_show_sidebar.html.erb +19 -0
- data/lib/generators/geoblacklight_admin/templates/_user_util_links.html.erb +1 -1
- data/lib/generators/geoblacklight_admin/templates/config/database.yml +9 -5
- data/lib/generators/geoblacklight_admin/templates/config/geomg_aardvark_schema.json +12 -6
- data/lib/generators/geoblacklight_admin/templates/config/initializers/devise.rb +315 -0
- data/lib/generators/geoblacklight_admin/templates/config/initializers/geoblacklight_admin.rb +1 -2
- data/lib/generators/geoblacklight_admin/templates/config/initializers/kithe.rb +2 -0
- data/lib/generators/geoblacklight_admin/templates/config/initializers/mime_types.rb +15 -0
- data/lib/generators/geoblacklight_admin/templates/config/initializers/pagy.rb +152 -68
- data/lib/generators/geoblacklight_admin/templates/config/initializers/simple_form.rb +178 -0
- data/lib/generators/geoblacklight_admin/templates/config/initializers/simple_form_bootstrap.rb +365 -0
- data/lib/generators/geoblacklight_admin/templates/config/settings.yml +293 -0
- data/lib/generators/geoblacklight_admin/templates/javascript/controllers/results_controller.js +10 -0
- data/lib/generators/geoblacklight_admin/templates/package.json +3 -0
- data/lib/generators/geoblacklight_admin/templates/solr/conf/schema.xml +3 -3
- data/lib/generators/geoblacklight_admin/views_generator.rb +2 -3
- data/lib/geoblacklight_admin/engine.rb +5 -6
- data/lib/geoblacklight_admin/version.rb +1 -1
- data/lib/geoblacklight_admin.rb +1 -1
- data/lib/tasks/geoblacklight_admin.rake +15 -11
- metadata +101 -63
- data/.editorconfig +0 -18
- data/.gitignore +0 -75
- data/.standard.yml +0 -4
- data/Gemfile +0 -59
- data/LICENSE +0 -21
- data/app/assets/images/.keep +0 -0
- data/app/controllers/admin/concerns/.keep +0 -0
- data/app/models/bookmark.rb +0 -17
- data/app/models/concerns/.keep +0 -0
- data/db/migrate/20230316183001_add_geoblacklight_admin.rb +0 -399
- data/geoblacklight_admin.gemspec +0 -67
- data/lib/generators/geoblacklight_admin/example_docs_generator.rb +0 -18
- data/lib/generators/geoblacklight_admin/templates/.env.development.example +0 -28
- data/lib/generators/geoblacklight_admin/templates/.solr_wrapper.yml +0 -7
- data/lib/generators/geoblacklight_admin/templates/solr/snapshots/.keep +0 -0
- data/lib/tasks/.keep +0 -0
- data/spec/test_app_templates/lib/generators/test_app_generator.rb +0 -35
- data/template.rb +0 -16
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/confirmations/new.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/invitations/edit.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/invitations/new.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/mailer/invitation_instructions.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/mailer/invitation_instructions.text.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/passwords/edit.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/passwords/new.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/registrations/edit.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/registrations/new.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/sessions/new.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/shared/_links.html.erb +0 -0
- /data/{app/views/admin → lib/generators/geoblacklight_admin/templates}/devise/unlocks/new.html.erb +0 -0
data/db/seeds_elements.csv
CHANGED
@@ -1,56 +1,57 @@
|
|
1
1
|
label,solr_field,field_definition,field_type,required,repeatable,formable,placeholder_text,data_entry_hint,test_fixture_example,controlled_vocabulary,js_behaviors,html_attributes,display_only_on_persisted,importable,import_deliminated,import_transformation_method,exportable,export_transformation_method,indexable,index_transformation_method,validation_method,position
|
2
|
-
Title,dct_title_s,https://opengeometadata.org/
|
3
|
-
Alternative Title,dct_alternative_sm,https://opengeometadata.org/
|
4
|
-
Description,dct_description_sm,https://opengeometadata.org/
|
5
|
-
Language,dct_language_sm,https://opengeometadata.org/
|
6
|
-
|
7
|
-
|
8
|
-
Creator
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
Resource
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
Geometry,locn_geometry,https://opengeometadata.org/
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
Is
|
30
|
-
|
31
|
-
Is
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
Accrual
|
47
|
-
|
48
|
-
Date
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
2
|
+
Title,dct_title_s,https://opengeometadata.org/ogm-aardvark/#title,string,TRUE,FALSE,TRUE,,"Theme: city, state, temporal coverage",title,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,title,presence,1
|
3
|
+
Alternative Title,dct_alternative_sm,https://opengeometadata.org/ogm-aardvark/#alternative-title,string,FALSE,TRUE,TRUE,,,alternative-title1|alternative-title2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,2
|
4
|
+
Description,dct_description_sm,https://opengeometadata.org/ogm-aardvark/#description,text,FALSE,TRUE,TRUE,,,description1|description2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,3
|
5
|
+
Language,dct_language_sm,https://opengeometadata.org/ogm-aardvark/#language,string,FALSE,TRUE,TRUE,,,language1|language2,languages,autocomplete,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,4
|
6
|
+
Display Note,gbl_displayNote_sm,https://opengeometadata.org/ogm-aardvark/#display-note,string,FALSE,TRUE,TRUE,,"Prefix the string with ""Danger:"", ""Info:"", ""Tip:"", or ""Warning:"" to specify the type of note.",Danger: This text will be displayed in a red box|Info: This text will be displayed in a blue box,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,5
|
7
|
+
B1G Language,b1g_language_sm,https://geobtaa.github.io/metadata/b1g-custom-elements/#language-string,string,FALSE,TRUE,TRUE,,,b1g_language1|b1g_language2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,iso_language_mapping,,6
|
8
|
+
Creator,dct_creator_sm,https://opengeometadata.org/ogm-aardvark/#creator,string,FALSE,TRUE,TRUE,,,creator1|creator2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,7
|
9
|
+
Creator ID,b1g_creatorID_sm,https://geobtaa.github.io/metadata/b1g-custom-elements/#creator-id,string,FALSE,TRUE,TRUE,,,creatorID1|creatorID2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,8
|
10
|
+
Publisher,dct_publisher_sm,https://opengeometadata.org/ogm-aardvark/#publisher,string,FALSE,TRUE,TRUE,,,publisher1|publisher2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,9
|
11
|
+
Provider,schema_provider_s,https://opengeometadata.org/ogm-aardvark/#provider,string,FALSE,FALSE,TRUE,,,Provider,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,10
|
12
|
+
Resource Class,gbl_resourceClass_sm,https://opengeometadata.org/ogm-aardvark/#resource-class,string,TRUE,TRUE,TRUE,,,Geospatial data|Maps,resource_classes,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,presence,11
|
13
|
+
Resource Type,gbl_resourceType_sm,https://opengeometadata.org/ogm-aardvark/#resource-type,string,FALSE,TRUE,TRUE,,,resource-type1|resource-type2,resource_types,autocomplete,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,12
|
14
|
+
Subject,dct_subject_sm,https://opengeometadata.org/ogm-aardvark/#subject,string,FALSE,TRUE,TRUE,,,subject1|subject2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,13
|
15
|
+
Theme,dcat_theme_sm,https://opengeometadata.org/ogm-aardvark/#theme,string,FALSE,TRUE,TRUE,,,Farming|Biota,themes,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,14
|
16
|
+
Keyword,dcat_keyword_sm,https://opengeometadata.org/ogm-aardvark/#keyword,string,FALSE,TRUE,TRUE,,,keyword1|keyword2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,15
|
17
|
+
Temporal Coverage,dct_temporal_sm,https://opengeometadata.org/ogm-aardvark/#temporal-coverage,string,FALSE,TRUE,TRUE,,,2019|2020,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,16
|
18
|
+
Date Issued,dct_issued_s,https://opengeometadata.org/ogm-aardvark/#date-issued,string,FALSE,FALSE,TRUE,,YYYY,1/1/20,,datepicker-years,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,17
|
19
|
+
Index Year,gbl_indexYear_im,https://opengeometadata.org/ogm-aardvark/#index-year,integer,FALSE,TRUE,TRUE,,YYYY,2020|2021,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,18
|
20
|
+
Date Range,gbl_dateRange_drsim,https://opengeometadata.org/ogm-aardvark/#date-range,string,FALSE,TRUE,TRUE,YYYY-YYYY,,2020-2020,,mask,"{:""data-inputmask""=>""'mask': '9999-9999'""}",FALSE,TRUE,TRUE,,TRUE,date_range_json,TRUE,date_range_json,Document::DateRangeValidator,19
|
21
|
+
Spatial Coverage,dct_spatial_sm,https://opengeometadata.org/ogm-aardvark/#spatial-coverage,string,FALSE,TRUE,TRUE,,,spatial-coverage1|spatial-coverage2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,20
|
22
|
+
Geometry,locn_geometry,https://opengeometadata.org/ogm-aardvark/#geometry,string,FALSE,FALSE,TRUE,,"WKT - An ENVELOPE, POLYGON, or MULTIPOLYGON value. Use ENVELOPE(-180,180,90,-90) for a whole earth geometry.","POLYGON((-88.11 41.75, -84.75 41.75, -84.75 37.86, -88.11 37.86, -88.11 41.75))",,,,FALSE,TRUE,FALSE,,TRUE,derive_locn_geometry,TRUE,derive_locn_geometry,Document::GeomValidator,21
|
23
|
+
Bounding Box,dcat_bbox,https://opengeometadata.org/ogm-aardvark/#bounding-box,string,FALSE,FALSE,TRUE,,"W,S,E,N - A centroid will be derived from this value.","-95.0379,40.6333,-91.198,43.1373",,,,FALSE,TRUE,FALSE,,TRUE,derive_dcat_bbox,TRUE,derive_dcat_bbox,Document::BboxValidator,22
|
24
|
+
Centroid,dcat_centroid,https://opengeometadata.org/ogm-aardvark/#centroid,string,FALSE,FALSE,TRUE,,,"39.805,-86.43",,,,FALSE,TRUE,FALSE,,TRUE,derive_dcat_centroid,TRUE,derive_dcat_centroid,,23
|
25
|
+
Georeferenced,gbl_georeferenced_b,https://opengeometadata.org/ogm-aardvark/#georeferenced,boolean,FALSE,FALSE,TRUE,,,FALSE,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,24
|
26
|
+
GeoNames,b1g_geonames_sm,https://geobtaa.github.io/metadata/b1g-custom-elements/#geonames,string,FALSE,TRUE,TRUE,,,geonames1|geonames2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,25
|
27
|
+
Relation,dct_relation_sm,https://opengeometadata.org/ogm-aardvark/#relation,string,FALSE,TRUE,TRUE,,,relation1|relation2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,26
|
28
|
+
Member Of,pcdm_memberOf_sm,https://opengeometadata.org/ogm-aardvark/#member-of,string,FALSE,TRUE,TRUE,,,member-of1|member-of2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,27
|
29
|
+
Is Part Of,dct_isPartOf_sm,https://opengeometadata.org/ogm-aardvark/#is-part-of,string,FALSE,TRUE,TRUE,,,is-part-of1|is-part-of2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,28
|
30
|
+
Source,dct_source_sm,https://opengeometadata.org/ogm-aardvark/#source,string,FALSE,TRUE,TRUE,,,source1|source2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,29
|
31
|
+
Is Version Of,dct_isVersionOf_sm,https://opengeometadata.org/ogm-aardvark/#is-version-of,string,FALSE,TRUE,TRUE,,,version1|version2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,30
|
32
|
+
Replaces,dct_replaces_sm,https://opengeometadata.org/ogm-aardvark/#replaces,string,FALSE,TRUE,TRUE,,,replaces1|replaces2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,31
|
33
|
+
Is Replaced By,dct_isReplacedBy_sm,https://opengeometadata.org/ogm-aardvark/#is-replaced-by,string,FALSE,TRUE,TRUE,,,is-replaced-by1|is-replaced-by2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,32
|
34
|
+
Rights,dct_rights_sm,https://opengeometadata.org/ogm-aardvark/#rights_1,string,FALSE,TRUE,TRUE,,,rights,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,33
|
35
|
+
Rights Holder,dct_rightsHolder_sm,https://opengeometadata.org/ogm-aardvark/#rights-holder,string,FALSE,TRUE,TRUE,,,rights-holder1|rights-holder2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,34
|
36
|
+
License,dct_license_sm,https://opengeometadata.org/ogm-aardvark/#license,string,FALSE,TRUE,TRUE,,,license1|license2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,35
|
37
|
+
Access Rights,dct_accessRights_s,https://opengeometadata.org/ogm-aardvark/#access-rights,string,TRUE,FALSE,TRUE,,,access-rights1|access-rights2,access_rights,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,presence,36
|
38
|
+
Format,dct_format_s,https://opengeometadata.org/ogm-aardvark/#format,string,FALSE,FALSE,TRUE,,,format,formats,autocomplete,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,37
|
39
|
+
File Size,gbl_fileSize_s,https://opengeometadata.org/ogm-aardvark/#file-size,string,FALSE,FALSE,TRUE,,,60mb,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,38
|
40
|
+
Reference,dct_references_s,https://opengeometadata.org/ogm-aardvark/#references,text,FALSE,TRUE,TRUE,,URIs and Values,,reference_values,,,FALSE,TRUE,FALSE,build_dct_references,TRUE,references_json,TRUE,references_json,,39
|
41
|
+
WxS Identifier,gbl_wxsIdentifier_s,https://opengeometadata.org/ogm-aardvark/#wxs-identifier,string,FALSE,FALSE,TRUE,,,wxs-identifier,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,40
|
42
|
+
B1G Image URL,b1g_image_ss,https://geobtaa.github.io/metadata/b1g-custom-elements/#image,string,FALSE,FALSE,TRUE,,,image,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,41
|
43
|
+
ID,geomg_id_s,https://opengeometadata.org/ogm-aardvark/#id,string,TRUE,FALSE,TRUE,,,slug,,disable_if_persisted,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,presence,42
|
44
|
+
Identifier,dct_identifier_sm,https://opengeometadata.org/ogm-aardvark/#identifier,string,FALSE,TRUE,TRUE,,,identifier1|identifier2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,43
|
45
|
+
Code,b1g_code_s,https://geobtaa.github.io/metadata/b1g-custom-elements/#code,string,FALSE,FALSE,TRUE,,,code,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,44
|
46
|
+
Accrual Method,b1g_dct_accrualMethod_s,https://geobtaa.github.io/metadata/b1g-custom-elements/#accrual-method,string,FALSE,FALSE,TRUE,,,accrual-method,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,45
|
47
|
+
Accrual Periodicity,b1g_dct_accrualPeriodicity_s,https://geobtaa.github.io/metadata/b1g-custom-elements/#accrual-periodicity,string,FALSE,FALSE,TRUE,,,Annually,accrual_periodicity,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,46
|
48
|
+
Date Accessioned,b1g_dateAccessioned_sm,https://geobtaa.github.io/metadata/b1g-custom-elements/#date-accessioned,string,FALSE,TRUE,TRUE,,,date-accessioned1|date-accessioned2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,47
|
49
|
+
Date Retired,b1g_dateRetired_s,https://geobtaa.github.io/metadata/b1g-custom-elements/#date-retired,string,FALSE,FALSE,TRUE,,YYYY-MM-DD,date-retired,,datepicker,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,48
|
50
|
+
Status,b1g_status_s,https://geobtaa.github.io/metadata/b1g-custom-elements/#status,string,FALSE,FALSE,TRUE,,,Active,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,49
|
51
|
+
Publication State,b1g_publication_state_s,https://geobtaa.github.io/metadata/b1g-custom-elements/#publication-state,string,TRUE,FALSE,TRUE,,,published,publication_states,,,TRUE,FALSE,FALSE,,TRUE,current_state,TRUE,current_state,,50
|
52
|
+
Suppressed Record,gbl_suppressed_b,https://opengeometadata.org/ogm-aardvark/#suppressed,boolean,FALSE,FALSE,TRUE,,,FALSE,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,51
|
53
|
+
Child Record,b1g_child_record_b,https://geobtaa.github.io/metadata/b1g-custom-elements/#child-record,boolean,FALSE,FALSE,TRUE,,,FALSE,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,,,52
|
54
|
+
Mediator,b1g_dct_mediator_sm,https://geobtaa.github.io/metadata/b1g-custom-elements/#mediator,string,FALSE,TRUE,TRUE,,,mediator1|mediator2,,,,FALSE,TRUE,TRUE,,TRUE,,TRUE,,,53
|
55
|
+
Access,b1g_access_s,https://geobtaa.github.io/metadata/b1g-custom-elements/#access,string,FALSE,FALSE,TRUE,,,access,,,,FALSE,TRUE,FALSE,,TRUE,,TRUE,access_json,,54
|
56
|
+
Created At,date_created_dtsi,,datetime,FALSE,FALSE,FALSE,,,2021-12-09 15:50:49.803415,,,,TRUE,FALSE,FALSE,,TRUE,created_at_dt,TRUE,created_at_dt,,55
|
57
|
+
Updated At,date_modified_dtsi,,datetime,FALSE,FALSE,FALSE,,,2022-12-12 17:02:03.422663,,,,TRUE,FALSE,FALSE,,TRUE,gbl_mdModified_dt,TRUE,gbl_mdModified_dt,,56
|
data/db/seeds_elements.numbers
CHANGED
Binary file
|
data/db/seeds_form_elements.csv
CHANGED
@@ -5,67 +5,68 @@ FormControl,,dct_title_s,3
|
|
5
5
|
FormControl,NULL,dct_alternative_sm,4
|
6
6
|
FormControl,,dct_description_sm,5
|
7
7
|
FormControl,,dct_language_sm,6
|
8
|
-
|
9
|
-
|
10
|
-
FormControl,,
|
11
|
-
FormControl,,
|
12
|
-
FormControl,,
|
13
|
-
|
14
|
-
|
15
|
-
FormControl,,
|
16
|
-
FormControl,,
|
17
|
-
FormControl,,
|
18
|
-
FormControl,,
|
19
|
-
|
20
|
-
|
21
|
-
FormControl,,
|
22
|
-
FormControl,,
|
23
|
-
|
24
|
-
|
25
|
-
FormControl,,
|
26
|
-
FormControl,,
|
27
|
-
FormControl,,
|
28
|
-
|
29
|
-
|
30
|
-
FormControl,,
|
31
|
-
FormControl,,
|
32
|
-
FormControl,,
|
33
|
-
FormControl,,
|
34
|
-
FormControl,,
|
35
|
-
FormControl,,
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
FormControl,,
|
40
|
-
FormControl,,
|
41
|
-
FormControl,,
|
42
|
-
|
43
|
-
|
44
|
-
FormControl,,
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
FormControl,,
|
50
|
-
FormControl,,
|
51
|
-
|
52
|
-
|
53
|
-
FormControl,,
|
54
|
-
FormControl,,
|
55
|
-
FormControl,,
|
56
|
-
|
57
|
-
|
58
|
-
FormControl,,
|
59
|
-
FormControl,,
|
60
|
-
FormControl,,
|
61
|
-
FormControl,,
|
62
|
-
FormControl,,
|
63
|
-
FormControl,,
|
64
|
-
FormControl,,
|
65
|
-
|
66
|
-
|
67
|
-
FormControl,,
|
68
|
-
FormControl,,
|
69
|
-
FormControl,,
|
70
|
-
|
71
|
-
|
8
|
+
FormControl,,gbl_displayNote_sm,7
|
9
|
+
FormGroup,Credits,,8
|
10
|
+
FormControl,,dct_creator_sm,9
|
11
|
+
FormControl,,b1g_creatorID_sm,10
|
12
|
+
FormControl,,dct_publisher_sm,11
|
13
|
+
FormControl,,schema_provider_s,12
|
14
|
+
FormGroup,Categories,,13
|
15
|
+
FormControl,,gbl_resourceClass_sm,14
|
16
|
+
FormControl,,gbl_resourceType_sm,15
|
17
|
+
FormControl,,dct_subject_sm,16
|
18
|
+
FormControl,,dcat_theme_sm,17
|
19
|
+
FormControl,,dcat_keyword_sm,18
|
20
|
+
FormGroup,Temporal,,19
|
21
|
+
FormControl,,dct_temporal_sm,20
|
22
|
+
FormControl,,dct_issued_s,21
|
23
|
+
FormControl,,gbl_dateRange_drsim,22
|
24
|
+
FormGroup,Spatial,,23
|
25
|
+
FormControl,,dct_spatial_sm,24
|
26
|
+
FormControl,,dcat_bbox,25
|
27
|
+
FormControl,,locn_geometry,26
|
28
|
+
FormControl,,b1g_geonames_sm,27
|
29
|
+
FormGroup,Relations,,28
|
30
|
+
FormControl,,dct_relation_sm,29
|
31
|
+
FormControl,,pcdm_memberOf_sm,30
|
32
|
+
FormControl,,dct_isPartOf_sm,31
|
33
|
+
FormControl,,dct_source_sm,32
|
34
|
+
FormControl,,dct_isVersionOf_sm,33
|
35
|
+
FormControl,,dct_replaces_sm,34
|
36
|
+
FormControl,,dct_isReplacedBy_sm,35
|
37
|
+
FormHeader,Distribution,,36
|
38
|
+
FormGroup,Object,,37
|
39
|
+
FormControl,,dct_format_s,38
|
40
|
+
FormControl,,gbl_fileSize_s,39
|
41
|
+
FormControl,,gbl_wxsIdentifier_s,40
|
42
|
+
FormControl,,gbl_georeferenced_b,41
|
43
|
+
FormGroup,Links,,42
|
44
|
+
FormControl,,dct_references_s,43
|
45
|
+
FormControl,,b1g_image_ss,44
|
46
|
+
FormFeature,Multiple Download Links,,45
|
47
|
+
FormHeader,Administrative,,46
|
48
|
+
FormGroup,Codes,,47
|
49
|
+
FormControl,,geomg_id_s,48
|
50
|
+
FormControl,,dct_identifier_sm,49
|
51
|
+
FormControl,,b1g_code_s,50
|
52
|
+
FormGroup,Rights,,51
|
53
|
+
FormControl,,dct_accessRights_s,52
|
54
|
+
FormControl,,dct_rightsHolder_sm,53
|
55
|
+
FormControl,,dct_license_sm,54
|
56
|
+
FormControl,,dct_rights_sm,55
|
57
|
+
FormGroup,Life Cycle,,56
|
58
|
+
FormControl,,date_created_dtsi,57
|
59
|
+
FormControl,,date_modified_dtsi,58
|
60
|
+
FormControl,,b1g_dct_accrualMethod_s,59
|
61
|
+
FormControl,,b1g_dct_accrualPeriodicity_s,60
|
62
|
+
FormControl,,b1g_dateAccessioned_sm,61
|
63
|
+
FormControl,,b1g_dateRetired_s,62
|
64
|
+
FormControl,,b1g_status_s,63
|
65
|
+
FormControl,,b1g_publication_state_s,64
|
66
|
+
FormGroup,Accessibility,,65
|
67
|
+
FormControl,,gbl_suppressed_b,66
|
68
|
+
FormControl,,b1g_child_record_b,67
|
69
|
+
FormControl,,b1g_dct_mediator_sm,68
|
70
|
+
FormControl,,b1g_access_s,69
|
71
|
+
FormHeader,Related Items,,70
|
72
|
+
FormFeature,Institutional Access Links,,71
|
Binary file
|
@@ -8,35 +8,29 @@ module GeoblacklightAdmin
|
|
8
8
|
|
9
9
|
desc <<-DESCRIPTION
|
10
10
|
This generator makes the following changes to your application:
|
11
|
-
1. Copies GBL Admin initializer
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
6. Copies .env.development to host
|
11
|
+
1. Copies GBL Admin initializer files to host config
|
12
|
+
5. Copies database.yml connection to host config
|
13
|
+
5. Copies settings.yml to host config
|
14
|
+
6. Copies .env.development and .env.test to host
|
15
|
+
6. Copies JSON Schema to host
|
17
16
|
7. Copies solr/* to host
|
18
17
|
8. Sets Routes
|
19
18
|
9. Sets Gems
|
20
|
-
10.Sets MimeTypes
|
21
19
|
11.Sets DB Seeds
|
20
|
+
11.Sets ActiveStorage
|
22
21
|
12.Sets Pagy Backend
|
23
22
|
|
24
23
|
DESCRIPTION
|
25
24
|
|
26
|
-
def
|
27
|
-
copy_file "config/initializers/geoblacklight_admin.rb", "config/initializers/geoblacklight_admin.rb"
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
copy_file "config/initializers/
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
copy_file "config/initializers/pagy.rb", "config/initializers/pagy.rb"
|
36
|
-
end
|
37
|
-
|
38
|
-
def create_statesman_initializer
|
39
|
-
copy_file "config/initializers/statesman.rb", "config/initializers/statesman.rb"
|
25
|
+
def create_gbl_admin_initializer_files
|
26
|
+
copy_file "config/initializers/geoblacklight_admin.rb", "config/initializers/geoblacklight_admin.rb", force: true
|
27
|
+
copy_file "config/initializers/devise.rb", "config/initializers/devise.rb", force: true
|
28
|
+
copy_file "config/initializers/kithe.rb", "config/initializers/kithe.rb", force: true
|
29
|
+
copy_file "config/initializers/mime_types.rb", "config/initializers/mime_types.rb", force: true
|
30
|
+
copy_file "config/initializers/pagy.rb", "config/initializers/pagy.rb", force: true
|
31
|
+
copy_file "config/initializers/simple_form.rb", "config/initializers/simple_form.rb", force: true
|
32
|
+
copy_file "config/initializers/simple_form_bootstrap.rb", "config/initializers/simple_form_bootstrap.rb", force: true
|
33
|
+
copy_file "config/initializers/statesman.rb", "config/initializers/statesman.rb", force: true
|
40
34
|
end
|
41
35
|
|
42
36
|
def create_database_yml
|
@@ -45,6 +39,15 @@ module GeoblacklightAdmin
|
|
45
39
|
|
46
40
|
def create_dotenv
|
47
41
|
copy_file ".env.development.example", ".env.development"
|
42
|
+
copy_file ".env.development.example", ".env.test"
|
43
|
+
end
|
44
|
+
|
45
|
+
def create_settings_yml
|
46
|
+
copy_file "config/settings.yml", "config/settings.yml", force: true
|
47
|
+
end
|
48
|
+
|
49
|
+
def create_solr_yml
|
50
|
+
copy_file ".solr_wrapper.yml", ".solr_wrapper.yml", force: true
|
48
51
|
end
|
49
52
|
|
50
53
|
def copy_json_schema
|
@@ -52,15 +55,11 @@ module GeoblacklightAdmin
|
|
52
55
|
end
|
53
56
|
|
54
57
|
def copy_solr
|
55
|
-
directory
|
56
|
-
end
|
57
|
-
|
58
|
-
def create_solr_yml
|
59
|
-
copy_file ".solr_wrapper.yml", ".solr_wrapper.yml", force: true
|
58
|
+
directory "solr", "solr", force: true
|
60
59
|
end
|
61
60
|
|
62
61
|
def set_routes
|
63
|
-
gbl_admin_routes = <<-
|
62
|
+
gbl_admin_routes = <<-ROUTES
|
64
63
|
####################
|
65
64
|
# GBL‡ADMIN
|
66
65
|
|
@@ -88,14 +87,14 @@ module GeoblacklightAdmin
|
|
88
87
|
patch :run, on: :member
|
89
88
|
patch :revert, on: :member
|
90
89
|
end
|
91
|
-
|
90
|
+
|
92
91
|
# Imports
|
93
92
|
resources :imports do
|
94
93
|
resources :mappings
|
95
94
|
resources :import_documents, only: [:show]
|
96
95
|
patch :run, on: :member
|
97
96
|
end
|
98
|
-
|
97
|
+
|
99
98
|
# Elements
|
100
99
|
resources :elements do
|
101
100
|
post :sort, on: :collection
|
@@ -109,7 +108,7 @@ module GeoblacklightAdmin
|
|
109
108
|
resources :form_group, path: :form_elements, controller: :form_elements
|
110
109
|
resources :form_control, path: :form_elements, controller: :form_elements
|
111
110
|
resources :form_feature, path: :form_elements, controller: :form_elements
|
112
|
-
|
111
|
+
|
113
112
|
# Notifications
|
114
113
|
resources :notifications do
|
115
114
|
put "batch", on: :collection
|
@@ -121,6 +120,9 @@ module GeoblacklightAdmin
|
|
121
120
|
# Bookmarks
|
122
121
|
resources :bookmarks
|
123
122
|
delete "/bookmarks", to: "bookmarks#destroy", as: :bookmarks_destroy_by_fkeys
|
123
|
+
|
124
|
+
# Search controller
|
125
|
+
get "/search" => "search#index"
|
124
126
|
|
125
127
|
# AdvancedSearch controller
|
126
128
|
get '/advanced_search' => 'advanced_search#index', constraints: lambda { |req| req.format == :json }
|
@@ -136,84 +138,84 @@ module GeoblacklightAdmin
|
|
136
138
|
# Documents
|
137
139
|
resources :documents do
|
138
140
|
get "versions"
|
139
|
-
|
141
|
+
|
140
142
|
# DocumentAccesses
|
141
143
|
resources :document_accesses, path: "access" do
|
142
144
|
collection do
|
143
145
|
get "import"
|
144
146
|
post "import"
|
145
|
-
|
147
|
+
|
146
148
|
get "destroy_all"
|
147
149
|
post "destroy_all"
|
148
150
|
end
|
149
151
|
end
|
150
|
-
|
152
|
+
|
151
153
|
# DocumentDownloads
|
152
154
|
resources :document_downloads, path: "downloads" do
|
153
155
|
collection do
|
154
156
|
get "import"
|
155
157
|
post "import"
|
156
|
-
|
158
|
+
|
157
159
|
get "destroy_all"
|
158
160
|
post "destroy_all"
|
159
161
|
end
|
160
162
|
end
|
161
|
-
|
163
|
+
|
162
164
|
# Document Assets
|
163
165
|
resources :document_assets, path: "assets" do
|
164
166
|
collection do
|
165
167
|
get "display_attach_form"
|
166
168
|
post "attach_files"
|
167
|
-
|
169
|
+
|
168
170
|
get "destroy_all"
|
169
171
|
post "destroy_all"
|
170
172
|
end
|
171
173
|
end
|
172
|
-
|
174
|
+
|
173
175
|
collection do
|
174
176
|
get "fetch"
|
175
177
|
end
|
176
178
|
end
|
177
|
-
|
179
|
+
|
178
180
|
# Document Accesses
|
179
181
|
resources :document_accesses, path: "access" do
|
180
182
|
collection do
|
181
183
|
get "import"
|
182
184
|
post "import"
|
183
|
-
|
185
|
+
|
184
186
|
get "destroy_all"
|
185
187
|
post "destroy_all"
|
186
188
|
end
|
187
189
|
end
|
188
|
-
|
190
|
+
|
189
191
|
# Document Downloads
|
190
192
|
resources :document_downloads, path: "downloads" do
|
191
193
|
collection do
|
192
194
|
get "import"
|
193
195
|
post "import"
|
194
|
-
|
196
|
+
|
195
197
|
get "destroy_all"
|
196
198
|
post "destroy_all"
|
197
199
|
end
|
198
200
|
end
|
199
|
-
|
201
|
+
|
200
202
|
# Document Assets
|
201
203
|
resources :document_assets, path: "assets" do
|
202
204
|
collection do
|
203
205
|
get "display_attach_form"
|
204
206
|
post "attach_files"
|
205
|
-
|
207
|
+
|
206
208
|
get "destroy_all"
|
207
209
|
post "destroy_all"
|
208
210
|
end
|
209
211
|
end
|
210
|
-
|
212
|
+
|
211
213
|
get "/documents/:id/ingest", to: "document_assets#display_attach_form", as: "asset_ingest"
|
212
214
|
post "/documents/:id/ingest", to: "document_assets#attach_files"
|
213
215
|
#mount Kithe::AssetUploader.upload_endpoint(:cache) => "/direct_upload", :as => :direct_app_upload
|
214
|
-
|
216
|
+
|
215
217
|
resources :collections, except: [:show]
|
216
|
-
|
218
|
+
|
217
219
|
# Note "assets" is Rails reserved word for routing, oops. So we use
|
218
220
|
# asset_files.
|
219
221
|
resources :assets, path: "asset_files", except: [:new, :create] do
|
@@ -221,11 +223,11 @@ module GeoblacklightAdmin
|
|
221
223
|
put "convert_to_child_work"
|
222
224
|
end
|
223
225
|
end
|
224
|
-
|
226
|
+
|
225
227
|
# @TODO
|
226
228
|
# mount Qa::Engine => "/authorities"
|
227
229
|
mount ActionCable.server => "/cable"
|
228
|
-
|
230
|
+
|
229
231
|
# @TODO
|
230
232
|
# authenticate :user, ->(user) { user } do
|
231
233
|
# mount Blazer::Engine, at: "blazer"
|
@@ -236,53 +238,14 @@ module GeoblacklightAdmin
|
|
236
238
|
inject_into_file "config/routes.rb", gbl_admin_routes, before: /^end/
|
237
239
|
end
|
238
240
|
|
239
|
-
def
|
240
|
-
|
241
|
-
|
242
|
-
# GBL‡ADMIN // @TODO: Why is this necessary? Shouldn't the engine dependencies get installed on their own?
|
243
|
-
gem 'active_storage_validations', '~> 1.0'
|
244
|
-
gem 'amazing_print'
|
245
|
-
gem 'blacklight_advanced_search'
|
246
|
-
gem 'bootstrap', '~> 4.0'
|
247
|
-
gem 'cocoon', '~> 1.2'
|
248
|
-
# gem 'devise', '~> 4.7'
|
249
|
-
gem 'devise-bootstrap-views', '~> 1.0'
|
250
|
-
gem 'devise_invitable', '~> 2.0'
|
251
|
-
gem 'dotenv-rails'
|
252
|
-
gem 'haml', '~> 5.2'
|
253
|
-
gem 'httparty'
|
254
|
-
gem 'inline_svg'
|
255
|
-
# gem 'jquery-rails', '~> 4.4'
|
256
|
-
gem 'kithe', '~> 2.0'
|
257
|
-
gem 'noticed'
|
258
|
-
gem 'pagy'
|
259
|
-
gem 'paper_trail'
|
260
|
-
gem 'qa', '~> 5.0'
|
261
|
-
gem 'ruby-progressbar'
|
262
|
-
gem 'simple_form', '~> 5.0'
|
263
|
-
gem 'statesman', '~> 7.1.0'
|
264
|
-
"
|
265
|
-
end
|
266
|
-
end
|
267
|
-
|
268
|
-
def set_mime_types
|
269
|
-
append_to_file "config/initializers/mime_types.rb" do
|
270
|
-
'
|
271
|
-
# GBL‡ADMIN
|
272
|
-
# Order is important. ActiveStorage needs :json to be last
|
273
|
-
Mime::Type.register "application/json", :json_aardvark
|
274
|
-
Mime::Type.register "application/json", :json_btaa_aardvark
|
275
|
-
Mime::Type.register "application/json", :json_gbl_v1
|
276
|
-
Mime::Type.register "application/json", :json
|
277
|
-
Mime::Type.register "text/csv", :csv_document_downloads
|
278
|
-
Mime::Type.register "text/csv", :csv_document_access_links
|
279
|
-
'
|
280
|
-
end
|
241
|
+
def set_development_mailer_host
|
242
|
+
mailer_host = "\n config.action_mailer.default_url_options = { :host => 'localhost:3000' }\n"
|
243
|
+
inject_into_file "config/environments/development.rb", mailer_host, after: "config.action_mailer.perform_caching = false"
|
281
244
|
end
|
282
245
|
|
283
246
|
def set_seeds
|
284
247
|
append_to_file "db/seeds.rb" do
|
285
|
-
|
248
|
+
"GeoblacklightAdmin::Engine.load_seed"
|
286
249
|
end
|
287
250
|
end
|
288
251
|
|
@@ -294,7 +257,7 @@ Mime::Type.register "text/csv", :csv_document_access_links
|
|
294
257
|
|
295
258
|
def add_activestorage
|
296
259
|
append_to_file "app/assets/javascripts/application.js" do
|
297
|
-
"
|
260
|
+
"
|
298
261
|
|
299
262
|
// Required by GBL Admin
|
300
263
|
//= require activestorage"
|
@@ -305,12 +268,16 @@ Mime::Type.register "text/csv", :csv_document_access_links
|
|
305
268
|
copy_file "_user_util_links.html.erb", "app/views/shared/_user_util_links.html.erb"
|
306
269
|
end
|
307
270
|
|
271
|
+
def add_show_sidebar
|
272
|
+
copy_file "_show_sidebar.html.erb", "app/views/catalog/_show_sidebar.html.erb"
|
273
|
+
end
|
274
|
+
|
308
275
|
# @TODO
|
309
276
|
# I'm certain this is not the best way to inject our JS behaviors into the root app
|
310
277
|
# But for now, this will do...
|
311
278
|
# Long term I hope to avoid webpack here altogether.
|
312
279
|
def copy_app_javascript
|
313
|
-
directory
|
280
|
+
directory "javascript", "app/javascript", force: true
|
314
281
|
end
|
315
282
|
|
316
283
|
def add_package_json
|
@@ -328,7 +295,7 @@ Mime::Type.register "text/csv", :csv_document_access_links
|
|
328
295
|
end
|
329
296
|
|
330
297
|
def add_catalog_controller_default_params
|
331
|
-
inject_into_file "app/controllers/catalog_controller.rb", after: "
|
298
|
+
inject_into_file "app/controllers/catalog_controller.rb", after: '"q.alt" => "*:*"' do
|
332
299
|
",\n 'fq' => ['b1g_publication_state_s:published']"
|
333
300
|
end
|
334
301
|
end
|