Browse Source

Merge branch 'working' of natehalldev/JhipsterGroupProject-Server into master

Lauren Green 5 years ago
parent
commit
3230ac9b17
64 changed files with 88 additions and 413 deletions
  1. 0
    4
      .jhipster/Cohort.json
  2. 0
    4
      .jhipster/Employer.json
  3. 4
    18
      .jhipster/Post.json
  4. 0
    4
      .jhipster/Privacy.json
  5. 0
    20
      .jhipster/UserProfile.json
  6. 2
    23
      jhipster-jdl.jh
  7. 10
    9
      src/main/java/rocks/zipcode/io/domain/Post.java
  8. 13
    12
      src/main/java/rocks/zipcode/io/domain/UserProfile.java
  9. 0
    4
      src/main/java/rocks/zipcode/io/repository/PostRepository.java
  10. 0
    8
      src/main/resources/config/liquibase/changelog/20181217184612_added_entity_UserProfile.xml
  11. 0
    12
      src/main/resources/config/liquibase/changelog/20181217184612_added_entity_constraints_UserProfile.xml
  12. 0
    4
      src/main/resources/config/liquibase/changelog/20181217184613_added_entity_Cohort.xml
  13. 0
    4
      src/main/resources/config/liquibase/changelog/20181217184614_added_entity_Employer.xml
  14. 4
    8
      src/main/resources/config/liquibase/changelog/20181217184615_added_entity_Post.xml
  15. 1
    7
      src/main/resources/config/liquibase/changelog/20181217184615_added_entity_constraints_Post.xml
  16. 0
    4
      src/main/resources/config/liquibase/changelog/20181217184616_added_entity_Privacy.xml
  17. 0
    4
      src/main/webapp/app/entities/cohort/cohort-detail.component.html
  18. 0
    5
      src/main/webapp/app/entities/cohort/cohort-update.component.html
  19. 0
    2
      src/main/webapp/app/entities/cohort/cohort.component.html
  20. 0
    4
      src/main/webapp/app/entities/employer/employer-detail.component.html
  21. 0
    5
      src/main/webapp/app/entities/employer/employer-update.component.html
  22. 0
    2
      src/main/webapp/app/entities/employer/employer.component.html
  23. 3
    9
      src/main/webapp/app/entities/post/post-detail.component.html
  24. 3
    15
      src/main/webapp/app/entities/post/post-update.component.html
  25. 11
    19
      src/main/webapp/app/entities/post/post-update.component.ts
  26. 3
    7
      src/main/webapp/app/entities/post/post.component.html
  27. 1
    2
      src/main/webapp/app/entities/post/post.module.ts
  28. 0
    4
      src/main/webapp/app/entities/privacy/privacy-detail.component.html
  29. 0
    5
      src/main/webapp/app/entities/privacy/privacy-update.component.html
  30. 0
    2
      src/main/webapp/app/entities/privacy/privacy.component.html
  31. 0
    16
      src/main/webapp/app/entities/user-profile/user-profile-detail.component.html
  32. 0
    5
      src/main/webapp/app/entities/user-profile/user-profile-update.component.html
  33. 7
    37
      src/main/webapp/app/entities/user-profile/user-profile-update.component.ts
  34. 0
    14
      src/main/webapp/app/entities/user-profile/user-profile.component.html
  35. 0
    1
      src/main/webapp/app/shared/model/cohort.model.ts
  36. 0
    1
      src/main/webapp/app/shared/model/employer.model.ts
  37. 3
    3
      src/main/webapp/app/shared/model/post.model.ts
  38. 0
    1
      src/main/webapp/app/shared/model/privacy.model.ts
  39. 4
    4
      src/main/webapp/app/shared/model/user-profile.model.ts
  40. 0
    1
      src/main/webapp/i18n/en/cohort.json
  41. 0
    1
      src/main/webapp/i18n/en/employer.json
  42. 1
    3
      src/main/webapp/i18n/en/post.json
  43. 0
    1
      src/main/webapp/i18n/en/privacy.json
  44. 0
    3
      src/main/webapp/i18n/en/userProfile.json
  45. 0
    1
      src/main/webapp/i18n/es/cohort.json
  46. 0
    1
      src/main/webapp/i18n/es/employer.json
  47. 1
    3
      src/main/webapp/i18n/es/post.json
  48. 0
    1
      src/main/webapp/i18n/es/privacy.json
  49. 0
    3
      src/main/webapp/i18n/es/userProfile.json
  50. 0
    9
      src/test/javascript/e2e/entities/cohort/cohort.page-object.ts
  51. 1
    2
      src/test/javascript/e2e/entities/cohort/cohort.spec.ts
  52. 0
    9
      src/test/javascript/e2e/entities/employer/employer.page-object.ts
  53. 0
    2
      src/test/javascript/e2e/entities/employer/employer.spec.ts
  54. 12
    21
      src/test/javascript/e2e/entities/post/post.page-object.ts
  55. 1
    4
      src/test/javascript/e2e/entities/post/post.spec.ts
  56. 0
    9
      src/test/javascript/e2e/entities/privacy/privacy.page-object.ts
  57. 1
    2
      src/test/javascript/e2e/entities/privacy/privacy.spec.ts
  58. 1
    10
      src/test/javascript/e2e/entities/user-profile/user-profile.page-object.ts
  59. 0
    4
      src/test/javascript/e2e/entities/user-profile/user-profile.spec.ts
  60. 1
    3
      src/test/javascript/spec/app/entities/cohort/cohort.service.spec.ts
  61. 0
    2
      src/test/javascript/spec/app/entities/employer/employer.service.spec.ts
  62. 0
    2
      src/test/javascript/spec/app/entities/post/post.service.spec.ts
  63. 0
    2
      src/test/javascript/spec/app/entities/privacy/privacy.service.spec.ts
  64. 0
    2
      src/test/javascript/spec/app/entities/user-profile/user-profile.service.spec.ts

+ 0
- 4
.jhipster/Cohort.json View File

2
     "name": "Cohort",
2
     "name": "Cohort",
