Skip to content

Commit

Permalink
[FEAT/#294] intern detail scrap amplitude
Browse files Browse the repository at this point in the history
  • Loading branch information
leeeyubin committed Oct 22, 2024
1 parent 2ef1b9e commit e46ad2d
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ import androidx.lifecycle.compose.LocalLifecycleOwner
import androidx.lifecycle.compose.collectAsStateWithLifecycle
import androidx.lifecycle.flowWithLifecycle
import androidx.navigation.NavHostController
import com.terning.core.analytics.EventType
import com.terning.core.analytics.LocalTracker
import com.terning.core.designsystem.component.topappbar.BackButtonTopAppBar
import com.terning.core.designsystem.theme.CalRed
import com.terning.core.designsystem.theme.Grey200
Expand Down Expand Up @@ -54,6 +56,7 @@ fun InternRoute(
val context = LocalContext.current
val lifecycleOwner = LocalLifecycleOwner.current
val internState by viewModel.internUiState.collectAsStateWithLifecycle(lifecycleOwner)
val amplitudeTracker = LocalTracker.current

LaunchedEffect(key1 = true) {
viewModel.getInternInfo(announcementId)
Expand Down Expand Up @@ -94,6 +97,10 @@ fun InternRoute(
viewModel.updateScrapCancelDialogVisibility(true)
},
onClickScrapButton = {
amplitudeTracker.track(
type = EventType.CLICK,
name = "detail_scrap"
)
viewModel.updateInternDialogVisibility(true)
}
)
Expand Down

0 comments on commit e46ad2d

Please sign in to comment.