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

4차 과제 다시 제출 #14

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

4차 과제 다시 제출 #14

wants to merge 1 commit into from

Conversation

SeoyoungOhMe
Copy link
Collaborator

@SeoyoungOhMe SeoyoungOhMe commented Jun 29, 2024

🔥Pull requests

👷 작업한 내용

  • 4차 세미나 과제 다시해서 제출
  • Network라는 폴더에 Base, BoxOffice 폴더를 만들어 네트워크 관련 코드를 넣음.
  • ChannelCollectionViewCell 밑에 func configure 작성
func configure(with model: DailyBoxOffice) {
        channelLabel.text = model.movieNm
        contentLabel.text = model.openDt
        rankLabel.text = model.rank
        ratingLabel.text = model.salesShare
        channelImageView.image = UIImage(named: "yellow")
    }
  • MainVC에서 인기 Live 프로그램 부분을 API 내용 반영하도록 함
private func fetchLivePrograms() {
            let date = "20240628"
            boxOfficeService.fetchBoxOfficeData(forDate: date) { [weak self] result in
                switch result {
                case .success(let livePrograms):
                    self?.livePrograms = livePrograms
                    self?.channelCollectionView.reloadData()
                case .requestErr:
                    print("요청 오류 입니다")
                case .decodedErr:
                    print("디코딩 오류 입니다")
                case .pathErr:
                    print("경로 오류 입니다")
                case .serverErr:
                    print("서버 오류입니다")
                case .networkFail:
                    print("네트워크 오류입니다")
                }
            }
        }

🚨 참고 사항

  • 합세 때 썼던 구조를 비슷하게 적용해봄

📸 스크린샷

기능 스크린샷
아이폰15Pro

@SeoyoungOhMe SeoyoungOhMe self-assigned this Jun 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant