Parcourir la source

refactored apis and controllers, still working on getting profile/login tied to user

Eric Foster il y a 6 ans
Parent
révision
ceca592e11

+ 181
- 165
.idea/workspace.xml Voir le fichier

@@ -2,20 +2,23 @@
2 2
 <project version="4">
3 3
   <component name="ChangeListManager">
4 4
     <list default="true" id="ad381d05-32c5-4ad5-8041-a0cb51a71fd9" name="Default" comment="">
5
-      <change afterPath="$PROJECT_DIR$/src/main/java/com/alidade/config/DestinationApis.java" afterDir="false" />
6
-      <change afterPath="$PROJECT_DIR$/src/main/java/com/alidade/config/LoginApis.java" afterDir="false" />
7
-      <change afterPath="$PROJECT_DIR$/src/main/java/com/alidade/config/ProfileApis.java" afterDir="false" />
8
-      <change afterPath="$PROJECT_DIR$/src/main/java/com/alidade/config/UserApis.java" afterDir="false" />
9 5
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
10
-      <change beforePath="$PROJECT_DIR$/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/pom.xml" afterDir="false" />
11 6
       <change beforePath="$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java" afterDir="false" />
12
-      <change beforePath="$PROJECT_DIR$/src/main/java/com/alidade/controller/LoginController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/alidade/controller/LoginController.java" afterDir="false" />
13 7
       <change beforePath="$PROJECT_DIR$/src/main/java/com/alidade/controller/ProfileController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/alidade/controller/ProfileController.java" afterDir="false" />
14 8
       <change beforePath="$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java" afterDir="false" />
15
-      <change beforePath="$PROJECT_DIR$/src/test/java/DestinationControllerTest.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/test/java/DestinationControllerTest.java" afterDir="false" />
16
-      <change beforePath="$PROJECT_DIR$/src/test/java/LoginControllerTest.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/test/java/LoginControllerTest.java" afterDir="false" />
17
-      <change beforePath="$PROJECT_DIR$/src/test/java/ProfileControllerTest.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/test/java/ProfileControllerTest.java" afterDir="false" />
18
-      <change beforePath="$PROJECT_DIR$/src/test/java/UserControllerTest.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/test/java/UserControllerTest.java" afterDir="false" />
9
+      <change beforePath="$PROJECT_DIR$/src/main/java/com/alidade/model/Destination.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/alidade/model/Destination.java" afterDir="false" />
10
+      <change beforePath="$PROJECT_DIR$/src/main/java/com/alidade/model/Profile.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/alidade/model/Profile.java" afterDir="false" />
11
+      <change beforePath="$PROJECT_DIR$/src/main/java/com/alidade/model/User.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/alidade/model/User.java" afterDir="false" />
12
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/config/LoginApis.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/config/LoginApis.class" afterDir="false" />
13
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/config/ProfileApis.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/config/ProfileApis.class" afterDir="false" />
14
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/config/UserApis.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/config/UserApis.class" afterDir="false" />
15
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/controller/DestinationController.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/controller/DestinationController.class" afterDir="false" />
16
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/controller/LoginController.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/controller/LoginController.class" afterDir="false" />
17
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/controller/ProfileController.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/controller/ProfileController.class" afterDir="false" />
18
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/controller/UserController.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/controller/UserController.class" afterDir="false" />
19
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/model/Destination.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/model/Destination.class" afterDir="false" />
20
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/model/Profile.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/model/Profile.class" afterDir="false" />
21
+      <change beforePath="$PROJECT_DIR$/target/classes/com/alidade/model/User.class" beforeDir="false" afterPath="$PROJECT_DIR$/target/classes/com/alidade/model/User.class" afterDir="false" />
19 22
     </list>
20 23
     <ignored path="$PROJECT_DIR$/out/" />
21 24
     <ignored path="$PROJECT_DIR$/target/" />
@@ -28,11 +31,11 @@
28 31
   </component>
29 32
   <component name="FileEditorManager">
30 33
     <leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
31
-      <file leaf-file-name="DestinationController.java" pinned="false" current-in-tab="false">
32
-        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java">
34
+      <file leaf-file-name="Destination.java" pinned="false" current-in-tab="false">
35
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Destination.java">
33 36
           <provider selected="true" editor-type-id="text-editor">
34
-            <state relative-caret-position="690">
35
-              <caret line="46" lean-forward="true" selection-start-line="46" selection-end-line="46" />
37
+            <state relative-caret-position="372">
38
+              <caret line="43" column="25" selection-start-line="43" selection-start-column="25" selection-end-line="43" selection-end-column="25" />
36 39
               <folding>
37 40
                 <element signature="imports" expanded="true" />
38 41
               </folding>
@@ -40,86 +43,92 @@
40 43
           </provider>
41 44
         </entry>
42 45
       </file>
43
-      <file leaf-file-name="pom.xml" pinned="false" current-in-tab="false">
44
-        <entry file="file://$PROJECT_DIR$/pom.xml">
46
+      <file leaf-file-name="DestinationApis.java" pinned="false" current-in-tab="false">
47
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/DestinationApis.java">
45 48
           <provider selected="true" editor-type-id="text-editor">
