This app allows for a user to post and relate to other students within school by providing a social networking platform service for college students.
Required Must-have Stories
[X] User can login, register and sign out [X] User can add images to dorm room wall [X] User can view location functionalities(current location, other location displayed on wall) [X] User can track location in real time [X] User profiles [X] User can view and like walls [X] User can view walls in airplane mode, or without connection
Optional Nice-to-have Stories
Login Screen
Registration Screen
Home page
Profile page
My Wall page
Chat page
Update page
Settings page
Tab Navigation (Tab to Screen)
[X] Home Feed [X] My wall
Flow Navigation (Screen to Screen)
[X] Wall [X] User (from parse) [X] Expiring Wall
Parse Network Requests
Home feed Screen
My Wall Screen
Profile Screen
[Create basic snippets for each Parse network request]
Home feed Screen
(Read/GET)Query all walls that the user follows
PFQuery *query = [PFQuery queryWithClassName:@"Wall"];
[query includeKey:@"user"];
[query whereKey:@"school" equalTo:@"Stanford"];
[query orderByDescending:@"createdAt"];
[query findObjectsInBackgroundWithBlock:^(NSArray *walls, NSError *error) {
if (walls != nil) {
NSLog(@"Retrieved walls successfully!!");
} else {
NSLog(@"%@", error.localizedDescription);
}
}];
(Create/WALL) Create new like on wall
PFQuery *query = [PFQuery queryWithClassName:@"Wall"];
[query getObjectInBackgroundWithId:@"WALL_USER_ID" block:^(PFObject *wall, NSError *error) {
if (!error) {
// Success!
// update like count for that user
} else {
// Failure!
}
}];
(Create/WALL) Create new comment on wall
(Delete) Remove existing like or comment
My Wall Screen
(Create/WALL) Create new wall
PFObject *newWall = [PFObject objectWithClassName:@"Wall"];
newWall[@"text"] = self.messageField.text;
newWall[@"user"] = PFUser.currentUser;
[newWall saveInBackgroundWithBlock:^(BOOL succeeded, NSError * error) {
if (succeeded) {
NSLog(@"The wall was saved!");
} else {
NSLog(@"Problem saving wall: %@", error.localizedDescription);
}
}];
(Update/WALL) Edit wall
PFQuery *query = [PFQuery queryWithClassName:@"Wall"];
[query getObjectInBackgroundWithId:@"WALL_USER_ID"
block:^(PFObject *wall, NSError *error) {
// change wall details
[wall saveInBackground];
}];
(Delete/WALL) Remove existing wall
Profile Screen
PFUser *currentUser = [PFUser currentUser];
if (currentUser) {
// retrieve information
} else {
// do something else
}
PFUser *user = [PFUser currentUser];
user[@"profilePicture"] = [self getPFFileFromImage:self.profilePicture.image];
[user saveInBackgroundWithBlock:^(BOOL succeeded, NSError * _Nullable error) {
if (succeeded) {
NSLog(@"This worked!");
}
}];