diff --git a/core/models/doc.go b/core/models/doc.go new file mode 100644 index 0000000..d071ad6 --- /dev/null +++ b/core/models/doc.go @@ -0,0 +1,2 @@ +// Package models contains the data models for the index +package models diff --git a/core/models/links.go b/core/models/links.go new file mode 100644 index 0000000..412cd0f --- /dev/null +++ b/core/models/links.go @@ -0,0 +1,7 @@ +package models + +type Link struct { + FromNoteID int + ToNoteID int + Raw string +} diff --git a/core/models/note.go b/core/models/note.go new file mode 100644 index 0000000..4d478b9 --- /dev/null +++ b/core/models/note.go @@ -0,0 +1,11 @@ + +package models + +type Note struct { + ID int + Path string + Title string + Slug string + CreatedAt string + UpdatedAt string +} diff --git a/core/models/note_tag.go b/core/models/note_tag.go new file mode 100644 index 0000000..a74d771 --- /dev/null +++ b/core/models/note_tag.go @@ -0,0 +1,6 @@ +package models + +type NoteTag struct { + NoteID int + TagID int +} diff --git a/core/models/tag.go b/core/models/tag.go new file mode 100644 index 0000000..0bc7531 --- /dev/null +++ b/core/models/tag.go @@ -0,0 +1,6 @@ +package models + +type Tag struct { + ID int + Name string +}