46
-            <state relative-caret-position="159">
47
-              <caret line="13" column="30" selection-start-line="13" selection-start-column="30" selection-end-line="13" selection-end-column="30" />
49
+            <state relative-caret-position="30">
50
+              <caret line="2" column="30" selection-start-line="2" selection-start-column="30" selection-end-line="2" selection-end-column="30" />
48 51
             </state>
49 52
           </provider>
50 53
         </entry>
51 54
       </file>
52
-      <file leaf-file-name="DestinationApis.java" pinned="false" current-in-tab="false">
53
-        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/DestinationApis.java">
55
+      <file leaf-file-name="Profile.java" pinned="false" current-in-tab="false">
56
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Profile.java">
54 57
           <provider selected="true" editor-type-id="text-editor">
55
-            <state relative-caret-position="60">
56
-              <caret line="4" column="45" selection-start-line="4" selection-start-column="45" selection-end-line="4" selection-end-column="45" />
58
+            <state relative-caret-position="91">
59
+              <caret line="14" column="50" selection-start-line="14" selection-start-column="50" selection-end-line="14" selection-end-column="50" />
60
+              <folding>
61
+                <element signature="imports" expanded="true" />
62
+              </folding>
57 63
             </state>
58 64
           </provider>
59 65
         </entry>
60 66
       </file>
61
-      <file leaf-file-name="LoginController.java" pinned="false" current-in-tab="false">
62
-        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/LoginController.java">
67
+      <file leaf-file-name="Login.java" pinned="false" current-in-tab="false">
68
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Login.java">
63 69
           <provider selected="true" editor-type-id="text-editor">
64
-            <state relative-caret-position="210">
65
-              <caret line="19" column="44" lean-forward="true" selection-start-line="19" selection-start-column="44" selection-end-line="19" selection-end-column="44" />
70
+            <state relative-caret-position="195">
71
+              <caret line="13" column="50" selection-start-line="13" selection-start-column="50" selection-end-line="13" selection-end-column="50" />
72
+              <folding>
73
+                <element signature="imports" expanded="true" />
74
+              </folding>
66 75
             </state>
67 76
           </provider>
68 77
         </entry>
69 78
       </file>
70
-      <file leaf-file-name="ProfileController.java" pinned="false" current-in-tab="false">
71
-        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/ProfileController.java">
79
+      <file leaf-file-name="User.java" pinned="false" current-in-tab="true">
80
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/User.java">
72 81
           <provider selected="true" editor-type-id="text-editor">
73
-            <state relative-caret-position="130">
74
-              <caret line="32" selection-start-line="32" selection-start-column="2" selection-end-line="38" selection-end-column="7" />
82
+            <state relative-caret-position="195">
83
+              <caret line="13" column="50" selection-start-line="13" selection-start-column="50" selection-end-line="13" selection-end-column="50" />
84
+              <folding>
85
+                <element signature="imports" expanded="true" />
86
+              </folding>
75 87
             </state>
76 88
           </provider>
77 89
         </entry>
78 90
       </file>
79
-      <file leaf-file-name="UserController.java" pinned="false" current-in-tab="false">
80
-        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java">
91
+      <file leaf-file-name="SharedTravelApp.java" pinned="false" current-in-tab="false">
92
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/SharedTravelApp.java">
81 93
           <provider selected="true" editor-type-id="text-editor">
82
-            <state relative-caret-position="315">
83
-              <caret line="28" column="43" lean-forward="true" selection-start-line="28" selection-start-column="43" selection-end-line="28" selection-end-column="43" />
94
+            <state relative-caret-position="75">
95
+              <caret line="6" column="13" selection-start-line="6" selection-start-column="13" selection-end-line="6" selection-end-column="13" />
84 96
             </state>
85 97
           </provider>
86 98
         </entry>
87 99
       </file>
88
-      <file leaf-file-name="DestinationControllerTest.java" pinned="false" current-in-tab="false">
89
-        <entry file="file://$PROJECT_DIR$/src/test/java/DestinationControllerTest.java">
100
+      <file leaf-file-name="UserController.java" pinned="false" current-in-tab="false">
101
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java">
90 102
           <provider selected="true" editor-type-id="text-editor">
91
-            <state relative-caret-position="215">
92
-              <caret line="33" selection-start-line="33" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
103
+            <state relative-caret-position="165">
104
+              <caret line="19" column="4" selection-start-line="19" selection-start-column="4" selection-end-line="19" selection-end-column="4" />
93 105
             </state>
94 106
           </provider>
95 107
         </entry>
96 108
       </file>
97
-      <file leaf-file-name="LoginControllerTest.java" pinned="false" current-in-tab="false">
98
-        <entry file="file://$PROJECT_DIR$/src/test/java/LoginControllerTest.java">
109
+      <file leaf-file-name="HomeController.java" pinned="false" current-in-tab="false">
110
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/HomeController.java">
99 111
           <provider selected="true" editor-type-id="text-editor">
100
-            <state relative-caret-position="185">
101
-              <caret line="33" selection-start-line="33" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
112
+            <state relative-caret-position="135">
113
+              <caret line="10" column="45" selection-start-line="10" selection-start-column="45" selection-end-line="10" selection-end-column="45" />
102 114
             </state>
103 115
           </provider>
104 116
         </entry>
105 117
       </file>
106
-      <file leaf-file-name="ProfileControllerTest.java" pinned="false" current-in-tab="false">
107
-        <entry file="file://$PROJECT_DIR$/src/test/java/ProfileControllerTest.java">
118
+      <file leaf-file-name="ProfileController.java" pinned="false" current-in-tab="false">
119
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/ProfileController.java">
108 120
           <provider selected="true" editor-type-id="text-editor">
109
-            <state relative-caret-position="170">
110
-              <caret line="32" lean-forward="true" selection-start-line="32" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
121
+            <state relative-caret-position="195">
122
+              <caret line="25" column="37" selection-start-line="25" selection-start-column="37" selection-end-line="25" selection-end-column="37" />
111 123
             </state>
112 124
           </provider>
113 125
         </entry>
114 126
       </file>
115
-      <file leaf-file-name="UserControllerTest.java" pinned="false" current-in-tab="true">
116
-        <entry file="file://$PROJECT_DIR$/src/test/java/UserControllerTest.java">
127
+      <file leaf-file-name="DestinationController.java" pinned="false" current-in-tab="false">
128
+        <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java">
117 129
           <provider selected="true" editor-type-id="text-editor">
118
-            <state relative-caret-position="112">
119
-              <caret line="32" lean-forward="true" selection-start-line="32" selection-end-line="32" />
120
-              <folding>
121
-                <element signature="imports" expanded="true" />
122
-              </folding>
130
+            <state relative-caret-position="270">
131
+              <caret line="27" column="33" selection-start-line="27" selection-start-column="33" selection-end-line="27" selection-end-column="33" />
123 132
             </state>
124 133
           </provider>
125 134
         </entry>
@@ -145,9 +154,6 @@
145 154
   <component name="IdeDocumentHistory">
146 155
     <option name="CHANGED_PATHS">
147 156
       <list>
148
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/FutureDestination.java" />
149
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/Feed.java" />
150
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/App.java" />
151 157
         <option value="$PROJECT_DIR$/src/main/java/com/alidade/repository/MessageRepository.java" />
152 158
         <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/FriendController.java" />
153 159
         <option value="$PROJECT_DIR$/src/test/java/UserControllerClass.java" />
@@ -182,20 +188,23 @@
182 188
         <option value="$PROJECT_DIR$/src/test/java/AppTest.java" />
183 189
         <option value="$PROJECT_DIR$/src/main/java/com/alidade/repository/LoginRepository.java" />
184 190
         <option value="$PROJECT_DIR$/src/main/java/com/alidade/repository/UserRepository.java" />
185
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/Destination.java" />
186
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/Login.java" />
187
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/Profile.java" />
188
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/User.java" />
189 191
         <option value="$PROJECT_DIR$/src/main/java/com/alidade/config/DestinationApis.java" />
190 192
         <option value="$PROJECT_DIR$/pom.xml" />
191
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java" />
192
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/LoginController.java" />
193
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/ProfileController.java" />
194
-        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java" />
195 193
         <option value="$PROJECT_DIR$/src/test/java/DestinationControllerTest.java" />
196 194
         <option value="$PROJECT_DIR$/src/test/java/LoginControllerTest.java" />
197 195
         <option value="$PROJECT_DIR$/src/test/java/ProfileControllerTest.java" />
198 196
         <option value="$PROJECT_DIR$/src/test/java/UserControllerTest.java" />
197
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/config/UserApis.java" />
198
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/config/ProfileApis.java" />
199
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/config/LoginApis.java" />
200
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/LoginController.java" />
201
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java" />
202
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/ProfileController.java" />
203
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java" />
204
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/Login.java" />
205
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/Profile.java" />
206
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/User.java" />
207
+        <option value="$PROJECT_DIR$/src/main/java/com/alidade/model/Destination.java" />
199 208
       </list>
200 209
     </option>
201 210
   </component>
@@ -229,6 +238,7 @@
229 238
     <panes>
230 239
       <pane id="AndroidView" />
231 240
       <pane id="PackagesPane" />
241
+      <pane id="Scope" />
232 242
       <pane id="ProjectPane">
233 243
         <subPane>
234 244
           <expand>
@@ -311,18 +321,10 @@
311 321
               <item name="src" type="462c0819:PsiDirectoryNode" />
312 322
               <item name="test" type="462c0819:PsiDirectoryNode" />
313 323
             </path>
314
-            <path>
315
-              <item name="SharedTravelMap" type="b2602c69:ProjectViewProjectNode" />
316
-              <item name="Shared-Travel-Map" type="462c0819:PsiDirectoryNode" />
317
-              <item name="src" type="462c0819:PsiDirectoryNode" />
318
-              <item name="test" type="462c0819:PsiDirectoryNode" />
319
-              <item name="java" type="462c0819:PsiDirectoryNode" />
320
-            </path>
321 324
           </expand>
