Account for admin and builder status in users table

This commit is contained in:
Andrew Kingston 2022-08-05 09:19:08 +01:00
parent 8cd07023ce
commit e4880eff24
1 changed files with 7 additions and 1 deletions

View File

@ -1,13 +1,19 @@
<script> <script>
import { Icon } from "@budibase/bbui" import { Icon } from "@budibase/bbui"
import { apps } from "stores/portal"
export let value export let value
export let row
$: priviliged = row?.admin?.global || row?.builder?.global
$: count = priviliged ? $apps.length : value?.length || 0
</script> </script>
<div class="align"> <div class="align">
<div class="spacing"> <div class="spacing">
<Icon name="WebPage" /> <Icon name="WebPage" />
</div> </div>
{parseInt(value?.length) || 0} {count}
</div> </div>
<style> <style>