| 31760 |
amit.gupta |
1 |
package com.spice.profitmandi.model;
|
|
|
2 |
|
|
|
3 |
import java.util.Map;
|
|
|
4 |
import java.util.Objects;
|
|
|
5 |
|
|
|
6 |
public class WarehouseItemQtyModel {
|
|
|
7 |
|
|
|
8 |
Map<Integer, Integer> vendorWarehouseNetAvailability;
|
|
|
9 |
private int itemId;
|
|
|
10 |
private int warehouseFrom;
|
| 33257 |
ranu |
11 |
String warehouseFromName;
|
| 31760 |
amit.gupta |
12 |
private int availability;
|
|
|
13 |
private int reserved;
|
|
|
14 |
private int netAvailability;
|
|
|
15 |
private int vendorWarehouseId;
|
|
|
16 |
private int fulfillQty;
|
| 31766 |
amit.gupta |
17 |
private int newColorQty;
|
| 31760 |
amit.gupta |
18 |
|
| 31766 |
amit.gupta |
19 |
@Override
|
|
|
20 |
public String toString() {
|
|
|
21 |
return "WarehouseItemQtyModel{" +
|
|
|
22 |
"vendorWarehouseNetAvailability=" + vendorWarehouseNetAvailability +
|
|
|
23 |
", itemId=" + itemId +
|
|
|
24 |
", warehouseFrom=" + warehouseFrom +
|
| 33257 |
ranu |
25 |
", warehouseFromName=" + warehouseFromName +
|
| 31766 |
amit.gupta |
26 |
", availability=" + availability +
|
|
|
27 |
", reserved=" + reserved +
|
|
|
28 |
", netAvailability=" + netAvailability +
|
|
|
29 |
", vendorWarehouseId=" + vendorWarehouseId +
|
|
|
30 |
", fulfillQty=" + fulfillQty +
|
|
|
31 |
", newColorQty=" + newColorQty +
|
|
|
32 |
'}';
|
|
|
33 |
}
|
|
|
34 |
|
|
|
35 |
public int getRemainingQty() {
|
|
|
36 |
return this.netAvailability - this.fulfillQty;
|
|
|
37 |
}
|
|
|
38 |
|
|
|
39 |
public int getNewColorQty() {
|
|
|
40 |
return newColorQty;
|
|
|
41 |
}
|
|
|
42 |
|
|
|
43 |
public void setNewColorQty(int newColorQty) {
|
|
|
44 |
this.newColorQty = newColorQty;
|
|
|
45 |
}
|
|
|
46 |
|
| 31760 |
amit.gupta |
47 |
public WarehouseItemQtyModel(int itemId, int warehouseFrom, int vendorWarehouseId, int availability, int reserved, int netAvailability) {
|
|
|
48 |
this.itemId = itemId;
|
|
|
49 |
this.warehouseFrom = warehouseFrom;
|
|
|
50 |
this.vendorWarehouseId = vendorWarehouseId;
|
|
|
51 |
this.availability = availability;
|
|
|
52 |
this.reserved = reserved;
|
|
|
53 |
this.netAvailability = netAvailability;
|
|
|
54 |
}
|
|
|
55 |
|
| 33396 |
amit.gupta |
56 |
public WarehouseItemQtyModel(int itemId, int vendorWarehouseId, int availability, int reserved, int netAvailability) {
|
|
|
57 |
this.itemId = itemId;
|
|
|
58 |
this.vendorWarehouseId = vendorWarehouseId;
|
|
|
59 |
this.availability = availability;
|
|
|
60 |
this.reserved = reserved;
|
|
|
61 |
this.netAvailability = netAvailability;
|
|
|
62 |
}
|
|
|
63 |
|
| 31760 |
amit.gupta |
64 |
public Map<Integer, Integer> getVendorWarehouseNetAvailability() {
|
|
|
65 |
return vendorWarehouseNetAvailability;
|
|
|
66 |
}
|
|
|
67 |
|
|
|
68 |
public void setVendorWarehouseNetAvailability(Map<Integer, Integer> vendorWarehouseNetAvailability) {
|
|
|
69 |
this.vendorWarehouseNetAvailability = vendorWarehouseNetAvailability;
|
|
|
70 |
}
|
|
|
71 |
|
|
|
72 |
public int getVendorWarehouseId() {
|
|
|
73 |
return vendorWarehouseId;
|
|
|
74 |
}
|
|
|
75 |
|
|
|
76 |
public void setVendorWarehouseId(int vendorWarehouseId) {
|
|
|
77 |
this.vendorWarehouseId = vendorWarehouseId;
|
|
|
78 |
}
|
|
|
79 |
|
|
|
80 |
public int getFulfillQty() {
|
|
|
81 |
return fulfillQty;
|
|
|
82 |
}
|
|
|
83 |
|
|
|
84 |
public void setFulfillQty(int fulfillQty) {
|
|
|
85 |
this.fulfillQty = fulfillQty;
|
|
|
86 |
}
|
|
|
87 |
|
|
|
88 |
@Override
|
|
|
89 |
public boolean equals(Object o) {
|
|
|
90 |
if (this == o) return true;
|
|
|
91 |
if (o == null || getClass() != o.getClass()) return false;
|
|
|
92 |
WarehouseItemQtyModel that = (WarehouseItemQtyModel) o;
|
| 33257 |
ranu |
93 |
return itemId == that.itemId && warehouseFrom == that.warehouseFrom && warehouseFromName == that.warehouseFromName && availability == that.availability && reserved == that.reserved && netAvailability == that.netAvailability && vendorWarehouseId == that.vendorWarehouseId;
|
| 31760 |
amit.gupta |
94 |
}
|
|
|
95 |
|
|
|
96 |
@Override
|
|
|
97 |
public int hashCode() {
|
| 33257 |
ranu |
98 |
return Objects.hash(itemId, warehouseFrom, warehouseFromName, availability, reserved, netAvailability, vendorWarehouseId);
|
| 31760 |
amit.gupta |
99 |
}
|
|
|
100 |
|
|
|
101 |
public int getNetAvailability() {
|
|
|
102 |
return netAvailability;
|
|
|
103 |
}
|
|
|
104 |
|
|
|
105 |
public void setNetAvailability(int netAvailability) {
|
|
|
106 |
this.netAvailability = netAvailability;
|
|
|
107 |
}
|
|
|
108 |
|
|
|
109 |
public int getAvailability() {
|
|
|
110 |
return availability;
|
|
|
111 |
}
|
|
|
112 |
|
|
|
113 |
public void setAvailability(int availability) {
|
|
|
114 |
this.availability = availability;
|
|
|
115 |
}
|
|
|
116 |
|
|
|
117 |
public int getReserved() {
|
|
|
118 |
return reserved;
|
|
|
119 |
}
|
|
|
120 |
|
|
|
121 |
public void setReserved(int reserved) {
|
|
|
122 |
this.reserved = reserved;
|
|
|
123 |
}
|
|
|
124 |
|
|
|
125 |
public int getItemId() {
|
|
|
126 |
return itemId;
|
|
|
127 |
}
|
|
|
128 |
|
|
|
129 |
public void setItemId(int itemId) {
|
|
|
130 |
this.itemId = itemId;
|
|
|
131 |
}
|
|
|
132 |
|
|
|
133 |
public int getWarehouseFrom() {
|
|
|
134 |
return warehouseFrom;
|
|
|
135 |
}
|
|
|
136 |
|
|
|
137 |
public void setWarehouseFrom(int warehouseFrom) {
|
|
|
138 |
this.warehouseFrom = warehouseFrom;
|
|
|
139 |
}
|
|
|
140 |
|
| 33257 |
ranu |
141 |
public String getWarehouseFromName() {
|
|
|
142 |
return warehouseFromName;
|
|
|
143 |
}
|
|
|
144 |
|
|
|
145 |
public void setWarehouseFromName(String warehouseFromName) {
|
|
|
146 |
this.warehouseFromName = warehouseFromName;
|
|
|
147 |
}
|
| 31760 |
amit.gupta |
148 |
}
|