| 33436 |
ranu |
1 |
package com.spice.profitmandi.dao.entity.fofo;
|
|
|
2 |
|
|
|
3 |
import java.io.Serializable;
|
|
|
4 |
import java.time.LocalDateTime;
|
|
|
5 |
import java.util.Objects;
|
|
|
6 |
|
|
|
7 |
import javax.persistence.Column;
|
|
|
8 |
import javax.persistence.Convert;
|
|
|
9 |
import javax.persistence.Entity;
|
|
|
10 |
import javax.persistence.GeneratedValue;
|
|
|
11 |
import javax.persistence.GenerationType;
|
|
|
12 |
import javax.persistence.Id;
|
|
|
13 |
import javax.persistence.Table;
|
|
|
14 |
|
|
|
15 |
|
|
|
16 |
import com.spice.profitmandi.dao.convertor.LocalDateTimeAttributeConverter;
|
|
|
17 |
|
|
|
18 |
/**
|
|
|
19 |
* @author amit
|
|
|
20 |
*
|
|
|
21 |
*/
|
|
|
22 |
@Entity
|
|
|
23 |
@Table(name = "fofo.pending_order_plan")
|
|
|
24 |
public class PendingOrderPlan implements Serializable {
|
|
|
25 |
|
|
|
26 |
/**
|
|
|
27 |
*
|
|
|
28 |
*/
|
|
|
29 |
private static final long serialVersionUID = 1L;
|
|
|
30 |
@Id
|
|
|
31 |
@Column(name = "id")
|
|
|
32 |
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
|
|
33 |
private int id;
|
|
|
34 |
|
|
|
35 |
@Column(name = "pending_order_item_id")
|
|
|
36 |
private int pendingOrderItemId;
|
|
|
37 |
|
|
|
38 |
@Column(name = "plan_id")
|
|
|
39 |
private int PlanId;
|
|
|
40 |
|
|
|
41 |
@Column(name = "plan_name")
|
|
|
42 |
private String planName;
|
|
|
43 |
|
|
|
44 |
@Convert(converter = LocalDateTimeAttributeConverter.class)
|
|
|
45 |
@Column(name = "create_timestamp")
|
|
|
46 |
private LocalDateTime createTimestamp = LocalDateTime.now();
|
|
|
47 |
|
|
|
48 |
@Column(name = "premium_price")
|
|
|
49 |
private double premiumPrice;
|
|
|
50 |
|
|
|
51 |
public int getId() {
|
|
|
52 |
return id;
|
|
|
53 |
}
|
|
|
54 |
|
|
|
55 |
public void setId(int id) {
|
|
|
56 |
this.id = id;
|
|
|
57 |
}
|
|
|
58 |
|
|
|
59 |
public int getPendingOrderItemId() {
|
|
|
60 |
return pendingOrderItemId;
|
|
|
61 |
}
|
|
|
62 |
|
|
|
63 |
public void setPendingOrderItemId(int pendingOrderItemId) {
|
|
|
64 |
this.pendingOrderItemId = pendingOrderItemId;
|
|
|
65 |
}
|
|
|
66 |
|
|
|
67 |
public int getPlanId() {
|
|
|
68 |
return PlanId;
|
|
|
69 |
}
|
|
|
70 |
|
|
|
71 |
public void setPlanId(int planId) {
|
|
|
72 |
PlanId = planId;
|
|
|
73 |
}
|
|
|
74 |
|
|
|
75 |
public String getPlanName() {
|
|
|
76 |
return planName;
|
|
|
77 |
}
|
|
|
78 |
|
|
|
79 |
public void setPlanName(String planName) {
|
|
|
80 |
this.planName = planName;
|
|
|
81 |
}
|
|
|
82 |
|
|
|
83 |
public LocalDateTime getCreateTimestamp() {
|
|
|
84 |
return createTimestamp;
|
|
|
85 |
}
|
|
|
86 |
|
|
|
87 |
public void setCreateTimestamp(LocalDateTime createTimestamp) {
|
|
|
88 |
this.createTimestamp = createTimestamp;
|
|
|
89 |
}
|
|
|
90 |
|
|
|
91 |
public double getPremiumPrice() {
|
|
|
92 |
return premiumPrice;
|
|
|
93 |
}
|
|
|
94 |
|
|
|
95 |
public void setPremiumPrice(double premiumPrice) {
|
|
|
96 |
this.premiumPrice = premiumPrice;
|
|
|
97 |
}
|
|
|
98 |
|
|
|
99 |
@Override
|
|
|
100 |
public boolean equals(Object o) {
|
|
|
101 |
if (this == o) return true;
|
|
|
102 |
if (o == null || getClass() != o.getClass()) return false;
|
|
|
103 |
PendingOrderPlan that = (PendingOrderPlan) o;
|
|
|
104 |
return id == that.id && pendingOrderItemId == that.pendingOrderItemId && PlanId == that.PlanId && Double.compare(premiumPrice, that.premiumPrice) == 0 && Objects.equals(planName, that.planName) && Objects.equals(createTimestamp, that.createTimestamp);
|
|
|
105 |
}
|
|
|
106 |
|
|
|
107 |
@Override
|
|
|
108 |
public int hashCode() {
|
|
|
109 |
return Objects.hash(id, pendingOrderItemId, PlanId, planName, createTimestamp, premiumPrice);
|
|
|
110 |
}
|
|
|
111 |
|
|
|
112 |
@Override
|
|
|
113 |
public String toString() {
|
|
|
114 |
return "PendingOrderPlan{" +
|
|
|
115 |
"id=" + id +
|
|
|
116 |
", pendingOrderItemId=" + pendingOrderItemId +
|
|
|
117 |
", PlanId=" + PlanId +
|
|
|
118 |
", planName='" + planName + '\'' +
|
|
|
119 |
", createTimestamp=" + createTimestamp +
|
|
|
120 |
", premiumPrice=" + premiumPrice +
|
|
|
121 |
'}';
|
|
|
122 |
}
|
|
|
123 |
}
|