This commit is contained in:
KasimBaybikov
2023-03-26 22:00:30 +03:00
parent f2f31b939e
commit b112c5ee22
10 changed files with 171 additions and 10 deletions

View File

@@ -660,3 +660,17 @@ func flattenComputeGetAudits(computeAudits ListShortAudits) []map[string]interfa
}
return res
}
func flattenSnapshotUsage(computeSnapshotUasges ListUsageSnapshots) []map[string]interface{} {
res := make([]map[string]interface{}, 0)
for _, computeUsage := range computeSnapshotUasges {
temp := map[string]interface{}{
"count": computeUsage.Count,
"stored": computeUsage.Stored,
"label": computeUsage.Label,
"timestamp": computeUsage.Timestamp,
}
res = append(res, temp)
}
return res
}