mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
chore: updates to the new folder model (#57776)
This commit is contained in:
parent
b9a0576638
commit
6a6fdbc1f9
@ -65,12 +65,9 @@ func modelsToFolders(m []*models.Folder) []*folder.Folder {
|
|||||||
UID: f.Uid,
|
UID: f.Uid,
|
||||||
Title: f.Title,
|
Title: f.Title,
|
||||||
Description: "", // model.Folder does not have a description
|
Description: "", // model.Folder does not have a description
|
||||||
URL: f.Url,
|
|
||||||
Created: f.Created,
|
Created: f.Created,
|
||||||
CreatedBy: f.CreatedBy,
|
|
||||||
Updated: f.Updated,
|
Updated: f.Updated,
|
||||||
UpdatedBy: f.UpdatedBy,
|
UpdatedBy: f.UpdatedBy,
|
||||||
HasACL: f.HasACL,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ret
|
return ret
|
||||||
|
@ -17,16 +17,11 @@ type Folder struct {
|
|||||||
Title string
|
Title string
|
||||||
Description string
|
Description string
|
||||||
|
|
||||||
// TODO: is URL relevant for folders?
|
|
||||||
URL string
|
|
||||||
|
|
||||||
Created time.Time
|
Created time.Time
|
||||||
Updated time.Time
|
Updated time.Time
|
||||||
|
|
||||||
// TODO: are these next three relevant for folders?
|
// TODO: validate if this field is required/relevant to folders.
|
||||||
UpdatedBy int64
|
UpdatedBy int64
|
||||||
CreatedBy int64
|
|
||||||
HasACL bool
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewFolder tales a title and returns a Folder with the Created and Updated
|
// NewFolder tales a title and returns a Folder with the Created and Updated
|
||||||
|
Loading…
Reference in New Issue
Block a user