mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Parsing time.Time in console help command
This commit is contained in:
committed by
Dan Christian Bogos
parent
a3822fe643
commit
440bc42777
@@ -25,6 +25,7 @@ import (
|
||||
"reflect"
|
||||
"regexp"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
)
|
||||
@@ -81,6 +82,10 @@ func (ce *CommandExecuter) clientArgs(iface interface{}) (args []string) {
|
||||
continue
|
||||
}
|
||||
}
|
||||
if _, canCast := valField.Interface().(time.Time); canCast {
|
||||
args = append(args, typeField.Name)
|
||||
continue
|
||||
}
|
||||
args = append(args, ce.clientArgs(valField.Interface())...)
|
||||
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user