1
0
mirror of https://github.com/rancher/steve.git synced 2025-09-03 16:35:25 +00:00

Handle int64 field type when adding index fields (#671)

* Handle int64 field type when adding index fields

* add support for float64
This commit is contained in:
Chad Roberts
2025-06-13 13:04:55 -04:00
committed by GitHub
parent 58f15a4349
commit 5de54d6a4a
2 changed files with 10 additions and 2 deletions

View File

@@ -499,7 +499,7 @@ func (l *ListOptionIndexer) addIndexFields(key string, obj any, tx transaction.C
switch typedValue := value.(type) {
case nil:
args = append(args, "")
case int, bool, string:
case int, bool, string, int64, float64:
args = append(args, fmt.Sprint(typedValue))
case []string:
args = append(args, strings.Join(typedValue, "|"))