Skip to content

Commit

Permalink
Merge pull request #116 from teamCA-PIN/feature/#114
Browse files Browse the repository at this point in the history
Merge Feature/#114 into develop
  • Loading branch information
seohyun-106 authored Dec 4, 2021
2 parents 759f406 + 1bc485b commit 34ca924
Show file tree
Hide file tree
Showing 17 changed files with 790 additions and 332 deletions.
20 changes: 16 additions & 4 deletions CA-PIN_IOS/CA-PIN_IOS.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,13 @@
9253708F269D8F3800E2E5EA /* SignupModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9253708E269D8F3800E2E5EA /* SignupModel.swift */; };
92537091269D959F00E2E5EA /* UINavigationController+Root.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92537090269D959E00E2E5EA /* UINavigationController+Root.swift */; };
925F64FD2743A80F00206D2F /* EditProfileViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 925F64FC2743A80F00206D2F /* EditProfileViewController.swift */; };
9275AA4E275B9C590082BF0E /* LogoutPopUpViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9275AA4D275B9C580082BF0E /* LogoutPopUpViewController.swift */; };
9292FFC82696352600BCD791 /* CategoryCafeListTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9292FFC72696352600BCD791 /* CategoryCafeListTableViewCell.swift */; };
9292FFCA26964AFA00BCD791 /* MyTagCollectionViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9292FFC926964AFA00BCD791 /* MyTagCollectionViewCell.swift */; };
9292FFCA26964AFA00BCD791 /* MyReviewTagCollectionViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9292FFC926964AFA00BCD791 /* MyReviewTagCollectionViewCell.swift */; };
9292FFCD26964DF400BCD791 /* EmptyCategoryTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9292FFCC26964DF400BCD791 /* EmptyCategoryTableViewCell.swift */; };
929AD4DC268EEB150071C394 /* SignUpViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 929AD4DB268EEB150071C394 /* SignUpViewController.swift */; };
92AC0D36275B48ED00478555 /* MyCategoryTagCollectionViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92AC0D35275B48ED00478555 /* MyCategoryTagCollectionViewCell.swift */; };
92AC0D38275B4C7200478555 /* ReportReviewPopUpViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92AC0D37275B4C7100478555 /* ReportReviewPopUpViewController.swift */; };
92B20D70269E212E0013D429 /* CategoryListModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92B20D6F269E212E0013D429 /* CategoryListModel.swift */; };
92B20D72269E53B10013D429 /* CafeInCategoryModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92B20D71269E53B10013D429 /* CafeInCategoryModel.swift */; };
CC05D61026A210C10037C2C3 /* DetailEmptyTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = CC05D60F26A210C10037C2C3 /* DetailEmptyTableViewCell.swift */; };
Expand Down Expand Up @@ -185,10 +188,13 @@
9253708E269D8F3800E2E5EA /* SignupModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SignupModel.swift; sourceTree = "<group>"; };
92537090269D959E00E2E5EA /* UINavigationController+Root.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "UINavigationController+Root.swift"; sourceTree = "<group>"; };
925F64FC2743A80F00206D2F /* EditProfileViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EditProfileViewController.swift; sourceTree = "<group>"; };
9275AA4D275B9C580082BF0E /* LogoutPopUpViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LogoutPopUpViewController.swift; sourceTree = "<group>"; };
9292FFC72696352600BCD791 /* CategoryCafeListTableViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CategoryCafeListTableViewCell.swift; sourceTree = "<group>"; };
9292FFC926964AFA00BCD791 /* MyTagCollectionViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MyTagCollectionViewCell.swift; sourceTree = "<group>"; };
9292FFC926964AFA00BCD791 /* MyReviewTagCollectionViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MyReviewTagCollectionViewCell.swift; sourceTree = "<group>"; };
9292FFCC26964DF400BCD791 /* EmptyCategoryTableViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EmptyCategoryTableViewCell.swift; sourceTree = "<group>"; };
929AD4DB268EEB150071C394 /* SignUpViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SignUpViewController.swift; sourceTree = "<group>"; };
92AC0D35275B48ED00478555 /* MyCategoryTagCollectionViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MyCategoryTagCollectionViewCell.swift; sourceTree = "<group>"; };
92AC0D37275B4C7100478555 /* ReportReviewPopUpViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReportReviewPopUpViewController.swift; sourceTree = "<group>"; };
92B20D6F269E212E0013D429 /* CategoryListModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CategoryListModel.swift; sourceTree = "<group>"; };
92B20D71269E53B10013D429 /* CafeInCategoryModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CafeInCategoryModel.swift; sourceTree = "<group>"; };
B350E96FA945D43E4A64DD28 /* Pods-CA-PIN_IOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-CA-PIN_IOS.debug.xcconfig"; path = "Target Support Files/Pods-CA-PIN_IOS/Pods-CA-PIN_IOS.debug.xcconfig"; sourceTree = "<group>"; };
Expand Down Expand Up @@ -392,9 +398,10 @@
9292FFCF26983D9300BCD791 /* CategoryDetail */ = {
isa = PBXGroup;
children = (
9292FFC926964AFA00BCD791 /* MyTagCollectionViewCell.swift */,
9292FFC926964AFA00BCD791 /* MyReviewTagCollectionViewCell.swift */,
9292FFC72696352600BCD791 /* CategoryCafeListTableViewCell.swift */,
9292FFCC26964DF400BCD791 /* EmptyCategoryTableViewCell.swift */,
92AC0D35275B48ED00478555 /* MyCategoryTagCollectionViewCell.swift */,
);
path = CategoryDetail;
sourceTree = "<group>";
Expand Down Expand Up @@ -540,6 +547,7 @@
CC45A18B26955CDE00E68817 /* CafeDetailViewController.swift */,
CC481FFF2698A79100D7F280 /* PhotoPreviewViewController.swift */,
CC6468D52699E6F200CF848A /* EntireReviewViewController.swift */,
92AC0D37275B4C7100478555 /* ReportReviewPopUpViewController.swift */,
);
path = ViewControllers;
sourceTree = "<group>";
Expand Down Expand Up @@ -907,6 +915,7 @@
isa = PBXGroup;
children = (
E8611AF1274D05D6000B3721 /* NewSettingViewController.swift */,
9275AA4D275B9C580082BF0E /* LogoutPopUpViewController.swift */,
);
path = Terms;
sourceTree = "<group>";
Expand Down Expand Up @@ -1194,6 +1203,7 @@
CCA85B582688F29700C9A32C /* UITableViewCell+.swift in Sources */,
CC05E034268C4F9300269427 /* MypageViewController.swift in Sources */,
CC4D163126975B1C00F3F9B4 /* CAFETITest21ViewController.swift in Sources */,
92AC0D36275B48ED00478555 /* MyCategoryTagCollectionViewCell.swift in Sources */,
CC05E030268C4EBF00269427 /* TabbarViewController.swift in Sources */,
CC45A1872694EFFF00E68817 /* ExitViewController.swift in Sources */,
CCA85B5D2688F29700C9A32C /* UIImage+.swift in Sources */,
Expand Down Expand Up @@ -1225,6 +1235,7 @@
9241370F269457A80016D18F /* MyReviewTableViewCell.swift in Sources */,
E8611AF2274D05D6000B3721 /* NewSettingViewController.swift in Sources */,
CC841FD526A09C1A00F7CE93 /* MapCoordinates.swift in Sources */,
92AC0D38275B4C7200478555 /* ReportReviewPopUpViewController.swift in Sources */,
CC4D163426978C4800F3F9B4 /* RecommendTagCollectionViewCell.swift in Sources */,
9241370F269457A80016D18F /* MyReviewTableViewCell.swift in Sources */,
E82E5AA4269F32FE00DE5C23 /* CafeTIModel.swift in Sources */,
Expand All @@ -1236,6 +1247,7 @@
CCE7B03C26A8377600F6D9D6 /* MapResponse.swift in Sources */,
925370792698F4DD00E2E5EA /* MyEmptyCategoryTableViewCell.swift in Sources */,
9292FFC82696352600BCD791 /* CategoryCafeListTableViewCell.swift in Sources */,
9275AA4E275B9C590082BF0E /* LogoutPopUpViewController.swift in Sources */,
CC9C854D269EBFA1002A3321 /* MyInfoModel.swift in Sources */,
CCA85B592688F29700C9A32C /* UIView+.swift in Sources */,
CC45A1852694D14C00E68817 /* TagTableViewCell.swift in Sources */,
Expand Down Expand Up @@ -1266,7 +1278,7 @@
CCB6C663268DC88E00941E92 /* HamburgerViewController.swift in Sources */,
CC9C855326A051B4002A3321 /* MyMapListModel.swift in Sources */,
CCA85B2A2688F14600C9A32C /* KeyChainStorage.swift in Sources */,
9292FFCA26964AFA00BCD791 /* MyTagCollectionViewCell.swift in Sources */,
9292FFCA26964AFA00BCD791 /* MyReviewTagCollectionViewCell.swift in Sources */,
CCB6C66E268F498B00941E92 /* CategoryCollectionViewCell.swift in Sources */,
CC45A183269478DA00E68817 /* TagViewController.swift in Sources */,
CCA85B2C2688F15300C9A32C /* StoryboardStorage.swift in Sources */,
Expand Down
10 changes: 9 additions & 1 deletion CA-PIN_IOS/CA-PIN_IOS/Network/Services/ReviewService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ enum ReviewService {
case writeReview(cafeId: String, recommend: [Int]?, content: String, rating: Float, images: [UIImage]?)
case editReview(reviewId: String, recommend: [Int]?, content: String, rating: Float, isAllDeleted: Bool, images: [UIImage]?)
case deleteReview(reviewId: String)
case reportReivew(reviewId: String)
}

extension ReviewService: TargetType {
Expand Down Expand Up @@ -42,6 +43,8 @@ extension ReviewService: TargetType {
return "/reviews/\(reviewId)"
case .deleteReview(let reviewId):
return "/reviews/\(reviewId)"
case .reportReivew(reviewId: let reviewId):
return "/reviews/report/\(reviewId)"
}
}

Expand All @@ -55,6 +58,8 @@ extension ReviewService: TargetType {
return .put
case .deleteReview:
return .delete
case .reportReivew:
return .post
}
}

Expand Down Expand Up @@ -145,14 +150,17 @@ extension ReviewService: TargetType {
}
}
return .uploadMultipart(multiPartFormData)
case .reportReivew(reviewId: let reviewId):
return .requestPlain
}

}

var headers: [String : String]? {
switch self {
case .reviewList,
.deleteReview:
.deleteReview,
.reportReivew:
return ["Content-Type": "application/json",
"token": token]
case .writeReview,
Expand Down
Loading

0 comments on commit 34ca924

Please sign in to comment.