Subversion Repositories SmartDukaan

Rev

Rev 28395 | Rev 28653 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 28395 Rev 28401
Line 40... Line 40...
40
	
40
	
41
	@Column(name="status")
41
	@Column(name="status")
42
	@Enumerated(EnumType.ORDINAL)
42
	@Enumerated(EnumType.ORDINAL)
43
	private status status;
43
	private status status;
44
	
44
	
45
	@Column(name = "product_group", length = 100)
-
 
46
	private String productGroup;
-
 
47
	
-
 
48
	@Column(name = "model_name", length = 100)
45
	@Column(name = "model_name", length = 100)
49
	private String modelName;
46
	private String modelName;
50
	
47
	
51
	@Column(name = "model_number", length = 100)
48
	@Column(name = "model_number", length = 100)
52
	private String modelNumber;
49
	private String modelNumber;
Line 55... Line 52...
55
	private String color;
52
	private String color;
56
	
53
	
57
	@Column(name="catalog_item_id")
54
	@Column(name="catalog_item_id")
58
	private int catalogItemId;
55
	private int catalogItemId;
59
	
56
	
60
	
-
 
61
	@Column(name="weight")
-
 
62
	private double weight;
-
 
63
	
-
 
64
	@Column(name="category")
57
	@Column(name="category")
65
	private int categoryId;
58
	private int categoryId;
66
	
59
	
