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

7th seminar #5

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open

7th seminar #5

wants to merge 3 commits into from

Conversation

SeoyoungOhMe
Copy link
Collaborator

@SeoyoungOhMe SeoyoungOhMe commented May 27, 2024

๐Ÿ”ฅPull requests

โ›ณ๏ธ ์ž‘์—…ํ•œ ๋ธŒ๋žœ์น˜

๐Ÿ‘ท ์ž‘์—…ํ•œ ๋‚ด์šฉ

  • ๊ธฐ์กด์˜ ์ฝ”๋“œ์— SOLID ํŒจํ„ด์„ ์ ์šฉํ–ˆ์Šต๋‹ˆ๋‹ค.(๊ธฐ๋ณธ๊ณผ์ œ)
  • ํด๋”๋ง์„ ์‹ ๊ฒฝ์จ์„œ ์ˆ˜์ •ํ–ˆ์Šต๋‹ˆ๋‹ค.
  • viewDidLoad์—๋Š” ํ•จ์ˆ˜๋งŒ ๋“ค์–ด๊ฐ€๋„๋ก ์ˆ˜์ •ํ–ˆ์Šต๋‹ˆ๋‹ค.
  • ์ „์— ์‹คํŒจํ–ˆ๋˜ API ์—ฐ๊ฒฐ์— ์„ฑ๊ณตํ–ˆ์Šต๋‹ˆ๋‹ค.
  • ์ด์Šˆ๋ฅผ ํŒŒ๊ณ  PR์„ ์ชผ๊ฐœ์„œ ์˜ฌ๋ฆฌ๋Š” ๊ฒƒ์„ ์‹œ๋„ํ•ด๋ณด์•˜์Šต๋‹ˆ๋‹ค.

๐Ÿšจ ์ฐธ๊ณ  ์‚ฌํ•ญ

  • ์ˆ˜์ •๋œ ํด๋”๋ง์€ ๋‹ค์Œ๊ณผ ๊ฐ™์Šต๋‹ˆ๋‹ค.
.
โ”œโ”€โ”€ Week2_assignment
โ”‚ย ย  โ”œโ”€โ”€ Application
โ”‚ย ย  โ”œโ”€โ”€ Base.lproj
โ”‚ย ย  โ”œโ”€โ”€ Global
โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ Extensions
โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ Resources
โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ Settings
โ”‚ย ย  โ”‚ย ย      โ”œโ”€โ”€ Config.swift
โ”‚ย ย  โ”‚ย ย      โ””โ”€โ”€ Info.plist
โ”‚ย ย  โ”œโ”€โ”€ Network
โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ Base
โ”‚ย ย  โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ BaseService.swift
โ”‚ย ย  โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ BaseTargetType.swift
โ”‚ย ย  โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ MoyaLoggingPlugin.swift
โ”‚ย ย  โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ NetworkResult.swift
โ”‚ย ย  โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ NetworkService.swift
โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ BoxOffice
โ”‚ย ย  โ”‚ย ย      โ”œโ”€โ”€ BoxOfficeService.swift
โ”‚ย ย  โ”‚ย ย      โ”œโ”€โ”€ BoxOfficeTargetType.swift
โ”‚ย ย  โ”‚ย ย      โ””โ”€โ”€ DTO
โ”‚ย ย  โ”‚ย ย          โ””โ”€โ”€ GetBoxOfficeResponse.swift
โ”‚ย ย  โ””โ”€โ”€ Presentation
โ”‚ย ย      โ”œโ”€โ”€ ContentCollection
โ”‚ย ย      โ”‚ย ย  โ”œโ”€โ”€ Cell
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ BaseballCollectionViewCell.swift
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ HeaderCollectionView.swift
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ LiveCollectionViewCell.swift
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ PosterCollectionViewCell.swift
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ TabControllCollectionViewCell.swift
โ”‚ย ย      โ”‚ย ย  โ”œโ”€โ”€ ContentCollectionViewCell.swift
โ”‚ย ย      โ”‚ย ย  โ”œโ”€โ”€ ContentViewController.swift
โ”‚ย ย      โ”‚ย ย  โ”œโ”€โ”€ Model
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ BaseballSlogan.swift
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ LiveProgramModel.swift
โ”‚ย ย      โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ PosterModel.swift
โ”‚ย ย      โ”‚ย ย  โ””โ”€โ”€ ViewController
โ”‚ย ย      โ”‚ย ย      โ”œโ”€โ”€ MainViewController.swift
โ”‚ย ย      โ”‚ย ย      โ””โ”€โ”€ TabBarController.swift
โ”‚ย ย      โ””โ”€โ”€ Welcome
โ”‚ย ย          โ””โ”€โ”€ ViewController
โ”‚ย ย              โ”œโ”€โ”€ ViewController.swift
โ”‚ย ย              โ””โ”€โ”€ WelcomeViewController.swift

