Skip to content
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

网络请求拦截器post方式RequestBody参数读取失败 #1

Open
xiaoxiaobai7 opened this issue Dec 6, 2019 · 0 comments
Open

Comments

@xiaoxiaobai7
Copy link

package com.dev.kit.basemodule.netRequest.util包中,CommonInterceptor 网络请求拦截器,post方法拦截里面getParamContent/** * 获取常规post请求参数*/这个方法抛出异常,无法获取到body里面的参数。我的项目现在post方法参数是,@Body RequestBody body,MediaType.parse("application/x-www-form-urlencoded; charset=utf-8"),MediaType是这个。body参数无法解析出来。body外面是hashmap组织的,现在需要在Interceptor还原成hashmap出来加密,请问大神有没有方法解决?在拦截器里把body参数还原成hashmap?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant