add printf to log
parent
bca0854a85
commit
befca816d5
|
@ -228,6 +228,11 @@ func (l *Log) AddHistory(s string) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (l *Log) Printf(s string, i ...interface{}) {
|
||||||
|
l.AddHistory(fmt.Sprintf(s, i...))
|
||||||
|
s = fmt.Sprintf("* %s: %s", time.Now().Format("02/01/06 - 15:04:05"), s)
|
||||||
|
}
|
||||||
|
|
||||||
type LogQuery struct {
|
type LogQuery struct {
|
||||||
From time.Time `json:"from"`
|
From time.Time `json:"from"`
|
||||||
Until time.Time `json:"until"`
|
Until time.Time `json:"until"`
|
||||||
|
|
Loading…
Reference in New Issue