mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-09-20 23:16:15 +08:00
Merge pull request #4769 from aignatov-bio/ai-sci-7695-fix-comments-view-mode-experiment-table
Experiment table - fix comments view mode [SCI-7695]
This commit is contained in:
commit
29c13d8578
|
@ -636,6 +636,7 @@ ExperimnetTable.render.tags = function(data) {
|
|||
};
|
||||
|
||||
ExperimnetTable.render.comments = function(data) {
|
||||
if (data.count === 0 && !data.can_create) return '<span class="disabled">0</span>';
|
||||
return `<a href="#"
|
||||
class="open-comments-sidebar" id="comment-count-${data.id}"
|
||||
data-object-type="MyModule" data-object-id="${data.id}">
|
||||
|
|
|
@ -153,6 +153,10 @@
|
|||
display: none;
|
||||
}
|
||||
|
||||
.comments-column .disabled {
|
||||
color: $color-silver-chalice;
|
||||
}
|
||||
|
||||
.table-row {
|
||||
display: contents;
|
||||
|
||||
|
|
|
@ -169,6 +169,7 @@ module Experiments
|
|||
{
|
||||
id: my_module.id,
|
||||
count: my_module.comments.count,
|
||||
can_create: can_create_my_module_comments?(@user, my_module),
|
||||
count_unseen: count_unseen_comments(my_module, @user)
|
||||
}
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue