TP-40253 | Disbursement Date Info Card (#7804)
This commit is contained in:
committed by
GitHub
parent
3c95004a24
commit
4eb619c618
@@ -8,6 +8,7 @@
|
||||
package com.naviapp.dashboard.loanapplicationdetails.models
|
||||
|
||||
import com.google.gson.annotations.SerializedName
|
||||
import com.navi.naviwidgets.models.response.ImageFieldData
|
||||
import com.navi.naviwidgets.models.response.TextFieldData
|
||||
|
||||
data class TrancheDisbursalResponse(
|
||||
@@ -50,6 +51,8 @@ data class AmountInputData(
|
||||
data class InstallmentInputData(
|
||||
@SerializedName("minValue") val minDate: Long? = null,
|
||||
@SerializedName("maxValue") val maxDate: Long? = null,
|
||||
@SerializedName("infoText") val infoText: TextFieldData? = null,
|
||||
@SerializedName("infoIcon") val infoIcon: ImageFieldData? = null,
|
||||
) : InputData()
|
||||
|
||||
open class InputData(
|
||||
|
||||
@@ -26,6 +26,7 @@ import com.navi.base.model.CtaData
|
||||
import com.navi.base.model.CtaType
|
||||
import com.navi.base.model.NaviClickAction
|
||||
import com.navi.base.utils.BaseUtils.numberToWords
|
||||
import com.navi.base.utils.isNotNull
|
||||
import com.navi.base.utils.orElse
|
||||
import com.navi.base.utils.orFalse
|
||||
import com.navi.base.utils.orZero
|
||||
@@ -41,6 +42,7 @@ import com.navi.design.utils.dpToPxInInt
|
||||
import com.navi.design.utils.getFontStyle
|
||||
import com.navi.insurance.util.timestampToddMMMMYYYY
|
||||
import com.navi.naviwidgets.callbacks.WidgetCallback
|
||||
import com.navi.naviwidgets.extensions.setImageFieldData
|
||||
import com.navi.naviwidgets.extensions.setTextFieldData
|
||||
import com.navi.naviwidgets.models.NaviWidget
|
||||
import com.navi.naviwidgets.utils.NaviWidgetIconUtils
|
||||
@@ -200,6 +202,14 @@ open class RequestInstallmentFragmentV2 :
|
||||
)
|
||||
amountInputData = viewState.response?.content?.amount
|
||||
installmentInputData = viewState.response?.content?.installmentDate
|
||||
viewState.response?.content?.installmentDate?.let { installmentDateData ->
|
||||
if (installmentDateData.infoIcon.isNotNull() && installmentDateData.infoText.isNotNull()) {
|
||||
binding.disbursementDateInfo.setVisibilityState(View.VISIBLE)
|
||||
binding.disbursementDateInfoText.setTextFieldData(installmentDateData.infoText)
|
||||
binding.disbursementDateInfoIcon.setImageFieldData(installmentDateData.infoIcon)
|
||||
}
|
||||
}
|
||||
|
||||
binding.uploadCard.setProperties(
|
||||
viewState.response?.content?.uploadCard,
|
||||
addDocumentCallback = {
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:id="@+id/content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_height="@dimen/dp_0"
|
||||
android:layout_weight="1"
|
||||
android:fillViewport="true"
|
||||
app:layout_constraintBottom_toTopOf="@+id/progress_footer"
|
||||
@@ -101,8 +101,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_4"
|
||||
android:layout_marginEnd="@dimen/dp_8"
|
||||
android:fontFamily="@font/tt_regular"
|
||||
android:background="@null"
|
||||
android:fontFamily="@font/tt_regular"
|
||||
android:inputType="number"
|
||||
android:maxLength="12"
|
||||
android:maxLines="1"
|
||||
@@ -191,6 +191,67 @@
|
||||
tools:text="10 December, 1997"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/disbursement_date_info"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_2"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/installmentStatusText">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/disbursement_date_notch"
|
||||
android:layout_width="@dimen/dp_20"
|
||||
android:layout_height="@dimen/dp_16"
|
||||
android:layout_marginStart="@dimen/dp_32"
|
||||
android:scaleType="fitXY"
|
||||
android:tint="@color/rose_white_dark"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:srcCompat="@drawable/bg_hl_solid_navy_blue_top_pointed_triangle" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="@dimen/dp_16"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:background="@drawable/rounded_8dp_light_grey_rect"
|
||||
android:backgroundTint="@color/rose_white_dark"
|
||||
android:paddingHorizontal="@dimen/dp_16"
|
||||
android:paddingVertical="@dimen/dp_8"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/disbursement_date_info_icon"
|
||||
android:layout_width="@dimen/dp_16"
|
||||
android:layout_height="@dimen/dp_16"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
android:layout_marginTop="@dimen/dp_2"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:srcCompat="@drawable/ic_info_icon_black" />
|
||||
|
||||
<com.navi.design.textview.NaviTextView
|
||||
android:id="@+id/disbursement_date_info_text"
|
||||
android:layout_width="@dimen/dp_0"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_6"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@id/disbursement_date_info_icon"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:text="Disbursement date is the date on which you want the amount to be disbursed to the builder"
|
||||
tools:textColor="@color/color_191919"
|
||||
tools:textSize="@dimen/sp_12" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.naviapp.dashboard.loanapplicationdetails.tranche_disbursal.UploadCardView
|
||||
android:id="@+id/uploadCard"
|
||||
android:layout_width="0dp"
|
||||
@@ -202,7 +263,7 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="1.0"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/installmentStatusText"
|
||||
app:layout_constraintTop_toBottomOf="@id/disbursement_date_info"
|
||||
app:layout_constraintVertical_bias="0.0" />
|
||||
|
||||
<com.navi.design.textview.NaviTextView
|
||||
@@ -225,8 +286,8 @@
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:orientation="horizontal"
|
||||
android:checkedButton="@id/radio_option_yes"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintTop_toBottomOf="@id/builder_selection_option">
|
||||
|
||||
<RadioButton
|
||||
|
||||
@@ -197,4 +197,5 @@
|
||||
<color name="tara_color">#D7DAFF</color>
|
||||
<color name="purple_light">#AA2EE4</color>
|
||||
<color name="hint_grey_color">#8C6B6B6B</color>
|
||||
<color name="rose_white_dark">#FFF0EB</color>
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user