Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feat] 코스 등록 + 일정 등록 (Enroll) 뷰 앰플리튜드 트래킹 이벤트 코드 심기 #265

Merged
merged 9 commits into from
Sep 17, 2024

Conversation

jihyunniiii
Copy link
Contributor

@jihyunniiii jihyunniiii commented Sep 17, 2024

Related issue 🛠

Work Description ✏️

  • 코스 등록 + 일정 등록 (Enroll) 뷰의 앰플리튜드 트래킹 이벤트 코드를 심었습니다.
    • view_add_schedule
    • click_schedule1_back
    • view_add_schedule2
    • click_schedule2_back
    • click_bring_course
    • view_add_bringcourse
    • view_add_bringcourse2
    • click_schedule2_back
    • view_course1
    • click_course1_back
    • click_course2_back
    • click_course3_back

Screenshot 📸

스크린샷 2024-09-17 오후 7 04 21 스크린샷 2024-09-17 오후 7 04 09 스크린샷 2024-09-17 오후 7 04 03 스크린샷 2024-09-17 오후 7 03 54 스크린샷 2024-09-17 오후 7 03 41 스크린샷 2024-09-17 오후 7 03 33 스크린샷 2024-09-17 오후 11 26 19

Uncompleted Tasks 😅

  • N/A

To Reviewers 📢

  • click_course3_back 이벤트에서 같은 이름의 property가 2개 있어서 해당 사항 기획 측에 질문 남겨놓은 상태입니다. (같은 이름의 property 보낼 수 없음) -> 해결 완!

Copy link
Contributor

@t1nm1ksun t1nm1ksun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

여기 좀 고봉밥이네!
고생많았어 엄마

Comment on lines +173 to +174
EnrollScreenType.SECOND -> Unit
EnrollScreenType.THIRD -> Unit
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

else 보다 이게 낫나?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

개인적으로 when문 선호합니둥 ㅋㅋ

Comment on lines 196 to 232
when (enrollType) {
EnrollType.COURSE -> {
when (uiState.page) {
EnrollScreenType.FIRST -> AmplitudeUtils.trackEventWithProperties(
eventName = CLICK_COURSE1_BACK,
properties = with(uiState.enroll) { mapOf(COURSE_IMAGE to images.isNotEmpty(), COURSE_TITLE to title.isNotEmpty(), COURSE_DATE to date.isNotEmpty(), COURSE_START_TIME to startAt.isNotEmpty(), COURSE_TAGS to tags.isNotEmpty(), DATE_AREA to (city != null)) }
)

EnrollScreenType.SECOND -> AmplitudeUtils.trackEventWithProperties(
eventName = CLICK_COURSE2_BACK,
properties = with(uiState.place) { mapOf(DATE_LOCATION to title.isNotEmpty(), DATE_SPEND_TIME to duration.isNotEmpty(), LOCATION_NUM to uiState.enroll.places.size) }
)

EnrollScreenType.THIRD -> AmplitudeUtils.trackEventWithProperties(
eventName = CLICK_COURSE3_BACK,
properties = with(uiState.enroll) { mapOf(COURSE_CONTENT to description.length, COURSE_COST to cost.isNotEmpty()) }
)
}
}

EnrollType.TIMELINE -> {
when (uiState.page) {
EnrollScreenType.FIRST -> AmplitudeUtils.trackEventWithProperties(
eventName = CLICK_SCHEDULE1_BACK,
properties = with(uiState.enroll) { mapOf(DATE_TITLE to title.isNotEmpty(), DATE_DATE to date.isNotEmpty(), DATE_TIME to startAt.isNotEmpty(), DATE_TAG_NUM to tags.size, DATE_AREA to (city != null)) }
)

EnrollScreenType.SECOND -> AmplitudeUtils.trackEventWithProperties(
eventName = CLICK_SCHEDULE2_BACK,
properties = with(uiState.place) { mapOf(DATE_DETAIL_LOCATION to title.isNotEmpty(), DATE_DETAIL_TIME to duration.isNotEmpty(), DATE_COURSE_NUM to uiState.enroll.places.size) }
)

EnrollScreenType.THIRD -> Unit
}
}
}
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

분기처리 쌈뽕하네

Comment on lines 97 to 103
object ViewPath {
const val HOME = "홈"
const val TIMELINE = "데이트 일정"
const val MY_COURSE_READ = "내가 열람한 코스"
const val COURSE_DETAIL = "코스 상세"
const val LOOK = "코스 둘러보기"
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

아 여기가 리뷰에 달았던 그거구나!! 고쳐놓을게요!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

맞습니당 하나만 고치고 얼른 머지할게요!!

# Conflicts:
#	app/src/main/java/org/sopt/dateroad/presentation/ui/enroll/EnrollScreen.kt
#	app/src/main/java/org/sopt/dateroad/presentation/ui/timeline/TimelineScreen.kt
#	app/src/main/java/org/sopt/dateroad/presentation/util/Constraints.kt
@jihyunniiii jihyunniiii merged commit d4da7f5 into develop Sep 17, 2024
1 check passed
@jihyunniiii jihyunniiii deleted the feat-enroll-amplitude branch September 17, 2024 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

[feat] 코스 등록 + 일정 등록 (Enroll) 뷰 앰플리튜드 트래킹 이벤트 코드 심기
2 participants