mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-21 22:32:15 +08:00
fix(region): Fix the snapshotpolicy info in DiskDetails
This commit is contained in:
@@ -138,8 +138,10 @@ type SimpleGuest struct {
|
||||
}
|
||||
|
||||
type SimpleSnapshotPolicy struct {
|
||||
RepeatWeekdays []int `json:"repeat_weekdays"`
|
||||
TimePoints []int `json:"time_points"`
|
||||
Id string `json:"id"`
|
||||
Name string `json:"name"`
|
||||
RepeatWeekdays []int `json:"repeat_weekdays"`
|
||||
TimePoints []int `json:"time_points"`
|
||||
}
|
||||
|
||||
type DiskDetails struct {
|
||||
|
||||
@@ -1802,6 +1802,8 @@ func (self *SDisk) getMoreDetails(ctx context.Context, userCred mcclient.TokenCr
|
||||
policy := api.SimpleSnapshotPolicy{}
|
||||
policy.RepeatWeekdays = SnapshotPolicyManager.RepeatWeekdaysToIntArray(sps[i].RepeatWeekdays)
|
||||
policy.TimePoints = SnapshotPolicyManager.TimePointsToIntArray(sps[i].TimePoints)
|
||||
policy.Id = sps[i].Id
|
||||
policy.Name = sps[i].Name
|
||||
out.Snapshotpolicies = append(out.Snapshotpolicies, policy)
|
||||
}
|
||||
storage := self.GetStorage()
|
||||
|
||||
Reference in New Issue
Block a user