-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Improve developer experience #681
Conversation
jingyuexing
commented
May 19, 2023
- feat: 添加字符串模板替换
- feat: 序列化Query请求字符串
feat: 添加模板字符串解析以及模板字符串单元测试
please fix ci |
i'm trying |
util/query.go
Outdated
for key, value := range params { | ||
valueString := "" | ||
switch v := value.(type) { | ||
case int, int8, int16, int32, int64: |
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.
是不是参数是 interface
应该考虑一下 uint uint8 uint32 uint64 这些类型?
if response, err = util.HTTPGet(strings.Join([]string{ | ||
userSimpleListURL, | ||
util.Query(map[string]interface{}{ | ||
"access_token": accessToken, |
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.
access_token
,department_id
可以搞成静态常量
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.
access_token
,department_id
可以搞成静态常量
可以设置全局的配置项,这个应该是由整个框架负责
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.
access_token
,department_id
可以搞成静态常量可以设置全局的配置项,这个应该是由整个框架负责
目前没这样处理,那这次就处理一下,建立统一的常量管理,access_token
,出现的地方还蛮多的。可以在根目录下面建一个常量管理文件以及每个子目录再建一个常量文件
没有人review吗? |
这个功能是急需使用吗? |
我开发的时候要用到的 |
先根据 commit 获取最新的代码 |
OK |