- order manager added.
This commit is contained in:
@@ -179,3 +179,15 @@ func MapValue2Scope(value, fromMin, fromMax, toMin, toMax int64) int64 {
|
||||
}
|
||||
return int64(math.Round(float64(value-fromMin)/float64(fromMax-fromMin)*float64(toMax-toMin) + float64(toMin)))
|
||||
}
|
||||
|
||||
func Errs2Str(sep string, errs ...error) (retVal string) {
|
||||
if sep == "" {
|
||||
sep = "\n"
|
||||
}
|
||||
for _, err := range errs {
|
||||
if err != nil {
|
||||
retVal += err.Error() + sep
|
||||
}
|
||||
}
|
||||
return retVal
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user