322 325
           <select />
323 326
         </subPane>
324 327
       </pane>
325
-      <pane id="Scope" />
326 328
     </panes>
327 329
   </component>
328 330
   <component name="PropertiesComponent">
@@ -514,7 +516,8 @@
514 516
       <workItem from="1532903810519" duration="7096000" />
515 517
       <workItem from="1533243150908" duration="1107000" />
516 518
       <workItem from="1533244431891" duration="596000" />
517
-      <workItem from="1533642779790" duration="1109000" />
519
+      <workItem from="1533642779790" duration="2177000" />
520
+      <workItem from="1533652431849" duration="7125000" />
518 521
     </task>
519 522
     <servers />
520 523
   </component>
@@ -545,7 +548,7 @@
545 548
     </history-entry>
546 549
   </component>
547 550
   <component name="TimeTrackingManager">
548
-    <option name="totallyTimeSpent" value="89577000" />
551
+    <option name="totallyTimeSpent" value="97770000" />
549 552
   </component>
550 553
   <component name="TodoView">
551 554
     <todo-panel id="selected-file">
@@ -557,7 +560,8 @@
557 560
     </todo-panel>
558 561
   </component>
559 562
   <component name="ToolWindowManager">
560
-    <frame x="0" y="0" width="1280" height="800" extended-state="6" />
563
+    <frame x="0" y="0" width="1280" height="800" extended-state="0" />
564
+    <editor active="true" />
561 565
     <layout>
562 566
       <window_info anchor="right" id="Palette" order="3" />
563 567
       <window_info anchor="bottom" id="Event Log" order="7" side_tool="true" />
@@ -577,10 +581,10 @@
577 581
       <window_info anchor="bottom" id="Java Enterprise" order="8" />
578 582
       <window_info anchor="right" id="Capture Analysis" order="3" />
579 583
       <window_info anchor="bottom" id="Version Control" order="7" weight="0.32954547" />
580
-      <window_info active="true" anchor="bottom" id="Run" order="2" visible="true" weight="0.5089655" />
584
+      <window_info anchor="bottom" id="Run" order="2" weight="0.51862067" />
581 585
       <window_info anchor="bottom" id="Spring" order="8" weight="0.32935324" />
582
-      <window_info anchor="bottom" id="Terminal" order="7" weight="0.72965515" />
583
-      <window_info content_ui="combo" id="Project" order="0" sideWeight="0.4985591" visible="true" weight="0.30210015" />
586
+      <window_info anchor="bottom" id="Terminal" order="7" weight="0.42487562" />
587
+      <window_info active="true" content_ui="combo" id="Project" order="0" sideWeight="0.4985591" visible="true" weight="0.30533117" />
584 588
       <window_info anchor="right" id="Bean Validation" order="4" />
585 589
       <window_info id="Web" order="3" side_tool="true" />
586 590
       <window_info anchor="right" id="Theme Preview" order="3" />
@@ -600,16 +604,7 @@
600 604
     <option name="myLimit" value="2678400000" />
601 605
   </component>
602 606
   <component name="editorHistoryManager">
603
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Message.java" />
604
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/MessageController.java" />
605 607
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/UserLoginRepository.java" />
606
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/SharedTravelApp.java">
607
-      <provider selected="true" editor-type-id="text-editor">
608
-        <state relative-caret-position="30">
609
-          <caret line="3" column="68" selection-start-line="3" selection-start-column="68" selection-end-line="3" selection-end-column="68" />
610
-        </state>
611
-      </provider>
612
-    </entry>
613 608
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/MessageBoardRepository.java" />
614 609
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/MessageBoardController.java" />
615 610
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/FriendListController.java" />
@@ -665,183 +660,204 @@
665 660
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/map/DestinationState.java" />
666 661
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/FriendList.java" />
667 662
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Map.java" />
668
-    <entry file="file://$PROJECT_DIR$/src/main/resources/application.properties">
663
+    <entry file="file://$PROJECT_DIR$/src/test/java/AppTest.java">
669 664
       <provider selected="true" editor-type-id="text-editor">
670
-        <state relative-caret-position="75">
671
-          <caret line="5" column="33" lean-forward="true" selection-start-line="5" selection-start-column="33" selection-end-line="5" selection-end-column="33" />
665
+        <state relative-caret-position="120">
666
+          <caret line="11" column="75" selection-start-line="11" selection-start-column="75" selection-end-line="11" selection-end-column="75" />
672 667
         </state>
673 668
       </provider>
674 669
     </entry>
675
-    <entry file="file://$PROJECT_DIR$/src/test/java/AppTest.java">
670
+    <entry file="file://$PROJECT_DIR$/src/test/java/DestinationControllerTest.java">
676 671
       <provider selected="true" editor-type-id="text-editor">
677
-        <state relative-caret-position="120">
678
-          <caret line="11" column="75" selection-start-line="11" selection-start-column="75" selection-end-line="11" selection-end-column="75" />
672
+        <state relative-caret-position="215">
673
+          <caret line="33" selection-start-line="33" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
679 674
         </state>
680 675
       </provider>
