mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-10-30 18:23:35 +08:00
huawei eip disassociate bugfix
This commit is contained in:
@@ -43,7 +43,7 @@ func NewPortManager(regionId string, projectId string, signer auth.Signer, debug
|
||||
SBaseManager: NewBaseManager2(signer, debug, &requestHook),
|
||||
ServiceName: ServiceNameVPC,
|
||||
Region: regionId,
|
||||
ProjectId: "",
|
||||
ProjectId: projectId,
|
||||
version: "v1",
|
||||
Keyword: "port",
|
||||
KeywordPlural: "ports",
|
||||
|
||||
@@ -20,7 +20,6 @@ import (
|
||||
"time"
|
||||
|
||||
"yunion.io/x/jsonutils"
|
||||
|
||||
billing_api "yunion.io/x/onecloud/pkg/apis/billing"
|
||||
api "yunion.io/x/onecloud/pkg/apis/compute"
|
||||
"yunion.io/x/onecloud/pkg/cloudprovider"
|
||||
@@ -144,7 +143,7 @@ func (self *SEipAddress) GetMode() string {
|
||||
}
|
||||
|
||||
func (self *SEipAddress) GetPort() *Port {
|
||||
if len(self.PortId) > 0 {
|
||||
if len(self.PortId) == 0 {
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
@@ -139,7 +139,7 @@ func (self *SRegion) GetPort(portId string) (Port, error) {
|
||||
return port, err
|
||||
}
|
||||
|
||||
// https://support.huaweicloud.com/api-vpc/zh-cn_topic_0030591299.html
|
||||
// https://support.huaweicloud.com/api-vpc/zh-cn_topic_0133195888.html
|
||||
func (self *SRegion) GetPorts(instanceId string) ([]Port, error) {
|
||||
ports := make([]Port, 0)
|
||||
querys := map[string]string{}
|
||||
|
||||
Reference in New Issue
Block a user