generated from cms/tibi-docs
This commit is contained in:
parent
c0209910e2
commit
baf4a4b7b2
@ -13,6 +13,11 @@
|
||||
|
||||
let module = $modules[col.moduleImport] || {}
|
||||
$: module = $modules[col.moduleImport] || {}
|
||||
$: console.log(
|
||||
"peron",
|
||||
$team,
|
||||
Object.values($team).filter((p) => p.personType == "employee")
|
||||
)
|
||||
</script>
|
||||
|
||||
{#if module.type == "iconCycleCircle"}
|
||||
|
@ -2,11 +2,12 @@
|
||||
export let persons: Page[]
|
||||
let boxes = persons.map((p) => p.personPreview.name)
|
||||
const sortByFirstName = (a, b) => {
|
||||
const nameA = a.name.split(" ")[0] // Extracts the first name from "First Last"
|
||||
const nameB = b.name.split(" ")[0]
|
||||
return nameA.localeCompare(nameB)
|
||||
const nameA = a?.name?.split(" ")[0] // Extracts the first name from "First Last"
|
||||
const nameB = b?.name?.split(" ")[0]
|
||||
return nameA?.localeCompare(nameB)
|
||||
}
|
||||
boxes = boxes.sort(sortByFirstName)
|
||||
$: console.log(boxes, "boxes", persons)
|
||||
</script>
|
||||
|
||||
<div class="boxList">
|
||||
|
@ -46,6 +46,7 @@
|
||||
img {
|
||||
width: 75%;
|
||||
height: auto;
|
||||
|
||||
}
|
||||
.text {
|
||||
display: flex;
|
||||
|
@ -43,5 +43,8 @@
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
gap: 20px;
|
||||
img {
|
||||
width: 48px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
@ -39,7 +39,7 @@
|
||||
/>
|
||||
</div>
|
||||
<div class="text">
|
||||
{p.personPreview.name}
|
||||
{p?.personPreview?.name}
|
||||
</div>
|
||||
</button>
|
||||
{/each}
|
||||
|
Loading…
Reference in New Issue
Block a user