更新md文件
This commit is contained in:
parent
336d938628
commit
6052845881
@ -1,4 +1,4 @@
|
|||||||
# simpleRequest --
|
# simpleRequest
|
||||||
## 说明
|
## 说明
|
||||||
[simpleRequest](www.github.com/dorlolo/simpleRequest) 是基于golang原生http库的封装,适合用来对第三方接口进行快速地对接和开发。
|
[simpleRequest](www.github.com/dorlolo/simpleRequest) 是基于golang原生http库的封装,适合用来对第三方接口进行快速地对接和开发。
|
||||||
它具备以下特点:
|
它具备以下特点:
|
||||||
@ -118,7 +118,7 @@ r.Body().Set("beginDate", "2022-03-01").Set("endDate", "2022-03-03")
|
|||||||
|
|
||||||
#### map赋值
|
#### map赋值
|
||||||
```go
|
```go
|
||||||
bodyBulid := map[string]interface{
|
bodyBulid := map[string]interface{}{
|
||||||
"beginDate":"2022-03-01",
|
"beginDate":"2022-03-01",
|
||||||
"endDate":"2022-03-03",
|
"endDate":"2022-03-03",
|
||||||
}
|
}
|
||||||
|
@ -28,6 +28,10 @@ func TestRequest(t *testing.T) {
|
|||||||
pamarsBulid := make(map[string]interface{})
|
pamarsBulid := make(map[string]interface{})
|
||||||
pamarsBulid["passwd"] = "123456"
|
pamarsBulid["passwd"] = "123456"
|
||||||
pamarsBulid["action"] = "login"
|
pamarsBulid["action"] = "login"
|
||||||
|
|
||||||
|
paramsBuild2 := map[string]interface{}{
|
||||||
|
"passwd": "123456",
|
||||||
|
}
|
||||||
r.QueryParams().Sets(pamarsBulid)
|
r.QueryParams().Sets(pamarsBulid)
|
||||||
|
|
||||||
//--添加body
|
//--添加body
|
||||||
|
Loading…
Reference in New Issue
Block a user