mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
fix: struct api params
This commit is contained in:
@@ -102,3 +102,7 @@ func (i ServerRebuildRootInput) GetKeypairName() string {
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type ServerResumeInput struct {
|
||||
apis.Meta
|
||||
}
|
||||
|
||||
@@ -757,7 +757,7 @@ func (self *SGuest) AllowPerformResume(ctx context.Context, userCred mcclient.To
|
||||
return self.IsOwner(userCred) || db.IsAdminAllowPerform(userCred, self, "resume")
|
||||
}
|
||||
|
||||
func (self *SGuest) PerformResume(ctx context.Context, userCred mcclient.TokenCredential, query struct{}, data struct{}) (jsonutils.JSONObject, error) {
|
||||
func (self *SGuest) PerformResume(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.ServerResumeInput) (jsonutils.JSONObject, error) {
|
||||
if self.Status == api.VM_SUSPEND {
|
||||
err := self.StartResumeTask(ctx, userCred, "")
|
||||
return nil, err
|
||||
|
||||
Reference in New Issue
Block a user