Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
96 commits
Select commit Hold shift + click to select a range
a0970dc
add: Glance 기본 세팅
HI-JIN2 Feb 23, 2025
2f3b943
add: glance preview 추가
HI-JIN2 Feb 23, 2025
5bc433d
feat: glance widget UI 구현 중
HI-JIN2 Feb 23, 2025
2655bf6
feat: worker 및 datastore
HI-JIN2 Feb 25, 2025
1c77fbc
feat: lazyColumn 구현 완료
HI-JIN2 Feb 25, 2025
28a816e
chore: 리시버 정리
HI-JIN2 Feb 26, 2025
dc2f3d9
feat: 변경된 디자인 4*2
HI-JIN2 Feb 26, 2025
527f6b5
setting: hilt compiler 추가
HI-JIN2 Feb 26, 2025
da1f4c4
feat: Worker에서 Usecase로 API 호출하고, datastore에 저장
HI-JIN2 Mar 1, 2025
bd7171c
feat: 위젯 UI BaseLayout을 재활용 하도록 수정
HI-JIN2 Mar 1, 2025
9a48c25
feat: 더미가 아닌 실제 데이터를 연결
HI-JIN2 Mar 1, 2025
95d4c43
chore: 코드 정리
HI-JIN2 Mar 1, 2025
db3cbf9
feat: data class WidgetMeal 만듦
HI-JIN2 Mar 1, 2025
1ea0593
chore: 코드 정리
HI-JIN2 Mar 1, 2025
613d617
chore: enum -> 한글화 함수 추가
HI-JIN2 Mar 1, 2025
9b08114
feat: 작은 위젯 추가
HI-JIN2 Mar 5, 2025
896ea76
feat: 위젯 설정 화면
HI-JIN2 Mar 5, 2025
212a87b
add: WidgetSettingScreen
HI-JIN2 Mar 5, 2025
230c947
setting: 라이브러리 정리 (hilt)
HI-JIN2 Jun 25, 2025
7353143
feat: 일단 빌드 됨
HI-JIN2 Jun 25, 2025
55d5a9e
feat: json 파싱 됨
HI-JIN2 Jul 1, 2025
6642cd5
add: Glance 기본 세팅
HI-JIN2 Feb 23, 2025
e7ed126
add: glance preview 추가
HI-JIN2 Feb 23, 2025
a76c160
feat: glance widget UI 구현 중
HI-JIN2 Feb 23, 2025
b5564ee
feat: worker 및 datastore
HI-JIN2 Feb 25, 2025
d632cfa
feat: lazyColumn 구현 완료
HI-JIN2 Feb 25, 2025
ac392d5
chore: 리시버 정리
HI-JIN2 Feb 26, 2025
945cf3e
feat: 변경된 디자인 4*2
HI-JIN2 Feb 26, 2025
d3762b2
feat: Worker에서 Usecase로 API 호출하고, datastore에 저장
HI-JIN2 Mar 1, 2025
919f4c0
feat: 위젯 UI BaseLayout을 재활용 하도록 수정
HI-JIN2 Mar 1, 2025
14e11f7
feat: 더미가 아닌 실제 데이터를 연결
HI-JIN2 Mar 1, 2025
27d518b
chore: 코드 정리
HI-JIN2 Mar 1, 2025
7ede900
feat: data class WidgetMeal 만듦
HI-JIN2 Mar 1, 2025
20e8b59
chore: 코드 정리
HI-JIN2 Mar 1, 2025
08a2348
chore: enum -> 한글화 함수 추가
HI-JIN2 Mar 1, 2025
4b28d99
feat: 작은 위젯 추가
HI-JIN2 Mar 5, 2025
c5deedb
feat: 위젯 설정 화면
HI-JIN2 Mar 5, 2025
5958cef
add: WidgetSettingScreen
HI-JIN2 Mar 5, 2025
4c5cc7d
feat: 일단 빌드 됨
HI-JIN2 Jun 25, 2025
22f936f
feat: 디자인 반영
HI-JIN2 Jul 1, 2025
42d4a37
feat: 시간 변경
HI-JIN2 Jul 1, 2025
db74247
delete: save 관련 로직 제거
HI-JIN2 Jul 1, 2025
a02eef9
feat: 위젯 클릭시 앱 실행
HI-JIN2 Jul 1, 2025
b13b7cd
feat: 색상 및 padding
HI-JIN2 Jul 2, 2025
a27d592
chore: 에러 화면도 클릭 시 앱 진입 하도록
HI-JIN2 Jul 6, 2025
19855b1
feat: meal 단위 분리 및 같은 meal 안에서는 +로 합치기
HI-JIN2 Jul 6, 2025
bc8160a
feat: 식당명 하드코딩 아니게 수정
HI-JIN2 Jul 6, 2025
746904f
feat: < > 눌렀을때 바로 반영됨
HI-JIN2 Jul 6, 2025
d71c2c5
feat: < > 눌렀을때 위젯 ui 상의 이름이랑 메뉴들도 바뀜 + 로그도 당연히 다 뜸
HI-JIN2 Jul 6, 2025
986dcf0
fix: 식당 이름만 잘 안바뀌던 문제 해결
HI-JIN2 Jul 6, 2025
3be69ed
refactor: MealWidgetScaffold로 중복코드 처리
HI-JIN2 Jul 6, 2025
1d13d12
fix: 위젯 끼리 동기화 되는 현상 고침 (glanceId를 주고 받도록 수정)
HI-JIN2 Jul 8, 2025
8df1da6
feat: 오른쪽도 추가
HI-JIN2 Jul 8, 2025
df8afc6
repackaging
HI-JIN2 Jul 11, 2025
5b7b85d
chore: more prettier code
HI-JIN2 Jul 11, 2025
fa585e2
feat: create component
HI-JIN2 Jul 27, 2025
8aab438
feat: setting configure
HI-JIN2 Jul 27, 2025
005e806
chore: repackaging
HI-JIN2 Jul 27, 2025
dc112d6
feat: Custom Radio Button success
HI-JIN2 Jul 27, 2025
ae1235e
feat: widget add scenario
HI-JIN2 Jul 27, 2025
888b6b3
fix: init default (dodam)
HI-JIN2 Jul 27, 2025
577103a
chore: separate core/design-system module
HI-JIN2 Aug 20, 2025
b404733
chore: change preview image
HI-JIN2 Aug 20, 2025
edfcc33
chore: top bar
HI-JIN2 Aug 26, 2025
b2ef81f
Revert "chore: top bar"
HI-JIN2 Aug 26, 2025
b406891
feat: 설정 없음 -> 액션 가하면 정상작동
HI-JIN2 Aug 26, 2025
fbee510
feat: 아침/점심/저녁 다 datastore에 저장
HI-JIN2 Aug 26, 2025
74a7e3f
feat: 딜레이 5초
HI-JIN2 Aug 26, 2025
99a3ef8
feat: 딜레이 2초
HI-JIN2 Aug 31, 2025
f99a53d
chore: package
HI-JIN2 Aug 31, 2025
06eec08
refactor: datastore 접근을 ui(widget)레이어에서 하지 않고 data/domain 계층을 추가하여 분리함
HI-JIN2 Sep 4, 2025
c81cd9b
chore: delete unused
HI-JIN2 Sep 4, 2025
34f62d6
chore: 위젯 클릭시 바로가기
HI-JIN2 Sep 4, 2025
f1bd342
add: common module
HI-JIN2 Sep 4, 2025
12c18e1
feat: logging app_launch (icon/notication/widget)
HI-JIN2 Sep 6, 2025
34fcb30
chore: enum class common 모듈로 이동
HI-JIN2 Sep 6, 2025
25936ff
feat: 로깅 이벤트 정의
HI-JIN2 Sep 6, 2025
6c7b7ca
chore: common 모듈로 옮기면서 report 사유 string을 불러올 수 없어 하드코딩함
HI-JIN2 Sep 6, 2025
d78b495
feat: logging click_cafeteria_info
HI-JIN2 Sep 6, 2025
bbf35dc
feat: logging select_day
HI-JIN2 Sep 6, 2025
f38f056
feat: logging write_review(_v1), complete_review(_v1)
HI-JIN2 Sep 6, 2025
6578c60
feat: logging select_mealtype
HI-JIN2 Sep 6, 2025
6a45e6f
chore: 리베이스 실수
HI-JIN2 Sep 6, 2025
dbc3ce2
chore: 리베이스 실수2
HI-JIN2 Sep 6, 2025
487f2f6
feat: logging click_map, click_map_mine, click_partner_restaurant
HI-JIN2 Sep 6, 2025
fefde9e
feat: logging click_menu
HI-JIN2 Sep 6, 2025
9826860
feat: logging add_widget
HI-JIN2 Sep 6, 2025
87a0abd
chore: analytics debug 수집 안되게 수정
HI-JIN2 Sep 6, 2025
8161a52
feat: logging remove_widget
HI-JIN2 Sep 7, 2025
9cc3c02
feat: logging complete_review_v1
HI-JIN2 Sep 7, 2025
a78a138
refactor: Restaurant enum을 바로 넘기도록 리팩토링
HI-JIN2 Sep 7, 2025
4340f4e
chore: 최종 문서 검토
HI-JIN2 Sep 7, 2025
a20fd85
chore: apply Copilt review
HI-JIN2 Sep 7, 2025
1b76569
chore: separate LaunchPath other files
HI-JIN2 Sep 8, 2025
b0a4468
chore: 코드리뷰 반영
HI-JIN2 Sep 8, 2025
14854b7
chore: 오타 수정
HI-JIN2 Sep 8, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,6 @@ android {
isShrinkResources = false
isMinifyEnabled = false
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro")

var shrinkResources = false
var minifyEnabled = false
}

