|
|
|
|
@ -30,7 +30,8 @@ class ApiManager {
|
|
|
|
|
headers.addAll(_headers);
|
|
|
|
|
|
|
|
|
|
Uri _url = Uri.parse(url);
|
|
|
|
|
// print(_url);
|
|
|
|
|
// print(_url);
|
|
|
|
|
// print(headers);
|
|
|
|
|
http.Response response = await http.get(_url,headers: headers);
|
|
|
|
|
if(jsonDecode(response.body) is Map<String,dynamic>){
|
|
|
|
|
final message = jsonDecode(response.body)["message"];
|
|
|
|
|
@ -54,9 +55,9 @@ class ApiManager {
|
|
|
|
|
headers.addAll(_headers);
|
|
|
|
|
|
|
|
|
|
Uri _url = Uri.parse(url);
|
|
|
|
|
// print(_url);
|
|
|
|
|
// print(headers);
|
|
|
|
|
log(json.encode(body));
|
|
|
|
|
// print(_url);
|
|
|
|
|
// print(headers);
|
|
|
|
|
// log(json.encode(body));
|
|
|
|
|
var request = http.Request('POST', _url);
|
|
|
|
|
request.body = json.encode(body);
|
|
|
|
|
request.headers.addAll(headers);
|
|
|
|
|
|