-
Notifications
You must be signed in to change notification settings - Fork 124
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add comment #36
base: master
Are you sure you want to change the base?
add comment #36
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your PR! I have a few comments, but the addition of the comment field is quite nice!
@@ -1,10 +1,13 @@ | |||
module github.com/Shelnutt2/db2struct | |||
module hktk1001/db2struct |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert the mod files (go.mod
and go.sum
), the changes here look like they are only from your fork?
utils_mysql.go
Outdated
@@ -95,20 +96,30 @@ func generateMysqlTypes(obj map[string]map[string]string, depth int, jsonAnnotat | |||
annotations = append(annotations, fmt.Sprintf("gorm:\"column:%s%s\"", key, primary)) | |||
} | |||
if jsonAnnotation == true { | |||
annotations = append(annotations, fmt.Sprintf("json:\"%s\"", key)) | |||
res :=Lcfirst(Case2Camel(key)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the json changes, it looks like your goal is to support different json name format right? snake case vs camel, etc? If so I believe the behavior should be added as a option the user passes in.
add comment
增加数据库的注释