Skip to content

Commit

Permalink
fixed merge
Browse files Browse the repository at this point in the history
  • Loading branch information
Eric Wang committed Nov 8, 2023
1 parent 98a0482 commit 5bdca02
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 7 deletions.
Binary file modified app/.DS_Store
Binary file not shown.
Binary file modified app/newHere1/.DS_Store
Binary file not shown.
22 changes: 20 additions & 2 deletions app/newHere1/newHere.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
objects = {

/* Begin PBXBuildFile section */
1506543B2AF8484A004C7909 /* api_call.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1506543A2AF84849004C7909 /* api_call.swift */; };
1531A8DE2AED95FD009F644E /* newHereApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1531A8DD2AED95FD009F644E /* newHereApp.swift */; };
1531A8E02AED95FD009F644E /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1531A8DF2AED95FD009F644E /* ContentView.swift */; };
1531A8E22AED95FF009F644E /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 1531A8E12AED95FF009F644E /* Assets.xcassets */; };
Expand All @@ -20,6 +21,9 @@
1531A90F2AED9917009F644E /* Post.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1531A90E2AED9917009F644E /* Post.swift */; };
1531A9132AEDAE2A009F644E /* LocationDataManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1531A9122AEDAE2A009F644E /* LocationDataManager.swift */; };
1531A9152AEDCADB009F644E /* Message.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1531A9142AEDCADB009F644E /* Message.swift */; };
15582E372AFB1544003910A2 /* Registration.swift in Sources */ = {isa = PBXBuildFile; fileRef = 15582E362AFB1544003910A2 /* Registration.swift */; };
1562EDE82AF6EA2B00A41779 /* CustomARView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1562EDE62AF6EA2B00A41779 /* CustomARView.swift */; };
1562EDE92AF6EA2B00A41779 /* CustomARViewRepresentable.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1562EDE72AF6EA2B00A41779 /* CustomARViewRepresentable.swift */; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
Expand All @@ -40,6 +44,7 @@
/* End PBXContainerItemProxy section */

