-
Notifications
You must be signed in to change notification settings - Fork 1
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
Feature/join moit #75
Conversation
remove: dummy file 삭제
Feat: Endpoint Header value 추가
commit 3651d14 Author: SongSeoYoung <[email protected]> Date: Mon Jul 24 13:49:56 2023 +0900 Feature/moit detail (#70) * add: impl, interface 모듈 분리 * add: 일부 dependency추가 * feat: demo 앱 연결 * feat: 상단 화면 UI * feat: sheet 인터렉션 레이아웃 * impl: 인터렉션 고도화 * feat: 스터디명, 설명 추가 * feat: infoview ui * chore: detailInfoView 파일 분리 및 출석viewcontroller생성 * add: moit 상세 페이지 하위 viewcontroller구성 * add: SkeletonView추가 * feat: 스켈레톤 뷰 작업 * feat: 세미나 출석 뷰 * feat: data 모듈 * feat: dependency추가 * feat: domain module * impl: 의존도 수정 * fix: 스켈레톤 수정 * feat: MOITFoundation 모듈, int extension * feat: DateString 함수 추가 * fix: 레이아웃 수정 * feat. 상세 네트워크 연결, 출석 네트워크 연결 * feat: 전체출결 리스트 * feat: 출석 비율 뷰 * feat: 내 출결 UI * feat: 전체 출결 없을 때 * impl: 출결 디테일한 부분 수정 * impl: 전체출결 구조 변경 * impl: 출결 없을 때 * impl: 내 출결 없을 때 * feat: 마무리 작업 --------- Co-authored-by: hyerin <[email protected]> commit 4f12995 Author: SongSeoYoung <[email protected]> Date: Sun Jul 23 22:38:11 2023 +0900 fix 빌드오류 수정 (#74) * feat: web 디버깅용 추가작업(textfield변경, 앱 사용성 개선, close 명령어 처리, 쿠키 보내는 쪽 수정) * fix: 빌드 오류 수정 commit 3d67d13 Author: SongSeoYoung <[email protected]> Date: Sun Jul 23 22:20:26 2023 +0900 feat: web 디버깅용 추가작업(textfield변경, 앱 사용성 개선, close 명령어 처리, 쿠키 보내는 쪽 수정) (#73) commit 7b45c86 Author: SongSeoYoung <[email protected]> Date: Sat Jul 15 16:38:33 2023 +0900 Feature/web debug (#68) * feat: 웹 디버깅용 개발 * fix: 일부 수정 * fix: back -> close변경 commit 3f8f29c Author: SongSeoYoung <[email protected]> Date: Sat Jul 15 16:17:59 2023 +0900 feat: 웹 디버깅용 개발 (#67) * feat: 웹 디버깅용 개발 * fix: 일부 수정 commit 8e677e7 Author: hyerin <[email protected]> Date: Thu Jul 13 23:50:21 2023 +0900 design: signin_logo 이미지 디자인 변경으로 인해 교체
치이카와이 ? 등장 ㅇ _ㅇ |
# Conflicts: # DesignSystem/Sources/List/MOITList.swift # Features/MOITDetail/MOITDetail/DemoApp/Sources/MOITDetailUserInterfaceAppDelegate.swift # Features/MOITDetail/MOITDetail/DemoApp/Sources/StubMOITAllAttendanceUsecase.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailAttendance/MOITDetailAttendanceViewController.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailAttendance/MOITDetailAttendanceViewModel.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailBuilder.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailInteractor.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailRouter.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailViewController.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITAttendanceStudyView.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITDetailInfoView.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITDetailInfosView.swift # Features/MOITDetail/MOITDetail/Interface/MOITDetailDependency.swift # Features/MOITDetail/MOITDetail/Project.swift # Features/MOITDetail/MOITDetailData/Implement/MOITDetailRepositoryImpl.swift # Features/MOITDetail/MOITDetailData/Interface/MOITDetailModel.swift # Features/MOITDetail/MOITDetailData/Interface/MOITDetailRepository.swift # Features/MOITDetail/MOITDetailData/Project.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITAllAttendanceUsecaseImpl.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITDayTypes.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITDetailUsecaseImpl.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITAllAttendanceEntity.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITDetailEntity.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITDetailUsecase.swift # Features/MOITDetail/MOITDetailDomain/Project.swift # Features/MOITParticipate/MOITParticipateUserInterface/Implement/ParticipationSuccess/ParticipationSuccessViewController.swift # Features/MOITWeb/Implement/MOITWebInteractor.swift # Features/MOITWeb/Implement/MOITWebViewController.swift # Features/MOITWeb/Interface/MOITWebPath.swift # MOITNetwork/Implement/NetworkImpl.swift # Plugins/UtilityPlugin/ProjectDescriptionHelpers/Dependency+Project.swift # Tuist/Dependencies.swift # Tuist/ProjectDescriptionHelpers/Project+Templates.swift
# Conflicts: # DesignSystem/Sources/List/MOITList.swift # Features/MOITDetail/MOITDetail/DemoApp/Sources/MOITDetailUserInterfaceAppDelegate.swift # Features/MOITDetail/MOITDetail/DemoApp/Sources/StubMOITAllAttendanceUsecase.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailAttendance/MOITDetailAttendanceViewController.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailAttendance/MOITDetailAttendanceViewModel.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailBuilder.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailInteractor.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailRouter.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailViewController.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITAttendanceStudyView.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITDetailInfoView.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITDetailInfosView.swift # Features/MOITDetail/MOITDetail/Interface/MOITDetailDependency.swift # Features/MOITDetail/MOITDetail/Project.swift # Features/MOITDetail/MOITDetailData/Implement/MOITDetailRepositoryImpl.swift # Features/MOITDetail/MOITDetailData/Interface/MOITDetailModel.swift # Features/MOITDetail/MOITDetailData/Interface/MOITDetailRepository.swift # Features/MOITDetail/MOITDetailData/Project.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITAllAttendanceUsecaseImpl.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITDayTypes.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITDetailUsecaseImpl.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITAllAttendanceEntity.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITDetailEntity.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITDetailUsecase.swift # Features/MOITDetail/MOITDetailDomain/Project.swift # Features/MOITParticipate/MOITParticipateUserInterface/Implement/ParticipationSuccess/ParticipationSuccessViewController.swift # Features/MOITWeb/Implement/MOITWebInteractor.swift # Features/MOITWeb/Implement/MOITWebViewController.swift # Features/MOITWeb/Interface/MOITWebPath.swift # MOITNetwork/Implement/NetworkImpl.swift # Plugins/UtilityPlugin/ProjectDescriptionHelpers/Dependency+Project.swift # Tuist/Dependencies.swift # Tuist/ProjectDescriptionHelpers/Project+Templates.swift Merge branch 'develop' into feature/join-MOIT # Conflicts: # DesignSystem/Sources/List/MOITList.swift # Features/MOITDetail/MOITDetail/DemoApp/Sources/MOITDetailUserInterfaceAppDelegate.swift # Features/MOITDetail/MOITDetail/DemoApp/Sources/StubMOITAllAttendanceUsecase.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailAttendance/MOITDetailAttendanceViewController.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailAttendance/MOITDetailAttendanceViewModel.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailBuilder.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailInteractor.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailRouter.swift # Features/MOITDetail/MOITDetail/Implement/MOITDetailViewController.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITAttendanceStudyView.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITDetailInfoView.swift # Features/MOITDetail/MOITDetail/Implement/View/MOITDetailInfosView.swift # Features/MOITDetail/MOITDetail/Interface/MOITDetailDependency.swift # Features/MOITDetail/MOITDetail/Project.swift # Features/MOITDetail/MOITDetailData/Implement/MOITDetailRepositoryImpl.swift # Features/MOITDetail/MOITDetailData/Interface/MOITDetailModel.swift # Features/MOITDetail/MOITDetailData/Interface/MOITDetailRepository.swift # Features/MOITDetail/MOITDetailData/Project.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITAllAttendanceUsecaseImpl.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITDayTypes.swift # Features/MOITDetail/MOITDetailDomain/Implement/MOITDetailUsecaseImpl.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITAllAttendanceEntity.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITDetailEntity.swift # Features/MOITDetail/MOITDetailDomain/Interface/MOITDetailUsecase.swift # Features/MOITDetail/MOITDetailDomain/Project.swift # Features/MOITParticipate/MOITParticipateUserInterface/Implement/ParticipationSuccess/ParticipationSuccessViewController.swift # Features/MOITWeb/Implement/MOITWebInteractor.swift # Features/MOITWeb/Implement/MOITWebViewController.swift # Features/MOITWeb/Interface/MOITWebPath.swift # MOITNetwork/Implement/NetworkImpl.swift # Plugins/UtilityPlugin/ProjectDescriptionHelpers/Dependency+Project.swift # Tuist/Dependencies.swift # Tuist/ProjectDescriptionHelpers/Project+Templates.swift
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
수고하셨습니다~
public func configureImage(with imageUrl: String?) { | ||
self.urlString = imageUrl | ||
configureAttributes() | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이거 private 함수의 파라미터로 urlstring 넘기는게 더 좋을 것 같아요
init(fromRawValue rawValue: String) { | ||
self = NotificationRemindOption(rawValue: rawValue) ?? .studyDay10am | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이거 기본적으로 init 있지 않나요?
public func convertToMOITDetailEntity( | ||
from moitDetailModel: MOITDetailModel | ||
) -> MOITDetailEntity { | ||
let scheduleDescription = self.moitScheduleDescription( | ||
scheduleDayOfWeeks: moitDetailModel.scheduleDayOfWeeks, | ||
scheduleRepeatCycle: moitDetailModel.scheduleRepeatCycle, | ||
scheduleStartTime: moitDetailModel.scheduleStartTime, | ||
scheduleEndTime: moitDetailModel.scheduleEndTime | ||
) | ||
let ruleShortDescription = self.ruleShortDescription( | ||
fineLateTime: moitDetailModel.fineLateTime, | ||
fineAbsenceTime: moitDetailModel.fineAbsenceTime | ||
) | ||
let ruleLongDescription = self.ruleLongDescription( | ||
fineLateTime: moitDetailModel.fineLateTime, | ||
fineLateAmount: moitDetailModel.fineLateAmount, | ||
fineAbsenceTime: moitDetailModel.fineAbsenceTime, | ||
fineAbsenceAmount: moitDetailModel.fineAbsenceAmount | ||
) | ||
let notificationDescription = self.notificationDescription( | ||
remindOption: moitDetailModel.notificationRemindOption | ||
) | ||
let periodDescription = self.periodDescription( | ||
startDate: moitDetailModel.startDate, | ||
endDate: moitDetailModel.endDate | ||
) | ||
return MOITDetailEntity( | ||
moitID: "\(moitDetailModel.moitID)", | ||
moitName: moitDetailModel.name, | ||
masterID: "\(moitDetailModel.masterID)", | ||
description: self.moitDescription(moitDetailModel.description), | ||
imageURL: moitDetailModel.imageURL, | ||
scheduleDescription: scheduleDescription, | ||
ruleShortDescription: ruleShortDescription, | ||
ruleLoneDescription: ruleLongDescription, | ||
isNotificationActive: moitDetailModel.notificationIsRemindActive, | ||
notificationDescription: notificationDescription, | ||
periodDescription: periodDescription | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
팀바이팀일 것 같긴 한데 description은 결국 뷰에 보여줄 string으로 변환하는 작업인 것 같은데 이 부분은 viewmodel에서나 interactor에서 처리하는게 맞다고 생각하긴 해요.
예를 들어 뷰모델에 moitdetailentity를 init에서 넣으면 description으로 바꿔서 저장하는 느낌?
지금은 굳이 안 바꿔도 될 것 같긴 합니다!
public final class ParticipateUseCaseImpl: ParticipateUseCase { | ||
|
||
// MARK: - properties | ||
private let participateRepository: ParticipateRepository | ||
private let moitDetailUseCase: MOITDetailUsecase | ||
|
||
// MARK: - init | ||
public init( | ||
participateRepository: ParticipateRepository | ||
participateRepository: ParticipateRepository, | ||
moitDetailUseCase: MOITDetailUsecase | ||
) { | ||
self.participateRepository = participateRepository | ||
self.moitDetailUseCase = moitDetailUseCase | ||
} | ||
|
||
// MARK: - public | ||
public func execute(with request: MOITParticipateRequest) -> Single<MOITParticipateDTO> { | ||
participateRepository.postParticipateCode(with: request) | ||
public func execute(with code: String) -> Single<MOITDetailEntity> { | ||
// ???: 이걸 여기서 만드는게 맞나?! 만드는 위치에 대한 고민... | ||
// TODO: userId 불러오는 로직 추가 필요 | ||
let request = MOITParticipateRequest( | ||
userId: 0, | ||
invitationCode: code | ||
) | ||
|
||
return participateRepository.postParticipateCode(with: request) | ||
.compactMap { [weak self] moitDetailModel -> MOITDetailEntity? in | ||
guard let self else { return nil} | ||
return self.moitDetailUseCase.convertToMOITDetailEntity(from: moitDetailModel) | ||
} | ||
.asObservable() | ||
.asSingle() | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
usecase가 usecase를 알고 있는 상황인데 수평적인 관계라 모르는 것이 맞는 것 같아요.
도메인 로직은 독립적으로 수행하고 도메인 로직을 순서대로 실행하는 비즈니스 로직은 인터랙터에서 처리하는게 바람직해보입니다
@objc private func keyboardWillShow(_ notification: Notification) { | ||
if let keyboardFrame: NSValue = notification.userInfo?[UIResponder.keyboardFrameEndUserInfoKey] as? NSValue { | ||
let keyboardHeight = keyboardFrame.cgRectValue.height - UIDevice.safeAreaBottomPadding | ||
self.keyboardHeight = keyboardHeight | ||
|
||
completeButton.flex.marginBottom(keyboardHeight) | ||
completeButton.flex.markDirty() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이런 부분은 uiviewcontroller extension으로 넣어주면 어떨가요???
진짜 질문임
headers: HTTPHeaders = [ | ||
"authorization" : "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJqd3QtdXNlci1kZWZhdWx0IiwiYXVkIjoiYXV0aDB8YWJjQG5hdmVyLmNvbXw3fGRlZmF1bHQiLCJpc3MiOiJodHRwczovL2dpdGh1Yi5jb20vbWFzaC11cC1rci9NT0lULWJhY2tlbmQiLCJpYXQiOjE2ODg4ODkyOTMsImV4cCI6MTY5MTQ4MTI5MywiaW5mbyI6eyJpZCI6NywicHJvdmlkZXJVbmlxdWVLZXkiOiJhdXRoMHxhYmNAbmF2ZXIuY29tIiwibmlja25hbWUiOiJkZWZhdWx0IiwicHJvZmlsZUltYWdlIjowLCJlbWFpbCI6ImFiY0BuYXZlci5jb20iLCJyb2xlcyI6WyJVU0VSIl19fQ.o9WjiGqNOZSkHGDKQ54b50TUEy-oWvPo1-5Egjw1HXc", | ||
"Content-Type": "application/json" | ||
], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
나중에 변경돼야 할 것 같아요
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM하고 다시 보겠음니당 ~~
|
||
self.view.rx.tapGesture() | ||
.when(.recognized) | ||
.bind(onNext: { [weak self] _ in | ||
self?.modifyTextField.resignFirstResponder() | ||
}) | ||
.disposed(by: self.diseposeBag) | ||
|
||
self.flexrootView.backgroundColor = .white | ||
self.label.text = "웹분들 여기예용 😲💖 화이팅! 전자군단🤖" | ||
self.tokenLabel.numberOfLines = 0 | ||
self.tokenLabel.text = """ | ||
토큰은 아래를 넘깁니다. | ||
Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJqd3QtdXNlci1kZWZhdWx0IiwiYXVkIjoiYXV0aDB8YWJjQG5hdmVyLmNvbXw3fGRlZmF1bHQiLCJpc3MiOiJodHRwczovL2dpdGh1Yi5jb20vbWFzaC11cC1rci9NT0lULWJhY2tlbmQiLCJpYXQiOjE2ODg4ODkyOTMsImV4cCI6MTY5MTQ4MTI5MywiaW5mbyI6eyJpZCI6NywicHJvdmlkZXJVbmlxdWVLZXkiOiJhdXRoMHxhYmNAbmF2ZXIuY29tIiwibmlja25hbWUiOiJkZWZhdWx0IiwicHJvZmlsZUltYWdlIjowLCJlbWFpbCI6ImFiY0BuYXZlci5jb20iLCJyb2xlcyI6WyJVU0VSIl19fQ.o9WjiGqNOZSkHGDKQ54b50TUEy-oWvPo1-5Egjw1HXc | ||
""" | ||
self.label.textAlignment = .center | ||
modifyTextField.layer.borderColor = UIColor.black.cgColor | ||
modifyTextField.layer.borderWidth = 1 | ||
moitCreateButton.setTitle("모잇생성 진입점", for: .normal) | ||
attendancesButton.setTitle("출석하기 진입점", for: .normal) | ||
modifyButton.setTitle("모잇 수정하기 진입점(아이디안적을시에2번으로수정됨)", for: .normal) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
왜 이게 다 diff로 잡히는거져 .. ? ㅠ _ㅠ
super.layoutSubviews() | ||
|
||
flexRootView.pin.all() | ||
flexRootView.flex.layout() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
flexRootView.flex.layout() | |
layout(mode: .adjustHieght) |
// MARK: - internal | ||
func showErrorToast() { | ||
// TODO: Point 수정 필요ㅜ | ||
let spaceBetweenButtonAndToast: CGFloat = 10 | ||
let toastHeight: CGFloat = 64 | ||
|
||
let verticalPoint = UIScreen.main.bounds.height - ( | ||
keyboardHeight + completeButton.bounds.height + spaceBetweenButtonAndToast + toastHeight * 2 | ||
) | ||
let horizontalPoint = UIScreen.main.bounds.width / 2 | ||
|
||
self.flexRootContainer.showToast( | ||
MOITToast(toastType: .fail, text: StringResource.errorToast.value), | ||
point: CGPoint(x: horizontalPoint, y: verticalPoint) | ||
) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
요거 나중에 같이 봐여 ^..^
What is this PR? 🔍
Changes 📝
Screenshot 📸
To Reviewers 🙏