mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-19 10:46:58 +08:00
fix(region): kvm secgroup filter (#18476)
This commit is contained in:
@@ -1573,6 +1573,12 @@ func (self *SKVMRegionDriver) RequestDeleteSecurityGroup(ctx context.Context, us
|
||||
return task.ScheduleRun(nil)
|
||||
}
|
||||
|
||||
func (self *SKVMRegionDriver) GetSecurityGroupFilter(vpc *models.SVpc) (func(q *sqlchemy.SQuery) *sqlchemy.SQuery, error) {
|
||||
return func(q *sqlchemy.SQuery) *sqlchemy.SQuery {
|
||||
return q.Equals("cloudregion_id", api.DEFAULT_REGION_ID)
|
||||
}, nil
|
||||
}
|
||||
|
||||
func (self *SKVMRegionDriver) ValidateUpdateSecurityGroupRuleInput(ctx context.Context, userCred mcclient.TokenCredential, input *api.SSecgroupRuleUpdateInput) (*api.SSecgroupRuleUpdateInput, error) {
|
||||
if input.Priority != nil {
|
||||
if *input.Priority < 1 || *input.Priority > 100 {
|
||||
|
||||
Reference in New Issue
Block a user