From 71ce7af51d3163c10b44ba5630126e7a5044f788 Mon Sep 17 00:00:00 2001 From: Mark Struchkov Date: Fri, 21 Dec 2018 23:14:50 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9B=D0=BE=D0=B3=D0=B8=D1=80=D0=BE=D0=B2?= =?UTF-8?q?=D0=B0=D0=BD=D0=B8=D0=B5=20=D0=B8=20=D1=81=D0=B2=D1=8F=D0=B7?= =?UTF-8?q?=D1=8C=20=D1=81=20=D0=91=D0=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Добавли логироание Log4j * Настроил тестовую взаимосвязь с БД MySQL --- pom.xml | 18 ++++++++++++++ .../org/sadtech/consultant/dao/NextStage.java | 14 +++++++++++ .../org/sadtech/consultant/dao/SaveStage.java | 16 +++++++++++++ .../consultant/dao/SocialNetworks.java | 18 ++++++++++++++ .../org/sadtech/consultant/dao/Stage.java | 17 +++++++++++++ .../java/org/sadtech/consultant/dao/User.java | 24 +++++++++++++++++++ 6 files changed, 107 insertions(+) create mode 100644 src/main/java/org/sadtech/consultant/dao/NextStage.java create mode 100644 src/main/java/org/sadtech/consultant/dao/SaveStage.java create mode 100644 src/main/java/org/sadtech/consultant/dao/SocialNetworks.java create mode 100644 src/main/java/org/sadtech/consultant/dao/Stage.java create mode 100644 src/main/java/org/sadtech/consultant/dao/User.java diff --git a/pom.xml b/pom.xml index 6f96fe4..b500633 100644 --- a/pom.xml +++ b/pom.xml @@ -11,5 +11,23 @@ consultant-core + + 1.0.2 + 1.18.4 + + + + + javax.persistence + persistence-api + ${persistence.ver} + + + + org.projectlombok + lombok + ${lombok.ver} + + \ No newline at end of file diff --git a/src/main/java/org/sadtech/consultant/dao/NextStage.java b/src/main/java/org/sadtech/consultant/dao/NextStage.java new file mode 100644 index 0000000..9a7947d --- /dev/null +++ b/src/main/java/org/sadtech/consultant/dao/NextStage.java @@ -0,0 +1,14 @@ +package org.sadtech.consultant.dao; + +import lombok.Data; + +import javax.persistence.Entity; + +@Entity +@Data +public class NextStage { + + private long id; + private long idNext; + +} diff --git a/src/main/java/org/sadtech/consultant/dao/SaveStage.java b/src/main/java/org/sadtech/consultant/dao/SaveStage.java new file mode 100644 index 0000000..c80e35e --- /dev/null +++ b/src/main/java/org/sadtech/consultant/dao/SaveStage.java @@ -0,0 +1,16 @@ +package org.sadtech.consultant.dao; + +import lombok.Data; + +import javax.persistence.Entity; +import javax.persistence.Id; + +@Entity +@Data +public class SaveStage { + + @Id + private long id; + private long idStage; + +} diff --git a/src/main/java/org/sadtech/consultant/dao/SocialNetworks.java b/src/main/java/org/sadtech/consultant/dao/SocialNetworks.java new file mode 100644 index 0000000..7dd831a --- /dev/null +++ b/src/main/java/org/sadtech/consultant/dao/SocialNetworks.java @@ -0,0 +1,18 @@ +package org.sadtech.consultant.dao; + +import lombok.Data; + +import javax.persistence.Entity; +import javax.persistence.Id; + +@Data +@Entity +public class SocialNetworks { + + @Id + private long id; + private long idVk; + private long idFacebook; + private long phone; + +} diff --git a/src/main/java/org/sadtech/consultant/dao/Stage.java b/src/main/java/org/sadtech/consultant/dao/Stage.java new file mode 100644 index 0000000..59aa1d7 --- /dev/null +++ b/src/main/java/org/sadtech/consultant/dao/Stage.java @@ -0,0 +1,17 @@ +package org.sadtech.consultant.dao; + +import lombok.Data; + +import javax.persistence.Entity; +import javax.persistence.Id; + +@Entity +@Data +public class Stage { + + @Id + private long id; + private String text; + private String wordKeys; + +} diff --git a/src/main/java/org/sadtech/consultant/dao/User.java b/src/main/java/org/sadtech/consultant/dao/User.java new file mode 100644 index 0000000..cf14046 --- /dev/null +++ b/src/main/java/org/sadtech/consultant/dao/User.java @@ -0,0 +1,24 @@ +package org.sadtech.consultant.dao; + +import lombok.Data; + +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.Id; +import java.util.List; + +@Entity +@Data +public class User { + + @Id + @GeneratedValue + private long id; + private String name; + private String token; + private String lastName; + private String city; + private List socialNetworks; + + +}