| | |
| | | }
|
| | |
|
| | |
|
| | | public void compareSurveillancePhotoAndIdCardPhoto(RequestParams params) {
|
| | | if (!BaseApplication.deviceAvailable) {
|
| | | return;
|
| | | }
|
| | | try {
|
| | | File path = BaseApplication.getInstance().getFilesDir();
|
| | | File f0 = new File(path, "f0");
|
| | | if (!f0.exists()) {
|
| | | f0.createNewFile();
|
| | | }
|
| | | File f2 = new File(path, "surveillancePhoto");
|
| | | if (!f2.exists()) {
|
| | | f2.createNewFile();
|
| | | }
|
| | | File f4 = new File(path, "idCardPhoto");
|
| | | if (!f4.exists()) {
|
| | | f4.createNewFile();
|
| | | }
|
| | | FileWriter fw0 = new FileWriter(f0);
|
| | | fw0.write("test1");
|
| | | fw0.close();
|
| | |
|
| | | params.setUri(AppApi.BASE_URL +AppApi.REGISTER_ID_CARD_AUTH);
|
| | | params.addBodyParameter("f0", f0);
|
| | | params.addBodyParameter("surveillancePhoto", f2);
|
| | | params.addBodyParameter("idCardPhoto", f4);
|
| | | x.http().post(params, new BaseCommonCallBack() {
|
| | | @Override
|
| | | public void success() {
|
| | | Toast.makeText(BaseApplication.getInstance(),"测试相似度", Toast.LENGTH_SHORT).show();
|
| | | }
|
| | | });
|
| | |
|
| | | } catch (Exception e) {
|
| | | e.printStackTrace();
|
| | | }
|
| | |
|
| | | }
|
| | |
|
| | |
|
| | | }
|