import 'package:autosos_flutter/util/xhttp.dart'; class LoginApi { static XHttp xHttp = XHttp.getInstance(); static void login(int type, String username, String password, String code, String cid, String openid, String unionid) async { var data = { "type": type, "username": username, "password": password, "code": code, "getui_cid": cid, "wx_openid": openid, "wx_unionid": unionid }; var headers = {'Content-Type': 'application/x-www-form-urlencoded'}; var post = await xHttp.post("/v2/auth/get-access-token", data, headers); // print(post); } }