From caec70594ad863b2e009da99ad57db670f4129c8 Mon Sep 17 00:00:00 2001 From: 915dbfl Date: Mon, 8 Jan 2024 15:56:45 +0900 Subject: [PATCH 1/5] =?UTF-8?q?[FEAT]=20home=20api=20version=20=EC=88=98?= =?UTF-8?q?=EC=A0=95(#201)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/lgtm/android/data/service/MissionService.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/src/main/java/com/lgtm/android/data/service/MissionService.kt b/data/src/main/java/com/lgtm/android/data/service/MissionService.kt index e03bb9da..5a09b6d6 100644 --- a/data/src/main/java/com/lgtm/android/data/service/MissionService.kt +++ b/data/src/main/java/com/lgtm/android/data/service/MissionService.kt @@ -21,7 +21,7 @@ import retrofit2.http.Query interface MissionService { - @GET("v1/home") + @GET("v2/home") suspend fun getHomeMission(): Response> @POST("v2/mission") From e790b4f7f99c27d5c5cec69848a120fe92f9a427 Mon Sep 17 00:00:00 2001 From: 915dbfl Date: Mon, 8 Jan 2024 16:03:21 +0900 Subject: [PATCH 2/5] =?UTF-8?q?[FEAT]=20SectionSubItem=20VO=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80=20(#201)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/lgtm/domain/server_drive_ui/SectionSubItemVO.kt | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 domain/src/main/java/com/lgtm/domain/server_drive_ui/SectionSubItemVO.kt diff --git a/domain/src/main/java/com/lgtm/domain/server_drive_ui/SectionSubItemVO.kt b/domain/src/main/java/com/lgtm/domain/server_drive_ui/SectionSubItemVO.kt new file mode 100644 index 00000000..a0bfe432 --- /dev/null +++ b/domain/src/main/java/com/lgtm/domain/server_drive_ui/SectionSubItemVO.kt @@ -0,0 +1,6 @@ +package com.lgtm.domain.server_drive_ui + +data class SectionSubItemVO( + val text: String, + val appUrl: String? +) : SduiContent \ No newline at end of file From 7cd0d33fe44cdc2d172531f711dfa9cb67a12ced Mon Sep 17 00:00:00 2001 From: 915dbfl Date: Mon, 8 Jan 2024 17:03:07 +0900 Subject: [PATCH 3/5] =?UTF-8?q?[FEAT]=20item=5Fsdui=5Fsub=5Fitem=20layout?= =?UTF-8?q?=20=EC=B6=94=EA=B0=80(#201)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/res/layout/item_sdui_sub_item.xml | 47 +++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 common-ui/src/main/res/layout/item_sdui_sub_item.xml diff --git a/common-ui/src/main/res/layout/item_sdui_sub_item.xml b/common-ui/src/main/res/layout/item_sdui_sub_item.xml new file mode 100644 index 00000000..15a228be --- /dev/null +++ b/common-ui/src/main/res/layout/item_sdui_sub_item.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file From 2d4d2a30eab626705acbd367a2271ac8a9532d0f Mon Sep 17 00:00:00 2001 From: 915dbfl Date: Mon, 8 Jan 2024 17:12:15 +0900 Subject: [PATCH 4/5] =?UTF-8?q?[FEAT]=20SduiSubItemViewHolder=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80(#201)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../viewholder/SduiSubItemViewHolder.kt | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiSubItemViewHolder.kt diff --git a/common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiSubItemViewHolder.kt b/common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiSubItemViewHolder.kt new file mode 100644 index 00000000..9ef01cc2 --- /dev/null +++ b/common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiSubItemViewHolder.kt @@ -0,0 +1,19 @@ +package com.lgtm.android.common_ui.viewholder + +import com.lgtm.android.common_ui.databinding.ItemSduiSubItemBinding +import com.lgtm.android.common_ui.util.setOnThrottleClickListener +import com.lgtm.domain.server_drive_ui.SduiContent +import com.lgtm.domain.server_drive_ui.SduiTheme +import com.lgtm.domain.server_drive_ui.SectionSubItemVO + +class SduiSubItemViewHolder( + private val binding: ItemSduiSubItemBinding +) : SduiBaseHolder(binding) { + override fun bind(theme: SduiTheme, viewContent: SduiContent) { + binding.data = viewContent as SectionSubItemVO + binding.theme = theme + binding.btnMissionRecommend.setOnThrottleClickListener { + // todo appUrl을 활용한 화면 전환 처리 + } + } +} \ No newline at end of file From b41c490dc0f542b47031ae1096f610ac429d7ed4 Mon Sep 17 00:00:00 2001 From: 915dbfl Date: Mon, 8 Jan 2024 17:13:22 +0900 Subject: [PATCH 5/5] =?UTF-8?q?[FEAT]=20subItem=20viewType=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80=20=EB=A1=9C=EC=A7=81=20=EA=B5=AC=ED=98=84(#201)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../lgtm/android/common_ui/viewholder/SduiViewHolderFactory.kt | 3 +++ .../main/java/com/lgtm/domain/server_drive_ui/SduiViewType.kt | 1 + 2 files changed, 4 insertions(+) diff --git a/common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiViewHolderFactory.kt b/common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiViewHolderFactory.kt index 4efdf230..7ab9de95 100644 --- a/common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiViewHolderFactory.kt +++ b/common-ui/src/main/java/com/lgtm/android/common_ui/viewholder/SduiViewHolderFactory.kt @@ -8,6 +8,7 @@ import com.lgtm.android.common_ui.R import com.lgtm.android.common_ui.databinding.ItemSduiCloserBinding import com.lgtm.android.common_ui.databinding.ItemSduiEmptyBinding import com.lgtm.android.common_ui.databinding.ItemSduiItemBinding +import com.lgtm.android.common_ui.databinding.ItemSduiSubItemBinding import com.lgtm.android.common_ui.databinding.ItemSduiTitleBinding import com.lgtm.android.common_ui.databinding.ItemSduiUnknownBinding import com.lgtm.domain.server_drive_ui.SduiViewType @@ -24,6 +25,7 @@ fun getSduiViewHolder(parent: ViewGroup, viewType: SduiViewType): SduiBaseHolder SduiViewType.ITEM -> SduiItemViewHolder(binding as ItemSduiItemBinding) SduiViewType.CLOSER -> SduiCloserViewHolder(binding as ItemSduiCloserBinding) SduiViewType.EMPTY -> SduiEmptyViewHolder(binding as ItemSduiEmptyBinding) + SduiViewType.SUBITEM -> SduiSubItemViewHolder(binding as ItemSduiSubItemBinding) SduiViewType.UNKNOWN -> SduiUnknownViewHolder(binding as ItemSduiUnknownBinding) } } @@ -34,6 +36,7 @@ private fun getLayoutByViewType(viewType: SduiViewType): Int { SduiViewType.ITEM -> R.layout.item_sdui_item SduiViewType.CLOSER -> R.layout.item_sdui_closer SduiViewType.EMPTY -> R.layout.item_sdui_empty + SduiViewType.SUBITEM -> R.layout.item_sdui_sub_item SduiViewType.UNKNOWN -> R.layout.item_sdui_unknown } } diff --git a/domain/src/main/java/com/lgtm/domain/server_drive_ui/SduiViewType.kt b/domain/src/main/java/com/lgtm/domain/server_drive_ui/SduiViewType.kt index bb1e3ce4..aa4fcfa3 100644 --- a/domain/src/main/java/com/lgtm/domain/server_drive_ui/SduiViewType.kt +++ b/domain/src/main/java/com/lgtm/domain/server_drive_ui/SduiViewType.kt @@ -9,6 +9,7 @@ enum class SduiViewType( EMPTY("empty", SectionEmptyVO::class.java), CLOSER("sectionCloser", SectionCloserVO::class.java), ITEM("sectionItem", SectionItemVO::class.java), + SUBITEM("sectionSubItem", SectionSubItemVO::class.java), UNKNOWN("sectionUnknown", SectionUnknownVO::class.java); companion object {