Skip to content

Commit

Permalink
Merge pull request #121 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 7, 2021
2 parents df905b6 + 49d965c commit f8e8c4b
Show file tree
Hide file tree
Showing 23 changed files with 85 additions and 262 deletions.
4 changes: 0 additions & 4 deletions CA-PIN_IOS/CA-PIN_IOS.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
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 */; };
92EBE9A4275F1C3A0078AA8A /* WithDrawalPopUpViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92EBE9A3275F1C3A0078AA8A /* WithDrawalPopUpViewController.swift */; };
CC05D61026A210C10037C2C3 /* DetailEmptyTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = CC05D60F26A210C10037C2C3 /* DetailEmptyTableViewCell.swift */; };
CC05E029268B865400269427 /* UIFont+.swift in Sources */ = {isa = PBXBuildFile; fileRef = CC05E027268B865400269427 /* UIFont+.swift */; };
CC05E02A268B865400269427 /* UIButton+.swift in Sources */ = {isa = PBXBuildFile; fileRef = CC05E028268B865400269427 /* UIButton+.swift */; };
Expand Down Expand Up @@ -200,7 +199,6 @@
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>"; };
92EBE9A3275F1C3A0078AA8A /* WithDrawalPopUpViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WithDrawalPopUpViewController.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>"; };
CC05D60F26A210C10037C2C3 /* DetailEmptyTableViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DetailEmptyTableViewCell.swift; sourceTree = "<group>"; };
CC05E027268B865400269427 /* UIFont+.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "UIFont+.swift"; sourceTree = "<group>"; };
Expand Down Expand Up @@ -449,7 +447,6 @@
CCB6C664268F044300941E92 /* PinPopupViewController.swift */,
CCB6C66B268F41E800941E92 /* CreateCategoryViewController.swift */,
CC45A1792694280800E68817 /* TermsViewController.swift */,
92EBE9A3275F1C3A0078AA8A /* WithDrawalPopUpViewController.swift */,
);
path = ViewControllers;
sourceTree = "<group>";
Expand Down Expand Up @@ -1281,7 +1278,6 @@
CCF78446268B197A005FDF1D /* UITextField+.swift in Sources */,
92537087269C7FAD00E2E5EA /* EditCategoryViewController.swift in Sources */,
CC45A17A2694280800E68817 /* TermsViewController.swift in Sources */,
92EBE9A4275F1C3A0078AA8A /* WithDrawalPopUpViewController.swift in Sources */,
CC05E038268C595F00269427 /* CafeTIViewController.swift in Sources */,
CC7BB2FF269C5D820079FC4F /* CategoryService.swift in Sources */,
CCA85B602688F29700C9A32C /* UICollectionView+.swift in Sources */,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ class ReportReviewPopUpViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
layout()
// Do any additional setup after loading the view.
print("###\(reviewId)")
}
}

Expand Down Expand Up @@ -124,44 +122,14 @@ extension ReportReviewPopUpViewController {
}
}

// func deleteService(categoryId: String) {
// CategoryService.rx.request(.deleteCategory(categoryId: categoryId))
// .asObservable()
// .subscribe(onNext: { response in
// if response.statusCode == 200 { /// μ‚­μ œ 성곡
// do {
// let myPageVC = self.presentingViewController?.children[0] as? MypageViewController
// self.dismiss(animated: false) {
// myPageVC?.viewWillAppear(true)
// myPageVC?.showGreenToast(message: "μΉ΄ν…Œκ³ λ¦¬ μ‚­μ œκ°€ μ™„λ£Œλ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
// }
// }
// catch {
// print(error)
// }
// }
// else { /// μ‚­μ œ μ‹€νŒ¨
// do {
// self.showGrayToast(message: "μ‚­μ œμ— μ‹€νŒ¨ν–ˆμŠ΅λ‹ˆλ‹€")
// }
// catch {
// print(error)
// }
// }
// }, onError: { error in
// print(error)
// }, onCompleted: {
// }).disposed(by: disposeBag)
// }

