0
我试图在params中使用int参数(matchID,typeID和live),但它们似乎是从使用params.toString()获取的最终查询字符串中丢失的。我在这里错过了什么?如何在RequestParams中传递int参数?
RequestParams params = new RequestParams();
String email = user.getEmail();
params.put("email", email);
params.put("password", user.getPassword());
params.put("token", TextUtil.getToken(email));
params.put("live", live);
params.put("matchID", matchID);
params.put("typeID", typeID);
params.put("quote", quote);
params.put("comment", comment);
System.out.println("matchID: " + matchID); // matchID: 1
System.out.println("typeID: " + typeID); // typeID : 2
System.out.println("params: " + params.toString()); // params: quote=2&token=XXX&comment=&[email protected]&password=mypw
您是否尝试过使用Integer? – broncoAbierto
是的,没有工作。 – Chris