mirror of
https://github.com/Theodor-Springmann-Stiftung/kgpz_web.git
synced 2025-10-29 09:05:30 +00:00
Suche: HTMX + Webseite
This commit is contained in:
@@ -8,7 +8,7 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
WORKS_CATEGORY = "work"
|
||||
WORK_TYPE = "work"
|
||||
)
|
||||
|
||||
type Work struct {
|
||||
@@ -21,10 +21,6 @@ type Work struct {
|
||||
AnnotationNote
|
||||
}
|
||||
|
||||
func (w Work) Name() string {
|
||||
return "work"
|
||||
}
|
||||
|
||||
type Citation struct {
|
||||
XMLName xml.Name `xml:"zitation"`
|
||||
Title string `xml:"title"`
|
||||
@@ -37,7 +33,7 @@ func (w Work) References() xmlprovider.ResolvingMap[Work] {
|
||||
refs := make(xmlprovider.ResolvingMap[Work])
|
||||
|
||||
for _, ref := range w.AgentRefs {
|
||||
refs[ref.Name()] = append(refs[ref.Name()], xmlprovider.Resolved[Work]{
|
||||
refs[ref.Type()] = append(refs[ref.Type()], xmlprovider.Resolved[Work]{
|
||||
Item: &w, // Reference to the current Work item
|
||||
Reference: ref.Ref, // Reference ID
|
||||
Category: ref.Category, // Category of the reference
|
||||
@@ -78,5 +74,5 @@ func (w Work) Readable(lib *Library) map[string]interface{} {
|
||||
}
|
||||
|
||||
func (w Work) Type() string {
|
||||
return WORKS_CATEGORY
|
||||
return WORK_TYPE
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user