From 4cfacd63b1552bf6ea33e28f3f66e11b75e5756a Mon Sep 17 00:00:00 2001 From: Gunther6070 Date: Thu, 6 Mar 2025 12:45:35 -0500 Subject: Created Cupboard Service and refactored the controller and DAO to add the service as an inbetween with logic --- .../src/main/java/com/ufund/api/ufundapi/model/Need.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'ufund-api/src/main/java/com/ufund/api/ufundapi/model/Need.java') diff --git a/ufund-api/src/main/java/com/ufund/api/ufundapi/model/Need.java b/ufund-api/src/main/java/com/ufund/api/ufundapi/model/Need.java index 2611357..9ca097a 100644 --- a/ufund-api/src/main/java/com/ufund/api/ufundapi/model/Need.java +++ b/ufund-api/src/main/java/com/ufund/api/ufundapi/model/Need.java @@ -31,6 +31,19 @@ public class Need { this.type = type; } + /** + * Create a new need + * + * @param name The name of the need + * @param maxGoal The maximum goal for this need + * @param type The type of need (monetary, physical) + */ + public Need(String name, GoalType type, double maxGoal) { + this.name = name; + this.type = type; + this.maxGoal = maxGoal; + } + /** * Create a deep copy of another need * -- cgit v1.2.3