postman 请求参数为数组及JsonObject
生活随笔
收集整理的這篇文章主要介紹了
postman 请求参数为数组及JsonObject
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
2019獨角獸企業重金招聘Python工程師標準>>>
1.
(1)數組的請求方式(post)
https://blog.csdn.net/qq_21205435/article/details/81909184
(2)數組的請求方式(get)
http://localhost:port/list?ages=10,20,30
后端接收方式:
@PostMapping("/xxx") @ResponseBody public Map<String, Object> xxx(@RequestParam(value = "ages[]") Integer[] ages,@RequestParam String type) {xxxxreturn map; }參考鏈接:https://www.jianshu.com/p/85251b746058
2.jsonObject 的請求方式(data 即為映射的bean屬性【
private JSONObject data;】):
格式如下:
{"data": {"address": "上海", "contractList": [{"fileId": "001"}]} }?
轉載于:https://my.oschina.net/qimhkaiyuan/blog/3019900
總結
以上是生活随笔為你收集整理的postman 请求参数为数组及JsonObject的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 梦到女儿长牙齿是什么预兆
- 下一篇: 杭电oj2047-2049、2051-2