debug {
Expand Down Expand Up @@ -114,6 +111,7 @@ android {

dependencies {
implementation(project(":core:design-system"))
implementation(project(":core:common"))

implementation(libs.androidx.core.ktx)
implementation(libs.androidx.appcompat)
Expand Down Expand Up @@ -200,7 +198,6 @@ dependencies {
implementation(libs.androidx.compose.ui.graphics)
implementation(libs.androidx.compose.ui.tooling.preview)
implementation(libs.androidx.compose.material3)
// androidTestImplementation(libs.androidx.compose.ui.test.junit4)
implementation(libs.compose.theme.adapter)
implementation(libs.accompanist.appcompat.theme)
androidTestImplementation(libs.androidx.compose.bom)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import android.os.Build
import androidx.annotation.RequiresApi
import androidx.core.app.NotificationCompat
import com.eatssu.android.R
import com.eatssu.android.presentation.cafeteria.CafeteriaFragment
import com.eatssu.android.presentation.login.IntroActivity
import java.time.DayOfWeek
import java.time.LocalDateTime

Expand Down Expand Up @@ -44,14 +44,14 @@ class NotificationReceiver : BroadcastReceiver() {
}


val intent = Intent(context, CafeteriaFragment::class.java).apply {
val intent = Intent(context, IntroActivity::class.java).apply {
flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK
}

val pendingIntent = PendingIntent.getActivity(
context,
0,
intent,
intent.putExtra("launch_path", "notification"),
PendingIntent.FLAG_IMMUTABLE or PendingIntent.FLAG_UPDATE_CURRENT
)

Expand Down
5 changes: 0 additions & 5 deletions app/src/main/java/com/eatssu/android/data/enums/Provider.kt

This file was deleted.

12 changes: 0 additions & 12 deletions app/src/main/java/com/eatssu/android/data/enums/ReportType.kt

This file was deleted.

27 changes: 0 additions & 27 deletions app/src/main/java/com/eatssu/android/data/enums/Restaurant.kt

This file was deleted.

13 changes: 0 additions & 13 deletions app/src/main/java/com/eatssu/android/data/enums/Time.kt

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.eatssu.android.data.repository

import com.eatssu.android.R
import com.eatssu.android.data.enums.Restaurant
import com.eatssu.android.domain.model.RestaurantInfo
import com.eatssu.common.enums.Restaurant
import com.google.firebase.remoteconfig.FirebaseRemoteConfig
import com.google.firebase.remoteconfig.FirebaseRemoteConfigSettings
import org.json.JSONArray
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ class MealRepositoryImpl @Inject constructor(
}
}


override suspend fun getMenuInfoByMealId(mealId: Long): Flow<BaseResponse<MenuOfMealResponse>> =
flow {
emit(mealService.getMenuInfoByMealId(mealId))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import androidx.datastore.preferences.core.Preferences
import androidx.datastore.preferences.core.edit
import androidx.datastore.preferences.core.stringPreferencesKey
import androidx.datastore.preferences.preferencesDataStore
import com.eatssu.android.data.enums.Restaurant
import com.eatssu.common.enums.Restaurant
import kotlinx.coroutines.flow.first
import timber.log.Timber
import javax.inject.Inject
Expand All @@ -20,9 +20,9 @@ class WidgetPreferencesRepository @Inject constructor(
private fun fileKeyRestaurantKey(fileKey: String) =
stringPreferencesKey("widget_restaurant_by_fileKey_$fileKey")

suspend fun saveRestaurantByFileKey(fileKey: String, restaurant: String) {
suspend fun saveRestaurantByFileKey(fileKey: String, restaurant: Restaurant) {
context.widgetPrefsDataStore.edit { prefs ->
prefs[fileKeyRestaurantKey(fileKey)] = restaurant
prefs[fileKeyRestaurantKey(fileKey)] = restaurant.name
}
Timber.d("saveRestaurantByFileKey 호출됨: fileKey='$fileKey', restaurant='$restaurant'")
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.eatssu.android.domain.model

import com.eatssu.android.data.enums.Restaurant
import com.eatssu.common.enums.Restaurant

data class RestaurantInfo(
val enum: Restaurant,
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/java/com/eatssu/android/domain/model/Section.kt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.eatssu.android.domain.model

import com.eatssu.android.data.enums.MenuType
import com.eatssu.android.data.enums.Restaurant
import com.eatssu.common.enums.MenuType
import com.eatssu.common.enums.Restaurant

data class Section(
val menuType: MenuType,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.eatssu.android.domain.model

import com.eatssu.android.data.enums.Restaurant
import com.eatssu.common.enums.Restaurant


sealed interface WidgetMealInfo {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ package com.eatssu.android.domain.usecase.review

import com.eatssu.android.data.dto.response.BaseResponse
import com.eatssu.android.data.dto.response.GetReviewListResponse
import com.eatssu.android.data.enums.MenuType
import com.eatssu.android.domain.repository.ReviewRepository
import com.eatssu.common.enums.MenuType
import kotlinx.coroutines.flow.Flow
import javax.inject.Inject

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ package com.eatssu.android.domain.usecase.review

import com.eatssu.android.data.dto.response.BaseResponse
import com.eatssu.android.data.dto.response.GetReviewListResponse
import com.eatssu.android.data.enums.MenuType
import com.eatssu.android.domain.repository.ReviewRepository
import com.eatssu.common.enums.MenuType
import kotlinx.coroutines.flow.Flow
import javax.inject.Inject

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.eatssu.android.domain.usecase.widget

import com.eatssu.android.data.enums.Restaurant
import com.eatssu.android.data.enums.Time
import com.eatssu.android.domain.repository.MealRepository
import com.eatssu.android.presentation.widget.WidgetMealList
import com.eatssu.common.enums.Restaurant
import com.eatssu.common.enums.Time
import kotlinx.coroutines.flow.combine
import kotlinx.coroutines.flow.first
import timber.log.Timber
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.eatssu.android.domain.usecase.widget

import com.eatssu.android.data.enums.Restaurant
import com.eatssu.android.data.repository.WidgetPreferencesRepository
import com.eatssu.common.enums.Restaurant
import javax.inject.Inject

class LoadRestaurantByFileKeyUseCase @Inject constructor(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
package com.eatssu.android.domain.usecase.widget

import com.eatssu.android.data.repository.WidgetPreferencesRepository
import com.eatssu.common.enums.Restaurant
import javax.inject.Inject

class SaveRestaurantByFileKeyUseCase @Inject constructor(
private val widgetPrefsRepository: WidgetPreferencesRepository
) {
suspend operator fun invoke(fileKey: String, restaurantDisplayName: String) {
widgetPrefsRepository.saveRestaurantByFileKey(fileKey, restaurantDisplayName)
suspend operator fun invoke(fileKey: String, restaurant: Restaurant) {
widgetPrefsRepository.saveRestaurantByFileKey(fileKey, restaurant)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,15 @@ import androidx.recyclerview.widget.GridLayoutManager
import androidx.recyclerview.widget.RecyclerView
import androidx.viewpager2.widget.ViewPager2
import com.eatssu.android.databinding.FragmentCafeteriaBinding
import com.eatssu.android.presentation.base.BaseFragment
import com.eatssu.android.presentation.MainViewModel
import com.eatssu.android.presentation.base.BaseFragment
import com.eatssu.android.presentation.cafeteria.calendar.CalendarAdapter
import com.eatssu.android.presentation.cafeteria.calendar.CalendarAdapter.OnItemListener
import com.eatssu.android.presentation.util.CalendarUtil
import com.eatssu.android.presentation.util.CalendarUtil.daysInWeekArray
import com.eatssu.android.presentation.util.CalendarUtil.monthYearFromDate
import com.eatssu.common.EventLogger
import com.eatssu.common.enums.Time
import com.google.android.material.tabs.TabLayout
import com.google.android.material.tabs.TabLayoutMediator
import dagger.hilt.android.AndroidEntryPoint
Expand Down Expand Up @@ -50,13 +52,33 @@ class CafeteriaFragment : BaseFragment<FragmentCafeteriaBinding>(), OnItemListen
val tabTitles = listOf("아침", "점심", "저녁")
TabLayoutMediator(tabLayout, viewPager) { tab, position -> tab.text = tabTitles[position] }.attach()

// ViewPager 페이지 변경 감지
setupViewPagerPageChangeListener(viewPager)

initWidgets()
CalendarUtil.selectedDate = LocalDate.now()
mainViewModel.setData(CalendarUtil.selectedDate)
setWeekView()
setCalendarWeekClickListener()
}

private fun setupViewPagerPageChangeListener(viewPager: ViewPager2) {
viewPager.registerOnPageChangeCallback(object : ViewPager2.OnPageChangeCallback() {
override fun onPageSelected(position: Int) {
super.onPageSelected(position)

// 페이지 변경 시 이벤트 로깅
val time = when (position) {
0 -> Time.MORNING
1 -> Time.LUNCH
2 -> Time.DINNER
else -> Time.LUNCH // 기본값
}
EventLogger.selectMealTime(time)
}
})
}

private fun initWidgets() {
calendarRecyclerView = binding.weekRecycler
monthYearText = binding.monthYearTV
Expand Down Expand Up @@ -94,5 +116,6 @@ class CafeteriaFragment : BaseFragment<FragmentCafeteriaBinding>(), OnItemListen
mainViewModel.setData(date)
mainPosition = position
setWeekView()
EventLogger.selectDay(date.dayOfWeek.name)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import androidx.annotation.RequiresApi
import androidx.fragment.app.Fragment
import androidx.fragment.app.FragmentActivity
import androidx.viewpager2.adapter.FragmentStateAdapter
import com.eatssu.android.data.enums.Time
import com.eatssu.android.presentation.cafeteria.menu.MenuFragment
import com.eatssu.common.enums.Time
import java.time.LocalTime

class CafeteriaViewPagerAdapter(fragmentActivity: FragmentActivity) :
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ import android.view.View
import android.view.ViewGroup
import androidx.fragment.app.activityViewModels
import com.bumptech.glide.Glide
import com.eatssu.android.data.enums.Restaurant
import com.eatssu.android.databinding.FragmentBottomsheetInfoBinding
import com.eatssu.common.EventLogger
import com.eatssu.common.enums.Restaurant
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers
Expand Down Expand Up @@ -36,7 +37,9 @@ class InfoBottomSheetFragment : BottomSheetDialogFragment() {
val restaurantType = enumValues<Restaurant>().find { it.name == name } ?: Restaurant.HAKSIK
Timber.d("onViewCreated: $name $restaurantType")

binding.tvName.text = restaurantType.displayName
EventLogger.clickRestaurantInfo(restaurantType)

binding.tvName.text = restaurantType.korean

CoroutineScope(Dispatchers.Main).launch {
infoViewModel.infoList.collect {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.eatssu.android.presentation.cafeteria.info

import androidx.lifecycle.ViewModel
import com.eatssu.android.data.enums.Restaurant
import com.eatssu.android.data.repository.FirebaseRemoteConfigRepository
import com.eatssu.android.domain.model.RestaurantInfo
import com.eatssu.common.enums.Restaurant
import dagger.hilt.android.lifecycle.HiltViewModel
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.StateFlow
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,14 @@ class MenuAdapter(
Log.d("MenuAdapter", "bind: ${sectionModel.cafeteria}")
}

binding.tvCafeteria.text = sectionModel.cafeteria.displayName
binding.tvCafeteria.text = sectionModel.cafeteria.korean
binding.tvCafeteriaLocation.text = sectionModel.cafeteriaLocation

binding.rvMenu.apply {
setHasFixedSize(true)
layoutManager = LinearLayoutManager(binding.root.context)
adapter = sectionModel.menuList?.let {
MenuSubAdapter(it, sectionModel.cafeteria.menuType)
MenuSubAdapter(it, sectionModel.cafeteria)
}
}
}
Expand Down
Loading