mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-19 10:46:58 +08:00
Merge pull request #639 in YUNIONIO/onecloud from release/2.3.0 to release/2.4.0
* commit '37578c8a6ddaf8c0f4b6b65a9bad9552aba3b201': 修复规则缺失优先级及描述信息
This commit is contained in:
@@ -281,7 +281,13 @@ func (self *SSecurityGroupRule) String() string {
|
||||
}
|
||||
|
||||
func (self *SSecurityGroupRule) toRule() (*secrules.SecurityRule, error) {
|
||||
return secrules.ParseSecurityRule(self.String())
|
||||
rule, err := secrules.ParseSecurityRule(self.String())
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
rule.Description = self.Description
|
||||
rule.Priority = int(self.Priority)
|
||||
return rule, nil
|
||||
}
|
||||
|
||||
func (self *SSecurityGroupRule) SingleRules() ([]secrules.SecurityRule, error) {
|
||||
|
||||
Reference in New Issue
Block a user