/* Begin PBXFileReference section */
1506543A2AF84849004C7909 /* api_call.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = api_call.swift; sourceTree = "<group>"; };
1531A8DA2AED95FD009F644E /* newHere.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = newHere.app; sourceTree = BUILT_PRODUCTS_DIR; };
1531A8DD2AED95FD009F644E /* newHereApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = newHereApp.swift; sourceTree = "<group>"; };
1531A8DF2AED95FD009F644E /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = "<group>"; };
Expand All @@ -57,6 +62,9 @@
1531A90E2AED9917009F644E /* Post.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Post.swift; sourceTree = "<group>"; };
1531A9122AEDAE2A009F644E /* LocationDataManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationDataManager.swift; sourceTree = "<group>"; };
1531A9142AEDCADB009F644E /* Message.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Message.swift; sourceTree = "<group>"; };
15582E362AFB1544003910A2 /* Registration.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Registration.swift; sourceTree = "<group>"; };
1562EDE62AF6EA2B00A41779 /* CustomARView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = CustomARView.swift; sourceTree = "<group>"; };
1562EDE72AF6EA2B00A41779 /* CustomARViewRepresentable.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = CustomARViewRepresentable.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand Down Expand Up @@ -110,9 +118,13 @@
1531A8DD2AED95FD009F644E /* newHereApp.swift */,
1531A8DF2AED95FD009F644E /* ContentView.swift */,
1531A9082AED9618009F644E /* Home.swift */,
1562EDE62AF6EA2B00A41779 /* CustomARView.swift */,
1562EDE72AF6EA2B00A41779 /* CustomARViewRepresentable.swift */,
1531A90C2AED9663009F644E /* Messages.swift */,
1531A90A2AED964A009F644E /* Profile.swift */,
1531A90E2AED9917009F644E /* Post.swift */,
15582E362AFB1544003910A2 /* Registration.swift */,
1506543A2AF84849004C7909 /* api_call.swift */,
1531A9142AEDCADB009F644E /* Message.swift */,
1531A9122AEDAE2A009F644E /* LocationDataManager.swift */,
1531A8E12AED95FF009F644E /* Assets.xcassets */,
Expand Down Expand Up @@ -281,6 +293,10 @@
1531A8E02AED95FD009F644E /* ContentView.swift in Sources */,
1531A90B2AED964A009F644E /* Profile.swift in Sources */,
1531A90D2AED9663009F644E /* Messages.swift in Sources */,
15582E372AFB1544003910A2 /* Registration.swift in Sources */,
1562EDE82AF6EA2B00A41779 /* CustomARView.swift in Sources */,
1506543B2AF8484A004C7909 /* api_call.swift in Sources */,
1562EDE92AF6EA2B00A41779 /* CustomARViewRepresentable.swift in Sources */,
1531A90F2AED9917009F644E /* Post.swift in Sources */,
1531A9152AEDCADB009F644E /* Message.swift in Sources */,
1531A9092AED9618009F644E /* Home.swift in Sources */,
Expand Down Expand Up @@ -449,6 +465,7 @@
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_LSApplicationCategoryType = "";
INFOPLIST_KEY_NSCameraUsageDescription = "Here needs access to your camera.";
INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "Here needs to access your location data to tell you your location";
"INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES;
"INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES;
Expand All @@ -460,7 +477,7 @@
"INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
IPHONEOS_DEPLOYMENT_TARGET = 17.0;
IPHONEOS_DEPLOYMENT_TARGET = 16.6;
LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks";
"LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks";
MACOSX_DEPLOYMENT_TARGET = 14.0;
Expand Down Expand Up @@ -489,6 +506,7 @@
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_LSApplicationCategoryType = "";
INFOPLIST_KEY_NSCameraUsageDescription = "Here needs access to your camera.";
INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "Here needs to access your location data to tell you your location";
"INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES;
"INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES;
Expand All @@ -500,7 +518,7 @@
"INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
IPHONEOS_DEPLOYMENT_TARGET = 17.0;
IPHONEOS_DEPLOYMENT_TARGET = 16.6;
LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks";
"LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks";
MACOSX_DEPLOYMENT_TARGET = 14.0;
Expand Down
4 changes: 2 additions & 2 deletions app/newHere1/newHere/ContentView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ struct ContentView: View {
} else {
RegistrationView(isRegistered: $isRegistered)
}
HomePageView()
.environmentObject(locationDataManager)
// HomePageView()
// .environmentObject(locationDataManager)
// if isRegistered {
// HomePageView()
// } else {
Expand Down
2 changes: 1 addition & 1 deletion app/newHere1/newHere/CustomARViewRepresentable.swift
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ struct CustomARViewRepresentable: UIViewRepresentable {

// Define the range of random positions for x, y, and z coordinates
let xRange: ClosedRange<Float> = -3.0...3.0 // Represents a 10-meter width (-5m to +5m)
let yRange: ClosedRange<Float> = 0.0...3.0 // Represents a height range above the ground (0m to +2m)
let yRange: ClosedRange<Float> = -1.5...2.0 // Represents a height range above the ground (0m to +2m)
let zRange: ClosedRange<Float> = -3.0...3.0 // Represents a 10-meter depth (-5m to +5m)

for message in messages {
Expand Down
4 changes: 2 additions & 2 deletions app/newHere1/newHere/Registration.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import SwiftUI

let registerUrlString = "https://here-swe.vercel.app/auth/register"
let apiKey = "qe5YT6jOgiA422_UcdbmVxxG1Z6G48aHV7fSV4TbAPs"
let regApiKey = "qe5YT6jOgiA422_UcdbmVxxG1Z6G48aHV7fSV4TbAPs"

struct RegistrationView: View {
@State private var firstName: String = ""
Expand Down Expand Up @@ -70,7 +70,7 @@ struct RegistrationView: View {
request.httpMethod = "POST"
request.httpBody = jsonData
request.setValue("application/json", forHTTPHeaderField: "Content-Type")
request.setValue(apiKey, forHTTPHeaderField: "x-api-key")
request.setValue(regApiKey, forHTTPHeaderField: "x-api-key")


URLSession.shared.dataTask(with: request) { data, response, error in
Expand Down

0 comments on commit 5bdca02

Please sign in to comment.