- 将FlatMap,Struct2FlatMap从jxutils移到utils中

+ 添加MarshalJSONIgnoreValues, MustMarshalJSONIgnoreValues
This commit is contained in:
gazebo
2019-04-03 10:47:06 +08:00
parent a9ba3b7cc1
commit f105cfed62
2 changed files with 58 additions and 12 deletions

View File

@@ -108,18 +108,6 @@ func GetAPIOperator(userName string) string {
return retVal
}
func MergeMaps(firstMap map[string]interface{}, otherMaps ...map[string]interface{}) (retVal map[string]interface{}) {
retVal = make(map[string]interface{})
allMaps := append(otherMaps, firstMap)
for _, oneMap := range allMaps {
for k, v := range oneMap {
retVal[k] = v
}
}
return retVal
}
func CallFuncLogError(funcToCall func() error, msg string, params ...interface{}) error {
err := funcToCall()
if err != nil {