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

PTV-833 Fix genome icons in data panel #1219

Merged
merged 4 commits into from
Dec 13, 2017

Conversation

briehl
Copy link
Member

@briehl briehl commented Dec 12, 2017

A recent update replaced the genome icons in the data panel with the default icon (document). This brings them back.

The problem was with how the object type was getting interpreted by the new KBaseDataCard abstraction. I added a new "viewType" parameter to that (so the "type" string could continue to have things like the scientific name), and shuffled around how the actual data type gets read.

Also did a little bit of general cleanup on a few things.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.03%) to 12.449% when pulling 36670c9 on briehl:PTV-833-genome-icons into 383e5f7 on kbase:develop.

// in order - entry.viewType > entry.type > parsing it out of the object_info type string.
var objectType = entry.type ? entry.type : object_info[2].split('.')[1].split('-')[0],
viewType = entry.viewType ? entry.viewType : entry.type;
viewType = viewType ? viewType : objectType;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

viewType set twice seems pretty confusing. Maybe break it out into if statements?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right. Got too clever for my own good. Fixed.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.02%) to 12.454% when pulling 8f3b416 on briehl:PTV-833-genome-icons into 732e249 on kbase:develop.

@briehl briehl merged commit 2935f95 into kbase:develop Dec 13, 2017
@briehl briehl deleted the PTV-833-genome-icons branch May 8, 2018 21:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants