Skip to content

Commit f9e298e

Browse files
committed
[#234] 마이페이지에 내 정보란 설계
1 parent 7aeacb2 commit f9e298e

File tree

5 files changed

+24
-10
lines changed

5 files changed

+24
-10
lines changed

EATSSU/App/Sources/Presentation/MyPage/Model/MyPageSettingList.swift renamed to EATSSU/App/Sources/Presentation/MyPage/Entity/MyPageSettingList.swift

+3
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ extension MyPageSettingList {
1616
// "푸시 알림 설정"
1717
MyPageSettingList(title: ESTextLiteral.MyPage.pushNotificationSetting),
1818

19+
// "내 정보"
20+
MyPageSettingList(title: ESTextLiteral.MyPage.myInfo),
21+
1922
// "내가 쓴 리뷰"
2023
MyPageSettingList(title: ESTextLiteral.MyPage.myReview),
2124

EATSSU/App/Sources/Presentation/MyPage/Enum/MyPageLabels.swift renamed to EATSSU/App/Sources/Presentation/MyPage/Enum/MyPageLabelsIndex.swift

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//
2-
// MyPageLabels.swift
2+
// MyPageLabelsIndex.swift
33
// EATSSU
44
//
55
// Created by Jiwoong CHOI on 9/11/24.
@@ -8,10 +8,13 @@
88
import Foundation
99

1010
/// "마이파이지"에서 확인할 수 있는 서비스 리스트
11-
enum MyPageLabels: Int {
11+
enum MyPageLabelsIndex: Int {
1212
/// 푸시 알림 설정
1313
case NotificationSetting = 0
1414

15+
/// 내 정보
16+
case MyInfo
17+
1518
/// 내가 쓴 리뷰
1619
case MyReview
1720

EATSSU/App/Sources/Presentation/MyPage/ViewController/MyPageViewController.swift

+12-8
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ extension MyPageViewController: UITableViewDataSource {
190190
/// "푸시 알림 설정" 셀만 별도로 처리합니다.
191191
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
192192
// "푸시 알림 설정" 셀
193-
if indexPath.row == MyPageLabels.NotificationSetting.rawValue {
193+
if indexPath.row == MyPageLabelsIndex.NotificationSetting.rawValue {
194194
guard let cell = tableView.dequeueReusableCell(
195195
withIdentifier: NotificationSettingTableViewCell.identifier,
196196
for: indexPath
@@ -243,7 +243,7 @@ extension MyPageViewController: UITableViewDelegate {
243243

244244
switch indexPath.row {
245245
// "푸시 알림 설정"
246-
case MyPageLabels.NotificationSetting.rawValue:
246+
case MyPageLabelsIndex.NotificationSetting.rawValue:
247247
NotificationManager.shared.checkNotificationSetting { setting in
248248
switch setting.authorizationStatus {
249249
case .denied:
@@ -285,13 +285,17 @@ extension MyPageViewController: UITableViewDelegate {
285285
}
286286
}
287287

288+
case MyPageLabelsIndex.MyInfo.rawValue:
289+
let myInfoViewController = MyInfoViewController()
290+
navigationController?.pushViewController(myInfoViewController, animated: true)
291+
288292
// "내가 쓴 리뷰"
289-
case MyPageLabels.MyReview.rawValue:
293+
case MyPageLabelsIndex.MyReview.rawValue:
290294
let myReviewViewController = MyReviewViewController()
291295
navigationController?.pushViewController(myReviewViewController, animated: true)
292296

293297
// "문의하기"
294-
case MyPageLabels.Inquiry.rawValue:
298+
case MyPageLabelsIndex.Inquiry.rawValue:
295299
TalkApi.shared.chatChannel(channelPublicId: ESTextLiteral.KakaoChannel.id) { [weak self] error in
296300
if error != nil {
297301
// 채널 연동 실패 시, 웹 브라우저로 연결
@@ -310,24 +314,24 @@ extension MyPageViewController: UITableViewDelegate {
310314
}
311315

312316
// "서비스 이용약관"
313-
case MyPageLabels.TermsOfUse.rawValue:
317+
case MyPageLabelsIndex.TermsOfUse.rawValue:
314318
let provisionViewController = ProvisionViewController(agreementType: .termsOfService)
315319
provisionViewController.navigationTitle = ESTextLiteral.MyPage.termsOfUse
316320
navigationController?.pushViewController(provisionViewController, animated: true)
317321

318322
// "개인정보 이용약관"
319-
case MyPageLabels.PrivacyTermsOfUse.rawValue:
323+
case MyPageLabelsIndex.PrivacyTermsOfUse.rawValue:
320324
let provisionViewController = ProvisionViewController(agreementType: .privacyPolicy)
321325
provisionViewController.navigationTitle = ESTextLiteral.MyPage.privacyTermsOfUse
322326
navigationController?.pushViewController(provisionViewController, animated: true)
323327

324328
// "만든사람들"
325-
case MyPageLabels.Creator.rawValue:
329+
case MyPageLabelsIndex.Creator.rawValue:
326330
let creatorViewController = CreatorViewController()
327331
navigationController?.pushViewController(creatorViewController, animated: true)
328332

329333
// "로그아웃"
330-
case MyPageLabels.Logout.rawValue:
334+
case MyPageLabelsIndex.Logout.rawValue:
331335
showLogoutAlert()
332336

333337
default:

EATSSU/App/Sources/Utility/Literal/ESTextLiteral.swift

+4
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,10 @@ enum ESTextLiteral {
184184
/// - Note: "푸시 알림 설정"
185185
static let pushNotificationSetting: String = "푸시 알림 설정"
186186

187+
/// 내 정보를 수정합니다.
188+
/// - Note: "내 정보"
189+
static let myInfo: String = "내 정보"
190+
187191
/// 제작자 목록을 표시하는 섹션의 타이틀 텍스트입니다.
188192
/// - Note: "만든사람들"
189193
static let creators: String = "만든사람들"

0 commit comments

Comments
 (0)