mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-10-28 03:23:25 +08:00
cloudnet: return non-nil data on validata create data pass
This commit is contained in:
@@ -103,7 +103,7 @@ func (man *SRouteManager) ValidateCreateData(ctx context.Context, userCred mccli
|
||||
router.Name+"-"+iface.Name+"-"+rand.String(4)),
|
||||
)
|
||||
}
|
||||
return nil, nil
|
||||
return data, nil
|
||||
}
|
||||
|
||||
func (man *SRouteManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query jsonutils.JSONObject) (*sqlchemy.SQuery, error) {
|
||||
|
||||
@@ -200,7 +200,7 @@ func (man *SRuleManager) ValidateCreateData(ctx context.Context, userCred mcclie
|
||||
if err := man.validateData(ctx, userCred, ownerId, query, data, nil); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return nil, nil
|
||||
return data, nil
|
||||
}
|
||||
|
||||
func (man *SRuleManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query jsonutils.JSONObject) (*sqlchemy.SQuery, error) {
|
||||
|
||||
Reference in New Issue
Block a user