with django-reporting, I was wishing parts of it were implemented differently. And so,
django-spreadsheet-reports was born.
Although this project has been in development for a few years, it's documentation is very light.
A few features provided by this are:
* Ability to produce spreadsheet reports off of a user model by creating a reports.py in your app
directories. The contents of the reports.py should look like:
class UserStatsReport(django_spreadsheet_reports.Report):
name = 'Simple User Report'
slug = 'simple-user-report'
model = UserStats
filter_by = django_spreadsheet_reports.filters(
django_spreadsheet_reports.DateFilter('user__date_joined'),
django_spreadsheet_reports.Filter('user__date_joined', name='Days', multiple=True),
)
group_by = django_spreadsheet_reports.groupbys(
'user__date_joined',
django_spreadsheet_reports.GroupBy('campaign__user__username', name='Affiliate'),
django_spreadsheet_reports.GroupBy('program__name', name='Program'),
django_spreadsheet_reports.GroupBy('referring_url', name='Referring URL'),
django_spreadsheet_reports.GroupBy('track__track', name='Track'),
django_spreadsheet_reports.GroupBy('tour__name', name='Tour',
additional_columns=[
django_spreadsheet_reports.Column('tour__url', name='Tour URL'),
django_spreadsheet_reports.Column('tour__program__name', name='Program'),
]),
)
list_aggregates = django_spreadsheet_reports.columns(
django_spreadsheet_reports.Column(Count('id'), name='Members'),
* Exporting to CSV is built in
* Sortable columns
Requirements: Python>=3.4, Django>=1.5
Installation
=============
* pip install django-spreadsheet-reports
* Add `django_spreadsheet_reports` to your installed apps
* Add to your urls file: url(r'^reports/', include(django_spreadsheet_reports.site.urls)),
* Create a reports.py in one of your app directories, and add a Report subclass in it.
* Register your report subclass, by adding a line like this to the bottom of your reports
file: django_spreadsheet_reports.site.register(UserStatsReport)
Metadata
Release files for django-spreadsheet-reports 0.01.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| django-spreadsheet-reports-0.01.4.tar.gz | 16.4 kB | Without provenance | Details |
Release files / django-spreadsheet-reports-0.01.4.tar.gz
| Download URL | django-spreadsheet-reports-0.01.4.tar.gz |
|---|---|
| Size | 16.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3189179834bfb42464acf6a61a56cf11daf767ed2b33d69c489403819ea97253
|
|
BLAKE2b-256 checksum How to use checksums |
68b75a8ce48e2e5ce1c9a9c985fbc83c910bc5095569995611209e9d32fcb6b4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for django-spreadsheet-reports 0.01.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.