67
	public int getCategoryId() {
60
	public int getCategoryId() {
68
		return categoryId;
61
		return categoryId;
Line 79... Line 72...
79
	private String hsnCode;
72
	private String hsnCode;
80
	
73
	
81
	@Column(name = "sellingPrice")
74
	@Column(name = "sellingPrice")
82
	private Float sellingPrice;
75
	private Float sellingPrice;
83
	
76
	
84
	public String getProductGroup() {
-
 
85
		return productGroup;
-
 
86
	}
-
 
87
	public void setProductGroup(String productGroup) {
-
 
88
		this.productGroup = productGroup;
-
 
89
	}
-
 
90
	public int getId() {
77
	public int getId() {
91
		return id;
78
		return id;
92
	}
79
	}
93
	public void setId(int id) {
80
	public void setId(int id) {
94
		this.id = id;
81
		this.id = id;
Line 139... Line 126...
139
	}
126
	}
140
	
127
	
141
	public int getCatalogItemId() {
128
	public int getCatalogItemId() {
142
		return catalogItemId;
129
		return catalogItemId;
143
	}
130
	}
144
	
-
 
145
	public double getWeight() {
-
 
146
		return weight;
-
 
147
	}
-
 
148
	public void setWeight(double weight) {
-
 
149
		this.weight = weight;
-
 
150
	}
-
 
151
	public void setCatalogItemId(int catalogItemId) {
131
	public void setCatalogItemId(int catalogItemId) {
152
		this.catalogItemId = catalogItemId;
132
		this.catalogItemId = catalogItemId;
153
	}
133
	}
154
	
134
	
155
	public Float getSellingPrice() {
135
	public Float getSellingPrice() {
Line 199... Line 179...
199
	
179
	
200
	@Override
180
	@Override
201
	public int hashCode() {
181
	public int hashCode() {
202
		final int prime = 31;
182
		final int prime = 31;
203
		int result = 1;
183
		int result = 1;
204
		result = prime * result + ((brand == null) ? 0 : brand.hashCode());
-
 
205
		result = prime * result + catalogItemId;
-
 
206
		result = prime * result + categoryId;
-
 
207
		result = prime * result + ((color == null) ? 0 : color.hashCode());
-
 
208
		result = prime * result + ((hsnCode == null) ? 0 : hsnCode.hashCode());
-
 
209
		result = prime * result + id;
184
		result = prime * result + id;
210
		result = prime * result + ((modelName == null) ? 0 : modelName.hashCode());
-
 
211
		result = prime * result + ((modelNumber == null) ? 0 : modelNumber.hashCode());
-
 
212
		result = prime * result + ((productGroup == null) ? 0 : productGroup.hashCode());
-
 
213
		result = prime * result + ((sellingPrice == null) ? 0 : sellingPrice.hashCode());
-
 
214
		result = prime * result + ((status == null) ? 0 : status.hashCode());
-
 
215
		result = prime * result + ((type == null) ? 0 : type.hashCode());
-
 
216
		long temp;
-
 
217
		temp = Double.doubleToLongBits(weight);
-
 
218
		result = prime * result + (int) (temp ^ (temp >>> 32));
-
 
219
		return result;
185
		return result;
220
	}
186
	}
221
	@Override
187
	@Override
222
	public boolean equals(Object obj) {
188
	public boolean equals(Object obj) {
223
		if (this == obj)
189
		if (this == obj)
Line 225... Line 191...
225
		if (obj == null)
191
		if (obj == null)
226
			return false;
192
			return false;
227
		if (getClass() != obj.getClass())
193
		if (getClass() != obj.getClass())
228
			return false;
194
			return false;
229
		Item other = (Item) obj;
195
		Item other = (Item) obj;
230
		if (brand == null) {
-
 
231
			if (other.brand != null)
-
 
232
				return false;
-
 
233
		} else if (!brand.equals(other.brand))
-
 
234
			return false;
-
 
235
		if (catalogItemId != other.catalogItemId)
-
 
236
			return false;
-
 
237
		if (categoryId != other.categoryId)
-
 
238
			return false;
-
 
239
		if (color == null) {
-
 
240
			if (other.color != null)
-
 
241
				return false;
-
 
242
		} else if (!color.equals(other.color))
-
 
243
			return false;
-
 
244
		if (hsnCode == null) {
-
 
245
			if (other.hsnCode != null)
-
 
246
				return false;
-
 
247
		} else if (!hsnCode.equals(other.hsnCode))
-
 
248
			return false;
-
 
249
		if (id != other.id)
196
		if (id != other.id)
250
			return false;
197
			return false;
251
		if (modelName == null) {
-
 
252
			if (other.modelName != null)
-
 
253
				return false;
-
 
254
		} else if (!modelName.equals(other.modelName))
-
 
255
			return false;
-
 
256
		if (modelNumber == null) {
-
 
257
			if (other.modelNumber != null)
-
 
258
				return false;
-
 
259
		} else if (!modelNumber.equals(other.modelNumber))
-
 
260
			return false;
-
 
261
		if (productGroup == null) {
-
 
262
			if (other.productGroup != null)
-
 
263
				return false;
-
 
264
		} else if (!productGroup.equals(other.productGroup))
-
 
265
			return false;
-
 
266
		if (sellingPrice == null) {
-
 
267
			if (other.sellingPrice != null)
-
 
268
				return false;
-
 
269
		} else if (!sellingPrice.equals(other.sellingPrice))
-
 
270
			return false;
-
 
271
		if (status != other.status)
-
 
272
			return false;
-
 
273
		if (type != other.type)
-
 
274
			return false;
-
 
275
		if (Double.doubleToLongBits(weight) != Double.doubleToLongBits(other.weight))
-
 
276
			return false;
-
 
277
		return true;
198
		return true;
278
	}
199
	}
279
	@Override
200
	@Override
280
	public String toString() {
201
	public String toString() {
281
		return "Item [id=" + id + ", brand=" + brand + ", status=" + status + ", productGroup=" + productGroup
202
		return "Item [id=" + id + ", brand=" + brand + ", status=" + status + ", modelName=" + modelName
282
				+ ", modelName=" + modelName + ", modelNumber=" + modelNumber + ", color=" + color + ", catalogItemId="
203
				+ ", modelNumber=" + modelNumber + ", color=" + color + ", catalogItemId=" + catalogItemId
283
				+ catalogItemId + ", weight=" + weight + ", categoryId=" + categoryId + ", type=" + type + ", hsnCode="
204
				+ ", categoryId=" + categoryId + ", type=" + type + ", hsnCode=" + hsnCode + ", sellingPrice="
284
				+ hsnCode + ", sellingPrice=" + sellingPrice + "]";
205
				+ sellingPrice + "]";
285
	}
206
	}
286
	public status getStatus() {
207
	public status getStatus() {
287
		return status;
208
		return status;
288
	}
209
	}
289
	public void setStatus(status status) {
210
	public void setStatus(status status) {