| | |
| | |
|
| | | import com.bsk.zhangbo.demoforbsk.R;
|
| | | import cn.com.basic.face.base.BaseFragment;
|
| | | import cn.com.basic.face.discern.common.CommonVariables;
|
| | | import cn.com.basic.face.discern.entity.Register;
|
| | | import cn.com.basic.face.discern.query.item.CheckInQueryItem;
|
| | | import cn.com.basic.face.service.DictionaryMng;
|
| | |
| | | fragment_register_surveillance_photo_img.compress(Bitmap.CompressFormat.JPEG, 100, byteArrayOutputStream);
|
| | | byte[] imageBytes = byteArrayOutputStream.toByteArray();
|
| | | String encodedImage = Base64.encodeToString(imageBytes, Base64.DEFAULT);
|
| | | params.addBodyParameter("choosePhoto", encodedImage);
|
| | | params.addBodyParameter(Register.FieldNames.surveillancePhoto, encodedImage);
|
| | | }
|
| | |
|
| | | if (fragment_register_upload_custom_photo_img != null) {
|
| | |
| | | fragment_register_upload_custom_photo_img.compress(Bitmap.CompressFormat.JPEG, 100, byteArrayOutputStream);
|
| | | byte[] imageBytes = byteArrayOutputStream.toByteArray();
|
| | | String encodedImage = Base64.encodeToString(imageBytes, Base64.DEFAULT);
|
| | | params.addBodyParameter("uploadPhoto", encodedImage);
|
| | | params.addBodyParameter(Register.FieldNames.uploadCustomPhoto, encodedImage);
|
| | | }
|
| | |
|
| | | if (fragment_register_id_card_photo_img != null) {
|
| | |
| | | fragment_register_id_card_photo_img.compress(Bitmap.CompressFormat.JPEG, 100, byteArrayOutputStream);
|
| | | byte[] imageBytes = byteArrayOutputStream.toByteArray();
|
| | | String encodedImage = Base64.encodeToString(imageBytes, Base64.DEFAULT);
|
| | | params.addBodyParameter("idPhoto", encodedImage);
|
| | | params.addBodyParameter(Register.FieldNames.idCardPhoto, encodedImage);
|
| | | }
|
| | |
|
| | | RegisterMng.getInstance().add(params);
|
| | |
| | | List<Bitmap> bitmapList = new ArrayList<>();
|
| | | bitmapList.add(0, bitmap);
|
| | |
|
| | | SurveillanceMng.getInstance().addBitmap(bitmapList, null, 0);
|
| | | SurveillanceMng.getInstance().addBitmap(bitmapList, null, 0, CommonVariables.Camera.IN);
|
| | |
|
| | | } catch (Exception e) {
|
| | | e.printStackTrace();
|