Add storage to member's list

This commit is contained in:
Tanner Collin 2022-11-27 16:10:33 +00:00
parent 86c8e4f102
commit d7ec3f6e87
3 changed files with 21 additions and 1 deletions

View File

@ -765,6 +765,7 @@ class UserSerializer(serializers.ModelSerializer):
'app_version',
#'usages',
'interests',
'storage',
]
depth = 1

View File

@ -235,7 +235,21 @@ export function Members(props) {
</>
:
<>
<Item.Description>Status: {x.member.status || 'Unknown'}</Item.Description>
<Item.Description>
Shelf: {x.member.storage.length ?
x.member.storage.map((x, i) =>
<Button
className='storage-button'
onClick={(e) => e.preventDefault()}
size='tiny'
>
{x.shelf_id}
</Button>
)
:
'None'
}
</Item.Description>
<Item.Description>Joined: {x.member.application_date || 'Unknown'}</Item.Description>
</>
}

View File

@ -162,6 +162,11 @@ body {
padding-right: 0.5rem;
}
.ui.button.storage-button {
padding-left: 0.5rem;
padding-right: 0.5rem;
}
.ui.tag.label {
padding-left: 1rem;
padding-right: 0.5rem;