๐Ÿ“ธ ์Šคํฌ๋ฆฐ์ƒท

๊ธฐ๋Šฅ ์Šคํฌ๋ฆฐ์ƒท
๋กœ๊ทธ์ธ ๋ทฐ
๋ฉ”์ธ ๋ทฐ

๐Ÿ“Ÿ ๊ด€๋ จ ์ด์Šˆ

@SeoyoungOhMe SeoyoungOhMe self-assigned this May 27, 2024
@SeoyoungOhMe SeoyoungOhMe marked this pull request as ready for review May 27, 2024 15:39
@SeoyoungOhMe SeoyoungOhMe changed the base branch from main to develop May 28, 2024 02:58
Copy link

@kim-seonwoo kim-seonwoo left a comment

Choose a reason for hiding this comment

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

์ƒ๋‹นํžˆ ๋งŽ์€ ๋ณ€๊ฒฝ์ด ๋ณด์ด๋„ค์š”..
์ •๋ง.. ์ˆ˜๊ณ ๋งŽ์œผ์…จ์Šต๋‹ˆ๋‹ค !! ๐Ÿ™‡๐Ÿ‘

var task: Task {
switch self {
case let .fetchBoxOfficeData(date):
return .requestParameters(parameters: ["key": "b4ddbf38f567f468512099872d9cc672", "targetDt": date], encoding: URLEncoding.queryString)

Choose a reason for hiding this comment

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

key๊ฐ’๋„ Config์—์„œ base url ์ˆจ๊ธฐ์‹  ๋ฐฉ์‹์ฒ˜๋Ÿผ ์ฒ˜๋ฆฌํ•˜์‹œ๋ฉด ์•ˆ์ „ํ•˜๋‹ต๋‹ˆ๋‹ค!

Choose a reason for hiding this comment

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

์ €๋„ ์ด๊ฒƒ๋–„๋ฌธ์— ๊ฟ€๋ฐคํ•œ๋ฒˆ ๋งž์•˜์Šต๋‹ˆ๋‹ค ์„ ์šฐ๊ฐ€ ๋งํ•œ๋Œ€๋กœ Config์—์„œ base url ์ˆจ๊ธด ๋ฐฉ๋ฒ•์ฒ˜๋Ÿผ Privacy๋กœ ๊ด€๋ฆฌํ•˜๋Š”๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค. ์•„๋‹ˆ ๊ทธ๋ ‡๊ฒŒ ํ•ด์•ผํ•ฉ๋‹ˆ๋‹ค. (ํŠนํžˆ๋‚˜ Git๋ ˆํฌ๊ฐ€ Public ์ƒํƒœ๋ผ๋ฉด.)
์™œ๋ƒํ•˜๋ฉด ์ด๋ ‡๊ฒŒ ์˜คํ”ˆ๋œ ๊นƒ ๋ ˆํฌ์— ๊ฐœ์ธ ํ‚ค๋‚˜ ์„œ๋ฒ„ url์ด ์˜คํ”ˆ๋˜์–ด์žˆ๋Š” ์ƒํƒœ๋ผ๋ฉด ์ด๋Ÿฐ๊ฒƒ๋งŒ ์ „๋ฌธ์ ์œผ๋กœ ํฌ๋กค๋งํ•˜๋Š” ์‚ฌ๋žŒ๋“ค์ด ํ•ด๋‹น ํ‚ค๋ฅผ ๋ณด๊ณ  ์„œ์˜๋‹˜ ์„œ๋ฒ„๋‚˜ ํ‚ค์— ์ ‘๊ทผํ•ด์„œ ๋ฉ‹๋Œ€๋กœ ์‚ฌ์šฉํ• ์ˆ˜๋„ ์žˆ๋Š” ์œ„ํ—˜ํ•œ ์ƒํ™ฉ์ด ์žˆ์„์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
๊ฐœ์ธ์ •๋ณด ๋ณดํ˜ธ๋ฅผ ์œ„ํ•ด privacy๋ฅผ ์ƒํ™œํ™” ํ•ด๋ด์š”!!

(์–ด๋ ค์šด ๋‚ด์šฉ์€ ์•„๋‹ˆ๊ณ  privacy Info.plist , git ignore <- ์ด ํ‚ค์›Œ๋“œ๋กœ ๊ฒ€์ƒ‰ํ•˜์‹œ๋ฉด ์ดํ•ด๋˜์‹ค๊ฑฐ์—์š”)

Comment on lines +109 to +116
view.addSubview(titleLabel)
view.addSubview(idTextField)
view.addSubview(passwordTextField)
view.addSubview(loginButton)
view.addSubview(idFindButton)
view.addSubview(passwordFindButton)
view.addSubview(accountQuestionLabel)
view.addSubview(signUpButton)

Choose a reason for hiding this comment

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

์ž๋ฃŒ์‹ค์— ์žˆ๋Š” addSubviews ์ต์Šคํ…์…˜ ์จ๋ด๋„ ์ข‹์„๊ฒƒ ๊ฐ™์•„์š”!!

Comment on lines +220 to +225
if let image = UIImage(named: "x-circle") {
let imageSize = image.size
print("Image Size: \(imageSize)")
} else {
print("Image not found or couldn't be loaded.")
}

Choose a reason for hiding this comment

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

์˜ค์˜น ์ด๋ถ€๋ถ„์€ ์–ด๋–ค ์ด์œ ๋กœ ์“ฐ์‹œ๊ฒŒ ๋˜์…จ๋‚˜์š”~?

Copy link

@hooni0918 hooni0918 left a comment

Choose a reason for hiding this comment

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

์•„๋ฆ„๋‹ค์šด ์ฝ”๋“œ ์ž˜๋ณด๊ณ ๊ฐ‘๋‹ˆ๋‹ค. ์˜ค๋Š˜๋„ ํ–‰๋ณตํ•œ ํ•˜๋ฃจ ๋˜์„ธ์š” :)


extension UITextField {

/// ํ…์ŠคํŠธํ•„๋“œ์˜ ์™ผ์ชฝ๊ณผ ์˜ค๋ฅธ์ชฝ์— ํŒจ๋”ฉ์„ ์ถ”๊ฐ€ํ•˜๋Š” ํ•จ์ˆ˜

Choose a reason for hiding this comment

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

ํ•˜๋‚˜์”ฉ ์•Œ์•„๊ฐ€๋ ค๋Š” ๋ชจ์Šต ์ •๋ง ์ข‹์Šต๋‹ˆ๋‹ค!!!

var task: Task {
switch self {
case let .fetchBoxOfficeData(date):
return .requestParameters(parameters: ["key": "b4ddbf38f567f468512099872d9cc672", "targetDt": date], encoding: URLEncoding.queryString)

Choose a reason for hiding this comment

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

์ €๋„ ์ด๊ฒƒ๋–„๋ฌธ์— ๊ฟ€๋ฐคํ•œ๋ฒˆ ๋งž์•˜์Šต๋‹ˆ๋‹ค ์„ ์šฐ๊ฐ€ ๋งํ•œ๋Œ€๋กœ Config์—์„œ base url ์ˆจ๊ธด ๋ฐฉ๋ฒ•์ฒ˜๋Ÿผ Privacy๋กœ ๊ด€๋ฆฌํ•˜๋Š”๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค. ์•„๋‹ˆ ๊ทธ๋ ‡๊ฒŒ ํ•ด์•ผํ•ฉ๋‹ˆ๋‹ค. (ํŠนํžˆ๋‚˜ Git๋ ˆํฌ๊ฐ€ Public ์ƒํƒœ๋ผ๋ฉด.)
์™œ๋ƒํ•˜๋ฉด ์ด๋ ‡๊ฒŒ ์˜คํ”ˆ๋œ ๊นƒ ๋ ˆํฌ์— ๊ฐœ์ธ ํ‚ค๋‚˜ ์„œ๋ฒ„ url์ด ์˜คํ”ˆ๋˜์–ด์žˆ๋Š” ์ƒํƒœ๋ผ๋ฉด ์ด๋Ÿฐ๊ฒƒ๋งŒ ์ „๋ฌธ์ ์œผ๋กœ ํฌ๋กค๋งํ•˜๋Š” ์‚ฌ๋žŒ๋“ค์ด ํ•ด๋‹น ํ‚ค๋ฅผ ๋ณด๊ณ  ์„œ์˜๋‹˜ ์„œ๋ฒ„๋‚˜ ํ‚ค์— ์ ‘๊ทผํ•ด์„œ ๋ฉ‹๋Œ€๋กœ ์‚ฌ์šฉํ• ์ˆ˜๋„ ์žˆ๋Š” ์œ„ํ—˜ํ•œ ์ƒํ™ฉ์ด ์žˆ์„์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
๊ฐœ์ธ์ •๋ณด ๋ณดํ˜ธ๋ฅผ ์œ„ํ•ด privacy๋ฅผ ์ƒํ™œํ™” ํ•ด๋ด์š”!!

(์–ด๋ ค์šด ๋‚ด์šฉ์€ ์•„๋‹ˆ๊ณ  privacy Info.plist , git ignore <- ์ด ํ‚ค์›Œ๋“œ๋กœ ๊ฒ€์ƒ‰ํ•˜์‹œ๋ฉด ์ดํ•ด๋˜์‹ค๊ฑฐ์—์š”)

private func setStyle() {
self.navigationController?.navigationBar.isHidden = true

mainPoster.do {

Choose a reason for hiding this comment

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

์™€์šฐ .do ๋ฅผ ์‚ฌ์šฉํ•˜๋‹ˆ ํ›จ์”ฌ ๊ฐ€๋…์„ฑ์ด ์ข‹์•„์ก‹๋„ค์š”! do๋ฅผ ์ด๋ ‡๊ฒŒ ์ž˜ ์‚ฌ์šฉํ•˜์‹œ๋‹ค๋‹ˆ ์ •๋ง ๋ฉ‹์ ธ์š”!!

Comment on lines +162 to +193
// //ํ…Œ์ด๋ธ” ๋ทฐ์— ์…€ ๋“ฑ๋ก 1.์–ด๋–ค ์…€ ๋“ฑ๋กํ• ์ง€ 2.์‹๋ณ„์ž
// private func register() {
// contentTableView.register(
// ContentTableViewCell.self,
// forCellReuseIdentifier: ContentTableViewCell.identifier
// )
// }
// private func setDelegate() {
// contentTableView.delegate = self
// contentTableView.dataSource = self
// }

}

//extension MainViewController: UITableViewDelegate {
// func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
// return tableView.frame.width // ํ…Œ์ด๋ธ” ๋ทฐ์˜ ๋„ˆ๋น„๋ฅผ ์…€์˜ ๋†’์ด๋กœ ์‚ฌ์šฉํ•˜์—ฌ ๊ฐ€๋กœ ์Šคํฌ๋กค์„ ์œ„ํ•œ ๋†’์ด ์กฐ์ ˆ
// }
//}

//extension MainViewController: UITableViewDataSource {
// func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
// return 5
// }
//
// func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
// guard let cell = tableView.dequeueReusableCell(withIdentifier: ContentTableViewCell.identifier, for: indexPath) as? ContentTableViewCell else { return UITableViewCell() }
// cell.dataBind(contentList[indexPath.row])
// return cell
// }
//}

Choose a reason for hiding this comment

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

๋ถˆํ•„์š”ํ•œ ์ฝ”๋“œ๋Š” ์ง€์šฐ๊ธฐ!

Comment on lines +250 to +257
protocol LoginPresenterProtocol {
func didTapLoginButton(id: String?, password: String?)
func didChangeTextField(text: String?, for textField: UITextField)
}

// MARK: - LoginPresenter
class LoginPresenter: LoginPresenterProtocol {

Choose a reason for hiding this comment

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

์š”๋ถ€๋ถ„๋„ ์ƒˆ๋กญ๊ฒŒ ๋ถ„๋ฆฌํ•ด๋ณด๋Š”๊ฒƒ ์ถ”์ฒœ๋“œ๋ ค์š” ๊ฐ™์€ ํŒŒ์ผ๋‚ด๋ถ€๋ณด๋‹ค ์ด๋ถ€๋ถ„๋งŒ ๋„๋ ค๋‚ด์„œ ์ƒˆ๋กœ์šด .swiftํŒŒ์ผ๋กœ ๋งŒ๋“ค์–ด๋„ ์ข‹์„๊ฒƒ๊ฐ™์Šต๋‹ˆ๋‹ค :)

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.

[FEAT] ๋ฆฌํŽ™ํ† ๋ง
3 participants