| 23405 |
amit.gupta |
1 |
package com.spice.profitmandi.dao.entity.fofo;
|
|
|
2 |
|
|
|
3 |
import java.time.LocalDateTime;
|
|
|
4 |
|
|
|
5 |
import javax.persistence.Column;
|
|
|
6 |
import javax.persistence.Convert;
|
|
|
7 |
import javax.persistence.Entity;
|
|
|
8 |
import javax.persistence.EnumType;
|
|
|
9 |
import javax.persistence.Enumerated;
|
|
|
10 |
import javax.persistence.GeneratedValue;
|
|
|
11 |
import javax.persistence.GenerationType;
|
|
|
12 |
import javax.persistence.Id;
|
|
|
13 |
import javax.persistence.Table;
|
|
|
14 |
|
|
|
15 |
import com.spice.profitmandi.common.enumuration.IndentStatus;
|
|
|
16 |
import com.spice.profitmandi.dao.convertor.LocalDateTimeAttributeConverter;
|
|
|
17 |
|
|
|
18 |
@Entity
|
| 31860 |
tejbeer |
19 |
@Table(name = "fofo.indent")
|
| 23405 |
amit.gupta |
20 |
public class Indent {
|
|
|
21 |
|
|
|
22 |
@Override
|
|
|
23 |
public String toString() {
|
|
|
24 |
return "Indent [id=" + id + ", status=" + status + ", fofoId=" + fofoId + ", closedTimestamp=" + closedTimestamp
|
|
|
25 |
+ ", createTimestamp=" + createTimestamp + ", allocatedTimestamp=" + allocatedTimestamp + "]";
|
|
|
26 |
}
|
|
|
27 |
|
|
|
28 |
public LocalDateTime getCreateTimestamp() {
|
|
|
29 |
return createTimestamp;
|
|
|
30 |
}
|
|
|
31 |
|
|
|
32 |
public void setCreateTimestamp(LocalDateTime createTimestamp) {
|
|
|
33 |
this.createTimestamp = createTimestamp;
|
|
|
34 |
}
|
|
|
35 |
|
|
|
36 |
public LocalDateTime getAllocatedTimestamp() {
|
|
|
37 |
return allocatedTimestamp;
|
|
|
38 |
}
|
|
|
39 |
|
|
|
40 |
public void setAllocatedTimestamp(LocalDateTime allocatedTimestamp) {
|
|
|
41 |
this.allocatedTimestamp = allocatedTimestamp;
|
|
|
42 |
}
|
|
|
43 |
|
|
|
44 |
@Id
|
|
|
45 |
@Column(name = "id", columnDefinition = "int(11)")
|
|
|
46 |
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
|
|
47 |
private int id;
|
|
|
48 |
|
|
|
49 |
@Override
|
|
|
50 |
public int hashCode() {
|
|
|
51 |
final int prime = 31;
|
|
|
52 |
int result = 1;
|
|
|
53 |
result = prime * result + id;
|
|
|
54 |
return result;
|
|
|
55 |
}
|
|
|
56 |
|
|
|
57 |
@Override
|
|
|
58 |
public boolean equals(Object obj) {
|
|
|
59 |
if (this == obj)
|
|
|
60 |
return true;
|
|
|
61 |
if (obj == null)
|
|
|
62 |
return false;
|
|
|
63 |
if (getClass() != obj.getClass())
|
|
|
64 |
return false;
|
|
|
65 |
Indent other = (Indent) obj;
|
|
|
66 |
if (id != other.id)
|
|
|
67 |
return false;
|
|
|
68 |
return true;
|
|
|
69 |
}
|
|
|
70 |
|
|
|
71 |
public int getId() {
|
|
|
72 |
return id;
|
|
|
73 |
}
|
|
|
74 |
|
|
|
75 |
public void setId(int id) {
|
|
|
76 |
this.id = id;
|
|
|
77 |
}
|
|
|
78 |
|
|
|
79 |
public int getFofoId() {
|
|
|
80 |
return fofoId;
|
|
|
81 |
}
|
|
|
82 |
|
|
|
83 |
public void setFofoId(int fofoId) {
|
|
|
84 |
this.fofoId = fofoId;
|
|
|
85 |
}
|
|
|
86 |
|
|
|
87 |
public LocalDateTime getClosedTimestamp() {
|
|
|
88 |
return closedTimestamp;
|
|
|
89 |
}
|
|
|
90 |
|
|
|
91 |
public void setClosedTimestamp(LocalDateTime closedTimestamp) {
|
|
|
92 |
this.closedTimestamp = closedTimestamp;
|
|
|
93 |
}
|
|
|
94 |
|
|
|
95 |
@Column(name = "status")
|
|
|
96 |
@Enumerated(EnumType.STRING)
|
|
|
97 |
private IndentStatus status;
|
|
|
98 |
|
|
|
99 |
@Column(name = "fofo_id", unique = true, updatable = false)
|
|
|
100 |
private int fofoId;
|
|
|
101 |
|
|
|
102 |
@Convert(converter = LocalDateTimeAttributeConverter.class)
|
|
|
103 |
@Column(name = "closed_timestamp")
|
|
|
104 |
private LocalDateTime closedTimestamp;
|
|
|
105 |
|
|
|
106 |
@Convert(converter = LocalDateTimeAttributeConverter.class)
|
|
|
107 |
@Column(name = "create_timestamp")
|
|
|
108 |
private LocalDateTime createTimestamp;
|
|
|
109 |
|
|
|
110 |
@Convert(converter = LocalDateTimeAttributeConverter.class)
|
|
|
111 |
@Column(name = "allocated_timestamp")
|
|
|
112 |
private LocalDateTime allocatedTimestamp;
|
|
|
113 |
|
|
|
114 |
public IndentStatus getStatus() {
|
|
|
115 |
return status;
|
|
|
116 |
}
|
|
|
117 |
|
|
|
118 |
public void setStatus(IndentStatus status) {
|
|
|
119 |
this.status = status;
|
|
|
120 |
}
|
|
|
121 |
|
|
|
122 |
}
|