-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #82 from YAPP-Github/TNT-232-myPage
[TNT-232] ํธ๋ ์ด๋, ํธ๋ ์ด๋ ๋ง์ดํ์ด์ง + ์ฑ ๋ด ํธ๋ ์ด๋/ํธ๋ ์ด๋ ์ฐ๊ฒฐ ์ฌ๋ถ ๋ฐ์
- Loading branch information
Showing
15 changed files
with
224 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// | ||
// MyPageEntity.swift | ||
// Domain | ||
// | ||
// Created by ๋ฐ๋ฏผ์ on 2/12/25. | ||
// Copyright ยฉ 2025 yapp25thTeamTnT. All rights reserved. | ||
// | ||
|
||
import Foundation | ||
|
||
public struct TraineeMyPageEntity: Equatable, Sendable { | ||
/// ํธ๋ ์ด๋ ์ฐ๊ฒฐ ์ฌ๋ถ | ||
public let isConnected: Bool | ||
/// ํธ๋ ์ด๋ ์ด๋ฆ | ||
public let name: String | ||
/// ํธ๋ ์ด๋ ํ๋กํ ์ด๋ฏธ์ง URL | ||
public let profileImageUrl: String | ||
/// ์์ ํ์ | ||
public let socialType: String | ||
} | ||
|
||
public struct TrainerMyPageEntity: Equatable, Sendable { | ||
/// ํธ๋ ์ด๋ ์ด๋ฆ | ||
public let name: String | ||
/// ํธ๋ ์ด๋ ํ๋กํ ์ด๋ฏธ์ง URL | ||
public let profileImageUrl: String | ||
/// ์์ ํ์ | ||
public let socialType: String | ||
/// ๊ด๋ฆฌ ์ค์ธ ํ์ ์ | ||
public let activeTraineeCount: Int? | ||
/// ํจ๊ปํ๋ ํ์ ์ | ||
public let totalTraineeCount: Int? | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
// | ||
// UserMapper.swift | ||
// Domain | ||
// | ||
// Created by ๋ฐ๋ฏผ์ on 2/12/25. | ||
// Copyright ยฉ 2025 yapp25thTeamTnT. All rights reserved. | ||
// | ||
|
||
import Foundation | ||
|
||
public extension GetMyPageInfoResDTO { | ||
func toEntity() -> TraineeMyPageEntity { | ||
return .init( | ||
isConnected: self.trainee?.isConnected ?? false, | ||
name: self.name, | ||
profileImageUrl: self.profileImageUrl, | ||
socialType: self.socialType | ||
) | ||
} | ||
|
||
func toEntity() -> TrainerMyPageEntity { | ||
return .init( | ||
name: self.name, | ||
profileImageUrl: self.profileImageUrl, | ||
socialType: self.socialType, | ||
activeTraineeCount: self.trainer?.activeTraineeCount, | ||
totalTraineeCount: self.trainer?.totalTraineeCount | ||
) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.