1
0
mirror of https://github.com/dstotijn/go-notion.git synced 2024-11-24 08:42:26 +02:00

Fix missing database page properties, use PageParent type

This commit is contained in:
David Stotijn 2021-05-18 21:18:30 +02:00
parent c16fdfbc88
commit ce7d6da4c6

View File

@ -23,7 +23,7 @@ type Page struct {
}
type PageParent struct {
Type string `json:"type"`
Type ParentType `json:"type"`
PageID *string `json:"page_id,omitempty"`
DatabaseID *string `json:"database_id,omitempty"`
@ -45,10 +45,12 @@ type DatabasePageProperty struct {
ID string `json:"id,omitempty"`
Type DatabasePropertyType `json:"type"`
Title []RichText `json:"title,omitempty"`
RichText []RichText `json:"rich_text,omitempty"`
Number *NumberMetadata `json:"number,omitempty"`
Select *SelectOptions `json:"select,omitempty"`
MultiSelect []SelectOptions `json:"multi_select,omitempty"`
Date *Date `json:"date,omitempty"`
Formula *FormulaMetadata `json:"formula,omitempty"`
Relation *RelationMetadata `json:"relation,omitempty"`
Rollup *RollupMetadata `json:"rollup,omitempty"`