3
     "fields": [
3
     "fields": [
4
         {
4
         {
5
-            "fieldName": "cohortId",
6
-            "fieldType": "Double"
7
-        },
8
-        {
9
             "fieldName": "gradDate",
5
             "fieldName": "gradDate",
10
             "fieldType": "String"
6
             "fieldType": "String"
11
         }
7
         }

+ 0
- 4
.jhipster/Employer.json View File

2
     "name": "Employer",
2
     "name": "Employer",
3
     "fields": [
3
     "fields": [
4
         {
4
         {
5
-            "fieldName": "employerId",
6
-            "fieldType": "Long"
7
-        },
8
-        {
9
             "fieldName": "companyName",
5
             "fieldName": "companyName",
10
             "fieldType": "String"
6
             "fieldType": "String"
11
         },
7
         },

+ 4
- 18
.jhipster/Post.json View File

2
     "name": "Post",
2
     "name": "Post",
3
     "fields": [
3
     "fields": [
4
         {
4
         {
5
-            "fieldName": "postId",
6
-            "fieldType": "Long"
7
-        },
8
-        {
9
             "fieldName": "timestamp",
5
             "fieldName": "timestamp",
10
             "fieldType": "LocalDate"
6
             "fieldType": "LocalDate"
11
         },
7
         },
20
     ],
16
     ],
21
     "relationships": [
17
     "relationships": [
22
         {
18
         {
23
-            "relationshipType": "one-to-one",
19
+            "relationshipType": "many-to-one",
24
             "relationshipName": "poster",
20
             "relationshipName": "poster",
25
-            "otherEntityName": "user",
26
-            "otherEntityField": "id",
27
-            "ownerSide": true,
28
-            "otherEntityRelationshipName": "post"
21
+            "otherEntityName": "userProfile",
22
+            "otherEntityField": "id"
29
         },
23
         },
30
         {
24
         {
31
-            "relationshipType": "one-to-one",
25
+            "relationshipType": "many-to-one",
32
             "relationshipName": "privacySetting",
26
             "relationshipName": "privacySetting",
33
             "otherEntityName": "privacy",
27
             "otherEntityName": "privacy",
34
-            "otherEntityField": "id",
35
-            "ownerSide": true,
36
-            "otherEntityRelationshipName": "post"
37
-        },
38
-        {
39
-            "relationshipType": "many-to-one",
40
-            "relationshipName": "poster",
41
-            "otherEntityName": "user",
42
             "otherEntityField": "id"
28
             "otherEntityField": "id"
43
         }
29
         }
44
     ],
30
     ],

+ 0
- 4
.jhipster/Privacy.json View File

2
     "name": "Privacy",
2
     "name": "Privacy",
3
     "fields": [
3
     "fields": [
4
         {
4
         {
5
-            "fieldName": "privacyId",
6
-            "fieldType": "Long"
7
-        },
8
-        {
9
             "fieldName": "publicView",
5
             "fieldName": "publicView",
10
             "fieldType": "Boolean"
6
             "fieldType": "Boolean"
11
         },
7
         },

+ 0
- 20
.jhipster/UserProfile.json View File

2
     "name": "UserProfile",
2
     "name": "UserProfile",
3
     "fields": [
3
     "fields": [
4
         {
4
         {
5
-            "fieldName": "profileId",
6
-            "fieldType": "Long"
7
-        },
8
-        {
9
             "fieldName": "firstName",
5
             "fieldName": "firstName",
10
             "fieldType": "String"
6
             "fieldType": "String"
11
         },
7
         },
28
             "otherEntityRelationshipName": "userProfile"
24
             "otherEntityRelationshipName": "userProfile"
29
         },
25
         },
30
         {
26
         {
31
-            "relationshipType": "one-to-one",
32
-            "relationshipName": "cohort",
33
-            "otherEntityName": "cohort",
34
-            "otherEntityField": "id",
35
-            "ownerSide": true,
36
-            "otherEntityRelationshipName": "userProfile"
37
-        },
38
-        {
39
-            "relationshipType": "one-to-one",
40
-            "relationshipName": "employer",
41
-            "otherEntityName": "employer",
42
-            "otherEntityField": "id",
43
-            "ownerSide": true,
44
-            "otherEntityRelationshipName": "userProfile"
45
-        },
46
-        {
47
             "relationshipType": "many-to-one",
27
             "relationshipType": "many-to-one",
48
             "relationshipName": "employer",
28
             "relationshipName": "employer",
49
             "otherEntityName": "employer",
29
             "otherEntityName": "employer",

+ 2
- 23
jhipster-jdl.jh View File

1
-entity User {
2
-	userId Long,
3
-}
4
-
5
 entity UserProfile {
1
 entity UserProfile {
6
-	profileId Long,
7
     firstName String,
2
     firstName String,
8
     lastName String,
3
     lastName String,
9
     userStack String,
4
     userStack String,
10
 }
5
 }
11
 
6
 
12
 entity Cohort {
7
 entity Cohort {
13
-	cohortId Double,
14
     gradDate String
8
     gradDate String
15
 }
9
 }
16
 
10
 
17
 entity Employer {
11
 entity Employer {
18
-	employerId Long,
19
     companyName String,
12
     companyName String,
20
     city String,
13
     city String,
21
     state String
14
     state String
22
 }
15
 }
23
 
16
 
24
 entity Post {
17
 entity Post {
25
-	postId Long,
26
     timestamp LocalDate,
18
     timestamp LocalDate,
27
     content String,
19
     content String,
28
     likes String,
20
     likes String,
29
 }
21
 }
30
 
22
 
31
 entity Privacy {
23
 entity Privacy {
32
-	privacyId Long,
33
 	publicView Boolean,
24
 	publicView Boolean,
34
     cohortView Boolean,
25
     cohortView Boolean,
35
     employerView Boolean
26
     employerView Boolean
41
 }
32
 }
42
 
33
 
43
 relationship ManyToOne {
34
 relationship ManyToOne {
44
-    Post{poster} to User
35
+    Post{poster} to UserProfile
45
 }
36
 }
46
 
37
 
47
 relationship ManyToOne {
38
 relationship ManyToOne {
52
 	UserProfile{user} to User
43
 	UserProfile{user} to User
53
 }
44
 }
54
 
45
 
55
-relationship OneToOne {
56
-    Post{poster} to User
57
-}
58
-
59
-relationship OneToOne {
60
-	UserProfile{cohort} to Cohort
61
-}
62
-
63
-relationship OneToOne {
64
-	UserProfile{employer} to Employer
65
-}
66
-
67
-relationship OneToOne {
46
+relationship ManyToOne {
68
 	Post{privacySetting} to Privacy
47
 	Post{privacySetting} to Privacy
69
 }
48
 }
70
 
49
 

+ 10
- 9
src/main/java/rocks/zipcode/io/domain/Post.java View File

33
     @Column(name = "likes")
33
     @Column(name = "likes")
34
     private String likes;
34
     private String likes;
35
 
35
 
36
-    @OneToOne    @JoinColumn(unique = true)
37
-    private Privacy privacySetting;
36
+    @ManyToOne
37
+    @JsonIgnoreProperties("")
38
+    private UserProfile poster;
38
 
39
 
39
     @ManyToOne
40
     @ManyToOne
40
     @JsonIgnoreProperties("")
41
     @JsonIgnoreProperties("")
41
-    private User poster;
42
+    private Privacy privacySetting;
42
 
43
 
43
     // jhipster-needle-entity-add-field - JHipster will add fields here, do not remove
44
     // jhipster-needle-entity-add-field - JHipster will add fields here, do not remove
44
     public Long getId() {
45
     public Long getId() {
88
         this.likes = likes;
89
         this.likes = likes;
89
     }
90
     }
90
 
91
 
91
-    public User getPoster() {
92
+    public UserProfile getPoster() {
92
         return poster;
93
         return poster;
93
     }
94
     }
94
 
95
 
95
-    public Post poster(User user) {
96
-        this.poster = user;
96
+    public Post poster(UserProfile userProfile) {
97
+        this.poster = userProfile;
97
         return this;
98
         return this;
98
     }
99
     }
99
 
100
 
100
-    public void setPoster(User user) {
101
-        this.poster = user;
101
+    public void setPoster(UserProfile userProfile) {
102
+        this.poster = userProfile;
102
     }
103
     }
103
 
104
 
104
     public Privacy getPrivacySetting() {
105
     public Privacy getPrivacySetting() {
113
     public void setPrivacySetting(Privacy privacy) {
114
     public void setPrivacySetting(Privacy privacy) {
114
         this.privacySetting = privacy;
115
         this.privacySetting = privacy;
115
     }
116
     }
116
-
117
+    // jhipster-needle-entity-add-getters-setters - JHipster will add getters and setters here, do not remove
117
 
118
 
118
     @Override
119
     @Override
119
     public boolean equals(Object o) {
120
     public boolean equals(Object o) {

+ 13
- 12
src/main/java/rocks/zipcode/io/domain/UserProfile.java View File

104
         this.user = user;
104
         this.user = user;
105
     }
105
     }
106
 
106
 
107
-    public Cohort getCohort() {
108
-        return cohort;
107
+    public Employer getEmployer() {
108
+        return employer;
109
     }
109
     }
110
 
110
 
111
-    public UserProfile cohort(Cohort cohort) {
112
-        this.cohort = cohort;
111
+    public UserProfile employer(Employer employer) {
112
+        this.employer = employer;
113
         return this;
113
         return this;
114
     }
114
     }
115
 
115
 
116
-    public void setCohort(Cohort cohort) {
117
-        this.cohort = cohort;
118
-    }
119
-
120
     public void setEmployer(Employer employer) {
116
     public void setEmployer(Employer employer) {
121
         this.employer = employer;
117
         this.employer = employer;
122
     }
118
     }
123
 
119
 
124
-    public Employer getEmployer() {
125
-        return employer;
120
+    public Cohort getCohort() {
121
+        return cohort;
126
     }
122
     }
127
 
123
 
128
-    public UserProfile employer(Employer employer) {
129
-        this.employer = employer;
124
+    public UserProfile cohort(Cohort cohort) {
125
+        this.cohort = cohort;
130
         return this;
126
         return this;
131
     }
127
     }
132
 
128
 
129
+    public void setCohort(Cohort cohort) {
130
+        this.cohort = cohort;
131
+    }
132
+    // jhipster-needle-entity-add-getters-setters - JHipster will add getters and setters here, do not remove
133
+
133
     @Override
134
     @Override
134
     public boolean equals(Object o) {
135
     public boolean equals(Object o) {
135
         if (this == o) {
136
         if (this == o) {

+ 0
- 4
src/main/java/rocks/zipcode/io/repository/PostRepository.java View File

4
 import org.springframework.data.jpa.repository.*;
4
 import org.springframework.data.jpa.repository.*;
5
 import org.springframework.stereotype.Repository;
5
 import org.springframework.stereotype.Repository;
6
 
6
 
7
-import java.util.List;
8
 
7
 
9
 /**
8
 /**
10
  * Spring Data  repository for the Post entity.
9
  * Spring Data  repository for the Post entity.
13
 @Repository
12
 @Repository
14
 public interface PostRepository extends JpaRepository<Post, Long> {
13
 public interface PostRepository extends JpaRepository<Post, Long> {
15
 
14
 
16
-    @Query("select post from Post post where post.poster.login = ?#{principal.username}")
17
-    List<Post> findByPosterIsCurrentUser();
18
-
19
 }
15
 }

+ 0
- 8
src/main/resources/config/liquibase/changelog/20181217184612_added_entity_UserProfile.xml View File

22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
23
                 <constraints primaryKey="true" nullable="false"/>
23
                 <constraints primaryKey="true" nullable="false"/>
24
             </column>
24
             </column>
25
-            <column name="profile_id" type="bigint">
26
-                <constraints nullable="true" />
27
-            </column>
28
-
29
             <column name="first_name" type="varchar(255)">
25
             <column name="first_name" type="varchar(255)">
30
                 <constraints nullable="true" />
26
                 <constraints nullable="true" />
31
             </column>
27
             </column>
39
             </column>
35
             </column>
40
             <column name="user_id" type="bigint">
36
             <column name="user_id" type="bigint">
41
                 <constraints unique="true" nullable="true" uniqueConstraintName="ux_user_profile_user_id" />
37
                 <constraints unique="true" nullable="true" uniqueConstraintName="ux_user_profile_user_id" />
42
-            </column>            <column name="cohort_id" type="bigint">
43
-                <constraints unique="true" nullable="true" uniqueConstraintName="ux_user_profile_cohort_id" />
44
-            </column>            <column name="employer_id" type="bigint">
45
-                <constraints unique="true" nullable="true" uniqueConstraintName="ux_user_profile_employer_id" />
46
             </column>
38
             </column>
47
             <column name="employer_id" type="bigint">
39
             <column name="employer_id" type="bigint">
48
                 <constraints nullable="true" />
40
                 <constraints nullable="true" />

+ 0
- 12
src/main/resources/config/liquibase/changelog/20181217184612_added_entity_constraints_UserProfile.xml View File

14
                                  referencedColumnNames="id"
14
                                  referencedColumnNames="id"
15
                                  referencedTableName="jhi_user"/>
15
                                  referencedTableName="jhi_user"/>
16
 
16
 
17
-        <addForeignKeyConstraint baseColumnNames="cohort_id"
18
-                                 baseTableName="user_profile"
19
-                                 constraintName="fk_user_profile_cohort_id"
20
-                                 referencedColumnNames="id"
21
-                                 referencedTableName="cohort"/>
22
-
23
-        <addForeignKeyConstraint baseColumnNames="employer_id"
24
-                                 baseTableName="user_profile"
25
-                                 constraintName="fk_user_profile_employer_id"
26
-                                 referencedColumnNames="id"
27
-                                 referencedTableName="employer"/>
28
-
29
         <addForeignKeyConstraint baseColumnNames="employer_id"
17
         <addForeignKeyConstraint baseColumnNames="employer_id"
30
                                  baseTableName="user_profile"
18
                                  baseTableName="user_profile"
31
                                  constraintName="fk_user_profile_employer_id"
19
                                  constraintName="fk_user_profile_employer_id"

+ 0
- 4
src/main/resources/config/liquibase/changelog/20181217184613_added_entity_Cohort.xml View File

22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
23
                 <constraints primaryKey="true" nullable="false"/>
23
                 <constraints primaryKey="true" nullable="false"/>
24
             </column>
24
             </column>
25
-            <column name="cohort_id" type="double">
26
-                <constraints nullable="true" />
27
-            </column>
28
-
29
             <column name="grad_date" type="varchar(255)">
25
             <column name="grad_date" type="varchar(255)">
30
                 <constraints nullable="true" />
26
                 <constraints nullable="true" />
31
             </column>
27
             </column>

+ 0
- 4
src/main/resources/config/liquibase/changelog/20181217184614_added_entity_Employer.xml View File

22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
23
                 <constraints primaryKey="true" nullable="false"/>
23
                 <constraints primaryKey="true" nullable="false"/>
24
             </column>
24
             </column>
25
-            <column name="employer_id" type="bigint">
26
-                <constraints nullable="true" />
27
-            </column>
28
-
29
             <column name="company_name" type="varchar(255)">
25
             <column name="company_name" type="varchar(255)">
30
                 <constraints nullable="true" />
26
                 <constraints nullable="true" />
31
             </column>
27
             </column>

+ 4
- 8
src/main/resources/config/liquibase/changelog/20181217184615_added_entity_Post.xml View File

22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
23
                 <constraints primaryKey="true" nullable="false"/>
23
                 <constraints primaryKey="true" nullable="false"/>
24
             </column>
24
             </column>
25
-            <column name="post_id" type="bigint">
26
-                <constraints nullable="true" />
27
-            </column>
28
-
29
             <column name="jhi_timestamp" type="date">
25
             <column name="jhi_timestamp" type="date">
30
                 <constraints nullable="true" />
26
                 <constraints nullable="true" />
31
             </column>
27
             </column>
37
             <column name="likes" type="varchar(255)">
33
             <column name="likes" type="varchar(255)">
38
                 <constraints nullable="true" />
34
                 <constraints nullable="true" />
39
             </column>
35
             </column>
36
+
40
             <column name="poster_id" type="bigint">
37
             <column name="poster_id" type="bigint">
41
-                <constraints unique="true" nullable="true" uniqueConstraintName="ux_post_poster_id" />
42
-            </column>            <column name="privacy_setting_id" type="bigint">
43
-                <constraints unique="true" nullable="true" uniqueConstraintName="ux_post_privacy_setting_id" />
38
+                <constraints nullable="true" />
44
             </column>
39
             </column>
45
-            <column name="poster_id" type="bigint">
40
+
41
+            <column name="privacy_setting_id" type="bigint">
46
                 <constraints nullable="true" />
42
                 <constraints nullable="true" />
47
             </column>
43
             </column>
48
 
44
 

+ 1
- 7
src/main/resources/config/liquibase/changelog/20181217184615_added_entity_constraints_Post.xml View File

12
                                  baseTableName="post"
12
                                  baseTableName="post"
13
                                  constraintName="fk_post_poster_id"
13
                                  constraintName="fk_post_poster_id"
14
                                  referencedColumnNames="id"
14
                                  referencedColumnNames="id"
15
-                                 referencedTableName="jhi_user"/>
15
+                                 referencedTableName="user_profile"/>
16
 
16
 
17
         <addForeignKeyConstraint baseColumnNames="privacy_setting_id"
17
         <addForeignKeyConstraint baseColumnNames="privacy_setting_id"
18
                                  baseTableName="post"
18
                                  baseTableName="post"
20
                                  referencedColumnNames="id"
20
                                  referencedColumnNames="id"
21
                                  referencedTableName="privacy"/>
21
                                  referencedTableName="privacy"/>
22
 
22
 
23
-        <addForeignKeyConstraint baseColumnNames="poster_id"
24
-                                 baseTableName="post"
25
-                                 constraintName="fk_post_poster_id"
26
-                                 referencedColumnNames="id"
27
-                                 referencedTableName="jhi_user"/>
28
-
29
     </changeSet>
23
     </changeSet>
30
 </databaseChangeLog>
24
 </databaseChangeLog>

+ 0
- 4
src/main/resources/config/liquibase/changelog/20181217184616_added_entity_Privacy.xml View File

22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
22
             <column name="id" type="bigint" autoIncrement="${autoIncrement}">
23
                 <constraints primaryKey="true" nullable="false"/>
23
                 <constraints primaryKey="true" nullable="false"/>
24
             </column>
24
             </column>
25
-            <column name="privacy_id" type="bigint">
26
-                <constraints nullable="true" />
27
-            </column>
28
-
29
             <column name="public_view" type="bit">
25
             <column name="public_view" type="bit">
30
                 <constraints nullable="true" />
26
                 <constraints nullable="true" />
31
             </column>
27
             </column>

+ 0
- 4
src/main/webapp/app/entities/cohort/cohort-detail.component.html View File

5
             <hr>
5
             <hr>
6
             <jhi-alert-error></jhi-alert-error>
6
             <jhi-alert-error></jhi-alert-error>
7
             <dl class="row-md jh-entity-details">
7
             <dl class="row-md jh-entity-details">
8
-                <dt><span jhiTranslate="zipConnectApp.cohort.cohortId">Cohort Id</span></dt>
9
-                <dd>
10
-                    <span>{{cohort.cohortId}}</span>
11
-                </dd>
12
                 <dt><span jhiTranslate="zipConnectApp.cohort.gradDate">Grad Date</span></dt>
8
                 <dt><span jhiTranslate="zipConnectApp.cohort.gradDate">Grad Date</span></dt>
13
                 <dd>
9
                 <dd>
14
                     <span>{{cohort.gradDate}}</span>
10
                     <span>{{cohort.gradDate}}</span>

+ 0
- 5
src/main/webapp/app/entities/cohort/cohort-update.component.html View File

10
                         [(ngModel)]="cohort.id" readonly />
10
                         [(ngModel)]="cohort.id" readonly />
11
                 </div>
11
                 </div>
12
                 <div class="form-group">
12
                 <div class="form-group">
13
-                    <label class="form-control-label" jhiTranslate="zipConnectApp.cohort.cohortId" for="field_cohortId">Cohort Id</label>
14
-                    <input type="number" class="form-control" name="cohortId" id="field_cohortId"
15
-                        [(ngModel)]="cohort.cohortId" />
16
-                </div>
17
-                <div class="form-group">
18
                     <label class="form-control-label" jhiTranslate="zipConnectApp.cohort.gradDate" for="field_gradDate">Grad Date</label>
13
                     <label class="form-control-label" jhiTranslate="zipConnectApp.cohort.gradDate" for="field_gradDate">Grad Date</label>
19
                     <input type="text" class="form-control" name="gradDate" id="field_gradDate"
14
                     <input type="text" class="form-control" name="gradDate" id="field_gradDate"
20
                         [(ngModel)]="cohort.gradDate" />
15
                         [(ngModel)]="cohort.gradDate" />

+ 0
- 2
src/main/webapp/app/entities/cohort/cohort.component.html View File

15
             <thead>
15
             <thead>
16
             <tr>
16
             <tr>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
18
-            <th><span jhiTranslate="zipConnectApp.cohort.cohortId">Cohort Id</span></th>
19
             <th><span jhiTranslate="zipConnectApp.cohort.gradDate">Grad Date</span></th>
18
             <th><span jhiTranslate="zipConnectApp.cohort.gradDate">Grad Date</span></th>
20
             <th></th>
19
             <th></th>
21
             </tr>
20
             </tr>
23
             <tbody>
22
             <tbody>
24
             <tr *ngFor="let cohort of cohorts ;trackBy: trackId">
23
             <tr *ngFor="let cohort of cohorts ;trackBy: trackId">
25
                 <td><a [routerLink]="['/cohort', cohort.id, 'view' ]">{{cohort.id}}</a></td>
24
                 <td><a [routerLink]="['/cohort', cohort.id, 'view' ]">{{cohort.id}}</a></td>
26
-                <td>{{cohort.cohortId}}</td>
27
                 <td>{{cohort.gradDate}}</td>
25
                 <td>{{cohort.gradDate}}</td>
28
                 <td class="text-right">
26
                 <td class="text-right">
29
                     <div class="btn-group flex-btn-group-container">
27
                     <div class="btn-group flex-btn-group-container">

+ 0
- 4
src/main/webapp/app/entities/employer/employer-detail.component.html View File

5
             <hr>
5
             <hr>
6
             <jhi-alert-error></jhi-alert-error>
6
             <jhi-alert-error></jhi-alert-error>
7
             <dl class="row-md jh-entity-details">
7
             <dl class="row-md jh-entity-details">
8
-                <dt><span jhiTranslate="zipConnectApp.employer.employerId">Employer Id</span></dt>
9
-                <dd>
10
-                    <span>{{employer.employerId}}</span>
11
-                </dd>
12
                 <dt><span jhiTranslate="zipConnectApp.employer.companyName">Company Name</span></dt>
8
                 <dt><span jhiTranslate="zipConnectApp.employer.companyName">Company Name</span></dt>
13
                 <dd>
9
                 <dd>
14
                     <span>{{employer.companyName}}</span>
10
                     <span>{{employer.companyName}}</span>

+ 0
- 5
src/main/webapp/app/entities/employer/employer-update.component.html View File

10
                         [(ngModel)]="employer.id" readonly />
10
                         [(ngModel)]="employer.id" readonly />
11
                 </div>
11
                 </div>
12
                 <div class="form-group">
12
                 <div class="form-group">
13
-                    <label class="form-control-label" jhiTranslate="zipConnectApp.employer.employerId" for="field_employerId">Employer Id</label>
14
-                    <input type="number" class="form-control" name="employerId" id="field_employerId"
15
-                        [(ngModel)]="employer.employerId" />
16
-                </div>
17
-                <div class="form-group">
18
                     <label class="form-control-label" jhiTranslate="zipConnectApp.employer.companyName" for="field_companyName">Company Name</label>
13
                     <label class="form-control-label" jhiTranslate="zipConnectApp.employer.companyName" for="field_companyName">Company Name</label>
19
                     <input type="text" class="form-control" name="companyName" id="field_companyName"
14
                     <input type="text" class="form-control" name="companyName" id="field_companyName"
20
                         [(ngModel)]="employer.companyName" />
15
                         [(ngModel)]="employer.companyName" />

+ 0
- 2
src/main/webapp/app/entities/employer/employer.component.html View File

15
             <thead>
15
             <thead>
16
             <tr>
16
             <tr>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
18
-            <th><span jhiTranslate="zipConnectApp.employer.employerId">Employer Id</span></th>
19
             <th><span jhiTranslate="zipConnectApp.employer.companyName">Company Name</span></th>
18
             <th><span jhiTranslate="zipConnectApp.employer.companyName">Company Name</span></th>
20
             <th><span jhiTranslate="zipConnectApp.employer.city">City</span></th>
19
             <th><span jhiTranslate="zipConnectApp.employer.city">City</span></th>
21
             <th><span jhiTranslate="zipConnectApp.employer.state">State</span></th>
20
             <th><span jhiTranslate="zipConnectApp.employer.state">State</span></th>
25
             <tbody>
24
             <tbody>
26
             <tr *ngFor="let employer of employers ;trackBy: trackId">
25
             <tr *ngFor="let employer of employers ;trackBy: trackId">
27
                 <td><a [routerLink]="['/employer', employer.id, 'view' ]">{{employer.id}}</a></td>
26
                 <td><a [routerLink]="['/employer', employer.id, 'view' ]">{{employer.id}}</a></td>
28
-                <td>{{employer.employerId}}</td>
29
                 <td>{{employer.companyName}}</td>
27
                 <td>{{employer.companyName}}</td>
30
                 <td>{{employer.city}}</td>
28
                 <td>{{employer.city}}</td>
31
                 <td>{{employer.state}}</td>
29
                 <td>{{employer.state}}</td>

+ 3
- 9
src/main/webapp/app/entities/post/post-detail.component.html View File

5
             <hr>
5
             <hr>
6
             <jhi-alert-error></jhi-alert-error>
6
             <jhi-alert-error></jhi-alert-error>
7
             <dl class="row-md jh-entity-details">
7
             <dl class="row-md jh-entity-details">
8
-                <dt><span jhiTranslate="zipConnectApp.post.postId">Post Id</span></dt>
9
-                <dd>
10
-                    <span>{{post.postId}}</span>
11
-                </dd>
12
                 <dt><span jhiTranslate="zipConnectApp.post.timestamp">Timestamp</span></dt>
8
                 <dt><span jhiTranslate="zipConnectApp.post.timestamp">Timestamp</span></dt>
13
                 <dd>
9
                 <dd>
14
                     <span>{{post.timestamp}}</span>
10
                     <span>{{post.timestamp}}</span>
23
                 </dd>
19
                 </dd>
24
                 <dt><span jhiTranslate="zipConnectApp.post.poster">Poster</span></dt>
20
                 <dt><span jhiTranslate="zipConnectApp.post.poster">Poster</span></dt>
25
                 <dd>
21
                 <dd>
26
-                    {{post.poster?.id}}
22
+                    <div *ngIf="post.poster">
23
+                        <a [routerLink]="['/user-profile', post.poster?.id, 'view']">{{post.poster?.id}}</a>
24
+                    </div>
27
                 </dd>
25
                 </dd>
28
                 <dt><span jhiTranslate="zipConnectApp.post.privacySetting">Privacy Setting</span></dt>
26
                 <dt><span jhiTranslate="zipConnectApp.post.privacySetting">Privacy Setting</span></dt>
29
                 <dd>
27
                 <dd>
31
                         <a [routerLink]="['/privacy', post.privacySetting?.id, 'view']">{{post.privacySetting?.id}}</a>
29
                         <a [routerLink]="['/privacy', post.privacySetting?.id, 'view']">{{post.privacySetting?.id}}</a>
32
                     </div>
30
                     </div>
33
                 </dd>
31
                 </dd>
34
-                <dt><span jhiTranslate="zipConnectApp.post.poster">Poster</span></dt>
35
-                <dd>
36
-                    {{post.poster?.id}}
37
-                </dd>
38
             </dl>
32
             </dl>
39
 
33
 
40
             <button type="submit"
34
             <button type="submit"

+ 3
- 15
src/main/webapp/app/entities/post/post-update.component.html View File

10
                         [(ngModel)]="post.id" readonly />
10
                         [(ngModel)]="post.id" readonly />
11
                 </div>
11
                 </div>
12
                 <div class="form-group">
12
                 <div class="form-group">
13
-                    <label class="form-control-label" jhiTranslate="zipConnectApp.post.postId" for="field_postId">Post Id</label>
14
-                    <input type="number" class="form-control" name="postId" id="field_postId"
15
-                        [(ngModel)]="post.postId" />
16
-                </div>
17
-                <div class="form-group">
18
                     <label class="form-control-label" jhiTranslate="zipConnectApp.post.timestamp" for="field_timestamp">Timestamp</label>
13
                     <label class="form-control-label" jhiTranslate="zipConnectApp.post.timestamp" for="field_timestamp">Timestamp</label>
19
                     <div class="input-group">
14
                     <div class="input-group">
20
                         <input id="field_timestamp" type="text" class="form-control" name="timestamp" ngbDatepicker  #timestampDp="ngbDatepicker" [(ngModel)]="post.timestamp"
15
                         <input id="field_timestamp" type="text" class="form-control" name="timestamp" ngbDatepicker  #timestampDp="ngbDatepicker" [(ngModel)]="post.timestamp"
39
                     <label class="form-control-label" jhiTranslate="zipConnectApp.post.poster" for="field_poster">Poster</label>
34
                     <label class="form-control-label" jhiTranslate="zipConnectApp.post.poster" for="field_poster">Poster</label>
40
                     <select class="form-control" id="field_poster" name="poster" [(ngModel)]="post.poster" >
35
                     <select class="form-control" id="field_poster" name="poster" [(ngModel)]="post.poster" >
41
                         <option [ngValue]="null"></option>
36
                         <option [ngValue]="null"></option>
42
-                        <option [ngValue]="userOption.id === post.poster?.id ? post.poster : userOption" *ngFor="let userOption of users; trackBy: trackUserById">{{userOption.id}}</option>
37
+                        <option [ngValue]="userProfileOption.id === post.poster?.id ? post.poster : userProfileOption" *ngFor="let userProfileOption of userprofiles; trackBy: trackUserProfileById">{{userProfileOption.id}}</option>
43
                     </select>
38
                     </select>
44
                 </div>
39
                 </div>
45
                 <div class="form-group">
40
                 <div class="form-group">
46
                     <label class="form-control-label" jhiTranslate="zipConnectApp.post.privacySetting" for="field_privacySetting">Privacy Setting</label>
41
                     <label class="form-control-label" jhiTranslate="zipConnectApp.post.privacySetting" for="field_privacySetting">Privacy Setting</label>
47
-                    <select class="form-control" id="field_privacySetting" name="privacySetting" [(ngModel)]="post.privacySetting">
48
-                        <option [ngValue]="null"></option>
49
-                        <option [ngValue]="privacyOption.id === post.privacySetting?.id ? post.privacySetting : privacyOption" *ngFor="let privacyOption of privacysettings; trackBy: trackPrivacyById">{{privacyOption.id}}</option>
50
-                    </select>
51
-                </div>
52
-                <div class="form-group">
53
-                    <label class="form-control-label" jhiTranslate="zipConnectApp.post.poster" for="field_poster">Poster</label>
54
-                    <select class="form-control" id="field_poster" name="poster" [(ngModel)]="post.poster" >
42
+                    <select class="form-control" id="field_privacySetting" name="privacySetting" [(ngModel)]="post.privacySetting" >
55
                         <option [ngValue]="null"></option>
43
                         <option [ngValue]="null"></option>
56
-                        <option [ngValue]="userOption.id === post.poster?.id ? post.poster : userOption" *ngFor="let userOption of users; trackBy: trackUserById">{{userOption.id}}</option>
44
+                        <option [ngValue]="privacyOption.id === post.privacySetting?.id ? post.privacySetting : privacyOption" *ngFor="let privacyOption of privacies; trackBy: trackPrivacyById">{{privacyOption.id}}</option>
57
                     </select>
45
                     </select>
58
                 </div>
46
                 </div>
59
             </div>
47
             </div>

+ 11
- 19
src/main/webapp/app/entities/post/post-update.component.ts View File

7
 
7
 
8
 import { IPost } from 'app/shared/model/post.model';
8
 import { IPost } from 'app/shared/model/post.model';
9
 import { PostService } from './post.service';
9
 import { PostService } from './post.service';
10
-import { IUser, UserService } from 'app/core';
10
+import { IUserProfile } from 'app/shared/model/user-profile.model';
11
+import { UserProfileService } from 'app/entities/user-profile';
11
 import { IPrivacy } from 'app/shared/model/privacy.model';
12
 import { IPrivacy } from 'app/shared/model/privacy.model';
12
 import { PrivacyService } from 'app/entities/privacy';
13
 import { PrivacyService } from 'app/entities/privacy';
13
 
14
 
19
     post: IPost;
20
     post: IPost;
20
     isSaving: boolean;
21
     isSaving: boolean;
21
 
22
 
22
-    users: IUser[];
23
+    userprofiles: IUserProfile[];
23
 
24
 
24
-    privacysettings: IPrivacy[];
25
+    privacies: IPrivacy[];
25
     timestampDp: any;
26
     timestampDp: any;
26
 
27
 
27
     constructor(
28
     constructor(
28
         private jhiAlertService: JhiAlertService,
29
         private jhiAlertService: JhiAlertService,
29
         private postService: PostService,
30
         private postService: PostService,
30
-        private userService: UserService,
31
+        private userProfileService: UserProfileService,
31
         private privacyService: PrivacyService,
32
         private privacyService: PrivacyService,
32
         private activatedRoute: ActivatedRoute
33
         private activatedRoute: ActivatedRoute
33
     ) {}
34
     ) {}
37
         this.activatedRoute.data.subscribe(({ post }) => {
38
         this.activatedRoute.data.subscribe(({ post }) => {
38
             this.post = post;
39
             this.post = post;
39
         });
40
         });
40
-        this.userService.query().subscribe(
41
-            (res: HttpResponse<IUser[]>) => {
42
-                this.users = res.body;
41
+        this.userProfileService.query().subscribe(
42
+            (res: HttpResponse<IUserProfile[]>) => {
43
+                this.userprofiles = res.body;
43
             },
44
             },
44
             (res: HttpErrorResponse) => this.onError(res.message)
45
             (res: HttpErrorResponse) => this.onError(res.message)
45
         );
46
         );
46
-        this.privacyService.query({ filter: 'post-is-null' }).subscribe(
47
+        this.privacyService.query().subscribe(
47
             (res: HttpResponse<IPrivacy[]>) => {
48
             (res: HttpResponse<IPrivacy[]>) => {
48
-                if (!this.post.privacySetting || !this.post.privacySetting.id) {
49
-                    this.privacysettings = res.body;
50
-                } else {
51
-                    this.privacyService.find(this.post.privacySetting.id).subscribe(
52
-                        (subRes: HttpResponse<IPrivacy>) => {
53
-                            this.privacysettings = [subRes.body].concat(res.body);
54
-                        },
55
-                        (subRes: HttpErrorResponse) => this.onError(subRes.message)
56
-                    );
57
-                }
49
+                this.privacies = res.body;
58
             },
50
             },
59
             (res: HttpErrorResponse) => this.onError(res.message)
51
             (res: HttpErrorResponse) => this.onError(res.message)
60
         );
52
         );
90
         this.jhiAlertService.error(errorMessage, null, null);
82
         this.jhiAlertService.error(errorMessage, null, null);
91
     }
83
     }
92
 
84
 
93
-    trackUserById(index: number, item: IUser) {
85
+    trackUserProfileById(index: number, item: IUserProfile) {
94
         return item.id;
86
         return item.id;
95
     }
87
     }
96
 
88
 

+ 3
- 7
src/main/webapp/app/entities/post/post.component.html View File

15
             <thead>
15
             <thead>
16
             <tr>
16
             <tr>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
18
-            <th><span jhiTranslate="zipConnectApp.post.postId">Post Id</span></th>
19
             <th><span jhiTranslate="zipConnectApp.post.timestamp">Timestamp</span></th>
18
             <th><span jhiTranslate="zipConnectApp.post.timestamp">Timestamp</span></th>
20
             <th><span jhiTranslate="zipConnectApp.post.content">Content</span></th>
19
             <th><span jhiTranslate="zipConnectApp.post.content">Content</span></th>
21
             <th><span jhiTranslate="zipConnectApp.post.likes">Likes</span></th>
20
             <th><span jhiTranslate="zipConnectApp.post.likes">Likes</span></th>
22
             <th><span jhiTranslate="zipConnectApp.post.poster">Poster</span></th>
21
             <th><span jhiTranslate="zipConnectApp.post.poster">Poster</span></th>
23
             <th><span jhiTranslate="zipConnectApp.post.privacySetting">Privacy Setting</span></th>
22
             <th><span jhiTranslate="zipConnectApp.post.privacySetting">Privacy Setting</span></th>
24
-            <th><span jhiTranslate="zipConnectApp.post.poster">Poster</span></th>
25
             <th></th>
23
             <th></th>
26
             </tr>
24
             </tr>
27
             </thead>
25
             </thead>
28
             <tbody>
26
             <tbody>
29
             <tr *ngFor="let post of posts ;trackBy: trackId">
27
             <tr *ngFor="let post of posts ;trackBy: trackId">
30
                 <td><a [routerLink]="['/post', post.id, 'view' ]">{{post.id}}</a></td>
28
                 <td><a [routerLink]="['/post', post.id, 'view' ]">{{post.id}}</a></td>
31
-                <td>{{post.postId}}</td>
32
                 <td>{{post.timestamp | date:'mediumDate'}}</td>
29
                 <td>{{post.timestamp | date:'mediumDate'}}</td>
33
                 <td>{{post.content}}</td>
30
                 <td>{{post.content}}</td>
34
                 <td>{{post.likes}}</td>
31
                 <td>{{post.likes}}</td>
35
                 <td>
32
                 <td>
36
-                    {{post.poster?.id}}
33
+                    <div *ngIf="post.poster">
34
+                        <a [routerLink]="['../user-profile', post.poster?.id, 'view' ]" >{{post.poster?.id}}</a>
35
+                    </div>
37
                 </td>
36
                 </td>
38
                 <td>
37
                 <td>
39
                     <div *ngIf="post.privacySetting">
38
                     <div *ngIf="post.privacySetting">
40
                         <a [routerLink]="['../privacy', post.privacySetting?.id, 'view' ]" >{{post.privacySetting?.id}}</a>
39
                         <a [routerLink]="['../privacy', post.privacySetting?.id, 'view' ]" >{{post.privacySetting?.id}}</a>
41
                     </div>
40
                     </div>
42
                 </td>
41
                 </td>
43
-                <td>
44
-                    {{post.poster?.id}}
45
-                </td>
46
                 <td class="text-right">
42
                 <td class="text-right">
47
                     <div class="btn-group flex-btn-group-container">
43
                     <div class="btn-group flex-btn-group-container">
48
                         <button type="submit"
44
                         <button type="submit"

+ 1
- 2
src/main/webapp/app/entities/post/post.module.ts View File

2
 import { RouterModule } from '@angular/router';
2
 import { RouterModule } from '@angular/router';
3
 
3
 
4
 import { ZipConnectSharedModule } from 'app/shared';
4
 import { ZipConnectSharedModule } from 'app/shared';
5
-import { ZipConnectAdminModule } from 'app/admin/admin.module';
6
 import {
5
 import {
7
     PostComponent,
6
     PostComponent,
8
     PostDetailComponent,
7
     PostDetailComponent,
16
 const ENTITY_STATES = [...postRoute, ...postPopupRoute];
15
 const ENTITY_STATES = [...postRoute, ...postPopupRoute];
17
 
16
 
18
 @NgModule({
17
 @NgModule({
19
-    imports: [ZipConnectSharedModule, ZipConnectAdminModule, RouterModule.forChild(ENTITY_STATES)],
18
+    imports: [ZipConnectSharedModule, RouterModule.forChild(ENTITY_STATES)],
20
     declarations: [PostComponent, PostDetailComponent, PostUpdateComponent, PostDeleteDialogComponent, PostDeletePopupComponent],
19
     declarations: [PostComponent, PostDetailComponent, PostUpdateComponent, PostDeleteDialogComponent, PostDeletePopupComponent],
21
     entryComponents: [PostComponent, PostUpdateComponent, PostDeleteDialogComponent, PostDeletePopupComponent],
20
     entryComponents: [PostComponent, PostUpdateComponent, PostDeleteDialogComponent, PostDeletePopupComponent],
22
     schemas: [CUSTOM_ELEMENTS_SCHEMA]
21
     schemas: [CUSTOM_ELEMENTS_SCHEMA]

+ 0
- 4
src/main/webapp/app/entities/privacy/privacy-detail.component.html View File

5
             <hr>
5
             <hr>
6
             <jhi-alert-error></jhi-alert-error>
6
             <jhi-alert-error></jhi-alert-error>
7
             <dl class="row-md jh-entity-details">
7
             <dl class="row-md jh-entity-details">
8
-                <dt><span jhiTranslate="zipConnectApp.privacy.privacyId">Privacy Id</span></dt>
9
-                <dd>
10
-                    <span>{{privacy.privacyId}}</span>
11
-                </dd>
12
                 <dt><span jhiTranslate="zipConnectApp.privacy.publicView">Public View</span></dt>
8
                 <dt><span jhiTranslate="zipConnectApp.privacy.publicView">Public View</span></dt>
13
                 <dd>
9
                 <dd>
14
                     <span>{{privacy.publicView}}</span>
10
                     <span>{{privacy.publicView}}</span>

+ 0
- 5
src/main/webapp/app/entities/privacy/privacy-update.component.html View File

10
                         [(ngModel)]="privacy.id" readonly />
10
                         [(ngModel)]="privacy.id" readonly />
11
                 </div>
11
                 </div>
12
                 <div class="form-group">
12
                 <div class="form-group">
13
-                    <label class="form-control-label" jhiTranslate="zipConnectApp.privacy.privacyId" for="field_privacyId">Privacy Id</label>
14
-                    <input type="number" class="form-control" name="privacyId" id="field_privacyId"
15
-                        [(ngModel)]="privacy.privacyId" />
16
-                </div>
17
-                <div class="form-group">
18
                     <label class="form-control-label" jhiTranslate="zipConnectApp.privacy.publicView" for="field_publicView">Public View</label>
13
                     <label class="form-control-label" jhiTranslate="zipConnectApp.privacy.publicView" for="field_publicView">Public View</label>
19
                     <input type="checkbox" class="form-control" name="publicView" id="field_publicView"
14
                     <input type="checkbox" class="form-control" name="publicView" id="field_publicView"
20
                         [(ngModel)]="privacy.publicView" />
15
                         [(ngModel)]="privacy.publicView" />

+ 0
- 2
src/main/webapp/app/entities/privacy/privacy.component.html View File

15
             <thead>
15
             <thead>
16
             <tr>
16
             <tr>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
18
-            <th><span jhiTranslate="zipConnectApp.privacy.privacyId">Privacy Id</span></th>
19
             <th><span jhiTranslate="zipConnectApp.privacy.publicView">Public View</span></th>
18
             <th><span jhiTranslate="zipConnectApp.privacy.publicView">Public View</span></th>
20
             <th><span jhiTranslate="zipConnectApp.privacy.cohortView">Cohort View</span></th>
19
             <th><span jhiTranslate="zipConnectApp.privacy.cohortView">Cohort View</span></th>
21
             <th><span jhiTranslate="zipConnectApp.privacy.employerView">Employer View</span></th>
20
             <th><span jhiTranslate="zipConnectApp.privacy.employerView">Employer View</span></th>
25
             <tbody>
24
             <tbody>
26
             <tr *ngFor="let privacy of privacies ;trackBy: trackId">
25
             <tr *ngFor="let privacy of privacies ;trackBy: trackId">
27
                 <td><a [routerLink]="['/privacy', privacy.id, 'view' ]">{{privacy.id}}</a></td>
26
                 <td><a [routerLink]="['/privacy', privacy.id, 'view' ]">{{privacy.id}}</a></td>
28
-                <td>{{privacy.privacyId}}</td>
29
                 <td>{{privacy.publicView}}</td>
27
                 <td>{{privacy.publicView}}</td>
30
                 <td>{{privacy.cohortView}}</td>
28
                 <td>{{privacy.cohortView}}</td>
31
                 <td>{{privacy.employerView}}</td>
29
                 <td>{{privacy.employerView}}</td>

+ 0
- 16
src/main/webapp/app/entities/user-profile/user-profile-detail.component.html View File

5
             <hr>
5
             <hr>
6
             <jhi-alert-error></jhi-alert-error>
6
             <jhi-alert-error></jhi-alert-error>
7
             <dl class="row-md jh-entity-details">
7
             <dl class="row-md jh-entity-details">
8
-                <dt><span jhiTranslate="zipConnectApp.userProfile.profileId">Profile Id</span></dt>
9
-                <dd>
10
-                    <span>{{userProfile.profileId}}</span>
11
-                </dd>
12
                 <dt><span jhiTranslate="zipConnectApp.userProfile.firstName">First Name</span></dt>
8
                 <dt><span jhiTranslate="zipConnectApp.userProfile.firstName">First Name</span></dt>
13
                 <dd>
9
                 <dd>
14
                     <span>{{userProfile.firstName}}</span>
10
                     <span>{{userProfile.firstName}}</span>
25
                 <dd>
21
                 <dd>
26
                     {{userProfile.user?.id}}
22
                     {{userProfile.user?.id}}
27
                 </dd>
23
                 </dd>
28
-                <dt><span jhiTranslate="zipConnectApp.userProfile.cohort">Cohort</span></dt>
29
-                <dd>
30
-                    <div *ngIf="userProfile.cohort">
31
-                        <a [routerLink]="['/cohort', userProfile.cohort?.id, 'view']">{{userProfile.cohort?.id}}</a>
32
-                    </div>
33
-                </dd>
34
-                <dt><span jhiTranslate="zipConnectApp.userProfile.employer">Employer</span></dt>
35
-                <dd>
36
-                    <div *ngIf="userProfile.employer">
37
-                        <a [routerLink]="['/employer', userProfile.employer?.id, 'view']">{{userProfile.employer?.id}}</a>
38
-                    </div>
39
-                </dd>
40
                 <dt><span jhiTranslate="zipConnectApp.userProfile.employer">Employer</span></dt>
24
                 <dt><span jhiTranslate="zipConnectApp.userProfile.employer">Employer</span></dt>
41
                 <dd>
25
                 <dd>
42
                     <div *ngIf="userProfile.employer">
26
                     <div *ngIf="userProfile.employer">

+ 0
- 5
src/main/webapp/app/entities/user-profile/user-profile-update.component.html View File

10
                         [(ngModel)]="userProfile.id" readonly />
10
                         [(ngModel)]="userProfile.id" readonly />
11
                 </div>
11
                 </div>
12
                 <div class="form-group">
12
                 <div class="form-group">
13
-                    <label class="form-control-label" jhiTranslate="zipConnectApp.userProfile.profileId" for="field_profileId">Profile Id</label>
14
-                    <input type="number" class="form-control" name="profileId" id="field_profileId"
15
-                        [(ngModel)]="userProfile.profileId" />
16
-                </div>
17
-                <div class="form-group">
18
                     <label class="form-control-label" jhiTranslate="zipConnectApp.userProfile.firstName" for="field_firstName">First Name</label>
13
                     <label class="form-control-label" jhiTranslate="zipConnectApp.userProfile.firstName" for="field_firstName">First Name</label>
19
                     <input type="text" class="form-control" name="firstName" id="field_firstName"
14
                     <input type="text" class="form-control" name="firstName" id="field_firstName"
20
                         [(ngModel)]="userProfile.firstName" />
15
                         [(ngModel)]="userProfile.firstName" />

+ 7
- 37
src/main/webapp/app/entities/user-profile/user-profile-update.component.ts View File

7
 import { IUserProfile } from 'app/shared/model/user-profile.model';
7
 import { IUserProfile } from 'app/shared/model/user-profile.model';
8
 import { UserProfileService } from './user-profile.service';
8
 import { UserProfileService } from './user-profile.service';
9
 import { IUser, UserService } from 'app/core';
9
 import { IUser, UserService } from 'app/core';
10
-import { ICohort } from 'app/shared/model/cohort.model';
11
-import { CohortService } from 'app/entities/cohort';
12
 import { IEmployer } from 'app/shared/model/employer.model';
10
 import { IEmployer } from 'app/shared/model/employer.model';
13
 import { EmployerService } from 'app/entities/employer';
11
 import { EmployerService } from 'app/entities/employer';
12
+import { ICohort } from 'app/shared/model/cohort.model';
13
+import { CohortService } from 'app/entities/cohort';
14
 
14
 
15
 @Component({
15
 @Component({
16
     selector: 'jhi-user-profile-update',
16
     selector: 'jhi-user-profile-update',
22
 
22
 
23
     users: IUser[];
23
     users: IUser[];
24
 
24
 
25
-    cohorts: ICohort[];
26
-
27
     employers: IEmployer[];
25
     employers: IEmployer[];
28
 
26
 
27
+    cohorts: ICohort[];
28
+
29
     constructor(
29
     constructor(
30
         private jhiAlertService: JhiAlertService,
30
         private jhiAlertService: JhiAlertService,
31
         private userProfileService: UserProfileService,
31
         private userProfileService: UserProfileService,
32
         private userService: UserService,
32
         private userService: UserService,
33
-        private cohortService: CohortService,
34
         private employerService: EmployerService,
33
         private employerService: EmployerService,
34
+        private cohortService: CohortService,
35
         private activatedRoute: ActivatedRoute
35
         private activatedRoute: ActivatedRoute
36
     ) {}
36
     ) {}
37
 
37
 
46
             },
46
             },
47
             (res: HttpErrorResponse) => this.onError(res.message)
47
             (res: HttpErrorResponse) => this.onError(res.message)
48
         );
48
         );
49
-        this.cohortService.query({ filter: 'userprofile-is-null' }).subscribe(
50
-            (res: HttpResponse<ICohort[]>) => {
51
-                if (!this.userProfile.cohort || !this.userProfile.cohort.id) {
52
-                    this.cohorts = res.body;
53
-                } else {
54
-                    this.cohortService.find(this.userProfile.cohort.id).subscribe(
55
-                        (subRes: HttpResponse<ICohort>) => {
56
-                            this.cohorts = [subRes.body].concat(res.body);
57
-                        },
58
-                        (subRes: HttpErrorResponse) => this.onError(subRes.message)
59
-                    );
60
-                }
61
-            },
62
-            (res: HttpErrorResponse) => this.onError(res.message)
63
-        );
64
-        this.employerService.query({ filter: 'userprofile-is-null' }).subscribe(
65
-            (res: HttpResponse<IEmployer[]>) => {
66
-                if (!this.userProfile.employer || !this.userProfile.employer.id) {
67
-                    this.employers = res.body;
68
-                } else {
69
-                    this.employerService.find(this.userProfile.employer.id).subscribe(
70
-                        (subRes: HttpResponse<IEmployer>) => {
71
-                            this.employers = [subRes.body].concat(res.body);
72
-                        },
73
-                        (subRes: HttpErrorResponse) => this.onError(subRes.message)
74
-                    );
75
-                }
76
-            },
77
-            (res: HttpErrorResponse) => this.onError(res.message)
78
-        );
79
         this.employerService.query().subscribe(
49
         this.employerService.query().subscribe(
80
             (res: HttpResponse<IEmployer[]>) => {
50
             (res: HttpResponse<IEmployer[]>) => {
81
                 this.employers = res.body;
51
                 this.employers = res.body;
124
         return item.id;
94
         return item.id;
125
     }
95
     }
126
 
96
 
127
-    trackCohortById(index: number, item: ICohort) {
97
+    trackEmployerById(index: number, item: IEmployer) {
128
         return item.id;
98
         return item.id;
129
     }
99
     }
130
 
100
 
131
-    trackEmployerById(index: number, item: IEmployer) {
101
+    trackCohortById(index: number, item: ICohort) {
132
         return item.id;
102
         return item.id;
133
     }
103
     }
134
 }
104
 }

+ 0
- 14
src/main/webapp/app/entities/user-profile/user-profile.component.html View File

15
             <thead>
15
             <thead>
16
             <tr>
16
             <tr>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
17
             <th><span jhiTranslate="global.field.id">ID</span></th>
18
-            <th><span jhiTranslate="zipConnectApp.userProfile.profileId">Profile Id</span></th>
19
             <th><span jhiTranslate="zipConnectApp.userProfile.firstName">First Name</span></th>
18
             <th><span jhiTranslate="zipConnectApp.userProfile.firstName">First Name</span></th>
20
             <th><span jhiTranslate="zipConnectApp.userProfile.lastName">Last Name</span></th>
19
             <th><span jhiTranslate="zipConnectApp.userProfile.lastName">Last Name</span></th>
21
             <th><span jhiTranslate="zipConnectApp.userProfile.userStack">User Stack</span></th>
20
             <th><span jhiTranslate="zipConnectApp.userProfile.userStack">User Stack</span></th>
22
             <th><span jhiTranslate="zipConnectApp.userProfile.user">User</span></th>
21
             <th><span jhiTranslate="zipConnectApp.userProfile.user">User</span></th>
23
-            <th><span jhiTranslate="zipConnectApp.userProfile.cohort">Cohort</span></th>
24
-            <th><span jhiTranslate="zipConnectApp.userProfile.employer">Employer</span></th>
25
             <th><span jhiTranslate="zipConnectApp.userProfile.employer">Employer</span></th>
22
             <th><span jhiTranslate="zipConnectApp.userProfile.employer">Employer</span></th>
26
             <th><span jhiTranslate="zipConnectApp.userProfile.cohort">Cohort</span></th>
23
             <th><span jhiTranslate="zipConnectApp.userProfile.cohort">Cohort</span></th>
27
             <th></th>
24
             <th></th>
30
             <tbody>
27
             <tbody>
31
             <tr *ngFor="let userProfile of userProfiles ;trackBy: trackId">
28
             <tr *ngFor="let userProfile of userProfiles ;trackBy: trackId">
32
                 <td><a [routerLink]="['/user-profile', userProfile.id, 'view' ]">{{userProfile.id}}</a></td>
29
                 <td><a [routerLink]="['/user-profile', userProfile.id, 'view' ]">{{userProfile.id}}</a></td>
33
-                <td>{{userProfile.profileId}}</td>
34
                 <td>{{userProfile.firstName}}</td>
30
                 <td>{{userProfile.firstName}}</td>
35
                 <td>{{userProfile.lastName}}</td>
31
                 <td>{{userProfile.lastName}}</td>
36
                 <td>{{userProfile.userStack}}</td>
32
                 <td>{{userProfile.userStack}}</td>
38
                     {{userProfile.user?.id}}
34
                     {{userProfile.user?.id}}
39
                 </td>
35
                 </td>
40
                 <td>
36
                 <td>
41
-                    <div *ngIf="userProfile.cohort">
42
-                        <a [routerLink]="['../cohort', userProfile.cohort?.id, 'view' ]" >{{userProfile.cohort?.id}}</a>
43
-                    </div>
44
-                </td>
45
-                <td>
46
-                    <div *ngIf="userProfile.employer">
47
-                        <a [routerLink]="['../employer', userProfile.employer?.id, 'view' ]" >{{userProfile.employer?.id}}</a>
48
-                    </div>
49
-                </td>
50
-                <td>
51
                     <div *ngIf="userProfile.employer">
37
                     <div *ngIf="userProfile.employer">
52
                         <a [routerLink]="['../employer', userProfile.employer?.id, 'view' ]" >{{userProfile.employer?.id}}</a>
38
                         <a [routerLink]="['../employer', userProfile.employer?.id, 'view' ]" >{{userProfile.employer?.id}}</a>
53
                     </div>
39
                     </div>

+ 0
- 1
src/main/webapp/app/shared/model/cohort.model.ts View File

1
 export interface ICohort {
1
 export interface ICohort {
2
     id?: number;
2
     id?: number;
3
-    cohortId?: number;
4
     gradDate?: string;
3
     gradDate?: string;
5
 }
4
 }
6
 
5
 

+ 0
- 1
src/main/webapp/app/shared/model/employer.model.ts View File

1
 export interface IEmployer {
1
 export interface IEmployer {
2
     id?: number;
2
     id?: number;
3
-    employerId?: number;
4
     companyName?: string;
3
     companyName?: string;
5
     city?: string;
4
     city?: string;
6
     state?: string;
5
     state?: string;

+ 3
- 3
src/main/webapp/app/shared/model/post.model.ts View File

1
 import { Moment } from 'moment';
1
 import { Moment } from 'moment';
2
-import { IUser } from 'app/core/user/user.model';
2
+import { IUserProfile } from 'app/shared/model//user-profile.model';
3
 import { IPrivacy } from 'app/shared/model//privacy.model';
3
 import { IPrivacy } from 'app/shared/model//privacy.model';
4
 
4
 
5
 export interface IPost {
5
 export interface IPost {
7
     timestamp?: Moment;
7
     timestamp?: Moment;
8
     content?: string;
8
     content?: string;
9
     likes?: string;
9
     likes?: string;
10
-    poster?: IUser;
10
+    poster?: IUserProfile;
11
     privacySetting?: IPrivacy;
11
     privacySetting?: IPrivacy;
12
 }
12
 }
13
 
13
 
17
         public timestamp?: Moment,
17
         public timestamp?: Moment,
18
         public content?: string,
18
         public content?: string,
19
         public likes?: string,
19
         public likes?: string,
20
-        public poster?: IUser,
20
+        public poster?: IUserProfile,
21
         public privacySetting?: IPrivacy
21
         public privacySetting?: IPrivacy
22
     ) {}
22
     ) {}
23
 }
23
 }

+ 0
- 1
src/main/webapp/app/shared/model/privacy.model.ts View File

1
 export interface IPrivacy {
1
 export interface IPrivacy {
2
     id?: number;
2
     id?: number;
3
-    privacyId?: number;
4
     publicView?: boolean;
3
     publicView?: boolean;
5
     cohortView?: boolean;
4
     cohortView?: boolean;
6
     employerView?: boolean;
5
     employerView?: boolean;

+ 4
- 4
src/main/webapp/app/shared/model/user-profile.model.ts View File

1
 import { IUser } from 'app/core/user/user.model';
1
 import { IUser } from 'app/core/user/user.model';
2
-import { ICohort } from 'app/shared/model//cohort.model';
3
 import { IEmployer } from 'app/shared/model//employer.model';
2
 import { IEmployer } from 'app/shared/model//employer.model';
3
+import { ICohort } from 'app/shared/model//cohort.model';
4
 
4
 
5
 export interface IUserProfile {
5
 export interface IUserProfile {
6
     id?: number;
6
     id?: number;
8
     lastName?: string;
8
     lastName?: string;
9
     userStack?: string;
9
     userStack?: string;
10
     user?: IUser;
10
     user?: IUser;
11
-    cohort?: ICohort;
12
     employer?: IEmployer;
11
     employer?: IEmployer;
12
+    cohort?: ICohort;
13
 }
13
 }
14
 
14
 
15
 export class UserProfile implements IUserProfile {
15
 export class UserProfile implements IUserProfile {
19
         public lastName?: string,
19
         public lastName?: string,
20
         public userStack?: string,
20
         public userStack?: string,
21
         public user?: IUser,
21
         public user?: IUser,
22
-        public cohort?: ICohort,
23
-        public employer?: IEmployer
22
+        public employer?: IEmployer,
23
+        public cohort?: ICohort
24
     ) {}
24
     ) {}
25
 }
25
 }

+ 0
- 1
src/main/webapp/i18n/en/cohort.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Cohort"
16
                 "title": "Cohort"
17
             },
17
             },
18
-            "cohortId": "Cohort Id",
19
             "gradDate": "Grad Date"
18
             "gradDate": "Grad Date"
20
         }
19
         }
21
     }
20
     }

+ 0
- 1
src/main/webapp/i18n/en/employer.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Employer"
16
                 "title": "Employer"
17
             },
17
             },
18
-            "employerId": "Employer Id",
19
             "companyName": "Company Name",
18
             "companyName": "Company Name",
20
             "city": "City",
19
             "city": "City",
21
             "state": "State"
20
             "state": "State"

+ 1
- 3
src/main/webapp/i18n/en/post.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Post"
16
                 "title": "Post"
17
             },
17
             },
18
-            "postId": "Post Id",
19
             "timestamp": "Timestamp",
18
             "timestamp": "Timestamp",
20
             "content": "Content",
19
             "content": "Content",
21
             "likes": "Likes",
20
             "likes": "Likes",
22
             "poster": "Poster",
21
             "poster": "Poster",
23
-            "privacySetting": "Privacy Setting",
24
-            "poster": "Poster"
22
+            "privacySetting": "Privacy Setting"
25
         }
23
         }
26
     }
24
     }
27
 }
25
 }

+ 0
- 1
src/main/webapp/i18n/en/privacy.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Privacy"
16
                 "title": "Privacy"
17
             },
17
             },
18
-            "privacyId": "Privacy Id",
19
             "publicView": "Public View",
18
             "publicView": "Public View",
20
             "cohortView": "Cohort View",
19
             "cohortView": "Cohort View",
21
             "employerView": "Employer View"
20
             "employerView": "Employer View"

+ 0
- 3
src/main/webapp/i18n/en/userProfile.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "User Profile"
16
                 "title": "User Profile"
17
             },
17
             },
18
-            "profileId": "Profile Id",
19
             "firstName": "First Name",
18
             "firstName": "First Name",
20
             "lastName": "Last Name",
19
             "lastName": "Last Name",
21
             "userStack": "User Stack",
20
             "userStack": "User Stack",
22
             "user": "User",
21
             "user": "User",
23
-            "cohort": "Cohort",
24
-            "employer": "Employer",
25
             "employer": "Employer",
22
             "employer": "Employer",
26
             "cohort": "Cohort"
23
             "cohort": "Cohort"
27
         }
24
         }

+ 0
- 1
src/main/webapp/i18n/es/cohort.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Cohort"
16
                 "title": "Cohort"
17
             },
17
             },
18
-            "cohortId": "Cohort Id",
19
             "gradDate": "Grad Date"
18
             "gradDate": "Grad Date"
20
         }
19
         }
21
     }
20
     }

+ 0
- 1
src/main/webapp/i18n/es/employer.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Employer"
16
                 "title": "Employer"
17
             },
17
             },
18
-            "employerId": "Employer Id",
19
             "companyName": "Company Name",
18
             "companyName": "Company Name",
20
             "city": "City",
19
             "city": "City",
21
             "state": "State"
20
             "state": "State"

+ 1
- 3
src/main/webapp/i18n/es/post.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Post"
16
                 "title": "Post"
17
             },
17
             },
18
-            "postId": "Post Id",
19
             "timestamp": "Timestamp",
18
             "timestamp": "Timestamp",
20
             "content": "Content",
19
             "content": "Content",
21
             "likes": "Likes",
20
             "likes": "Likes",
22
             "poster": "Poster",
21
             "poster": "Poster",
23
-            "privacySetting": "Privacy Setting",
24
-            "poster": "Poster"
22
+            "privacySetting": "Privacy Setting"
25
         }
23
         }
26
     }
24
     }
27
 }
25
 }

+ 0
- 1
src/main/webapp/i18n/es/privacy.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "Privacy"
16
                 "title": "Privacy"
17
             },
17
             },
18
-            "privacyId": "Privacy Id",
19
             "publicView": "Public View",
18
             "publicView": "Public View",
20
             "cohortView": "Cohort View",
19
             "cohortView": "Cohort View",
21
             "employerView": "Employer View"
20
             "employerView": "Employer View"

+ 0
- 3
src/main/webapp/i18n/es/userProfile.json View File

15
             "detail": {
15
             "detail": {
16
                 "title": "User Profile"
16
                 "title": "User Profile"
17
             },
17
             },
18
-            "profileId": "Profile Id",
19
             "firstName": "First Name",
18
             "firstName": "First Name",
20
             "lastName": "Last Name",
19
             "lastName": "Last Name",
21
             "userStack": "User Stack",
20
             "userStack": "User Stack",
22
             "user": "User",
21
             "user": "User",
23
-            "cohort": "Cohort",
24
-            "employer": "Employer",
25
             "employer": "Employer",
22
             "employer": "Employer",
26
             "cohort": "Cohort"
23
             "cohort": "Cohort"
27
         }
24
         }

+ 0
- 9
src/test/javascript/e2e/entities/cohort/cohort.page-object.ts View File

26
     pageTitle = element(by.id('jhi-cohort-heading'));
26
     pageTitle = element(by.id('jhi-cohort-heading'));
27
     saveButton = element(by.id('save-entity'));
27
     saveButton = element(by.id('save-entity'));
28
     cancelButton = element(by.id('cancel-save'));
28
     cancelButton = element(by.id('cancel-save'));
29
-    cohortIdInput = element(by.id('field_cohortId'));
30
     gradDateInput = element(by.id('field_gradDate'));
29
     gradDateInput = element(by.id('field_gradDate'));
31
 
30
 
32
     async getPageTitle() {
31
     async getPageTitle() {
33
         return this.pageTitle.getAttribute('jhiTranslate');
32
         return this.pageTitle.getAttribute('jhiTranslate');
34
     }
33
     }
35
 
34
 
36
-    async setCohortIdInput(cohortId) {
37
-        await this.cohortIdInput.sendKeys(cohortId);
38
-    }
39
-
40
-    async getCohortIdInput() {
41
-        return this.cohortIdInput.getAttribute('value');
42
-    }
43
-
44
     async setGradDateInput(gradDate) {
35
     async setGradDateInput(gradDate) {
45
         await this.gradDateInput.sendKeys(gradDate);
36
         await this.gradDateInput.sendKeys(gradDate);
46
     }
37
     }

+ 1
- 2
src/test/javascript/e2e/entities/cohort/cohort.spec.ts View File

38
         const nbButtonsBeforeCreate = await cohortComponentsPage.countDeleteButtons();
38
         const nbButtonsBeforeCreate = await cohortComponentsPage.countDeleteButtons();
39
 
39
 
40
         await cohortComponentsPage.clickOnCreateButton();
40
         await cohortComponentsPage.clickOnCreateButton();
41
-        await promise.all([cohortUpdatePage.setCohortIdInput('5'), cohortUpdatePage.setGradDateInput('gradDate')]);
42
-        expect(await cohortUpdatePage.getCohortIdInput()).to.eq('5');
41
+        await promise.all([cohortUpdatePage.setGradDateInput('gradDate')]);
43
         expect(await cohortUpdatePage.getGradDateInput()).to.eq('gradDate');
42
         expect(await cohortUpdatePage.getGradDateInput()).to.eq('gradDate');
44
         await cohortUpdatePage.save();
43
         await cohortUpdatePage.save();
45
         expect(await cohortUpdatePage.getSaveButton().isPresent()).to.be.false;
44
         expect(await cohortUpdatePage.getSaveButton().isPresent()).to.be.false;

+ 0
- 9
src/test/javascript/e2e/entities/employer/employer.page-object.ts View File

26
     pageTitle = element(by.id('jhi-employer-heading'));
26
     pageTitle = element(by.id('jhi-employer-heading'));
27
     saveButton = element(by.id('save-entity'));
27
     saveButton = element(by.id('save-entity'));
28
     cancelButton = element(by.id('cancel-save'));
28
     cancelButton = element(by.id('cancel-save'));
29
-    employerIdInput = element(by.id('field_employerId'));
30
     companyNameInput = element(by.id('field_companyName'));
29
     companyNameInput = element(by.id('field_companyName'));
31
     cityInput = element(by.id('field_city'));
30
     cityInput = element(by.id('field_city'));
32
     stateInput = element(by.id('field_state'));
31
     stateInput = element(by.id('field_state'));
35
         return this.pageTitle.getAttribute('jhiTranslate');
34
         return this.pageTitle.getAttribute('jhiTranslate');
36
     }
35
     }
37
 
36
 
38
-    async setEmployerIdInput(employerId) {
39
-        await this.employerIdInput.sendKeys(employerId);
40
-    }
41
-
42
-    async getEmployerIdInput() {
43
-        return this.employerIdInput.getAttribute('value');
44
-    }
45
-
46
     async setCompanyNameInput(companyName) {
37
     async setCompanyNameInput(companyName) {
47
         await this.companyNameInput.sendKeys(companyName);
38
         await this.companyNameInput.sendKeys(companyName);
48
     }
39
     }

+ 0
- 2
src/test/javascript/e2e/entities/employer/employer.spec.ts View File

39
 
39
 
40
         await employerComponentsPage.clickOnCreateButton();
40
         await employerComponentsPage.clickOnCreateButton();
41
         await promise.all([
41
         await promise.all([
42
-            employerUpdatePage.setEmployerIdInput('5'),
43
             employerUpdatePage.setCompanyNameInput('companyName'),
42
             employerUpdatePage.setCompanyNameInput('companyName'),
44
             employerUpdatePage.setCityInput('city'),
43
             employerUpdatePage.setCityInput('city'),
45
             employerUpdatePage.setStateInput('state')
44
             employerUpdatePage.setStateInput('state')
46
         ]);
45
         ]);
47
-        expect(await employerUpdatePage.getEmployerIdInput()).to.eq('5');
48
         expect(await employerUpdatePage.getCompanyNameInput()).to.eq('companyName');
46
         expect(await employerUpdatePage.getCompanyNameInput()).to.eq('companyName');
49
         expect(await employerUpdatePage.getCityInput()).to.eq('city');
47
         expect(await employerUpdatePage.getCityInput()).to.eq('city');
50
         expect(await employerUpdatePage.getStateInput()).to.eq('state');
48
         expect(await employerUpdatePage.getStateInput()).to.eq('state');

+ 12
- 21
src/test/javascript/e2e/entities/post/post.page-object.ts View File

26
     pageTitle = element(by.id('jhi-post-heading'));
26
     pageTitle = element(by.id('jhi-post-heading'));
27
     saveButton = element(by.id('save-entity'));
27
     saveButton = element(by.id('save-entity'));
28
     cancelButton = element(by.id('cancel-save'));
28
     cancelButton = element(by.id('cancel-save'));
29
-    postIdInput = element(by.id('field_postId'));
30
     timestampInput = element(by.id('field_timestamp'));
29
     timestampInput = element(by.id('field_timestamp'));
31
     contentInput = element(by.id('field_content'));
30
     contentInput = element(by.id('field_content'));
32
     likesInput = element(by.id('field_likes'));
31
     likesInput = element(by.id('field_likes'));
37
         return this.pageTitle.getAttribute('jhiTranslate');
36
         return this.pageTitle.getAttribute('jhiTranslate');
38
     }
37
     }
39
 
38
 
40
-    async setPostIdInput(postId) {
41
-        await this.postIdInput.sendKeys(postId);
42
-    }
43
-
44
-    async getPostIdInput() {
45
-        return this.postIdInput.getAttribute('value');
46
-    }
47
-
48
     async setTimestampInput(timestamp) {
39
     async setTimestampInput(timestamp) {
49
         await this.timestampInput.sendKeys(timestamp);
40
         await this.timestampInput.sendKeys(timestamp);
50
     }
41
     }
76
             .click();
67
             .click();
77
     }
68
     }
78
 
69
 
70
+    async posterSelectOption(option) {
71
+        await this.posterSelect.sendKeys(option);
72
+    }
73
+
74
+    getPosterSelect(): ElementFinder {
75
+        return this.posterSelect;
76
+    }
77
+
78
+    async getPosterSelectedOption() {
79
+        return this.posterSelect.element(by.css('option:checked')).getText();
80
+    }
81
+
79
     async privacySettingSelectLastOption() {
82
     async privacySettingSelectLastOption() {
80
         await this.privacySettingSelect
83
         await this.privacySettingSelect
81
             .all(by.tagName('option'))
84
             .all(by.tagName('option'))
95
         return this.privacySettingSelect.element(by.css('option:checked')).getText();
98
         return this.privacySettingSelect.element(by.css('option:checked')).getText();
96
     }
99
     }
97
 
100
 
98
-    async posterSelectOption(option) {
99
-        await this.posterSelect.sendKeys(option);
100
-    }
101
-
102
-    getPosterSelect(): ElementFinder {
103
-        return this.posterSelect;
104
-    }
105
-
106
-    async getPosterSelectedOption() {
107
-        return this.posterSelect.element(by.css('option:checked')).getText();
108
-    }
109
-
110
     async save() {
101
     async save() {
111
         await this.saveButton.click();
102
         await this.saveButton.click();
112
     }
103
     }

+ 1
- 4
src/test/javascript/e2e/entities/post/post.spec.ts View File

39
 
39
 
40
         await postComponentsPage.clickOnCreateButton();
40
         await postComponentsPage.clickOnCreateButton();
41
         await promise.all([
41
         await promise.all([
42
-            postUpdatePage.setPostIdInput('5'),
43
             postUpdatePage.setTimestampInput('2000-12-31'),
42
             postUpdatePage.setTimestampInput('2000-12-31'),
44
             postUpdatePage.setContentInput('content'),
43
             postUpdatePage.setContentInput('content'),
45
             postUpdatePage.setLikesInput('likes'),
44
             postUpdatePage.setLikesInput('likes'),
46
             postUpdatePage.posterSelectLastOption(),
45
             postUpdatePage.posterSelectLastOption(),
47
-            postUpdatePage.privacySettingSelectLastOption(),
48
-            postUpdatePage.posterSelectLastOption()
46
+            postUpdatePage.privacySettingSelectLastOption()
49
         ]);
47
         ]);
50
-        expect(await postUpdatePage.getPostIdInput()).to.eq('5');
51
         expect(await postUpdatePage.getTimestampInput()).to.eq('2000-12-31');
48
         expect(await postUpdatePage.getTimestampInput()).to.eq('2000-12-31');
52
         expect(await postUpdatePage.getContentInput()).to.eq('content');
49
         expect(await postUpdatePage.getContentInput()).to.eq('content');
53
         expect(await postUpdatePage.getLikesInput()).to.eq('likes');
50
         expect(await postUpdatePage.getLikesInput()).to.eq('likes');

+ 0
- 9
src/test/javascript/e2e/entities/privacy/privacy.page-object.ts View File

26
     pageTitle = element(by.id('jhi-privacy-heading'));
26
     pageTitle = element(by.id('jhi-privacy-heading'));
27
     saveButton = element(by.id('save-entity'));
27
     saveButton = element(by.id('save-entity'));
28
     cancelButton = element(by.id('cancel-save'));
28
     cancelButton = element(by.id('cancel-save'));
29
-    privacyIdInput = element(by.id('field_privacyId'));
30
     publicViewInput = element(by.id('field_publicView'));
29
     publicViewInput = element(by.id('field_publicView'));
31
     cohortViewInput = element(by.id('field_cohortView'));
30
     cohortViewInput = element(by.id('field_cohortView'));
32
     employerViewInput = element(by.id('field_employerView'));
31
     employerViewInput = element(by.id('field_employerView'));
35
         return this.pageTitle.getAttribute('jhiTranslate');
34
         return this.pageTitle.getAttribute('jhiTranslate');
36
     }
35
     }
37
 
36
 
38
-    async setPrivacyIdInput(privacyId) {
39
-        await this.privacyIdInput.sendKeys(privacyId);
40
-    }
41
-
42
-    async getPrivacyIdInput() {
43
-        return this.privacyIdInput.getAttribute('value');
44
-    }
45
-
46
     getPublicViewInput() {
37
     getPublicViewInput() {
47
         return this.publicViewInput;
38
         return this.publicViewInput;
48
     }
39
     }

+ 1
- 2
src/test/javascript/e2e/entities/privacy/privacy.spec.ts View File

38
         const nbButtonsBeforeCreate = await privacyComponentsPage.countDeleteButtons();
38
         const nbButtonsBeforeCreate = await privacyComponentsPage.countDeleteButtons();
39
 
39
 
40
         await privacyComponentsPage.clickOnCreateButton();
40
         await privacyComponentsPage.clickOnCreateButton();
41
-        await promise.all([privacyUpdatePage.setPrivacyIdInput('5')]);
42
-        expect(await privacyUpdatePage.getPrivacyIdInput()).to.eq('5');
41
+        await promise.all([]);
43
         const selectedPublicView = privacyUpdatePage.getPublicViewInput();
42
         const selectedPublicView = privacyUpdatePage.getPublicViewInput();
44
         if (await selectedPublicView.isSelected()) {
43
         if (await selectedPublicView.isSelected()) {
45
             await privacyUpdatePage.getPublicViewInput().click();
44
             await privacyUpdatePage.getPublicViewInput().click();

+ 1
- 10
src/test/javascript/e2e/entities/user-profile/user-profile.page-object.ts View File

26
     pageTitle = element(by.id('jhi-user-profile-heading'));
26
     pageTitle = element(by.id('jhi-user-profile-heading'));
27
     saveButton = element(by.id('save-entity'));
27
     saveButton = element(by.id('save-entity'));
28
     cancelButton = element(by.id('cancel-save'));
28
     cancelButton = element(by.id('cancel-save'));
29
-    profileIdInput = element(by.id('field_profileId'));
30
     firstNameInput = element(by.id('field_firstName'));
29
     firstNameInput = element(by.id('field_firstName'));
31
     lastNameInput = element(by.id('field_lastName'));
30
     lastNameInput = element(by.id('field_lastName'));
32
     userStackInput = element(by.id('field_userStack'));
31
     userStackInput = element(by.id('field_userStack'));
33
     userSelect = element(by.id('field_user'));
32
     userSelect = element(by.id('field_user'));
34
-    cohortSelect = element(by.id('field_cohort'));
35
     employerSelect = element(by.id('field_employer'));
33
     employerSelect = element(by.id('field_employer'));
34
+    cohortSelect = element(by.id('field_cohort'));
36
 
35
 
37
     async getPageTitle() {
36
     async getPageTitle() {
38
         return this.pageTitle.getAttribute('jhiTranslate');
37
         return this.pageTitle.getAttribute('jhiTranslate');
39
     }
38
     }
40
 
39
 
41
-    async setProfileIdInput(profileId) {
42
-        await this.profileIdInput.sendKeys(profileId);
43
-    }
44
-
45
-    async getProfileIdInput() {
46
-        return this.profileIdInput.getAttribute('value');
47
-    }
48
-
49
     async setFirstNameInput(firstName) {
40
     async setFirstNameInput(firstName) {
50
         await this.firstNameInput.sendKeys(firstName);
41
         await this.firstNameInput.sendKeys(firstName);
51
     }
42
     }

+ 0
- 4
src/test/javascript/e2e/entities/user-profile/user-profile.spec.ts View File

39
 
39
 
40
         await userProfileComponentsPage.clickOnCreateButton();
40
         await userProfileComponentsPage.clickOnCreateButton();
41
         await promise.all([
41
         await promise.all([
42
-            userProfileUpdatePage.setProfileIdInput('5'),
43
             userProfileUpdatePage.setFirstNameInput('firstName'),
42
             userProfileUpdatePage.setFirstNameInput('firstName'),
44
             userProfileUpdatePage.setLastNameInput('lastName'),
43
             userProfileUpdatePage.setLastNameInput('lastName'),
45
             userProfileUpdatePage.setUserStackInput('userStack'),
44
             userProfileUpdatePage.setUserStackInput('userStack'),
46
             userProfileUpdatePage.userSelectLastOption(),
45
             userProfileUpdatePage.userSelectLastOption(),
47
-            userProfileUpdatePage.cohortSelectLastOption(),
48
-            userProfileUpdatePage.employerSelectLastOption(),
49
             userProfileUpdatePage.employerSelectLastOption(),
46
             userProfileUpdatePage.employerSelectLastOption(),
50
             userProfileUpdatePage.cohortSelectLastOption()
47
             userProfileUpdatePage.cohortSelectLastOption()
51
         ]);
48
         ]);
52
-        expect(await userProfileUpdatePage.getProfileIdInput()).to.eq('5');
53
         expect(await userProfileUpdatePage.getFirstNameInput()).to.eq('firstName');
49
         expect(await userProfileUpdatePage.getFirstNameInput()).to.eq('firstName');
54
         expect(await userProfileUpdatePage.getLastNameInput()).to.eq('lastName');
50
         expect(await userProfileUpdatePage.getLastNameInput()).to.eq('lastName');
55
         expect(await userProfileUpdatePage.getUserStackInput()).to.eq('userStack');
51
         expect(await userProfileUpdatePage.getUserStackInput()).to.eq('userStack');

+ 1
- 3
src/test/javascript/spec/app/entities/cohort/cohort.service.spec.ts View File

21
             service = injector.get(CohortService);
21
             service = injector.get(CohortService);
22
             httpMock = injector.get(HttpTestingController);
22
             httpMock = injector.get(HttpTestingController);
23
 
23
 
24
-            elemDefault = new Cohort(0, 'January 2019');
24
+            elemDefault = new Cohort(0, 'AAAAAAA');
25
         });
25
         });
26
 
26
 
27
         describe('Service methods', async () => {
27
         describe('Service methods', async () => {
55
             it('should update a Cohort', async () => {
55
             it('should update a Cohort', async () => {
56
                 const returnedFromService = Object.assign(
56
                 const returnedFromService = Object.assign(
57
                     {
57
                     {
58
-                        cohortId: 1,
59
                         gradDate: 'BBBBBB'
58
                         gradDate: 'BBBBBB'
60
                     },
59
                     },
61
                     elemDefault
60
                     elemDefault
73
             it('should return a list of Cohort', async () => {
72
             it('should return a list of Cohort', async () => {
74
                 const returnedFromService = Object.assign(
73
                 const returnedFromService = Object.assign(
75
                     {
74
                     {
76
-                        cohortId: 1,
77
                         gradDate: 'BBBBBB'
75
                         gradDate: 'BBBBBB'
78
                     },
76
                     },
79
                     elemDefault
77
                     elemDefault

+ 0
- 2
src/test/javascript/spec/app/entities/employer/employer.service.spec.ts View File

55
             it('should update a Employer', async () => {
55
             it('should update a Employer', async () => {
56
                 const returnedFromService = Object.assign(
56
                 const returnedFromService = Object.assign(
57
                     {
57
                     {
58
-                        employerId: 1,
59
                         companyName: 'BBBBBB',
58
                         companyName: 'BBBBBB',
60
                         city: 'BBBBBB',
59
                         city: 'BBBBBB',
61
                         state: 'BBBBBB'
60
                         state: 'BBBBBB'
75
             it('should return a list of Employer', async () => {
74
             it('should return a list of Employer', async () => {
76
                 const returnedFromService = Object.assign(
75
                 const returnedFromService = Object.assign(
77
                     {
76
                     {
78
-                        employerId: 1,
79
                         companyName: 'BBBBBB',
77
                         companyName: 'BBBBBB',
80
                         city: 'BBBBBB',
78
                         city: 'BBBBBB',
81
                         state: 'BBBBBB'
79
                         state: 'BBBBBB'

+ 0
- 2
src/test/javascript/spec/app/entities/post/post.service.spec.ts View File

70
             it('should update a Post', async () => {
70
             it('should update a Post', async () => {
71
                 const returnedFromService = Object.assign(
71
                 const returnedFromService = Object.assign(
72
                     {
72
                     {
73
-                        postId: 1,
74
                         timestamp: currentDate.format(DATE_FORMAT),
73
                         timestamp: currentDate.format(DATE_FORMAT),
75
                         content: 'BBBBBB',
74
                         content: 'BBBBBB',
76
                         likes: 'BBBBBB'
75
                         likes: 'BBBBBB'
95
             it('should return a list of Post', async () => {
94
             it('should return a list of Post', async () => {
96
                 const returnedFromService = Object.assign(
95
                 const returnedFromService = Object.assign(
97
                     {
96
                     {
98
-                        postId: 1,
99
                         timestamp: currentDate.format(DATE_FORMAT),
97
                         timestamp: currentDate.format(DATE_FORMAT),
100
                         content: 'BBBBBB',
98
                         content: 'BBBBBB',
101
                         likes: 'BBBBBB'
99
                         likes: 'BBBBBB'

+ 0
- 2
src/test/javascript/spec/app/entities/privacy/privacy.service.spec.ts View File

55
             it('should update a Privacy', async () => {
55
             it('should update a Privacy', async () => {
56
                 const returnedFromService = Object.assign(
56
                 const returnedFromService = Object.assign(
57
                     {
57
                     {
58
-                        privacyId: 1,
59
                         publicView: true,
58
                         publicView: true,
60
                         cohortView: true,
59
                         cohortView: true,
61
                         employerView: true
60
                         employerView: true
75
             it('should return a list of Privacy', async () => {
74
             it('should return a list of Privacy', async () => {
76
                 const returnedFromService = Object.assign(
75
                 const returnedFromService = Object.assign(
77
                     {
76
                     {
78
-                        privacyId: 1,
79
                         publicView: true,
77
                         publicView: true,
80
                         cohortView: true,
78
                         cohortView: true,
81
                         employerView: true
79
                         employerView: true

+ 0
- 2
src/test/javascript/spec/app/entities/user-profile/user-profile.service.spec.ts View File

55
             it('should update a UserProfile', async () => {
55
             it('should update a UserProfile', async () => {
56
                 const returnedFromService = Object.assign(
56
                 const returnedFromService = Object.assign(
57
                     {
57
                     {
58
-                        profileId: 1,
59
                         firstName: 'BBBBBB',
58
                         firstName: 'BBBBBB',
60
                         lastName: 'BBBBBB',
59
                         lastName: 'BBBBBB',
61
                         userStack: 'BBBBBB'
60
                         userStack: 'BBBBBB'
75
             it('should return a list of UserProfile', async () => {
74
             it('should return a list of UserProfile', async () => {
76
                 const returnedFromService = Object.assign(
75
                 const returnedFromService = Object.assign(
77
                     {
76
                     {
78
-                        profileId: 1,
79
                         firstName: 'BBBBBB',
77
                         firstName: 'BBBBBB',
80
                         lastName: 'BBBBBB',
78
                         lastName: 'BBBBBB',
81
                         userStack: 'BBBBBB'
79
                         userStack: 'BBBBBB'