func reportService(reviewId: String) {
/// TODO: - 리뷰 μ‹ κ³  μ„œλ²„ μ—°κ²°
reviewProvider.rx.request(.reportReivew(reviewId: reviewId))
.asObservable()
.subscribe(onNext: { response in
if response.statusCode == 200 { /// μ‹ κ³ 
do {
let cafeDetailVC = CafeDetailViewController()
let endIndex = self.presentingViewController?.children.endIndex ?? 0
let cafeDetailVC = self.presentingViewController?.children[endIndex-1] as? CafeDetailViewController ?? UIViewController()
self.dismiss(animated: false) {
cafeDetailVC.viewWillAppear(true)
cafeDetailVC.showGreenToast(message: "리뷰λ₯Ό μ‹ κ³ ν–ˆμŠ΅λ‹ˆλ‹€")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,9 +194,7 @@ extension CAFETIResultViewController {

if let resultdata = resultData?.introduction {
if resultdata == nil {
print("닐이야닐")
} else {
print(resultdata)
self.CAFETIintroLabel.setupLabel(text: resultdata, color: .subcolorBlue1, font: .notoSansKRRegularFont(fontSize: 14), align: .center)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,6 @@ extension LoginViewController {
KeychainWrapper.standard.set(data.loginData!.tokenRefresh, forKey: "tokenRefresh")

let cafeTI = KeychainWrapper.standard.string(forKey: "userCafeTI")
// let cafeTI = UserDefaults.standard.string(forKey: "userCafeTI")
if cafeTI != nil {
let mapVC = MapViewController()
self.emailTextField.text = ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -231,9 +231,10 @@ extension CreateCategoryViewController {
let decoder = JSONDecoder()
let data = try decoder.decode(ResponseType<ServerReview>.self,
from: response.data)
if let myPageVC = self.navigationController?.children[0] as? MypageViewController {
let endIndex = self.navigationController?.children.endIndex ?? 0
if let myPageVC = self.navigationController?.children[endIndex-2] as? MypageViewController {
self.navigationController?.popToViewController(myPageVC, animated: false)

myPageVC.viewWillAppear(true)
myPageVC.showGreenToast(message: "μΉ΄ν…Œκ³ λ¦¬κ°€ μΆ”κ°€λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
}
if let pinVC = self.navigationController?.children[0] as? PinPopupViewController {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -391,18 +391,18 @@ extension MapViewController {
}
@objc func clickedMenuButton() {
let NewSettingVC = NewSettingViewController()
self.navigationController?.pushViewController(NewSettingVC, animated: false)
self.navigationController?.pushViewController(NewSettingVC, animated: true)
}
@objc func clickedMypageButton() {
let MypageVC = MypageViewController()
self.navigationController?.pushViewController(MypageVC, animated: false)
self.navigationController?.pushViewController(MypageVC, animated: true)
}
@objc func clickedHashButton() {
let tagVC = TagViewController()
tagVC.selectedTag = self.tags
tagVC.capinOrMyMap = self.capinOrMyMap
tagVC.mapViewController = self
self.navigationController?.pushViewController(tagVC, animated: false)
self.navigationController?.pushViewController(tagVC, animated: true)
}
@objc func clickedAddCategoryButton() {
setupCategory()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,9 +188,8 @@ extension TermsViewController: UITableViewDataSource {
}
else {
// νšŒμ›νƒˆν‡΄
let withdrawlPopUPVC = WithDrawalPopUpViewController()
withdrawlPopUPVC.modalPresentationStyle = .overCurrentContext
self.present(withdrawlPopUPVC, animated: false, completion: nil)
let withdrawVC = WithdrawViewController()
self.navigationController?.pushViewController(withdrawVC, animated: true)
}
}
}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ extension EmptyCategoryTableViewCell {
self.contentView.add(self.explainLabel) {
$0.setupLabel(text: "이 μΉ΄ν…Œκ³ λ¦¬μ— ν•€ ν•΄λ‘” μΉ΄νŽ˜κ°€ μ—†μŠ΅λ‹ˆλ‹€.", color: .gray4, font: UIFont.notoSansKRMediumFont(fontSize: 16), align: .center)
$0.snp.makeConstraints {
// $0.width.equalTo(300)
// $0.height.equalTo(23)
$0.top.equalTo(self.emptyImageView.snp.bottom).offset(19)
$0.centerX.equalToSuperview()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,39 +112,6 @@ extension MyCategoryCollectionViewCell {
}
}

// MARK: - Server
// func getCategoryData() {
// UserProvider.rx.request(.categoryList)
// .asObservable()
// .subscribe(onNext: { response in
// if response.statusCode == 200 {
// do {
// let decoder = JSONDecoder()
// let data = try decoder.decode(CategoryResponseArrayType<MyCategoryList>.self,
// from: response.data)
// self.categoryArray = data.myCategoryList!
// print("mycategorytableview.reload")
// self.myCategoryTableView.reloadData()
// for i in 0...self.categoryArray.count-1 {
// self.categoryIdArray.append(self.categoryArray[i].id)
// }
// let mypageVC = self.rootViewController as? MypageViewController
// print("mypage.page.reload")
// mypageVC?.pageCollectionView.reloadData()
// } catch {
// print(error)
// }
// }
// else {
//
// }
// }, onError: { error in
// print(error)
// }, onCompleted: {
//
// }).disposed(by: disposeBag)
// }

func getCafeDataInCategory(index: Int) {
CategoryProvider.rx.request(.cafeListInCategory(categoryId: self.categoryIdArray[index]))
.asObservable()
Expand Down Expand Up @@ -193,7 +160,6 @@ extension MyCategoryCollectionViewCell {
}
extension MyCategoryCollectionViewCell: UITableViewDelegate {
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
// getCategoryData()
if categoryArray.count == 1 {
if indexPath.section == 0 {
return 53
Expand Down
Loading

0 comments on commit f8e8c4b

Please sign in to comment.