Skip to content

Commit

Permalink
feat : 불필요 파일 삭제
Browse files Browse the repository at this point in the history
  • Loading branch information
jinhoon227 committed Feb 9, 2024
2 parents ca68645 + d2accfb commit e381a8f
Show file tree
Hide file tree
Showing 146 changed files with 5,049 additions and 873 deletions.
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/issue-template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
name: Issue Template
about: issue template
title: ''
labels: ''
assignees: ''

---

## 📋 Description

1 change: 0 additions & 1 deletion .github/ISSUE_TEMPLATE/issue_template.md

This file was deleted.

9 changes: 7 additions & 2 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@

## ⭐️ Issue Number

#number
- #number

## 🚩 Summary


-

## 🛠️ Technical Concerns

Expand All @@ -17,6 +17,11 @@ Content

Content

## 🙂 To Reviwer

- Review Point
- Caution Point

## 📋 To Do

-
73 changes: 0 additions & 73 deletions .github/workflows/action-test.ci.yml

This file was deleted.

7 changes: 5 additions & 2 deletions KCS/.swiftlint.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
disabled_rules:
- trailing_whitespace

- file_length

opt_in_rules:
- empty_string

Expand All @@ -9,4 +10,6 @@ excluded:
- KCS/Application

line_length: 140
file_length: 600
cyclomatic_complexity: 20
identifier_name:
max_length: 50
30 changes: 30 additions & 0 deletions KCS/GoogleService-Info.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>API_KEY</key>
<string>AIzaSyAHg3iyzwXwUd3TpKqM7jpl-EZaXUmiqHw</string>
<key>GCM_SENDER_ID</key>
<string>127350323526</string>
<key>PLIST_VERSION</key>
<string>1</string>
<key>BUNDLE_ID</key>
<string>com.kcs.nainga</string>
<key>PROJECT_ID</key>
<string>korea-certified-stores</string>
<key>STORAGE_BUCKET</key>
<string>korea-certified-stores.appspot.com</string>
<key>IS_ADS_ENABLED</key>
<false></false>
<key>IS_ANALYTICS_ENABLED</key>
<false></false>
<key>IS_APPINVITE_ENABLED</key>
<true></true>
<key>IS_GCM_ENABLED</key>
<true></true>
<key>IS_SIGNIN_ENABLED</key>
<true></true>
<key>GOOGLE_APP_ID</key>
<string>1:127350323526:ios:15feb5ff2ff45f42448d47</string>
</dict>
</plist>
523 changes: 438 additions & 85 deletions KCS/KCS.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion KCS/KCS.xcodeproj/xcshareddata/xcschemes/KCS.xcscheme
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1510"
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
3 changes: 2 additions & 1 deletion KCS/KCS/Application/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,16 @@

import UIKit
import NMapsMap
import Firebase

@main
final class AppDelegate: UIResponder, UIApplicationDelegate {

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
if let id = Bundle.main.object(forInfoDictionaryKey: "NMAP_CLIENT_ID") as? String {
NMFAuthManager.shared().clientId = id
}
FirebaseApp.configure()

return true
}
Expand Down
60 changes: 55 additions & 5 deletions KCS/KCS/Application/SceneDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,12 @@
//

import UIKit
import RxRelay

class SceneDelegate: UIResponder, UIWindowSceneDelegate {

var window: UIWindow?

func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {

guard let windowScene = (scene as? UIWindowScene) else { return }
Expand All @@ -22,11 +23,60 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
dependency: HomeDependency(),
fetchRefreshStoresUseCase: FetchRefreshStoresUseCaseImpl(repository: repository),
fetchStoresUseCase: FetchStoresUseCaseImpl(repository: repository),
getStoreInformationUseCase: GetStoreInformationUseCaseImpl(repository: repository)
getStoreInformationUseCase: GetStoreInformationUseCaseImpl(repository: repository),
fetchSearchStoresUseCase: FetchSearchStoresUseCaseImpl(repository: repository)
)
let summaryViewHeightObserver = PublishRelay<SummaryViewHeightCase>()
let listCellSelectedObserver = PublishRelay<Int>()
let storeInformationViewController = StoreInformationViewController(
summaryViewHeightObserver: summaryViewHeightObserver,
viewModel: StoreInformationViewModelImpl(
getOpenClosedUseCase: GetOpenClosedUseCaseImpl(),
fetchImageUseCase: FetchImageUseCaseImpl(
repository: ImageRepositoryImpl(cache: ImageCache())
)
)
)
let searchObserver = PublishRelay<String>()
let homeViewController = HomeViewController(
viewModel: viewModel,
storeInformationViewController: storeInformationViewController,
storeListViewController: StoreListViewController(
viewModel: StoreListViewModelImpl(
fetchImageUseCase: FetchImageUseCaseImpl(
repository: ImageRepositoryImpl(cache: ImageCache())
)
),
listCellSelectedObserver: listCellSelectedObserver
),
summaryViewHeightObserver: summaryViewHeightObserver,
listCellSelectedObserver: listCellSelectedObserver,
searchViewController: SearchViewController(
viewModel: SearchViewModelImpl(),
searchObserver: searchObserver
),
searchObserver: searchObserver
)

var rootViewController: UIViewController

if Storage.isOnboarded() {
rootViewController = OnboardingViewController(homeViewController: homeViewController)
} else {
rootViewController = homeViewController
}

let splashViewController = SplashViewController(
viewModel: SplashViewModelImpl(
checkNetworkStatusUseCase: CheckNetworkStatusUseCaseImpl(
repository: NetworkRepositoryImpl()
)
), rootViewController: rootViewController
)
window?.rootViewController = HomeViewController(viewModel: viewModel)

window?.rootViewController = splashViewController
window?.makeKeyAndVisible()
}

}

