|
|
@ -28,6 +28,7 @@ import com.google.gson.reflect.TypeToken; |
|
|
|
import com.icssoft.icspda.R; |
|
|
|
import com.icssoft.icspda.entity.ApplicationModel; |
|
|
|
import com.icssoft.icspda.entity.UserData; |
|
|
|
import com.icssoft.icspda.entity.VersionData; |
|
|
|
import com.icssoft.icspda.entity.WorkPointData; |
|
|
|
import com.icssoft.icspda.net.WebServiceUtil; |
|
|
|
import com.icssoft.icspda.util.HelpUtil; |
|
|
@ -189,10 +190,6 @@ public class LoginActivity extends AppCompatActivity { |
|
|
|
// startActivity(intent); |
|
|
|
// } |
|
|
|
// }); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
private void UpdateAction() { |
|
|
@ -228,16 +225,16 @@ public class LoginActivity extends AppCompatActivity { |
|
|
|
params.put("version",thisVersion+""); |
|
|
|
try { |
|
|
|
result = WebServiceUtil.GetWSReturnInfo("GetNewVersion",params); |
|
|
|
// System.out.println(result); |
|
|
|
if (result!=null&&!result.equals("")){ |
|
|
|
VersionData data= new Gson().fromJson(result, VersionData.class); |
|
|
|
Version = Integer.parseInt(data.getVersion()); |
|
|
|
Url = data.getUrl(); |
|
|
|
} |
|
|
|
handler.sendEmptyMessage(100); |
|
|
|
} catch (Exception exception) { |
|
|
|
exception.printStackTrace(); |
|
|
|
} |
|
|
|
if (result!=null&&!result.equals("")){ |
|
|
|
Map<String,String> o = new Gson().fromJson(result, new TypeToken<HashMap<String,String>>(){}.getType()); |
|
|
|
Version = Integer.parseInt(o.get("Version")); |
|
|
|
Url = o.get("Url"); |
|
|
|
} |
|
|
|
handler.sendEmptyMessage(100); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// 获取当前应用的版本号 |
|
|
|