681 676
     </entry>
682
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/LoginRepository.java">
677
+    <entry file="file://$PROJECT_DIR$/src/test/java/LoginControllerTest.java">
683 678
       <provider selected="true" editor-type-id="text-editor">
684
-        <state relative-caret-position="105">
685
-          <caret line="7" column="17" selection-start-line="7" selection-start-column="17" selection-end-line="7" selection-end-column="17" />
679
+        <state relative-caret-position="185">
680
+          <caret line="33" selection-start-line="33" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
686 681
         </state>
687 682
       </provider>
688 683
     </entry>
689
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/UserRepository.java">
684
+    <entry file="file://$PROJECT_DIR$/src/test/java/ProfileControllerTest.java">
690 685
       <provider selected="true" editor-type-id="text-editor">
691
-        <state relative-caret-position="90">
692
-          <caret line="6" column="11" selection-start-line="6" selection-start-column="11" selection-end-line="6" selection-end-column="11" />
686
+        <state relative-caret-position="170">
687
+          <caret line="32" lean-forward="true" selection-start-line="32" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
693 688
         </state>
694 689
       </provider>
695 690
     </entry>
696
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/ProfileRepository.java">
691
+    <entry file="file://$PROJECT_DIR$/src/test/java/UserControllerTest.java">
692
+      <provider selected="true" editor-type-id="text-editor">
693
+        <state relative-caret-position="321">
694
+          <caret line="32" lean-forward="true" selection-start-line="32" selection-end-line="32" />
695
+          <folding>
696
+            <element signature="imports" expanded="true" />
697
+          </folding>
698
+        </state>
699
+      </provider>
700
+    </entry>
701
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/LoginApis.java">
702
+      <provider selected="true" editor-type-id="text-editor">
703
+        <state relative-caret-position="30">
704
+          <caret line="2" column="24" lean-forward="true" selection-start-line="2" selection-start-column="24" selection-end-line="2" selection-end-column="24" />
705
+        </state>
706
+      </provider>
707
+    </entry>
708
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/DestinationRepository.java">
697 709
       <provider selected="true" editor-type-id="text-editor">
698 710
         <state relative-caret-position="75">
699 711
           <caret line="7" column="17" selection-start-line="7" selection-start-column="17" selection-end-line="7" selection-end-column="17" />
700 712
         </state>
701 713
       </provider>
702 714
     </entry>
703
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/DestinationRepository.java">
715
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/LoginRepository.java">
704 716
       <provider selected="true" editor-type-id="text-editor">
705 717
         <state relative-caret-position="75">
706 718
           <caret line="7" column="17" selection-start-line="7" selection-start-column="17" selection-end-line="7" selection-end-column="17" />
707 719
         </state>
708 720
       </provider>
709 721
     </entry>
710
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Destination.java">
722
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/ProfileRepository.java">
711 723
       <provider selected="true" editor-type-id="text-editor">
712
-        <state relative-caret-position="180">
713
-          <caret line="12" selection-start-line="12" selection-end-line="12" selection-end-column="15" />
714
-          <folding>
715
-            <element signature="imports" expanded="true" />
716
-          </folding>
724
+        <state relative-caret-position="75">
725
+          <caret line="7" column="17" selection-start-line="7" selection-start-column="17" selection-end-line="7" selection-end-column="17" />
717 726
         </state>
718 727
       </provider>
719 728
     </entry>
720
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Login.java">
729
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/repository/UserRepository.java">
721 730
       <provider selected="true" editor-type-id="text-editor">
722
-        <state relative-caret-position="390">
723
-          <caret line="26" selection-start-line="26" selection-end-line="26" />
724
-          <folding>
725
-            <element signature="imports" expanded="true" />
726
-          </folding>
731
+        <state relative-caret-position="60">
732
+          <caret line="6" column="11" selection-start-line="6" selection-start-column="11" selection-end-line="6" selection-end-column="11" />
727 733
         </state>
728 734
       </provider>
729 735
     </entry>
730
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Profile.java">
736
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/ProfileApis.java">
731 737
       <provider selected="true" editor-type-id="text-editor">
732
-        <state relative-caret-position="555">
733
-          <caret line="42" selection-start-line="42" selection-end-line="42" />
738
+        <state relative-caret-position="45">
739
+          <caret line="3" column="66" selection-start-line="3" selection-start-column="66" selection-end-line="3" selection-end-column="66" />
734 740
         </state>
735 741
       </provider>
736 742
     </entry>
737
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/User.java">
743
+    <entry file="jar://$MAVEN_REPOSITORY$/org/apache/tomcat/embed/tomcat-embed-core/8.5.32/tomcat-embed-core-8.5.32.jar!/org/apache/catalina/core/ApplicationFilterChain.class">
738 744
       <provider selected="true" editor-type-id="text-editor">
739
-        <state relative-caret-position="420">
740
-          <caret line="30" selection-start-line="30" selection-end-line="30" />
741
-          <folding>
742
-            <element signature="imports" expanded="true" />
743
-          </folding>
745
+        <state relative-caret-position="151">
746
+          <caret line="91" selection-start-line="91" selection-end-line="91" />
744 747
         </state>
