我希望以http://localhost:8000/api/projects/?id=2021&a=2&b=3&c=4的格式传递url参数,并在视图函数中获取值
js5cn81o1#
在DRF中,您可以获得如下烫发值...
URL = http://localhost:8000/api/projects/?id=2021&a=2&b=3&c=4 id = request.query_params.get('id') a = request.query_params.get('a') b = request.query_params.get('b') c = request.query_params.get('c') print(id,a,b,c)
1条答案
按热度按时间js5cn81o1#
在DRF中,您可以获得如下烫发值...
Postman 屏幕