-
Notifications
You must be signed in to change notification settings - Fork 3
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] #27 - 책리스트api연결 #28
base: develop
Are you sure you want to change the base?
The head ref may contain hidden characters: "feat/#27-\uCC45\uB9AC\uC2A4\uD2B8api\uC5F0\uACB0"
Conversation
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.
고생하셨어용 대박~
@@ -0,0 +1,41 @@ | |||
// | |||
// File.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.
주석 이름 체크해주세영~
|
||
import Foundation | ||
|
||
// MARK: - Welcome |
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.
이것도..
// | ||
|
||
import Foundation | ||
import UIKit |
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.
요건 필요 없지않아여?
case .success(let result): | ||
let status = result.statusCode | ||
if status >= 200 && status < 300 { | ||
do { | ||
self.bookListResponse = try result.map(BookListResponseDTO?.self)! | ||
guard let pickArray = self.bookListResponse?.data.pick else { return } | ||
guard let topicArray = self.bookListResponse?.data.topic else { return } | ||
self.hotBookContainerView.topicViewArray = topicArray |
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.
오 곤듀~ 잘했다 ~ 👍🏻
var pickArray: [BookListDataArray] = [] | ||
var topicArray: [BookListDataArray] = [] | ||
var bookListResponse: BookListResponseDTO? |
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.
맨 위에 선언해주면 더 잘보일거같아여~
override func viewWillAppear(_ animated: Bool) { | ||
super.viewWillAppear(animated) | ||
|
||
bookListAPI() | ||
} |
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.
life cycle 관련 코드는 위로 올려주세요..~
@@ -10,6 +10,8 @@ import SnapKit | |||
import Then | |||
|
|||
class HotBookCVC: UICollectionViewCell { | |||
|
|||
static let identifier = "HotBookCVC" |
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.
여기 이거 선언하지말구 제가 util에 만들어놓은 classname으루 쓰면 될 것 같아여
DispatchQueue.global().async { [weak self] in | ||
let url = URL(string: model.cover) | ||
if let data = try? Data(contentsOf: url!) { | ||
if let image = UIImage(data: data) { | ||
DispatchQueue.main.async { | ||
self?.bookSampleImageView.image = image | ||
} | ||
} | ||
} | ||
} |
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.
대박. 이 코드 설명좀 해주세여 ~
// let url = URL(string: model.cover) | ||
// do { | ||
// let data = try Data(contentsOf: url!) | ||
// bookSampleImageView.image = UIImage(data: data) | ||
// } catch (let error) { | ||
// print("err") | ||
// } |
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.
안쓰는 코드 지워주쎄용
bookNameLabel.text = model.name | ||
bookIntroLabel.text = model.pickDescription |
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.
곤듀님 쵝오.. 수고했숴용
🔥Pull requests
⛳️ 작업한 브랜치
👷 작업한 내용
책리스트 api를 연결해보았습니다.
🚨참고 사항
미완성이지만,, 서버가 연결되긴 했어요..
📸 스크린샷
📟 관련 이슈