Skip to content

Commit

Permalink
feat: network(#47)
Browse files Browse the repository at this point in the history
  • Loading branch information
Zoe0929 committed Jun 4, 2024
1 parent d273600 commit 910eb6c
Show file tree
Hide file tree
Showing 8 changed files with 82 additions and 5 deletions.
42 changes: 37 additions & 5 deletions SOPKATHON-iOS-TEAM2/SOPKATHON-iOS-TEAM2.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@
3663C2AF2BF950AC004C07AC /* SharedInstaView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3663C2AE2BF950AC004C07AC /* SharedInstaView.swift */; };
367B146B2BF8EDEA000DBA22 /* Adjust.swift in Sources */ = {isa = PBXBuildFile; fileRef = 367B146A2BF8EDEA000DBA22 /* Adjust.swift */; };
3689D5E62C0E3C260060B674 /* HomeViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3689D5E52C0E3C260060B674 /* HomeViewModel.swift */; };
3689D5E82C0F74540060B674 /* BaseNetwork.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3689D5E72C0F74540060B674 /* BaseNetwork.swift */; };
3689D5EA2C0F74BC0060B674 /* QuestionViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3689D5E92C0F74BC0060B674 /* QuestionViewModel.swift */; };
3689D5ED2C0F77A60060B674 /* QuestionService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3689D5EC2C0F77A60060B674 /* QuestionService.swift */; };
3689D5F02C0F7F5D0060B674 /* AttemptService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3689D5EF2C0F7F5D0060B674 /* AttemptService.swift */; };
3689D5F22C0F84FD0060B674 /* SharedInstaView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3689D5F12C0F84FD0060B674 /* SharedInstaView.swift */; };
AF2B55F42BF939B700F382A0 /* APITarget+Members.swift in Sources */ = {isa = PBXBuildFile; fileRef = AF2B55F32BF939B700F382A0 /* APITarget+Members.swift */; };
AF2B55FE2BF93B7800F382A0 /* APITarget+Questions.swift in Sources */ = {isa = PBXBuildFile; fileRef = AF2B55FD2BF93B7800F382A0 /* APITarget+Questions.swift */; };
AF2B56002BF93F9E00F382A0 /* APITarget+Attempts.swift in Sources */ = {isa = PBXBuildFile; fileRef = AF2B55FF2BF93F9E00F382A0 /* APITarget+Attempts.swift */; };
Expand Down Expand Up @@ -118,6 +123,11 @@
3663C2AE2BF950AC004C07AC /* SharedInstaView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SharedInstaView.swift; sourceTree = "<group>"; };
367B146A2BF8EDEA000DBA22 /* Adjust.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Adjust.swift; sourceTree = "<group>"; };
3689D5E52C0E3C260060B674 /* HomeViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HomeViewModel.swift; sourceTree = "<group>"; };
3689D5E72C0F74540060B674 /* BaseNetwork.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseNetwork.swift; sourceTree = "<group>"; };
3689D5E92C0F74BC0060B674 /* QuestionViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = QuestionViewModel.swift; sourceTree = "<group>"; };
3689D5EC2C0F77A60060B674 /* QuestionService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = QuestionService.swift; sourceTree = "<group>"; };
3689D5EF2C0F7F5D0060B674 /* AttemptService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AttemptService.swift; sourceTree = "<group>"; };
3689D5F12C0F84FD0060B674 /* SharedInstaView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SharedInstaView.swift; sourceTree = "<group>"; };
AF2B55F32BF939B700F382A0 /* APITarget+Members.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "APITarget+Members.swift"; sourceTree = "<group>"; };
AF2B55FD2BF93B7800F382A0 /* APITarget+Questions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "APITarget+Questions.swift"; sourceTree = "<group>"; };
AF2B55FF2BF93F9E00F382A0 /* APITarget+Attempts.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "APITarget+Attempts.swift"; sourceTree = "<group>"; };
Expand Down Expand Up @@ -191,6 +201,26 @@
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
3689D5EB2C0F77980060B674 /* Service */ = {
isa = PBXGroup;
children = (
3689D5EC2C0F77A60060B674 /* QuestionService.swift */,
3689D5EF2C0F7F5D0060B674 /* AttemptService.swift */,
);
path = Service;
sourceTree = "<group>";
};
3689D5EE2C0F77FE0060B674 /* Base */ = {
isa = PBXGroup;
children = (
AFD35AAB2BF526D700354EE5 /* Config.swift */,
AFD35AAF2BF5270200354EE5 /* MoyaLogginPlugin.swift */,
AFD35AB12BF5270700354EE5 /* NetworkResult.swift */,
3689D5E72C0F74540060B674 /* BaseNetwork.swift */,
);
path = Base;
sourceTree = "<group>";
};
AF42C37B2BF941D2009A250D /* Recovered References */ = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -279,6 +309,7 @@
isa = PBXGroup;
children = (
3689D5E52C0E3C260060B674 /* HomeViewModel.swift */,
3689D5E92C0F74BC0060B674 /* QuestionViewModel.swift */,
AFD35A872BF51F7900354EE5 /* MockModel.swift */,
AFB3AB1E2BF9512900D76C23 /* TodayQuiz.swift */,
);
Expand All @@ -295,7 +326,7 @@
2E559B192BF911C5000FBE89 /* QuestionViewController.swift */,
2E559B1B2BF9166E000FBE89 /* CustomButton.swift */,
3663C2802BF915C3004C07AC /* SolvedViewController.swift */,
3663C2AE2BF950AC004C07AC /* SharedInstaView.swift */,
3689D5F12C0F84FD0060B674 /* SharedInstaView.swift */,
);
path = ViewController;
sourceTree = "<group>";
Expand Down Expand Up @@ -363,11 +394,10 @@
AFD35A7C2BF51E8C00354EE5 /* Network */ = {
isa = PBXGroup;
children = (
3689D5EE2C0F77FE0060B674 /* Base */,
3689D5EB2C0F77980060B674 /* Service */,
AFD35A8A2BF5200300354EE5 /* DTO */,
AFD35A892BF5200000354EE5 /* API */,
AFD35AAB2BF526D700354EE5 /* Config.swift */,
AFD35AAF2BF5270200354EE5 /* MoyaLogginPlugin.swift */,
AFD35AB12BF5270700354EE5 /* NetworkResult.swift */,
);
path = Network;
sourceTree = "<group>";
Expand Down Expand Up @@ -534,21 +564,23 @@
AFD35A882BF51F7900354EE5 /* MockModel.swift in Sources */,
DD834FBE2BF8E5CC0014D066 /* UIImage+.swift in Sources */,
AFD695712BF92F7600FADE46 /* DTO+GetQuestionsResponse.swift in Sources */,
3663C2AF2BF950AC004C07AC /* SharedInstaView.swift in Sources */,
AFD35A5F2BF51DB700354EE5 /* AppDelegate.swift in Sources */,
AF2B56002BF93F9E00F382A0 /* APITarget+Attempts.swift in Sources */,
AF2B55FE2BF93B7800F382A0 /* APITarget+Questions.swift in Sources */,
2E559B1A2BF911C5000FBE89 /* QuestionViewController.swift in Sources */,
AFD695852BF9342300FADE46 /* DTO+GetRecordListResponse.swift in Sources */,
3689D5E82C0F74540060B674 /* BaseNetwork.swift in Sources */,
AFD695792BF931DB00FADE46 /* DTO+PostCorrectInfoResponse.swift in Sources */,
DD834FC22BF8EAAA0014D066 /* UILabel+.swift in Sources */,
AFD35AAC2BF526D700354EE5 /* Config.swift in Sources */,
DD834FC02BF8E5F00014D066 /* UIView+.swift in Sources */,
AFD695832BF933D100FADE46 /* DTO+GetQuestionDescriptionRequest.swift in Sources */,
AFD695892BF9349900FADE46 /* DTO+CreateMemberResponse.swift in Sources */,
3689D5F22C0F84FD0060B674 /* SharedInstaView.swift in Sources */,
AFB3AB1F2BF9512900D76C23 /* TodayQuiz.swift in Sources */,
AFD35A8E2BF5202200354EE5 /* APITarget+Namespace.swift in Sources */,
AFD35A902BF5204E00354EE5 /* UIColor+.swift in Sources */,
3689D5EA2C0F74BC0060B674 /* QuestionViewModel.swift in Sources */,
AFD695732BF92F8000FADE46 /* DTO+GetQuestionsRequest.swift in Sources */,
AFD35AB22BF5270700354EE5 /* NetworkResult.swift in Sources */,
AFD35A7E2BF51F5F00354EE5 /* MockFonts.swift in Sources */,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
//
// SolvedViewModel.swift
// SOPKATHON-iOS-TEAM2
//
// Created by 이지희 on 6/5/24.
//

import Foundation

import RxSwift

class SolvedViewModel: ObservableObject {

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
//
// BaseNetwork.swift
// SOPKATHON-iOS-TEAM2
//
// Created by 이지희 on 6/5/24.
//

import Foundation

import Moya

protocol Networkable {
var provider: MoyaProvider<MultiTarget> { get }
func request<T: Decodable>(_ target: TargetType, completion: @escaping (Result<T, Error>) -> Void)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
//
// AttemptService.swift
// SOPKATHON-iOS-TEAM2
//
// Created by 이지희 on 6/5/24.
//

import Foundation
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
//
// QuestionService.swift
// SOPKATHON-iOS-TEAM2
//
// Created by 이지희 on 6/5/24.
//

import Foundation

0 comments on commit 910eb6c

Please sign in to comment.