what-the-bank/sources/com/scb/phone/view/fragment/merchant/MerchantWalletOutgoingTrans...

217 lines
8.1 KiB
Java

package com.scb.phone.view.fragment.merchant;
import android.content.Context;
import android.os.Bundle;
import com.scb.phone.view.adapter.merchant.MerchantWalletOutgoingTransactionAdapter;
import com.scb.phone.view.fragment.merchant.MerchantWalletOutgoingTransactionFragment;
import java.util.List;
import o.AbstractC12404exa;
import o.C14957gcv;
import o.C15889jRC;
import o.C16148leh;
import o.C5280bq;
import o.InterfaceC13391fZD;
import o.RK;
import o.RM;
import o.RN;
import o.ZI;
import o.bSB;
import o.cZR;
import o.kIT;
/* loaded from: classes5.dex */
public class MerchantWalletOutgoingTransactionFragment extends Hilt_MerchantWalletOutgoingTransactionFragment implements cZR.RVV, cZR.IeS, C16148leh.HBt, C16148leh.IeS {
private MerchantWalletOutgoingTransactionAdapter g;
@InterfaceC13391fZD
public bSB mPresenter;
public static MerchantWalletOutgoingTransactionFragment d(RK rk, String str, String str2) {
MerchantWalletOutgoingTransactionFragment merchantWalletOutgoingTransactionFragment = new MerchantWalletOutgoingTransactionFragment();
Bundle bundle = new Bundle();
bundle.putParcelable("com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment.EXTRA_WALLET_DETAIL", rk);
bundle.putString("com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment.EXTRA_START_DATE", str);
bundle.putString("com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment.EXTRA_END_DATE", str2);
merchantWalletOutgoingTransactionFragment.setArguments(bundle);
return merchantWalletOutgoingTransactionFragment;
}
@Override // com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment, androidx.fragment.app.Fragment
public void onCreate(Bundle bundle) {
super.onCreate(bundle);
this.mPresenter.e((bSB) this);
}
@Override // com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment
public final void c(String str, String str2, String str3) {
this.mTextMessage.setVisibility(8);
this.mRecyclerView.setVisibility(8);
this.mEmptyCard.setVisibility(8);
bSB bsb = this.mPresenter;
if (bsb.f != 0) {
bsb.f.v();
}
bsb.g = str;
bsb.e = str2;
bsb.d = str3;
C5280bq c5280bq = new C5280bq();
C14957gcv.e(str, "");
c5280bq.b = str;
c5280bq.c = Integer.valueOf(bsb.c);
c5280bq.a = 20;
c5280bq.d = str2;
c5280bq.e = str3;
bsb.b.a(c5280bq);
C15889jRC c15889jRC = bsb.b;
c15889jRC.d(c15889jRC.i, new bSB.AnonymousClass2(bsb));
}
@Override // com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment
public final AbstractC12404exa d() {
MerchantWalletOutgoingTransactionAdapter merchantWalletOutgoingTransactionAdapter = new MerchantWalletOutgoingTransactionAdapter(((BaseMerchantWalletItemTransactionFragment) this).d);
this.g = merchantWalletOutgoingTransactionAdapter;
return merchantWalletOutgoingTransactionAdapter;
}
@Override // com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment, com.scb.phone.view.fragment.BaseFragment, androidx.fragment.app.Fragment
public void onDestroyView() {
this.mPresenter.w_();
super.onDestroyView();
}
@Override // o.cZR.RVV
public final void c(RM rm, List<RN> list) {
kIT kit;
if (list == null) {
return;
}
if (list.isEmpty()) {
this.mTextMessage.setVisibility(0);
this.mRecyclerView.setVisibility(8);
return;
}
this.mTextMessage.setVisibility(8);
this.mRecyclerView.setVisibility(0);
this.mRecyclerView.setFocusable(false);
this.g.a(rm, list);
for (int i = 0; i < list.size(); i++) {
RN rn = list.get(i);
if (rn != null && rn.d && (kit = ((BaseMerchantWalletItemTransactionFragment) this).d.j) != null) {
kit.a(i, false);
}
}
this.mRecyclerView.setFocusable(true);
}
@Override // o.C16148leh.HBt
public final void d(int i) {
RN c = c(i);
if (c != null) {
c.d = true;
}
}
@Override // o.C16148leh.IeS
public final void e(int i) {
RN c = c(i);
if (c != null) {
c.d = false;
}
}
private RN c(int i) {
List<RN> a = this.g.a();
if (i < a.size()) {
return a.get(i);
}
return null;
}
@Override // com.scb.phone.view.fragment.BaseFragment
public final void aJ_() {
MerchantWalletOutgoingTransactionAdapter merchantWalletOutgoingTransactionAdapter;
if (((BaseMerchantWalletItemTransactionFragment) this).c == null || (merchantWalletOutgoingTransactionAdapter = this.g) == null) {
return;
}
merchantWalletOutgoingTransactionAdapter.c(true, new AbstractC12404exa.HBt(this) { // from class: o.fnH
private MerchantWalletOutgoingTransactionFragment e;
@Override // o.AbstractC12404exa.HBt
public final void c(boolean z) {
MerchantWalletOutgoingTransactionFragment.c(this.e, z);
}
{
this.e = this;
}
});
}
@Override // com.scb.phone.view.fragment.merchant.Hilt_MerchantWalletOutgoingTransactionFragment, com.scb.phone.view.fragment.merchant.BaseMerchantWalletItemTransactionFragment, com.scb.phone.view.fragment.merchant.Hilt_BaseMerchantWalletItemTransactionFragment, com.scb.phone.view.fragment.Hilt_BaseFragment, androidx.fragment.app.Fragment
public void onAttach(Context context) {
super.onAttach(context);
if (((BaseMerchantWalletItemTransactionFragment) this).j != null) {
((BaseMerchantWalletItemTransactionFragment) this).j.d(this);
}
}
@Override // o.cZR.RVV
public final void e(List<RN> list) {
MerchantWalletOutgoingTransactionAdapter merchantWalletOutgoingTransactionAdapter;
if (isDetached() || ((BaseMerchantWalletItemTransactionFragment) this).c == null || (merchantWalletOutgoingTransactionAdapter = this.g) == null) {
return;
}
merchantWalletOutgoingTransactionAdapter.c(false, null);
this.g.d(list);
}
@Override // o.cZR.LWm
public final void c() {
if (((BaseMerchantWalletItemTransactionFragment) this).j != null) {
((BaseMerchantWalletItemTransactionFragment) this).j.d((cZR.IeS) null);
}
}
public static /* synthetic */ void c(MerchantWalletOutgoingTransactionFragment merchantWalletOutgoingTransactionFragment, boolean z) {
if (z) {
bSB bsb = merchantWalletOutgoingTransactionFragment.mPresenter;
int i = bsb.c + 1;
bsb.c = i;
if (i <= bsb.a) {
C5280bq c5280bq = new C5280bq();
String str = bsb.g;
C14957gcv.e(str, "");
c5280bq.b = str;
c5280bq.c = Integer.valueOf(bsb.c);
c5280bq.a = 20;
c5280bq.d = bsb.e;
c5280bq.e = bsb.d;
bsb.b.a(c5280bq);
C15889jRC c15889jRC = bsb.b;
c15889jRC.d(c15889jRC.i, new bSB.AnonymousClass5(bsb));
return;
}
ZI.IeS ieS = new ZI.IeS() { // from class: o.bSE
@Override // o.ZI.IeS
public final void e(Object obj) {
((cZR.RVV) obj).e();
}
};
if (bsb.f != 0) {
ieS.e(bsb.f);
}
}
}
@Override // o.cZR.LWm
public final void e() {
if (((BaseMerchantWalletItemTransactionFragment) this).j != null) {
((BaseMerchantWalletItemTransactionFragment) this).j.d((cZR.IeS) null);
}
MerchantWalletOutgoingTransactionAdapter merchantWalletOutgoingTransactionAdapter = this.g;
if (merchantWalletOutgoingTransactionAdapter != null) {
merchantWalletOutgoingTransactionAdapter.c(false, null);
}
}
}