parent
2101cdeb86
commit
03320d9cec
|
@ -657,6 +657,25 @@ class AudioContentDetailActivity : BaseActivity<ActivityAudioContentDetailBindin
|
|||
startActivity(shareIntent)
|
||||
}
|
||||
}
|
||||
|
||||
if (response.totalContentCount != null && response.remainingContentCount != null) {
|
||||
binding.rlLimitedEdition.visibility = View.VISIBLE
|
||||
|
||||
if (response.existOrdered) {
|
||||
binding.tvRemaining.visibility = View.GONE
|
||||
binding.tvTotalCount.visibility = View.VISIBLE
|
||||
|
||||
binding.tvRemainingCount.text = "${response.orderSequence}"
|
||||
binding.tvTotalCount.text = " / ${response.totalContentCount}"
|
||||
} else {
|
||||
binding.tvRemaining.visibility = View.VISIBLE
|
||||
binding.tvTotalCount.visibility = View.GONE
|
||||
|
||||
binding.tvRemainingCount.text = "${response.remainingContentCount}"
|
||||
}
|
||||
} else {
|
||||
binding.rlLimitedEdition.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
|
||||
private fun setupMosaicArea(isMosaic: Boolean) {
|
||||
|
|
|
@ -15,6 +15,9 @@ data class GetAudioContentDetailResponse(
|
|||
@SerializedName("price") val price: Int,
|
||||
@SerializedName("duration") val duration: String,
|
||||
@SerializedName("releaseDate") val releaseDate: String?,
|
||||
@SerializedName("totalContentCount") val totalContentCount: Int?,
|
||||
@SerializedName("remainingContentCount") val remainingContentCount: Int?,
|
||||
@SerializedName("orderSequence") val orderSequence: Int?,
|
||||
@SerializedName("isActivePreview") val isActivePreview: Boolean,
|
||||
@SerializedName("isAdult") val isAdult: Boolean,
|
||||
@SerializedName("isMosaic") val isMosaic: Boolean,
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="@color/color_14262d" />
|
||||
<corners android:radius="5.3dp" />
|
||||
<stroke
|
||||
android:width="1dp"
|
||||
android:color="@color/color_14262d" />
|
||||
</shape>
|
|
@ -364,6 +364,61 @@
|
|||
</LinearLayout>
|
||||
</ScrollView>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/rl_limited_edition"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="13.3dp"
|
||||
android:layout_marginTop="13.3dp"
|
||||
android:background="@drawable/bg_round_corner_5_3_14262d"
|
||||
android:paddingHorizontal="10.3dp"
|
||||
android:paddingVertical="8dp"
|
||||
android:visibility="gone">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:fontFamily="@font/gmarket_sans_medium"
|
||||
android:text="한정판"
|
||||
android:textColor="@color/color_3bb9f1"
|
||||
android:textSize="13.3sp" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_remaining"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:fontFamily="@font/gmarket_sans_medium"
|
||||
android:text="잔여수량"
|
||||
android:textColor="@color/color_d2d2d2"
|
||||
android:textSize="13.3sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_remaining_count"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="5.3dp"
|
||||
android:fontFamily="@font/gmarket_sans_bold"
|
||||
android:textColor="@color/color_3bb9f1"
|
||||
android:textSize="13.3sp"
|
||||
tools:text="10" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_total_count"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:fontFamily="@font/gmarket_sans_medium"
|
||||
android:textColor="@color/color_d2d2d2"
|
||||
android:textSize="13.3sp"
|
||||
tools:text=" / 10" />
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
|
|
|
@ -113,4 +113,5 @@
|
|||
<color name="color_0057ff">#0057FF</color>
|
||||
<color name="color_ffecf7">#FFECF7</color>
|
||||
<color name="color_ecf9ff">#ECF9FF</color>
|
||||
<color name="color_14262d">#14262D</color>
|
||||
</resources>
|
||||
|
|
Loading…
Reference in New Issue