Last change
on this file was f7c05a1, checked in by Elena Shulevska <elena.shulevska@…>, 15 months ago |
initial commit of the source code on origin
|
-
Property mode
set to
100644
|
File size:
1.2 KB
|
Line | |
---|
1 | package com.example.villadihovo.model.users;
|
---|
2 |
|
---|
3 | import jakarta.persistence.*;
|
---|
4 | import lombok.AllArgsConstructor;
|
---|
5 | import lombok.Data;
|
---|
6 | import lombok.NoArgsConstructor;
|
---|
7 |
|
---|
8 | @Data
|
---|
9 | @AllArgsConstructor
|
---|
10 | @NoArgsConstructor
|
---|
11 | @Entity
|
---|
12 | @Inheritance(strategy = InheritanceType.JOINED)
|
---|
13 | @Table(name="user_table")
|
---|
14 | public class UserTable {
|
---|
15 |
|
---|
16 | @Id
|
---|
17 | @GeneratedValue(strategy = GenerationType.IDENTITY)
|
---|
18 | private int user_id;
|
---|
19 |
|
---|
20 | @Column(nullable = false, unique = true)
|
---|
21 | private String embg;
|
---|
22 |
|
---|
23 | @Column(nullable = false)
|
---|
24 | private String address;
|
---|
25 |
|
---|
26 | @Column(nullable = false)
|
---|
27 | private String email;
|
---|
28 |
|
---|
29 | @Column(nullable = false)
|
---|
30 | private String password;
|
---|
31 |
|
---|
32 | @Column(nullable = false)
|
---|
33 | private String username;
|
---|
34 |
|
---|
35 | @Column(nullable = false)
|
---|
36 | private String full_name;
|
---|
37 |
|
---|
38 | @Column(nullable = false)
|
---|
39 | private String phone_number;
|
---|
40 |
|
---|
41 | public UserTable(String embg, String address, String email, String password, String username, String full_name, String phone_number) {
|
---|
42 | this.embg = embg;
|
---|
43 | this.address = address;
|
---|
44 | this.email = email;
|
---|
45 | this.password = password;
|
---|
46 | this.username = username;
|
---|
47 | this.full_name = full_name;
|
---|
48 | this.phone_number = phone_number;
|
---|
49 | }
|
---|
50 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.