mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-11-07 15:07:15 +08:00
Add shared inventories to smart annotation
This commit is contained in:
parent
9fda2dd97e
commit
f8a28f378e
2 changed files with 4 additions and 1 deletions
|
|
@ -142,7 +142,7 @@ class Repository < RepositoryBase
|
|||
end
|
||||
|
||||
def self.viewable_by_user(_user, teams)
|
||||
where(team: teams)
|
||||
accessible_by_teams(teams)
|
||||
end
|
||||
|
||||
def self.name_like(query)
|
||||
|
|
|
|||
|
|
@ -14,6 +14,9 @@
|
|||
<div class=sci-btn-group>
|
||||
<% repositories.each do |repository| %>
|
||||
<button class="btn btn-light repository-object" data-object-id="<%= repository.id %>">
|
||||
<% if repository.shared_with?(current_team) %>
|
||||
<i class="fas fa-user-friends"></i>
|
||||
<% end %>
|
||||
<%= repository.name %>
|
||||
</button>
|
||||
<% end %>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue