-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'development' into webscraper-woolworths
- Loading branch information
Showing
87 changed files
with
3,795 additions
and
1,678 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ $RECYCLE.BIN/ | |
*.log | ||
log.txt | ||
mealmaestro-logs.txt | ||
logs/ | ||
|
||
|
||
# ios | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
backend/src/main/java/fellowship/mealmaestro/config/exceptions/UserNotFoundException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package fellowship.mealmaestro.config.exceptions; | ||
|
||
public class UserNotFoundException extends RuntimeException { | ||
public UserNotFoundException(String message) { | ||
super(message); | ||
} | ||
} |
42 changes: 42 additions & 0 deletions
42
backend/src/main/java/fellowship/mealmaestro/controllers/LikeDislikeController.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
package fellowship.mealmaestro.controllers; | ||
|
||
import org.springframework.http.ResponseEntity; | ||
import org.springframework.web.bind.annotation.PostMapping; | ||
import org.springframework.web.bind.annotation.RequestBody; | ||
import org.springframework.web.bind.annotation.RequestHeader; | ||
import org.springframework.web.bind.annotation.RestController; | ||
|
||
import fellowship.mealmaestro.models.neo4j.MealModel; | ||
import jakarta.validation.Valid; | ||
|
||
@RestController | ||
public class LikeDislikeController { | ||
|
||
public LikeDislikeController() { | ||
|
||
} | ||
|
||
@PostMapping("/liked") | ||
public ResponseEntity<Void> liked(@Valid @RequestBody MealModel request, @RequestHeader("Authorization") String token) { | ||
if (token == null || token.isEmpty()) { | ||
return ResponseEntity.badRequest().build(); | ||
} | ||
|
||
String authToken = token.substring(7); | ||
//service here | ||
|
||
return ResponseEntity.ok().build(); | ||
} | ||
|
||
@PostMapping("/disliked") | ||
public ResponseEntity<Void> disliked(@Valid @RequestBody MealModel request, @RequestHeader("Authorization") String token) { | ||
if (token == null || token.isEmpty()) { | ||
return ResponseEntity.badRequest().build(); | ||
} | ||
|
||
String authToken = token.substring(7); | ||
//service here | ||
|
||
return ResponseEntity.ok().build(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.