745 748
       </provider>
746 749
     </entry>
747 750
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/UserApis.java">
748 751
       <provider selected="true" editor-type-id="text-editor">
749
-        <state relative-caret-position="30">
750
-          <caret line="2" column="21" selection-start-line="2" selection-start-column="21" selection-end-line="2" selection-end-column="21" />
752
+        <state relative-caret-position="45">
753
+          <caret line="3" column="56" lean-forward="true" selection-start-line="3" selection-end-line="4" />
751 754
         </state>
752 755
       </provider>
753 756
     </entry>
754
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/LoginApis.java">
757
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/LoginController.java">
755 758
       <provider selected="true" editor-type-id="text-editor">
756
-        <state relative-caret-position="30">
757
-          <caret line="2" column="22" selection-start-line="2" selection-start-column="22" selection-end-line="2" selection-end-column="22" />
759
+        <state relative-caret-position="180">
760
+          <caret line="19" column="39" selection-start-line="19" selection-start-column="39" selection-end-line="19" selection-end-column="39" />
758 761
         </state>
759 762
       </provider>
760 763
     </entry>
761
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/ProfileApis.java">
764
+    <entry file="file://$PROJECT_DIR$/src/main/resources/application.properties">
762 765
       <provider selected="true" editor-type-id="text-editor">
763
-        <state relative-caret-position="30">
764
-          <caret line="2" column="26" selection-start-line="2" selection-start-column="26" selection-end-line="2" selection-end-column="26" />
766
+        <state relative-caret-position="75">
767
+          <caret line="5" column="33" lean-forward="true" selection-start-line="5" selection-start-column="33" selection-end-line="5" selection-end-column="33" />
765 768
         </state>
766 769
       </provider>
767 770
     </entry>
768
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/HomeController.java">
771
+    <entry file="file://$PROJECT_DIR$/pom.xml">
769 772
       <provider selected="true" editor-type-id="text-editor">
770
-        <state relative-caret-position="135">
771
-          <caret line="10" column="45" selection-start-line="10" selection-start-column="45" selection-end-line="10" selection-end-column="45" />
773
+        <state relative-caret-position="159">
774
+          <caret line="13" column="30" selection-start-line="13" selection-start-column="30" selection-end-line="13" selection-end-column="30" />
772 775
         </state>
773 776
       </provider>
774 777
     </entry>
775
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/DestinationApis.java">
778
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/SharedTravelApp.java">
776 779
       <provider selected="true" editor-type-id="text-editor">
777
-        <state relative-caret-position="60">
778
-          <caret line="4" column="45" selection-start-line="4" selection-start-column="45" selection-end-line="4" selection-end-column="45" />
780
+        <state relative-caret-position="75">
781
+          <caret line="6" column="13" selection-start-line="6" selection-start-column="13" selection-end-line="6" selection-end-column="13" />
779 782
         </state>
780 783
       </provider>
781 784
     </entry>
782
-    <entry file="file://$PROJECT_DIR$/pom.xml">
785
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java">
783 786
       <provider selected="true" editor-type-id="text-editor">
784
-        <state relative-caret-position="159">
785
-          <caret line="13" column="30" selection-start-line="13" selection-start-column="30" selection-end-line="13" selection-end-column="30" />
787
+        <state relative-caret-position="165">
788
+          <caret line="19" column="4" selection-start-line="19" selection-start-column="4" selection-end-line="19" selection-end-column="4" />
786 789
         </state>
787 790
       </provider>
788 791
     </entry>
789
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java">
792
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/HomeController.java">
790 793
       <provider selected="true" editor-type-id="text-editor">
791
-        <state relative-caret-position="690">
792
-          <caret line="46" lean-forward="true" selection-start-line="46" selection-end-line="46" />
793
-          <folding>
794
-            <element signature="imports" expanded="true" />
795
-          </folding>
794
+        <state relative-caret-position="135">
795
+          <caret line="10" column="45" selection-start-line="10" selection-start-column="45" selection-end-line="10" selection-end-column="45" />
796 796
         </state>
797 797
       </provider>
798 798
     </entry>
799
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/LoginController.java">
799
+    <entry file="jar://$MAVEN_REPOSITORY$/org/hibernate/javax/persistence/hibernate-jpa-2.1-api/1.0.2.Final/hibernate-jpa-2.1-api-1.0.2.Final.jar!/javax/persistence/OneToOne.class">
800 800
       <provider selected="true" editor-type-id="text-editor">
801
-        <state relative-caret-position="210">
802
-          <caret line="19" column="44" lean-forward="true" selection-start-line="19" selection-start-column="44" selection-end-line="19" selection-end-column="44" />
801
+        <state relative-caret-position="120">
802
+          <caret line="14" column="18" selection-start-line="14" selection-start-column="18" selection-end-line="14" selection-end-column="18" />
803
+        </state>
804
+      </provider>
805
+    </entry>
806
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/config/DestinationApis.java">
807
+      <provider selected="true" editor-type-id="text-editor">
808
+        <state relative-caret-position="30">
809
+          <caret line="2" column="30" selection-start-line="2" selection-start-column="30" selection-end-line="2" selection-end-column="30" />
803 810
         </state>
