Merge branch 'merge-latest' into geo_fench
This commit is contained in:
commit
90c9a48197
@ -8,6 +8,7 @@ import androidx.appcompat.app.AlertDialog;
|
|||||||
import androidx.appcompat.app.AppCompatActivity;
|
import androidx.appcompat.app.AppCompatActivity;
|
||||||
|
|
||||||
import com.google.gson.Gson;
|
import com.google.gson.Gson;
|
||||||
|
import com.google.gson.JsonSyntaxException;
|
||||||
import com.google.gson.stream.MalformedJsonException;
|
import com.google.gson.stream.MalformedJsonException;
|
||||||
import com.utsmyanmar.baselib.emv.EmvParamOperation;
|
import com.utsmyanmar.baselib.emv.EmvParamOperation;
|
||||||
import com.utsmyanmar.baselib.fragment.DataBindingFragment;
|
import com.utsmyanmar.baselib.fragment.DataBindingFragment;
|
||||||
@ -242,7 +243,7 @@ public class TransactionResultFragment extends DataBindingFragment implements Da
|
|||||||
try {
|
try {
|
||||||
SiriusError siriusError = new Gson().fromJson(error.response().errorBody().string(), SiriusError.class);
|
SiriusError siriusError = new Gson().fromJson(error.response().errorBody().string(), SiriusError.class);
|
||||||
LogUtil.d(TAG,siriusError.getMessage());
|
LogUtil.d(TAG,siriusError.getMessage());
|
||||||
} catch (IOException ex) {
|
} catch (IOException | JsonSyntaxException ex) {
|
||||||
ex.printStackTrace();
|
ex.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -11,6 +11,7 @@ import androidx.annotation.NonNull;
|
|||||||
import androidx.annotation.Nullable;
|
import androidx.annotation.Nullable;
|
||||||
|
|
||||||
|
|
||||||
|
import com.utsmm.kbz.util.tms.TMSUtil;
|
||||||
import com.utsmyanmar.baselib.fragment.DataBindingFragment;
|
import com.utsmyanmar.baselib.fragment.DataBindingFragment;
|
||||||
import com.utsmyanmar.baselib.network.model.DemoQRStatusRequest;
|
import com.utsmyanmar.baselib.network.model.DemoQRStatusRequest;
|
||||||
import com.utsmyanmar.baselib.network.model.KPayQRQueryRequest;
|
import com.utsmyanmar.baselib.network.model.KPayQRQueryRequest;
|
||||||
@ -320,7 +321,7 @@ public class QRTransactionFragment extends DataBindingFragment implements DataBi
|
|||||||
|
|
||||||
String currentTimeStamp = new java.text.SimpleDateFormat("MMddHHmmss", java.util.Locale.getDefault())
|
String currentTimeStamp = new java.text.SimpleDateFormat("MMddHHmmss", java.util.Locale.getDefault())
|
||||||
.format(new java.util.Date());
|
.format(new java.util.Date());
|
||||||
String serial = SystemParamsOperation.getInstance().getCurrentSerialNum();
|
String serial = TMSUtil.getInstance().getSerialNumber();
|
||||||
String packageName = getActivity().getPackageName();
|
String packageName = getActivity().getPackageName();
|
||||||
EReceiptQRRequest request = new EReceiptQRRequest();
|
EReceiptQRRequest request = new EReceiptQRRequest();
|
||||||
request.setDE3("QR");
|
request.setDE3("QR");
|
||||||
|
|||||||
@ -166,7 +166,7 @@ public class ManualEntryFragment extends DataBindingFragment {
|
|||||||
|
|
||||||
public void onConfirm() {
|
public void onConfirm() {
|
||||||
if(manualEntryViewModel.validateData()) {
|
if(manualEntryViewModel.validateData()) {
|
||||||
if(sharedViewModel.transactionsType.getValue() == TransactionsType.REFUND || sharedViewModel.transactionsType.getValue() == TransactionsType.PRE_AUTH_SALE || sharedViewModel.transactionsType.getValue() == TransactionsType.SALE || sharedViewModel.transactionsType.getValue() == TransactionsType.PRE_AUTH_VOID) {
|
if(sharedViewModel.transactionsType.getValue() == TransactionsType.REFUND || sharedViewModel.transactionsType.getValue() == TransactionsType.PRE_AUTH_SALE || sharedViewModel.transactionsType.getValue() == TransactionsType.SALE || sharedViewModel.transactionsType.getValue() == TransactionsType.PRE_AUTH_VOID || sharedViewModel.transactionsType.getValue() == TransactionsType.PRE_AUTH_COMPLETE) {
|
||||||
|
|
||||||
if(manualEntryViewModel.get_cardScheme().getValue() != null && manualEntryViewModel.get_cardScheme().getValue() == CardScheme.MPU) {
|
if(manualEntryViewModel.get_cardScheme().getValue() != null && manualEntryViewModel.get_cardScheme().getValue() == CardScheme.MPU) {
|
||||||
processMPUCard();
|
processMPUCard();
|
||||||
|
|||||||
@ -696,7 +696,7 @@ public class TMSSetupsImpl implements TMSSetups{
|
|||||||
int value = Integer.parseInt(data);
|
int value = Integer.parseInt(data);
|
||||||
return value == 1;
|
return value == 1;
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
// e.printStackTrace();
|
||||||
return Boolean.parseBoolean(data);
|
return Boolean.parseBoolean(data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -177,10 +177,10 @@ public class TransactionsOperation {
|
|||||||
if (responseMap.get("F038") != null) {
|
if (responseMap.get("F038") != null) {
|
||||||
transPayDetail.setApprovalCode(Objects.requireNonNull(responseMap.get("F038")).getDataStr());
|
transPayDetail.setApprovalCode(Objects.requireNonNull(responseMap.get("F038")).getDataStr());
|
||||||
} else {
|
} else {
|
||||||
if(hostName == HostName.BPC) {
|
// if(hostName == HostName.BPC) {
|
||||||
transPayDetail.setIsNeedReversal(true);
|
// transPayDetail.setIsNeedReversal(true);
|
||||||
return;
|
// return;
|
||||||
}
|
// }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -99,13 +99,15 @@ public class BitmapConfig {
|
|||||||
// commented on Nov 13, 2024
|
// commented on Nov 13, 2024
|
||||||
// public static final String BPC_PRE_AUTH_SALE_COMPLETE = "3230058028C09800";
|
// public static final String BPC_PRE_AUTH_SALE_COMPLETE = "3230058028C09800";
|
||||||
// public static final String BPC_PRE_AUTH_SALE_COMPLETE = "3230058028C09A00";
|
// public static final String BPC_PRE_AUTH_SALE_COMPLETE = "3230058028C09A00";
|
||||||
public static final String BPC_PRE_AUTH_SALE_COMPLETE = "3230058028C09200"; // for tmk
|
// public static final String BPC_PRE_AUTH_SALE_COMPLETE = "3230058028C09200"; // for tmk
|
||||||
|
public static final String BPC_PRE_AUTH_SALE_COMPLETE = "7234058028C09200"; // for tmk ,bpc
|
||||||
|
|
||||||
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "7230058028C09000";
|
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "7230058028C09000";
|
||||||
|
|
||||||
// commented on Nov 13,2024
|
// commented on Nov 13,2024
|
||||||
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "7230058028C19800"; // added DE 2
|
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "7230058028C19800"; // added DE 2
|
||||||
public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "7234058008C09000"; // for tmk MPU
|
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "7234058008C09000"; // for tmk MPU
|
||||||
|
public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "7230058008C09000"; // for KBZ MPU
|
||||||
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "3230058028C19800";
|
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "3230058028C19800";
|
||||||
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "3230058028C19A00"; //DE55
|
// public static final String BPC_PRE_AUTH_SALE_VOID_REVERSAL = "3230058028C19A00"; //DE55
|
||||||
//
|
//
|
||||||
|
|||||||
@ -316,6 +316,7 @@ public class FieldUtils {
|
|||||||
break;
|
break;
|
||||||
case 14: // ExpireDate YYMM
|
case 14: // ExpireDate YYMM
|
||||||
String expDate = payDetail.getEXPDate();
|
String expDate = payDetail.getEXPDate();
|
||||||
|
expDate += "31";
|
||||||
if (expDate != null && expDate.trim().length() > 0) {
|
if (expDate != null && expDate.trim().length() > 0) {
|
||||||
field.setDataStr(expDate);
|
field.setDataStr(expDate);
|
||||||
} else {
|
} else {
|
||||||
@ -331,6 +332,7 @@ public class FieldUtils {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 22: //POS Service Entry Mode
|
case 22: //POS Service Entry Mode
|
||||||
|
|
||||||
String value;
|
String value;
|
||||||
if (AidlConstants.CardType.MAGNETIC.getValue() == cardType) { // 磁条
|
if (AidlConstants.CardType.MAGNETIC.getValue() == cardType) { // 磁条
|
||||||
value = "02";
|
value = "02";
|
||||||
@ -393,8 +395,6 @@ public class FieldUtils {
|
|||||||
|
|
||||||
field.setDataStr("61"); // BPC
|
field.setDataStr("61"); // BPC
|
||||||
// field.setDataStr("00");// MPU
|
// field.setDataStr("00");// MPU
|
||||||
} if (payDetail.getTransactionType() == PRE_AUTH_VOID.value) { // || payDetail.getTransactionType() == PRE_AUTH_VOID.value BPC need 06
|
|
||||||
field.setDataStr("06");
|
|
||||||
} else {
|
} else {
|
||||||
field.setDataStr("00");
|
field.setDataStr("00");
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user