16 changes: 16 additions & 0 deletions KCS/KCS/Data/Network/DTO/SearchDTO.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
//
// SearchDTO.swift
// KCS
//
// Created by 조성민 on 2/9/24.
//

import Foundation

struct SearchDTO: Encodable {

let currLong: Double
let currLat: Double
let searchKeyword: String

}
24 changes: 9 additions & 15 deletions KCS/KCS/Data/Network/DTO/StoreDTO.swift
Original file line number Diff line number Diff line change
Expand Up @@ -33,25 +33,19 @@ struct StoreDTO: Codable {

}

func toEntity() -> Store {
func toEntity() throws -> Store {
var certificationTypes: [CertificationType] = []
var openingHours: [RegularOpeningHours] = []

do {
for name in certificationName {
guard let type = CertificationType(rawValue: name) else {
throw JSONContentsError.wrongCertificationType
}
certificationTypes.append(type)
for name in certificationName {
guard let type = CertificationType(rawValue: name) else {
throw JSONContentsError.wrongCertificationType
}

for hour in regularOpeningHours {
openingHours.append(try hour.toEntity())
}
} catch let error as JSONContentsError {
print(error.errorDescription)
} catch let error {
print(error.localizedDescription)
certificationTypes.append(type)
}

for hour in regularOpeningHours {
openingHours.append(try hour.toEntity())
}

return Store(
Expand Down
3 changes: 3 additions & 0 deletions KCS/KCS/Data/Network/Error/NetworkError.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,14 @@ import Foundation
enum NetworkError: Error, LocalizedError {

case wrongURL
case wrongParameters

var errorDescription: String {
switch self {
case .wrongURL:
return "URL이 잘못되었습니다."
case .wrongParameters:
return "Parameters가 잘못되었습니다."
}
}

Expand Down
5 changes: 4 additions & 1 deletion KCS/KCS/Data/Network/Extension/Encodable+.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ extension Encodable {

func asDictionary() throws -> [String: Any] {
let data = try JSONEncoder().encode(self)
guard let dictionary = try JSONSerialization.jsonObject(with: data, options: .allowFragments) as? [String: Any] else {
guard let dictionary = try JSONSerialization.jsonObject(
with: data,
options: .allowFragments
) as? [String: Any] else {
throw JSONContentsError.dictionaryConvert
}
return dictionary
Expand Down
2 changes: 1 addition & 1 deletion KCS/KCS/Data/Network/Response/Protocol/APIResponse.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ protocol APIResponse: Codable {

var code: Int { get }
var message: String { get }
var data: [ResponseType] { get }
var data: ResponseType { get }

}
18 changes: 18 additions & 0 deletions KCS/KCS/Data/Network/Response/RefreshStoreResponse.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
//
// RefreshStoreResponse.swift
// KCS
//
// Created by 조성민 on 1/11/24.
//

import Foundation

struct RefreshStoreResponse: APIResponse {

typealias ResponseType = [[StoreDTO]]

let code: Int
let message: String
let data: ResponseType

}
18 changes: 18 additions & 0 deletions KCS/KCS/Data/Network/Response/SearchStoreResponse.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
//
// SearchStoreResponse.swift
// KCS
//
// Created by 조성민 on 2/9/24.
//

import Foundation

struct SearchStoreResponse: APIResponse {

typealias ResponseType = [StoreDTO]

let code: Int
let message: String
let data: ResponseType

}
Loading

0 comments on commit e381a8f

Please sign in to comment.