Added csv download option to reports.

This commit is contained in:
naomi 2022-04-21 13:48:35 +01:00
parent c1a79f6747
commit 917161c3e6
8 changed files with 1272 additions and 828 deletions

View File

@ -52,6 +52,7 @@
"drupal/typed_data": "^1.0@alpha",
"drupal/views_aggregator": "^2.0",
"drupal/views_autosubmit": "^1.4",
"drupal/views_data_export": "^1.1",
"drupal/views_summarize": "1.1.x-dev",
"drush/drush": "*"
},

205
composer.lock generated
View File

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "cae722cdc05e4e2525a003694a33aa1d",
"content-hash": "fc650255701de3f228f8fcc1979b9880",
"packages": [
{
"name": "asm89/stack-cors",
@ -2557,6 +2557,56 @@
},
"time": "2022-03-21T21:21:58+00:00"
},
{
"name": "drupal/csv_serialization",
"version": "2.0.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/csv_serialization.git",
"reference": "8.x-2.0"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/csv_serialization-8.x-2.0.zip",
"reference": "8.x-2.0",
"shasum": "3531383a6926a4ed761be56553997c2a937449ac"
},
"require": {
"drupal/core": "^8 || ^9",
"league/csv": "^9.1"
},
"require-dev": {
"dealerdirect/phpcodesniffer-composer-installer": "^0.5.0",
"drupal/coder": "^8.3"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-2.0",
"datestamp": "1612801962",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "Matthew Grasmick",
"homepage": "https://www.drupal.org/user/455714"
}
],
"description": "Provides CSV as a serialization format.",
"homepage": "https://www.drupal.org/project/csv_serialization",
"support": {
"source": "http://cgit.drupalcode.org/csv_serialization",
"issues": "https://www.drupal.org/project/issues/csv_serialization"
}
},
{
"name": "drupal/ctools",
"version": "3.7.0",
@ -4406,6 +4456,75 @@
"issues": "https://www.drupal.org/project/issues/views_autosubmit"
}
},
{
"name": "drupal/views_data_export",
"version": "1.1.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/views_data_export.git",
"reference": "8.x-1.1"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/views_data_export-8.x-1.1.zip",
"reference": "8.x-1.1",
"shasum": "8ee9d441e69b5861ab12286246522d52613f4e61"
},
"require": {
"drupal/core": "^8.8 || ^9",
"drupal/csv_serialization": "~1.4 || ~2.0"
},
"require-dev": {
"drupal/search_api": "~1.12",
"drupal/xls_serialization": "~1.0"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-1.1",
"datestamp": "1642805106",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0+"
],
"authors": [
{
"name": "Steven Jones",
"homepage": "https://www.drupal.org/user/99644"
},
{
"name": "amoebanath",
"homepage": "https://www.drupal.org/user/2810799"
},
{
"name": "james.williams",
"homepage": "https://www.drupal.org/user/592268"
},
{
"name": "jamsilver",
"homepage": "https://www.drupal.org/user/476732"
},
{
"name": "jhedstrom",
"homepage": "https://www.drupal.org/user/208732"
},
{
"name": "nerdstein",
"homepage": "https://www.drupal.org/user/1557710"
}
],
"description": "Plugin to export views data into various file formats.",
"homepage": "https://www.drupal.org/project/views_data_export",
"support": {
"source": "https://git.drupalcode.org/project/views_data_export"
}
},
{
"name": "drupal/views_summarize",
"version": "dev-1.1.x",
@ -5426,6 +5545,90 @@
],
"time": "2021-11-16T10:29:06+00:00"
},
{
"name": "league/csv",
"version": "9.8.0",
"source": {
"type": "git",
"url": "https://github.com/thephpleague/csv.git",
"reference": "9d2e0265c5d90f5dd601bc65ff717e05cec19b47"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thephpleague/csv/zipball/9d2e0265c5d90f5dd601bc65ff717e05cec19b47",
"reference": "9d2e0265c5d90f5dd601bc65ff717e05cec19b47",
"shasum": ""
},
"require": {
"ext-json": "*",
"ext-mbstring": "*",
"php": "^7.4 || ^8.0"
},
"require-dev": {
"ext-curl": "*",
"ext-dom": "*",
"friendsofphp/php-cs-fixer": "^v3.4.0",
"phpstan/phpstan": "^1.3.0",
"phpstan/phpstan-phpunit": "^1.0.0",
"phpstan/phpstan-strict-rules": "^1.1.0",
"phpunit/phpunit": "^9.5.11"
},
"suggest": {
"ext-dom": "Required to use the XMLConverter and or the HTMLConverter classes",
"ext-iconv": "Needed to ease transcoding CSV using iconv stream filters"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "9.x-dev"
}
},
"autoload": {
"files": [
"src/functions_include.php"
],
"psr-4": {
"League\\Csv\\": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Ignace Nyamagana Butera",
"email": "nyamsprod@gmail.com",
"homepage": "https://github.com/nyamsprod/",
"role": "Developer"
}
],
"description": "CSV data manipulation made easy in PHP",
"homepage": "https://csv.thephpleague.com",
"keywords": [
"convert",
"csv",
"export",
"filter",
"import",
"read",
"transform",
"write"
],
"support": {
"docs": "https://csv.thephpleague.com",
"issues": "https://github.com/thephpleague/csv/issues",
"rss": "https://github.com/thephpleague/csv/releases.atom",
"source": "https://github.com/thephpleague/csv"
},
"funding": [
{
"url": "https://github.com/sponsors/nyamsprod",
"type": "github"
}
],
"time": "2022-01-04T00:13:07+00:00"
},
{
"name": "masterminds/html5",
"version": "2.7.5",

View File

@ -14,6 +14,7 @@ module:
contact: 0
content_as_config: 0
contextual: 0
csv_serialization: 0
ctools: 0
date_popup: 0
datetime: 0
@ -78,6 +79,7 @@ module:
user: 0
views_aggregator: 0
views_autosubmit: 0
views_data_export: 0
views_summarize: 0
views_ui: 0
hide_revision_field: 1

View File

@ -15,12 +15,16 @@ dependencies:
- taxonomy.vocabulary.tags
- user.role.gno_admin_user
module:
- csv_serialization
- datetime
- opencase_cases
- opencase_entities
- options
- rest
- serialization
- taxonomy
- user
- views_data_export
- views_summarize
id: case_fees_report
label: 'Case Fees Report'
@ -1162,6 +1166,55 @@ display:
- user
- user.roles
tags: { }
data_export_1:
id: data_export_1
display_title: 'Data export'
display_plugin: data_export
position: 3
display_options:
style:
type: data_export
options:
formats:
csv: csv
csv_settings:
delimiter: ','
enclosure: '"'
escape_char: \
strip_tags: true
trim: true
encoding: utf8
utf8_bom: '0'
use_serializer_encode_only: false
display_extenders: { }
path: case_fees_report/download
auth:
- cookie
displays:
page_1: page_1
default: '0'
filename: '[view:label]-[date:short] '
automatic_download: false
store_in_public_file_directory: null
custom_redirect_path: false
redirect_to_display: none
include_query_params: false
cache_metadata:
max-age: -1
contexts:
- 'languages:language_content'
- 'languages:language_interface'
- request_format
- url
- user
- user.roles
tags:
- 'config:field.storage.oc_case.field_contract_signed_date'
- 'config:field.storage.oc_organisation.field_client_subtype'
- 'config:field.storage.oc_organisation.field_client_type'
- 'config:field.storage.oc_organisation.field_tags'
- 'config:field.storage.oc_organisation.field_type_of_umbrella_client'
- 'config:field.storage.oc_organisation.field_umbrella_client'
page_1:
id: page_1
display_title: Page

View File

@ -8,10 +8,14 @@ dependencies:
- system.menu.opencase
- user.role.gno_admin_user
module:
- csv_serialization
- opencase_cases
- opencase_entities
- options
- rest
- serialization
- user
- views_data_export
id: case_provision_report
label: 'Case provision report'
module: views
@ -693,6 +697,50 @@ display:
tags:
- 'config:field.storage.oc_case_provision.field_rate'
- 'config:field.storage.oc_case_provision.field_rate_type'
data_export_1:
id: data_export_1
display_title: 'Data export'
display_plugin: data_export
position: 2
display_options:
style:
type: data_export
options:
formats:
csv: csv
csv_settings:
delimiter: ','
enclosure: '"'
escape_char: \
strip_tags: true
trim: true
encoding: utf8
utf8_bom: '0'
use_serializer_encode_only: false
display_extenders: { }
path: case_provision_report/download
auth:
- cookie
displays:
page_1: page_1
default: '0'
filename: 'Trainer-report-[date:short] '
automatic_download: false
store_in_public_file_directory: null
custom_redirect_path: false
redirect_to_display: none
include_query_params: false
cache_metadata:
max-age: -1
contexts:
- 'languages:language_content'
- 'languages:language_interface'
- request_format
- url
- user.roles
tags:
- 'config:field.storage.oc_case_provision.field_rate'
- 'config:field.storage.oc_case_provision.field_rate_type'
page_1:
id: page_1
display_title: Page

View File

@ -21,11 +21,15 @@ dependencies:
- user.role.gno_admin_user
module:
- better_exposed_filters
- csv_serialization
- datetime
- opencase_entities
- options
- rest
- serialization
- taxonomy
- user
- views_data_export
id: client_report
label: 'Client Report'
module: views
@ -1256,6 +1260,57 @@ display:
- 'config:field.storage.oc_organisation.field_tags'
- 'config:field.storage.oc_organisation.field_type_of_umbrella_client'
- 'config:field.storage.oc_organisation.field_umbrella_client'
data_export_1:
id: data_export_1
display_title: 'Data export'
display_plugin: data_export
position: 2
display_options:
style:
type: data_export
options:
formats:
csv: csv
csv_settings:
delimiter: ','
enclosure: '"'
escape_char: \
strip_tags: true
trim: true
encoding: utf8
utf8_bom: '0'
use_serializer_encode_only: false
display_extenders: { }
path: client-report/download
auth:
- cookie
displays:
page_1: page_1
default: '0'
filename: '[view:label]-[date:short]'
automatic_download: false
store_in_public_file_directory: null
custom_redirect_path: false
redirect_to_display: none
include_query_params: false
cache_metadata:
max-age: -1
contexts:
- 'languages:language_content'
- 'languages:language_interface'
- request_format
- url
- user
- user.roles
tags:
- 'config:field.storage.oc_organisation.field_accreditation_date'
- 'config:field.storage.oc_organisation.field_client_status'
- 'config:field.storage.oc_organisation.field_client_substatus'
- 'config:field.storage.oc_organisation.field_client_subtype'
- 'config:field.storage.oc_organisation.field_client_type'
- 'config:field.storage.oc_organisation.field_tags'
- 'config:field.storage.oc_organisation.field_type_of_umbrella_client'
- 'config:field.storage.oc_organisation.field_umbrella_client'
page_1:
id: page_1
display_title: Page

View File

@ -8,7 +8,10 @@ dependencies:
- user.role.gno_admin_user
module:
- opencase_entities
- rest
- serialization
- user
- views_data_export
id: debrief_report
label: 'Debrief Report'
module: views
@ -362,6 +365,34 @@ display:
- url.query_args
- user.roles
tags: { }
data_export_1:
id: data_export_1
display_title: 'Data export'
display_plugin: data_export
position: 2
display_options:
display_extenders: { }
path: debrief-report/download
auth:
- cookie
displays:
page_1: page_1
default: '0'
filename: '[view:label]-[date:short]'
automatic_download: false
store_in_public_file_directory: null
custom_redirect_path: false
redirect_to_display: none
include_query_params: false
cache_metadata:
max-age: -1
contexts:
- 'languages:language_content'
- 'languages:language_interface'
- request_format
- url
- user.roles
tags: { }
page_1:
id: page_1
display_title: Page

File diff suppressed because it is too large Load Diff