mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-21 06:09:39 +08:00
32 lines
612 B
Go
32 lines
612 B
Go
package modules
|
|
|
|
import (
|
|
"yunion.io/x/jsonutils"
|
|
"yunion.io/x/onecloud/pkg/mcclient"
|
|
)
|
|
|
|
type SUpdateManager struct {
|
|
ResourceManager
|
|
}
|
|
|
|
var (
|
|
Updates SUpdateManager
|
|
)
|
|
|
|
func (this *SUpdateManager) DoUpdate(s *mcclient.ClientSession, params jsonutils.JSONObject) (jsonutils.JSONObject, error) {
|
|
ret := jsonutils.NewDict()
|
|
this.PerformAction(s, "", "", params)
|
|
return ret, nil
|
|
}
|
|
|
|
func init() {
|
|
|
|
Updates = SUpdateManager{NewAutoUpdateManager("update", "updates",
|
|
// user view
|
|
[]string{"localVersion", "remoteVersion", "status", "updateAvailable"},
|
|
[]string{}, // admin view
|
|
)}
|
|
|
|
register(&Updates)
|
|
}
|