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

Wrap long location values #69

Closed reynoldtan closed 5 years ago

reynoldtan commented 5 years ago

Issue # 68 - Summary page update - wrap text in location Convert comma separated values in location into multiple lines where the country information and city/region are in separate lines.

Metadata

[https://github.com/UofS-Pulse-Binfo/rawphenotypes/issues/68]

Documentation:

Description

I reused a code used by beanplot chart in AP that wraps text into separate lines. Function wrapWords(text) added to attached JavaScript of rawdata page.

Dependencies

[https://github.com/UofS-Pulse-Binfo/rawphenotypes/pull/67]

Testing?

This update will only separate location value when a comma symbol is present. I've made two test cases where one showed Country first followed by city and another where the city preceded country information. In either format, the function separates the csv values in location into separate lines as expected. In upload page we can enforce either format as required.

sample results: screen shot 2018-10-03 at 3 44 02 pm

screen shot 2018-10-03 at 3 45 33 pm

carolyncaron commented 5 years ago

This PR works great on dev/fresh. 👍 I just endured the slowness since #67 isn't ready yet! However I would like to see how it performs on a generic Tripal site, hoping to get cloud9 set up soon to do so...