Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add recent charts and reports portlet #968

Merged
merged 2 commits into from
Jul 12, 2019

Conversation

mkzia
Copy link
Contributor

@mkzia mkzia commented Jun 20, 2019

Description

This PR adds the recent charts and report portlet. The following files were changed:

  • classes/Rest/Controllers/SummaryControllerProvider.php was updated to add a new REST endpoint recentchartsreports. This endpoint returns a user's recent charts and reports in JSON format.
  • configuration/etl/etl_tables.d/xdb/reports.json was updated to modify the Reports table to include the last modified date.
  • configuration/etl/etl.d/xdmod-migration-8_1_2-8_5_0.json was added to add the last modified field to the Reports table when migrating.
  • classes/XDReportManager.php was updated to return the newly addedlast_modified field when fetchReportTable is called.
  • configuration/assets.json was updated to include the this portlet
  • html/gui/js/modules/ReportGenerator.js was updated to add a new listener called load_report. This listener is used to fire an event that selects the report clicked in the recent charts and reports portlet.
  • html/gui/js/report_builder/ReportsOverview.js was updated to add a new listener called load_report that opens the report selected by the load_report listener in html/gui/js/modules/ReportGenerator.js.
  • html/gui/js/modules/summary/RecentChartsReportsPortlet.js was added to render the recent charts and reports portlet.

To enable, add the following to /etc/xdmod/roles.d/summary.json

{
    "+roles": {
        "+default": {
            "summary_portlets": [
                {
                    "name": "Recent Charts and Reports",
                    "type": "RecentChartsReportsPortlet",
                    "config": {}
                }
            ]
        }
    }
}

Motivation and Context

To make it easier for selected users to quickly access their recent charts and reports.

Tests performed

Manually tested the functionality. Have plans to add integrations tests.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project as found in the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@mkzia mkzia requested a review from jpwhite4 June 20, 2019 21:12
@jpwhite4 jpwhite4 added the Category:User Dashboard Screen shown after user login label Jul 11, 2019
@jpwhite4
Copy link
Member

Need to fix merge conflicts

@mkzia mkzia force-pushed the add_recent_charts_reports_portlet2 branch from 788e84d to 542e3ca Compare July 12, 2019 14:02
@jpwhite4 jpwhite4 merged commit 127fed5 into ubccr:xdmod8.5 Jul 12, 2019
@jpwhite4 jpwhite4 added this to the 8.5.0 milestone Aug 5, 2019
@plessbd plessbd added the new feature New functionality label Oct 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category:User Dashboard Screen shown after user login new feature New functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants