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] 마이페이지 > 활동중인 모임 #352

Merged
merged 12 commits into from
May 8, 2023

Conversation

soobin-k
Copy link
Contributor

@soobin-k soobin-k commented May 7, 2023

📌 PR 요약

마이페이지 > 활동중인 모임 기능을 구현했습니다.

🌱 작업한 내용

  • 내 게시물 조회 API 연동
  • 내 todo 조회 API 연동
  • 기타 UI 작업

🌱 PR 포인트

  • 다음 pr에 셀 클릭 이벤트 관련 작업들 마저하겠습니다.
  • todo는 postman으로 생성했는데, 타임존이 맞�지 않는건지 서버에서 "2023-05-07"로 내려오는데 dateformatter 사용하면 "2023-05-06"으로 바꿔어서 이것도 다음에 고쳐보겠습니다.

📸 스크린샷

RPReplay_Final1683436577.mov

📮 관련 이슈

@soobin-k soobin-k self-assigned this May 7, 2023
@soobin-k soobin-k added 🍎 ConfigureUI 화면 프로토타입 UI 구현 D+2 일반적인 범주의 PR이에요. 이틀 이내에 리뷰 해주시면 됩니다 👤 MyPage labels May 7, 2023
Copy link
Contributor

@dlrjswns dlrjswns left a comment

Choose a reason for hiding this comment

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

수고했어요 수빈 ☺️👍👍👍

recruitButton
.rx.tap
.asDriver()
.drive(with: self) { owner, _ in
let vc = DetailRecruitmentViewController(plubbingID: owner.viewModel.plubbingID)
let vc = DetailRecruitmentViewController(plubbingID: owner.viewModel.plumbingID)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
let vc = DetailRecruitmentViewController(plubbingID: owner.viewModel.plumbingID)
let vc = DetailRecruitmentViewController(plubbingID: owner.viewModel.plubbingID)

오타 있는거같아요 !!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

수정했습니다~!

@@ -52,6 +80,19 @@ final class ActiveMeetingViewModel {
)
}

private func handleMyTodoInfo(todoInfo: TodoInfo) {
todoList = todoInfo.todoContent
.prefix(2)
Copy link
Contributor

Choose a reason for hiding this comment

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

prefix는 어떤 연산자인가요 ??

Copy link
Contributor Author

Choose a reason for hiding this comment

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

string에서 사용하면 지정된 개수만큼 앞에서부터 잘라주고
배열에서 사용하면 처음부터 지정된 개수만큼의 요소를 반환해줘요!

기획상으로 최대 2개의 todo, feed만 보여줘야해서 저렇게 사용했습니다~!


override func layoutSubviews() {
super.layoutSubviews()
contentView.frame = contentView.frame.inset(by: UIEdgeInsets(top: 4, left: 16, bottom: 4, right: 16))
Copy link
Contributor

Choose a reason for hiding this comment

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

이 부분은 왜 layoutSubviews안에 정의하신건가요 ??

Copy link
Member

Choose a reason for hiding this comment

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

음.. 그러네요, contentView의 inset을 설정하기보다, wholeStackView의 constraint로 inset을 설정하면 좋을 것 같아요.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

cell의 contentView에 radius가 잡혀있어서 inset을 주려면 또다른 뷰로 감싸줘야해서 저렇게 구현하긴 했는데
수정하겠습니다!

Copy link
Member

@WhiteHyun WhiteHyun left a comment

Choose a reason for hiding this comment

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

코드 구현하시느라 고생 많으셨습니다. :)


struct FeedInfo: Codable {
let totalElements: Int
let last: Bool
Copy link
Member

Choose a reason for hiding this comment

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

isLast로 변경하는 건 어때요? 저희 대부분의 모델에서는 isLast로 표기하고 있어요!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

수정했습니다~!

@@ -10,33 +10,61 @@ import Foundation
import RxSwift
import RxCocoa

protocol ActiveMeetingViewModelType {
// MARK: Property
var plumbingID: Int { get }
Copy link
Member

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.

수정했습니다~!

feedList = feedInfo.feedList
.filter { $0.viewType != .system }
.prefix(2)
.map { $0 }
Copy link
Member

Choose a reason for hiding this comment

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

여기서 .map { $0 }은 스킵해도 될 거 같아요

Copy link
Contributor Author

Choose a reason for hiding this comment

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

이거 스킵하면 에러가 나더라구요!


override func layoutSubviews() {
super.layoutSubviews()
contentView.frame = contentView.frame.inset(by: UIEdgeInsets(top: 4, left: 16, bottom: 4, right: 16))
Copy link
Member

Choose a reason for hiding this comment

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

음.. 그러네요, contentView의 inset을 설정하기보다, wholeStackView의 constraint로 inset을 설정하면 좋을 것 같아요.

@soobin-k soobin-k merged commit a8ee518 into develop May 8, 2023
@soobin-k soobin-k deleted the feat/291-MyPage/ActiveMeeting branch May 8, 2023 14:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🍎 ConfigureUI 화면 프로토타입 UI 구현 D+2 일반적인 범주의 PR이에요. 이틀 이내에 리뷰 해주시면 됩니다 👤 MyPage
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants