Commit 456e2881 authored by Wahyu Pratama's avatar Wahyu Pratama

fixing layout on bca tap

parent 799f973b
...@@ -60,7 +60,7 @@ dependencies { ...@@ -60,7 +60,7 @@ dependencies {
implementation(group: 'com.mdd.payment', name: 'aar-deviceid-release', version: '2.0.5', ext: 'aar') implementation(group: 'com.mdd.payment', name: 'aar-deviceid-release', version: '2.0.5', ext: 'aar')
implementation(group: 'com.mdd.service', name: 'partner-connect', version: '2.3.4', ext: 'aar') implementation(group: 'com.mdd.service', name: 'partner-connect', version: '2.3.4', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'mybanklibrary-release', version: '3.6.5', ext: 'aar') implementation(group: 'com.mdd.payment', name: 'mybanklibrary-release', version: '3.6.7', ext: 'aar')
implementation(group: 'com.mdd.topup', name: 'update-balance', version: '2.8.6', ext: 'aar') implementation(group: 'com.mdd.topup', name: 'update-balance', version: '2.8.6', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'z91library-release', version: '2.1.0', ext: 'aar') implementation(group: 'com.mdd.payment', name: 'z91library-release', version: '2.1.0', ext: 'aar')
implementation(group: 'com.mdd.payment', name: 'organicdrv-release', version: '2.1.0', ext: 'aar') implementation(group: 'com.mdd.payment', name: 'organicdrv-release', version: '2.1.0', ext: 'aar')
......
...@@ -164,8 +164,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV ...@@ -164,8 +164,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV
setContentView(R.layout.activity_main); setContentView(R.layout.activity_main);
ButterKnife.bind(this); ButterKnife.bind(this);
// config = Config.load(this);
if (isInternetAvailable()) { if (isInternetAvailable()) {
setUp(); setUp();
if (iya) { if (iya) {
...@@ -364,8 +362,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV ...@@ -364,8 +362,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV
textCardNumber.setText(cardInfo.getCardNumber()); textCardNumber.setText(cardInfo.getCardNumber());
mOpsResult.setTextColor(getColorRes(R.color.text_normal)); mOpsResult.setTextColor(getColorRes(R.color.text_normal));
// mOpsResult.setText(getResources().getString(R.string.TapMore));
// setCommand(MDDCommand.COMMAND_UPDATE_BALANCE);
}); });
beep(); beep();
...@@ -392,9 +388,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV ...@@ -392,9 +388,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV
textBalance.setText("Rp " + formatter.format(successUpdateBalance.getBalance())); textBalance.setText("Rp " + formatter.format(successUpdateBalance.getBalance()));
textCardNumber.setText(successUpdateBalance.getCardNumber()); textCardNumber.setText(successUpdateBalance.getCardNumber());
displayResult(R.color.text_success, R.string.no_pending_balance); displayResult(R.color.text_success, R.string.no_pending_balance);
// findViewById(R.id.lyUpdateBalance).setVisibility(View.GONE);
// displayResult(R.color.text_success, R.string.no_pending_balance);
// mProgress.setVisibility(View.INVISIBLE);
} }
hideProgressBar(); hideProgressBar();
beep(); beep();
...@@ -495,12 +488,7 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV ...@@ -495,12 +488,7 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV
boolean hasCardUid = !cardUid.isEmpty(); boolean hasCardUid = !cardUid.isEmpty();
if (hasCardUid) { if (hasCardUid) {
Log.d(TAG, "---> Send to UI Card Found"); Log.d(TAG, "---> Send to UI Card Found");
runOnUiThread(new Runnable() { runOnUiThread(() -> onNfcCardFound());
@Override
public void run() {
onNfcCardFound();
}
});
CardInfoCommand command = new CardInfoCommand(reader.myReader); CardInfoCommand command = new CardInfoCommand(reader.myReader);
Log.e("myReader", "Myreader : "+reader.myReader); Log.e("myReader", "Myreader : "+reader.myReader);
...@@ -510,9 +498,10 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV ...@@ -510,9 +498,10 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV
Log.d("cardInfo", "ini card infonnya bro : "+detectedCardInfo.toString()); Log.d("cardInfo", "ini card infonnya bro : "+detectedCardInfo.toString());
Log.d("executeSuccess", "executeIsSuccess = " + execute.isSuccess()); Log.d("executeSuccess", "executeIsSuccess = " + execute.isSuccess());
if (execute.isSuccess()) { if (execute.isSuccess()) {
if (detectedCardInfo.getBankType().equalsIgnoreCase("DKI-NEW")){ if (detectedCardInfo.getBankType().toLowerCase().contains("dki")
runOnUiThread(() -> MainActivity.this.onBalanceInfoAvailable(detectedCardInfo)); || detectedCardInfo.getBankType().toLowerCase().contains("bca")){
runOnUiThread(() -> { runOnUiThread(() -> {
MainActivity.this.onBalanceInfoAvailable(detectedCardInfo);
mProgress.setVisibility(View.GONE); mProgress.setVisibility(View.GONE);
mOpsResult.setText(R.string.tap_card); mOpsResult.setText(R.string.tap_card);
}); });
...@@ -565,10 +554,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV ...@@ -565,10 +554,6 @@ public class MainActivity extends AppCompatActivity implements MDDUpdateBalanceV
@Override @Override
public void onTagDiscovered(Tag tag) { public void onTagDiscovered(Tag tag) {
Log.d("OnTagDiscovered", "Udh sampe OnTagDiscover loh");
// taG = ByteArrayToHexString(tag.getId());
// this.tagFromIntent = tag;
execute(tag); execute(tag);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment