This commit is contained in:
wenxu12345
2021-12-10 17:30:11 +08:00
parent 2ace964573
commit 8b4da90497
4 changed files with 377 additions and 70 deletions
+3 -8
View File
@@ -3,6 +3,7 @@ package utils
import (
"fmt"
"reflect"
"strconv"
)
// copy a by b b->a
@@ -44,12 +45,6 @@ func CopyStructFields(a interface{}, b interface{}, fields ...string) (err error
return nil
}
type S1 struct {
Name string
Age int
}
type S2 struct {
Name string
Age int32
func OperationIDGenerator() string {
return strconv.FormatInt(time.Now().UnixNano()+int64(rand.Uint32()), 10)
}