|
@@ -247,14 +247,20 @@ public class Network
|
|
|
// 传递自定义参数
|
|
// 传递自定义参数
|
|
|
// connection.setRequestProperty("MyProperty", "this is me!");
|
|
// connection.setRequestProperty("MyProperty", "this is me!");
|
|
|
|
|
|
|
|
- if(!TextUtils.isEmpty(RedAntApplication.user)) {
|
|
|
|
|
|
|
+ if (parms.getString("user") == null) {
|
|
|
|
|
+ if(!TextUtils.isEmpty(RedAntApplication.user)) {
|
|
|
// parms.putString("user", AES.encrypt("usai", RedAntApplication.user));
|
|
// parms.putString("user", AES.encrypt("usai", RedAntApplication.user));
|
|
|
- parms.putString("user", AES.encrypt("Usai2010", RedAntApplication.user));
|
|
|
|
|
|
|
+ parms.putString("user", AES.encrypt("Usai2010", RedAntApplication.user));
|
|
|
|
|
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
if(!TextUtils.isEmpty(RedAntApplication.password)) {
|
|
if(!TextUtils.isEmpty(RedAntApplication.password)) {
|
|
|
// parms.putString("password", AES.encrypt("usai", RedAntApplication.password));
|
|
// parms.putString("password", AES.encrypt("usai", RedAntApplication.password));
|
|
|
parms.putString("pwd", AES.encrypt("Usai2010", RedAntApplication.password));
|
|
parms.putString("pwd", AES.encrypt("Usai2010", RedAntApplication.password));
|
|
|
|
|
+ if (parms.getString("password") == null) {
|
|
|
|
|
+ parms.putString("password", AES.encrypt("usai", RedAntApplication.password));
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
parms.putString("app_ver", RedAntApplication.getInstance()
|
|
parms.putString("app_ver", RedAntApplication.getInstance()
|
|
@@ -914,8 +920,12 @@ public class Network
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
Params.putString("_operate","handset_get_manufacturer");
|
|
Params.putString("_operate","handset_get_manufacturer");
|
|
|
- String jstr = getJson(RedAntApplication.active_address
|
|
|
|
|
- + Network.URL_QUERY_MANUFACTURER,Params);
|
|
|
|
|
|
|
+// String jstr = getJson(RedAntApplication.active_address
|
|
|
|
|
+// + Network.URL_QUERY_MANUFACTURER,Params);
|
|
|
|
|
+
|
|
|
|
|
+ Params.putString("_action","handset_new");
|
|
|
|
|
+ String jstr = getJson(RedAntApplication.active_address,Params);
|
|
|
|
|
+
|
|
|
// file.delete();
|
|
// file.delete();
|
|
|
if (jstr == null || jstr.length() <= 0)
|
|
if (jstr == null || jstr.length() <= 0)
|
|
|
{
|
|
{
|
|
@@ -972,8 +982,12 @@ public class Network
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
Params.putString("_operate","valid_upload");
|
|
Params.putString("_operate","valid_upload");
|
|
|
- String jstr = getJson(RedAntApplication.active_address
|
|
|
|
|
- + Network.URL_VERIFY_CODE,Params);
|
|
|
|
|
|
|
+ Params.putString("_action","handset_new");
|
|
|
|
|
+ String url;
|
|
|
|
|
+
|
|
|
|
|
+// String jstr = getJson(RedAntApplication.active_address
|
|
|
|
|
+// + Network.URL_VERIFY_CODE,Params);
|
|
|
|
|
+ String jstr = getJson(RedAntApplication.active_address, Params);
|
|
|
// file.delete();
|
|
// file.delete();
|
|
|
if (jstr == null || jstr.length() <= 0)
|
|
if (jstr == null || jstr.length() <= 0)
|
|
|
{
|
|
{
|
|
@@ -1082,6 +1096,8 @@ public class Network
|
|
|
// dbgUtil.fileLog(e.toString());
|
|
// dbgUtil.fileLog(e.toString());
|
|
|
// return RESULT_LOCALFILE_ERROR;
|
|
// return RESULT_LOCALFILE_ERROR;
|
|
|
// }
|
|
// }
|
|
|
|
|
+
|
|
|
|
|
+ Params.putString("_action","handset_new");
|
|
|
String jstr = UploadFile(path,server, Params,listener);
|
|
String jstr = UploadFile(path,server, Params,listener);
|
|
|
// file.delete();
|
|
// file.delete();
|
|
|
if (jstr == null || jstr.length() <= 0)
|
|
if (jstr == null || jstr.length() <= 0)
|