| 26629 |
tejbeer |
1 |
package com.spice.profitmandi.dao.entity.fofo;
|
|
|
2 |
|
|
|
3 |
import java.io.Serializable;
|
|
|
4 |
import java.time.LocalDateTime;
|
|
|
5 |
|
|
|
6 |
import javax.persistence.Column;
|
|
|
7 |
import javax.persistence.Convert;
|
|
|
8 |
import javax.persistence.Entity;
|
|
|
9 |
import javax.persistence.GeneratedValue;
|
|
|
10 |
import javax.persistence.GenerationType;
|
|
|
11 |
import javax.persistence.Id;
|
|
|
12 |
import javax.persistence.Table;
|
|
|
13 |
import javax.persistence.UniqueConstraint;
|
|
|
14 |
|
|
|
15 |
import com.spice.profitmandi.dao.convertor.LocalDateTimeAttributeConverter;
|
|
|
16 |
|
|
|
17 |
@Entity
|
|
|
18 |
@Table(name = "fofo.pending_order_item", schema = "fofo", uniqueConstraints = {
|
|
|
19 |
@UniqueConstraint(name = "UK_ORDER_ID_AND_ITEM_ID", columnNames = { "order_id", "item_id" }) })
|
|
|
20 |
public class PendingOrderItem implements Serializable {
|
|
|
21 |
|
|
|
22 |
private static final long serialVersionUID = 1L;
|
|
|
23 |
|
|
|
24 |
@Id
|
|
|
25 |
@Column(name = "id")
|
|
|
26 |
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
|
|
27 |
private int id;
|
|
|
28 |
|
|
|
29 |
@Column(name = "order_id")
|
|
|
30 |
private int orderId;
|
|
|
31 |
|
|
|
32 |
@Column(name = "item_id")
|
|
|
33 |
private int itemId;
|
|
|
34 |
|
|
|
35 |
@Column(name = "quantity")
|
|
|
36 |
private int quantity;
|
|
|
37 |
|
|
|
38 |
@Column(name = "selling_price")
|
|
|
39 |
private float sellingPrice;
|
|
|
40 |
|
|
|
41 |
@Convert(converter = LocalDateTimeAttributeConverter.class)
|
|
|
42 |
@Column(name = "create_timestamp")
|
|
|
43 |
private LocalDateTime createTimestamp = LocalDateTime.now();
|
|
|
44 |
|
|
|
45 |
public int getId() {
|
|
|
46 |
return id;
|
|
|
47 |
}
|
|
|
48 |
|
|
|
49 |
public void setId(int id) {
|
|
|
50 |
this.id = id;
|
|
|
51 |
}
|
|
|
52 |
|
|
|
53 |
public int getOrderId() {
|
|
|
54 |
return orderId;
|
|
|
55 |
}
|
|
|
56 |
|
|
|
57 |
public void setOrderId(int orderId) {
|
|
|
58 |
this.orderId = orderId;
|
|
|
59 |
}
|
|
|
60 |
|
|
|
61 |
public int getItemId() {
|
|
|
62 |
return itemId;
|
|
|
63 |
}
|
|
|
64 |
|
|
|
65 |
public void setItemId(int itemId) {
|
|
|
66 |
this.itemId = itemId;
|
|
|
67 |
}
|
|
|
68 |
|
|
|
69 |
public int getQuantity() {
|
|
|
70 |
return quantity;
|
|
|
71 |
}
|
|
|
72 |
|
|
|
73 |
public void setQuantity(int quantity) {
|
|
|
74 |
this.quantity = quantity;
|
|
|
75 |
}
|
|
|
76 |
|
|
|
77 |
public float getSellingPrice() {
|
|
|
78 |
return sellingPrice;
|
|
|
79 |
}
|
|
|
80 |
|
|
|
81 |
public void setSellingPrice(float sellingPrice) {
|
|
|
82 |
this.sellingPrice = sellingPrice;
|
|
|
83 |
}
|
|
|
84 |
|
|
|
85 |
public LocalDateTime getCreateTimestamp() {
|
|
|
86 |
return createTimestamp;
|
|
|
87 |
}
|
|
|
88 |
|
|
|
89 |
public void setCreateTimestamp(LocalDateTime createTimestamp) {
|
|
|
90 |
this.createTimestamp = createTimestamp;
|
|
|
91 |
}
|
|
|
92 |
|
|
|
93 |
public static long getSerialversionuid() {
|
|
|
94 |
return serialVersionUID;
|
|
|
95 |
}
|
|
|
96 |
|
|
|
97 |
@Override
|
|
|
98 |
public String toString() {
|
|
|
99 |
return "PendingOrderItem [id=" + id + ", orderId=" + orderId + ", itemId=" + itemId + ", quantity=" + quantity
|
|
|
100 |
+ ", sellingPrice=" + sellingPrice + ", createTimestamp=" + createTimestamp + "]";
|
|
|
101 |
}
|
|
|
102 |
|
|
|
103 |
}
|