804 811
       </provider>
805 812
     </entry>
806 813
     <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/ProfileController.java">
807 814
       <provider selected="true" editor-type-id="text-editor">
808
-        <state relative-caret-position="130">
809
-          <caret line="32" selection-start-line="32" selection-start-column="2" selection-end-line="38" selection-end-column="7" />
815
+        <state relative-caret-position="195">
816
+          <caret line="25" column="37" selection-start-line="25" selection-start-column="37" selection-end-line="25" selection-end-column="37" />
810 817
         </state>
811 818
       </provider>
812 819
     </entry>
813
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/UserController.java">
820
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/controller/DestinationController.java">
814 821
       <provider selected="true" editor-type-id="text-editor">
815
-        <state relative-caret-position="315">
816
-          <caret line="28" column="43" lean-forward="true" selection-start-line="28" selection-start-column="43" selection-end-line="28" selection-end-column="43" />
822
+        <state relative-caret-position="270">
823
+          <caret line="27" column="33" selection-start-line="27" selection-start-column="33" selection-end-line="27" selection-end-column="33" />
817 824
         </state>
818 825
       </provider>
819 826
     </entry>
820
-    <entry file="file://$PROJECT_DIR$/src/test/java/DestinationControllerTest.java">
827
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Destination.java">
821 828
       <provider selected="true" editor-type-id="text-editor">
822
-        <state relative-caret-position="215">
823
-          <caret line="33" selection-start-line="33" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
829
+        <state relative-caret-position="372">
830
+          <caret line="43" column="25" selection-start-line="43" selection-start-column="25" selection-end-line="43" selection-end-column="25" />
831
+          <folding>
832
+            <element signature="imports" expanded="true" />
833
+          </folding>
824 834
         </state>
825 835
       </provider>
826 836
     </entry>
827
-    <entry file="file://$PROJECT_DIR$/src/test/java/LoginControllerTest.java">
837
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Login.java">
828 838
       <provider selected="true" editor-type-id="text-editor">
829
-        <state relative-caret-position="185">
830
-          <caret line="33" selection-start-line="33" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
839
+        <state relative-caret-position="195">
840
+          <caret line="13" column="50" selection-start-line="13" selection-start-column="50" selection-end-line="13" selection-end-column="50" />
841
+          <folding>
842
+            <element signature="imports" expanded="true" />
843
+          </folding>
831 844
         </state>
832 845
       </provider>
833 846
     </entry>
834
-    <entry file="file://$PROJECT_DIR$/src/test/java/ProfileControllerTest.java">
847
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/Profile.java">
835 848
       <provider selected="true" editor-type-id="text-editor">
836
-        <state relative-caret-position="170">
837
-          <caret line="32" lean-forward="true" selection-start-line="32" selection-start-column="2" selection-end-line="41" selection-end-column="7" />
849
+        <state relative-caret-position="91">
850
+          <caret line="14" column="50" selection-start-line="14" selection-start-column="50" selection-end-line="14" selection-end-column="50" />
851
+          <folding>
852
+            <element signature="imports" expanded="true" />
853
+          </folding>
838 854
         </state>
839 855
       </provider>
840 856
     </entry>
841
-    <entry file="file://$PROJECT_DIR$/src/test/java/UserControllerTest.java">
857
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/alidade/model/User.java">
842 858
       <provider selected="true" editor-type-id="text-editor">
843
-        <state relative-caret-position="112">
844
-          <caret line="32" lean-forward="true" selection-start-line="32" selection-end-line="32" />
859
+        <state relative-caret-position="195">
860
+          <caret line="13" column="50" selection-start-line="13" selection-start-column="50" selection-end-line="13" selection-end-column="50" />
845 861
           <folding>
846 862
             <element signature="imports" expanded="true" />
847 863
           </folding>

+ 1
- 1
src/main/java/com/alidade/controller/DestinationController.java Voir le fichier

