{{- $model := index . 0 -}} {{- $entry := index . 1 -}} {{- $series := index . 2 -}} {{/* .parameters type SearchParameters struct { Parameters Sort string Annotations bool Persons bool Title bool Alm bool Series bool Places bool Refs bool Year bool AnnotationsString string PersonsString string TitleString string AlmString string SeriesString string PlacesString string RefsString string YearString string TypeFilter string } type Parameters struct { Query string Collection string Extended bool } type SearchResultBaende struct { // these are the sorted IDs for hits Hits []string Series map[string]*dbmodels.Series // <- Key: Series ID Entries map[string]*dbmodels.Entry // <- Key: Entry ID Places map[string]*dbmodels.Place // <- All places, Key: Place IDs Agents map[string]*dbmodels.Agent // <- Key: Agent IDs EntriesSeries map[string][]*dbmodels.REntriesSeries // <- Key: Whatever the Hit IDs are EntriesAgents map[string][]*dbmodels.REntriesAgents // <- Key: Entry ID } */}} {{- $isAlm := or $model.parameters.Alm $model.parameters.AlmString -}} {{- $isTitle := or $model.parameters.Title $model.parameters.TitleString -}} {{- $isRefs := or $model.parameters.Refs $model.parameters.RefsString -}} {{- $isPlaces := or $model.parameters.Places $model.parameters.PlacesString -}} {{- $isYear := or $model.parameters.Year $model.parameters.YearString -}} {{- $isSeries := or $model.parameters.Series $model.parameters.SeriesString -}} {{- $isPersons := or $model.parameters.Persons $model.parameters.PersonsString -}} {{- $isAnnotations := or $model.parameters.Annotations $model.parameters.AnnotationsString -}}
{{- if not $entry.TitleStmt -}}
Keine nähere Erfassung
{{- else if eq $entry.EditState "Edited" -}}
Mit erfassten Beiträgen
{{- else -}}
Mit genaueren Titelangaben
{{- end -}}
{{ if $entry.References }}
{{ $entry.References }}
{{ end }}
{{- if $entry.TitleStmt -}}
{{- $entry.TitleStmt -}}
{{- end -}} {{- if and $entry.ResponsibilityStmt (not (eq $entry.ResponsibilityStmt "unbezeichnet")) -}}
{{ $entry.ResponsibilityStmt -}}
{{- end -}}
{{- if $entry.Places -}} {{- range $_, $placeid := $entry.Places -}} {{- $place := index $model.result.Places $placeid -}} {{- if $place -}} {{- end -}} {{- end -}} {{- end -}} {{- if $entry.Year -}}
{{ $entry.Year }}
{{- else -}}
o.J.
{{- end -}}
{{- $srels := index $model.result.EntriesSeries $entry.Id -}} {{- if $srels -}}
{{- range $_, $srel := $srels -}} {{- $series := index $model.result.Series $srel.Series -}} {{- if $series -}} {{- end -}} {{- end -}}
{{- end -}} {{- $arels := index $model.result.EntriesAgents $entry.Id -}} {{- if $arels -}}
{{- range $_, $arel := $arels -}} {{- $agent := index $model.result.Agents $arel.Agent -}} {{- if $agent -}}
{{- $arel.Type -}} {{- $agent.Name -}}
{{- end -}} {{- end -}}
{{- end -}} {{- if $entry.Annotation -}}
Anm.: {{- Safe (ReplaceSlashParenSlash $entry.Annotation) -}}
{{- end -}}