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:
839 bytes
|
Line | |
---|
1 | package com.example.villadihovo.model.payments;
|
---|
2 |
|
---|
3 | import com.example.villadihovo.model.users.UserTable;
|
---|
4 | import jakarta.persistence.*;
|
---|
5 | import lombok.AllArgsConstructor;
|
---|
6 | import lombok.Data;
|
---|
7 | import lombok.NoArgsConstructor;
|
---|
8 |
|
---|
9 | import java.time.LocalDate;
|
---|
10 |
|
---|
11 | @AllArgsConstructor
|
---|
12 | @NoArgsConstructor
|
---|
13 | @Entity
|
---|
14 | @Data
|
---|
15 | @Inheritance(strategy = InheritanceType.JOINED)
|
---|
16 | @Table(name="payment")
|
---|
17 | public class Payment {
|
---|
18 |
|
---|
19 | @Id
|
---|
20 | @GeneratedValue(strategy = GenerationType.IDENTITY)
|
---|
21 | private int payment_id;
|
---|
22 |
|
---|
23 | @Column(nullable = false)
|
---|
24 | private float total_payment;
|
---|
25 |
|
---|
26 | @Column(nullable = false)
|
---|
27 | private LocalDate pay_date;
|
---|
28 |
|
---|
29 | @Column(nullable = false)
|
---|
30 | private String rec_id;
|
---|
31 |
|
---|
32 | @Column(nullable = false)
|
---|
33 | private String customer_id;
|
---|
34 |
|
---|
35 | @ManyToOne
|
---|
36 | @JoinColumn(name = "user_id", nullable = false)
|
---|
37 | private UserTable user_id;
|
---|
38 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.