mirror of
https://github.com/Theodor-Springmann-Stiftung/kgpz_web.git
synced 2025-10-29 17:15:31 +00:00
Akteure beginning
This commit is contained in:
@@ -0,0 +1,58 @@
|
||||
{{ if ne (len .model.Search) 1 }}
|
||||
{{ $agent := index $.model.Agents .model.Search }}
|
||||
{{ if not $agent }}
|
||||
<div>Agent nicht gefunden: {{ .model.Search }}</div>
|
||||
{{ else }}
|
||||
<div>
|
||||
{{ $letter := Upper (FirstLetter $agent.ID) }}
|
||||
<a href="/akteure/{{ $letter }}">
|
||||
← Personen & Körperschaften – Buchstabe
|
||||
{{ $letter }}
|
||||
</a>
|
||||
</div>
|
||||
<div>{{ index $agent.Names 0 }}</div>
|
||||
{{ end }}
|
||||
{{ else }}
|
||||
<div>
|
||||
{{ range $_, $l := .model.AvailableLetters }}
|
||||
<a href="/akteure/{{ $l }}">
|
||||
{{ $l }}
|
||||
</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ range $_, $id := .model.Sorted }}
|
||||
<div class="pb-4">
|
||||
<a href="/akteure/{{ $id }}">
|
||||
{{ $a := index $.model.Agents $id }}
|
||||
{{ index $a.Names 0 }}
|
||||
</a>
|
||||
<div>
|
||||
{{ $gnd := GetGND $a.GND }}
|
||||
{{ if and (ne $gnd nil) (ne $gnd.DateOfBirth nil) }}
|
||||
{{- if ne (len $gnd.DateOfBirth) 0 -}}
|
||||
<i class="ri-asterisk text-xs relative bottom-0.5"></i>
|
||||
{{- HRDateShort (index $gnd.DateOfBirth 0) -}}
|
||||
{{- end -}}
|
||||
{{- if ne (len $gnd.DateOfDeath) 0 }}
|
||||
 <i class="ri-cross-fill text-xs relative bottom-0.5"></i
|
||||
> {{ HRDateShort (index $gnd.DateOfDeath 0) }}
|
||||
{{ end }}
|
||||
{{- if ne (len $gnd.ProfessionOrOccupation) 0 -}}
|
||||
<div>
|
||||
{{- (index $gnd.ProfessionOrOccupation 0).Label -}}
|
||||
{{- if gt (len $gnd.ProfessionOrOccupation) 1 -}}
|
||||
,
|
||||
{{ (index $gnd.ProfessionOrOccupation 1).Label -}}
|
||||
{{ end -}}
|
||||
{{- if gt (len $gnd.ProfessionOrOccupation) 2 -}}
|
||||
,
|
||||
{{ (index $gnd.ProfessionOrOccupation 2).Label -}}
|
||||
{{ end -}}
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
9
views/routes/akteure/head.gohtml
Normal file
9
views/routes/akteure/head.gohtml
Normal file
@@ -0,0 +1,9 @@
|
||||
<title>
|
||||
KGPZ –
|
||||
{{ if ne (len .model.Search) 1 }}
|
||||
{{ index (index .model.Agents .model.Search).Names 0 }}
|
||||
{{ else }}
|
||||
Personen & Körperschaften:
|
||||
{{ Upper .model.Search }}
|
||||
{{ end }}
|
||||
</title>
|
||||
@@ -10,7 +10,7 @@
|
||||
<div>
|
||||
<div class="py-3 text-xl">
|
||||
<div>{{ $date.Year }}</div>
|
||||
<div>Stück {{ $model.No }}</div>
|
||||
<div>Stück {{ $model.Number.No }}</div>
|
||||
<div>{{ WeekdayName $date.Weekday }}, {{ $date.Day }}. {{ MonthName $date.Month }}</div>
|
||||
</div>
|
||||
{{ template "_inhaltsverzeichnis" . }}
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
<div>Seite {{ $page }}</div>
|
||||
|
||||
{{ range $piece := (index $model.Pieces.Items $page) }}
|
||||
|
||||
{{ template "_inhaltsverzeichnis_eintrag" $piece }}
|
||||
|
||||
|
||||
@@ -21,7 +20,9 @@
|
||||
<li>
|
||||
<a
|
||||
href="/{{- $issue.When -}}/{{- $issue.Nr -}}"
|
||||
{{ if and (eq $issue.Nr $model.No) (eq $issue.When.Year $model.Datum.When.Year) }}
|
||||
{{- if and (eq $issue.Nr $model.Number.No) (eq $issue.When.Year
|
||||
$model.Datum.When.Year)
|
||||
-}}
|
||||
aria-current="page"
|
||||
{{ end }}>
|
||||
{{- $issue.When.Year }} Nr.
|
||||
|
||||
@@ -1 +1 @@
|
||||
<title>KGPZ – Ausgabe {{ .model.No }} / {{ .model.Year }}</title>
|
||||
<title>KGPZ – Ausgabe {{ .model.Number.No }} / {{ .model.Year }}</title>
|
||||
|
||||
Reference in New Issue
Block a user