Xcuello 5 年 前
コミット
1460b7537e
共有2 個のファイルを変更した10 個の追加0 個の削除を含む
  1. 5
    0
      src/main/java/com/zipcodewilmington/bakery/Models/Baker.java
  2. 5
    0
      src/main/java/com/zipcodewilmington/bakery/Models/Muffin.java

+ 5
- 0
src/main/java/com/zipcodewilmington/bakery/Models/Baker.java ファイルの表示

@@ -1,5 +1,7 @@
1 1
 package com.zipcodewilmington.bakery.Models;
2 2
 
3
+import com.zipcodewilmington.bakery.Repositories.BakerRepository;
4
+import org.springframework.beans.factory.annotation.Autowired;
3 5
 import org.springframework.data.annotation.Id;
4 6
 import javax.persistence.Entity;
5 7
 import javax.persistence.GeneratedValue;
@@ -8,6 +10,9 @@ import javax.persistence.GenerationType;
8 10
 @Entity
9 11
 public class Baker {
10 12
 
13
+    @Autowired
14
+    BakerRepository bakerRepository;
15
+
11 16
     @Id
12 17
     @GeneratedValue(strategy = GenerationType.AUTO)
13 18
     private Long id;

+ 5
- 0
src/main/java/com/zipcodewilmington/bakery/Models/Muffin.java ファイルの表示

@@ -1,5 +1,7 @@
1 1
 package com.zipcodewilmington.bakery.Models;
2 2
 
3
+import com.zipcodewilmington.bakery.Repositories.MuffinRepository;
4
+import org.springframework.beans.factory.annotation.Autowired;
3 5
 import org.springframework.data.annotation.Id;
4 6
 import javax.persistence.Entity;
5 7
 import javax.persistence.GeneratedValue;
@@ -8,6 +10,9 @@ import javax.persistence.GenerationType;
8 10
 @Entity
9 11
 public class Muffin {
10 12
 
13
+    @Autowired
14
+    MuffinRepository muffinRepository;
15
+
11 16
     @Id
12 17
     @GeneratedValue(strategy = GenerationType.AUTO)
13 18
     private Long id;