Commit bbe38b2eb7a9f869ececa4c69d2be1cb7e0cadf9

Authored by wdn127929
1 parent 213320f4

di odio

... ... @@ -417,7 +417,7 @@ class DioUtil {
/// get Def Options.
static BaseOptions getDefOptions() {
BaseOptions options = new BaseOptions();
options.contentType = 'application/json; charset=utf-8';
options.contentType = Headers.formUrlEncodedContentType;
options.connectTimeout = 1000 * 10; //默认10s
options.receiveTimeout = 1000 * 10; //默认10s
return options;
... ...
... ... @@ -63,7 +63,7 @@ class ContactModel {
data: params,
options: Options(
method: Method.post,
// contentType: "application/x-www-form-urlencoded"
contentType: "application/x-www-form-urlencoded"
))
.catchError((error) {
print(error.toString());
... ...