@@ -20,7 +20,7 @@ public class DestinationController {
20 20
 
21 21
     @PostMapping(path = DESTINATION_BASE_URL)
22 22
     public Destination createDestination(@RequestBody Destination destination){
23
-        return destinationRepository.saveAndFlush(destination);
23
+        return destinationRepository.save(destination);
24 24
     }
25 25
 
26 26
     @GetMapping(path = DESTINATION_BY_ID)

+ 8
- 2
src/main/java/com/alidade/controller/ProfileController.java Voir le fichier

@@ -8,6 +8,7 @@ import org.springframework.http.HttpStatus;
8 8
 import org.springframework.http.ResponseEntity;
9 9
 import org.springframework.web.bind.annotation.*;
10 10
 
11
+import java.util.Collection;
11 12
 import java.util.Optional;
12 13
 
13 14
 import static com.alidade.config.ProfileApis.PROFILE_BASE_URL;
@@ -21,8 +22,13 @@ public class ProfileController {
21 22
     private ProfileRepository profileRepository;
22 23
 
23 24
     @PostMapping(value = PROFILE_BASE_URL)
24
-    public ResponseEntity<Profile> createProfile(@RequestBody Profile profile){
25
-        return new ResponseEntity<>(profileRepository.saveAndFlush(profile), HttpStatus.CREATED);
25
+    public Profile createProfile(@RequestBody Profile profile){
26
+        return profileRepository.save(profile);
27
+    }
28
+
29
+    @GetMapping(value = PROFILE_BASE_URL)
30
+    public Collection<Profile> getAllProfiles(){
31
+        return profileRepository.findAll();
26 32
     }
27 33
 
28 34
     @GetMapping(value = PROFILE_BY_ID)

+ 2
- 4
src/main/java/com/alidade/controller/UserController.java Voir le fichier

@@ -3,8 +3,6 @@ package com.alidade.controller;
3 3
 import com.alidade.model.User;
4 4
 import com.alidade.repository.UserRepository;
5 5
 import org.springframework.beans.factory.annotation.Autowired;
6
-import org.springframework.http.HttpStatus;
7
-import org.springframework.http.ResponseEntity;
8 6
 import org.springframework.web.bind.annotation.*;
9 7
 
10 8
 import java.util.Optional;
@@ -20,8 +18,8 @@ public class UserController {
20 18
     private UserRepository userRepository;
21 19
 
22 20
     @PostMapping(value = USER_BASE_URL)
23
-    public ResponseEntity<User> createUser(@RequestBody User user){
24
-        return new ResponseEntity<>(userRepository.saveAndFlush(user), HttpStatus.CREATED);
21
+    public User createUser(@RequestBody User user){
22
+        return userRepository.save(user);
25 23
     }
26 24
 
27 25
     @GetMapping(value = USER_BY_ID)

+ 2
- 0
src/main/java/com/alidade/model/Destination.java Voir le fichier

@@ -1,5 +1,6 @@
1 1
 package com.alidade.model;
2 2
 
3
+import com.fasterxml.jackson.annotation.JsonIgnore;
3 4
 import lombok.Getter;
4 5
 import lombok.Setter;
5 6
 import org.hibernate.annotations.OnDelete;
@@ -45,6 +46,7 @@ public class Destination {
45 46
     @ManyToOne(fetch = FetchType.LAZY, optional = false)
46 47
     @JoinColumn(name = "PROFILE_ID", nullable = false)
47 48
     @OnDelete(action = OnDeleteAction.CASCADE)
49
+    @JsonIgnore
48 50
     private Profile profile;
49 51
 
50 52
 }

+ 2
- 2
src/main/java/com/alidade/model/Profile.java Voir le fichier

@@ -4,7 +4,6 @@ import lombok.Getter;
4 4
 import lombok.Setter;
5 5
 
6 6
 import javax.persistence.*;
7
-import java.util.ArrayList;
8 7
 import java.util.List;
9 8
 
10 9
 @Entity
@@ -33,7 +32,8 @@ public class Profile {
33 32
     private String imagePath;
34 33
 
35 34
     @ManyToMany
36
-    @JoinTable(name = "FRIENDLIST", joinColumns = { @JoinColumn(name = "PROFILE_ID") },
35
+    @JoinTable(name = "FRIENDLIST",
36
+            joinColumns = { @JoinColumn(name = "PROFILE_ID") },
37 37
             inverseJoinColumns = { @JoinColumn(name = "FRIEND_PROFILE_ID") })
38 38
     private List<Profile> friendList;
39 39
 

+ 2
- 4
src/main/java/com/alidade/model/User.java Voir le fichier

@@ -21,12 +21,10 @@ public class User {
21 21
     @Column(name = "LAST_NAME")
22 22
     private String lastName;
23 23
 
24
-    @OneToOne(mappedBy = "user", cascade = CascadeType.ALL, fetch = FetchType.LAZY)
25
-    @JoinColumn(name = "USER_ID")
24
+    @OneToOne(mappedBy = "user", cascade = CascadeType.ALL)
26 25
     private Login login;
27 26
 
28
-    @OneToOne(mappedBy = "user", cascade = CascadeType.ALL, fetch = FetchType.LAZY)
29
-    @JoinColumn(name = "USER_ID")
27
+    @OneToOne(mappedBy = "user", cascade = CascadeType.ALL)
30 28
     private Profile profile;
31 29
 
32 30
 }

BIN
target/classes/com/alidade/config/LoginApis.class Voir le fichier


BIN
target/classes/com/alidade/config/ProfileApis.class Voir le fichier


BIN
target/classes/com/alidade/config/UserApis.class Voir le fichier


BIN
target/classes/com/alidade/controller/DestinationController.class Voir le fichier


BIN
target/classes/com/alidade/controller/LoginController.class Voir le fichier


BIN
target/classes/com/alidade/controller/ProfileController.class Voir le fichier


BIN
target/classes/com/alidade/controller/UserController.class Voir le fichier


BIN
target/classes/com/alidade/model/Destination.class Voir le fichier


BIN
target/classes/com/alidade/model/Profile.class Voir le fichier


BIN
target/classes/com/alidade/model/User.class Voir le fichier