导航菜单

页面标题

页面副标题

用信花 v1.1.3 - RepaymentIngActivity.java 源代码

正在查看: 用信花 v1.1.3 应用的 RepaymentIngActivity.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package com.duoshan.loan.ui.repayment.activity;

import android.os.CountDownTimer;
import androidx.camera.core.FocusMeteringAction;
import androidx.lifecycle.Observer;
import androidx.recyclerview.widget.RecyclerView;
import com.bumptech.glide.b;
import com.duoshan.loan.a;
import com.duoshan.loan.base.BaseActivity;
import com.duoshan.loan.databinding.ActivityRepaymentIngBinding;
import com.duoshan.loan.ui.repayment.activity.RepaymentIngActivity;
import com.duoshan.loan.ui.repayment.bean.RepayStatusBean;
import com.duoshan.loan.ui.repayment.vm.RepaymentViewModel;
import d5.f;
import e2.r;
import g5.g;

public class RepaymentIngActivity extends BaseActivity<ActivityRepaymentIngBinding, RepaymentViewModel> {

    public String f2914e;

    public CountDownTimer f2915f;

    public class a implements r.b {
        public a() {
        }

        @Override
        public void a(Long l4) {
            RepaymentIngActivity repaymentIngActivity = RepaymentIngActivity.this;
            ((RepaymentViewModel) repaymentIngActivity.f2433c).i(repaymentIngActivity.f2914e);
        }

        @Override
        public void onFinish() {
        }
    }

    public void s(RepayStatusBean repayStatusBean) {
        int repayStatus = repayStatusBean.getRepayStatus();
        if (repayStatus == 2) {
            e2.a.D(this);
            finish();
        } else {
            if (repayStatus != 3) {
                return;
            }
            e2.a.z(this, "");
            finish();
        }
    }

    public void t(f fVar) {
        ((ActivityRepaymentIngBinding) this.f2431a).smartRefresh.y(1000);
    }

    @Override
    public void g() {
        this.f2914e = getIntent().getStringExtra("userProductRepayPlanId");
        u();
    }

    @Override
    public void i() {
        ((RepaymentViewModel) this.f2433c).f2928k.observe(this, new Observer() {
            @Override
            public final void onChanged(Object obj) {
                RepaymentIngActivity.this.s((RepayStatusBean) obj);
            }
        });
    }

    @Override
    public void initView() {
        this.f2434d.titleBar(((ActivityRepaymentIngBinding) this.f2431a).parent).init();
        b.H(this).y().n(Integer.valueOf(a.h.gif_repay_ing)).l1(((ActivityRepaymentIngBinding) this.f2431a).ivRepayIng);
        ((ActivityRepaymentIngBinding) this.f2431a).smartRefresh.h(new g() {
            public final void n(d5.f fVar) {
                RepaymentIngActivity.this.t(fVar);
            }
        });
    }

    @Override
    public void onDestroy() {
        CountDownTimer countDownTimer = this.f2915f;
        if (countDownTimer != null) {
            countDownTimer.cancel();
        }
        super.onDestroy();
    }

    public final void u() {
        this.f2915f = r.a(Long.valueOf(RecyclerView.FOREVER_NS), Long.valueOf(FocusMeteringAction.DEFAULT_AUTOCANCEL_DURATION), new a()).start();
    }
}