UofS-Pulse-Binfo / rawphenotypes

A Tripal module for storing raw phenotypic data. Specifically meant to help researchers contribute raw data, visualize summaries and download for further analysis.
2 stars 2 forks source link

Issue # 64 - Download page updates #65

Closed reynoldtan closed 5 years ago

reynoldtan commented 5 years ago
reynoldtan commented 5 years ago

PR# 65 - Download page updates

Metadata

Issue # 64 - [https://github.com/UofS-Pulse-Binfo/rawphenotypes/issues/64]

Documentation:

Description

Dropped the option "All projects" from select project option and modified the query that generates projects to inspect which got a recent data upload (latest planting year) and push it to the top of the list of projects.

Environment data file option disables or enables base on whether the filter combination returns a file or not. This is achieved by adding a query to check if year+location+project returned a file. A script attached listens for event and uses the check value to enable or disable evn. data option.

Improved page load time by utilizing a table (materialized view) containing a summarized data of all raw phenotypes to load trait set given a location + project.

Dependencies

no dependencies.

Testing?

I compared page load time of download page in portal versus KP clone and accessed projects available in either sites and compared the set of traits available for export. In both trials, page load time with this PR is faster than that in portal and traits appear to be the same.

Note: This PR now sorts the traits in alphabetical order.

A simple example: screen shot 2018-10-01 at 2 22 36 pm 2 Left is dev with this PR and right is portal.

The first option in select project filter indicates the project with the recent planting year. Upload a spreadsheet file with different planting year into a different project to alter the order and let that project be the first option.

Environment data option enables and disables based on whether a combination of filter correspond to an environment data file or not.

carolyncaron commented 5 years ago

Firstly, thank you so much for filling out the template for this PR, even though it came before the PR templates were a thing! 🤗 This made reviewing much easier for me.

All of my testing was done on dev/fresh. Because this dev site appears to be a couple of months old, I would like to re-test the functionality on a truly fresh site before approving this PR. That said, all of the changes appear to work as described and are a huge improvement to the module. From what I can tell, no bugs have been introduced.

I see that Lacey has made some comments on the code as well. Once those have been addressed I will re-test everything on a fresh site 👍

reynoldtan commented 5 years ago

Revised query to speed up data download page. Back to you Lacey.