mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-01 13:13:22 +08:00
Merge pull request #2482 from okriuchykhin/ok_SCI_4479
Fix taken space display for teams [SCI-4479]
This commit is contained in:
commit
c09ef36f52
2 changed files with 5 additions and 1 deletions
|
@ -5,6 +5,10 @@ module Api
|
|||
class TeamSerializer < ActiveModel::Serializer
|
||||
attributes :id, :name, :description, :space_taken
|
||||
belongs_to :created_by, serializer: UserSerializer
|
||||
|
||||
def space_taken
|
||||
object.storage_used.to_i
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
<div class="space-usage grid-block">
|
||||
<span class="fas fa-hdd"></span>
|
||||
<span class="hidden-xs hidden-sm"><%= t("users.settings.teams.edit.header_space_taken") %></span>
|
||||
<b data-hook="team-space-taken"><%= "#{number_to_human_size(@team.space_taken)}" %></b>
|
||||
<b data-hook="team-space-taken"><%= "#{number_to_human_size(@team.storage_used)}" %></b>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Reference in a new issue