feat: write template
This commit is contained in:
commit
a0a6d2cf84
98 files changed
+6609
No files matched your search
@@ -0,0 +1,39 @@
|
||||
|
||||
#let _persons = state("598041ec-f6ce-4a04-872a-032a8325b760", ())
|
||||
|
||||
#let byFunction(
|
||||
function,
|
||||
) = {
|
||||
let ps = _persons.get().filter(person => person.at("function", default: "") == function)
|
||||
if ps.len() > 0 {
|
||||
return ps.at(0)
|
||||
} else {
|
||||
return (
|
||||
name: "Axel Schweiss",
|
||||
email: "axel.schweiss@bit.admin.ch",
|
||||
shorthand: "AS",
|
||||
function: function,
|
||||
where: "In der Genehmigung",
|
||||
git: "xxxxxxxxx",
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
#let overview() = {
|
||||
return (
|
||||
[Name],
|
||||
[Kontakt],
|
||||
[Kürzel],
|
||||
.._persons
|
||||
.get()
|
||||
.map(p => (
|
||||
[#p.at("function-name", default: p.function): \ #p.name],
|
||||
[
|
||||
#if p.at("phone", default: "") != "" { [Telefon: #link("tel:" + p.phone, p.phone) \ ] }
|
||||
#if p.at("email", default: "") != "" { [Email: #link("mailto:" + p.email, p.email) \ ] }
|
||||
],
|
||||
p.shorthand,
|
||||
))
|
||||
.flatten(),
|
||||
)
|
||||
}
|
||||
Reference in new issue
Block a user