- commit
- aa98c7d
- parent
- 065a976
- author
- Eric Bower
- date
- 2024-03-12 18:55:44 +0000 UTC
chore(pgs): add id to objects
1 files changed,
+2,
-0
+2,
-0
1@@ -356,6 +356,7 @@ type objectsPayload struct {
2 }
3
4 type ProjectObject struct {
5+ ID string `json:"id"`
6 Name string `json:"name"`
7 Size int64 `json:"size"`
8 ModTime time.Time `json:"mod_time"`
9@@ -388,6 +389,7 @@ func getProjectObjects(httpCtx *shared.HttpCtx, ctx ssh.Context, user *db.User)
10 pobjs := []*ProjectObject{}
11 for _, obj := range objects {
12 pobjs = append(pobjs, &ProjectObject{
13+ ID: fmt.Sprintf("%s%s", projectName, obj.Name()),
14 Name: obj.Name(),
15 Size: obj.Size(),
16 ModTime: obj.ModTime(),