-
Notifications
You must be signed in to change notification settings - Fork 37
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 image section to trial details page #5337
base: master
Are you sure you want to change the base?
Conversation
…d displays images from each plot in a table
add accession name to table, make images a bit larger, allow sorting by columns |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Ben, this looks great. A nice addition would be to add a button or link to an image upload facility. What do you think?
@lukasmueller That sounds like a good idea, I will add that! |
@@ -111,6 +111,24 @@ sub image_search :Path('/ajax/search/images') Args(0) { | |||
my $image_page = "/image/view/$image_id"; | |||
my $colorbox = qq|<a href="$image_img" title="<a href=$image_page>Go to image page ($image_name)</a>" class="image_search_group" rel="gallery-figures"><img src="$small_image" width="40" height="30" border="0" alt="$image_description" /></a>|; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in the img src tag, do not specify both width and height because that distorts images. I would just specify width, because that's important for the table, and the height is whatever it is
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
mason/image/plot_images.mas
Outdated
@@ -12,6 +12,10 @@ $stockref => undef | |||
|
|||
<& /util/import_javascript.mas, classes => [ 'jquery', 'thickbox', 'jquery.dataTables' ] &> | |||
|
|||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.7.1/jszip.min.js"></script> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could also be done in the backend? If javascript, install it with npm?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just two small comments. Let me know what you think
@@ -40,7 +40,7 @@ sub image_search :Path('/ajax/search/images') Args(0) { | |||
|
|||
my @stock_name_list; | |||
if (exists($params->{image_stock_uniquename}) && $params->{image_stock_uniquename}) { | |||
push @stock_name_list, $params->{image_stock_uniquename}; | |||
@stock_name_list = split /,/, $params->{image_stock_uniquename}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this be compatible with previous usage? When a url parameter is repeated, it will appear as a listref here. So maybe check for it being a listref and handle that case, and then handle the case of the comma separated string?
|
||
<script> | ||
|
||
<%perl> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The authentication should not be needed, as the user is either unauthenticated and can't see this page, or they are already authenticataed and this shouldn't be necessary?
… stock name search
…e() in trial images test
Requires solgenomics/cxgn-corelibs#44 to be merged to pass tests |
add a note to meatadata that something was deleted? |
Description
Adds an image section to the trial details page that displays all of the images from every plot associated with the trial
Closes #5276
Checklist
/t/data/fixture/patches/
./docs
has been updated./js
to/js/source/legacy
.