Subversion Repositories SmartDukaan

Rev

Rev 28339 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
22858 ashik.ali 1
package com.spice.profitmandi.common.model;
21612 ashik.ali 2
 
21680 ashik.ali 3
import java.util.Set;
4
 
21612 ashik.ali 5
public class CreateOrderRequest {
21680 ashik.ali 6
	private CustomCustomer customer;
26821 amit.gupta 7
	private int orderId;
28339 tejbeer 8
	private Integer poId;
9
	private Integer poItemId;
22858 ashik.ali 10
	private Set<CustomFofoOrderItem> fofoOrderItems;
21680 ashik.ali 11
	private Set<CustomPaymentOption> paymentOptions;
36064 aman 12
	private boolean sendInvoiceOnWhatsApp = true;
28339 tejbeer 13
 
36064 aman 14
	public boolean isSendInvoiceOnWhatsApp() {
15
		return sendInvoiceOnWhatsApp;
16
	}
17
 
18
	public void setSendInvoiceOnWhatsApp(boolean sendInvoiceOnWhatsApp) {
19
		this.sendInvoiceOnWhatsApp = sendInvoiceOnWhatsApp;
20
	}
21
 
22244 ashik.ali 22
	public void setCustomer(CustomCustomer customer) {
23
		this.customer = customer;
24
	}
28339 tejbeer 25
 
21680 ashik.ali 26
	public CustomCustomer getCustomer() {
27
		return customer;
21612 ashik.ali 28
	}
28339 tejbeer 29
 
26821 amit.gupta 30
	public int getOrderId() {
31
		return orderId;
32
	}
28339 tejbeer 33
 
26821 amit.gupta 34
	public void setOrderId(int orderId) {
35
		this.orderId = orderId;
36
	}
28339 tejbeer 37
 
24440 amit.gupta 38
	@Override
39
	public int hashCode() {
40
		final int prime = 31;
41
		int result = 1;
42
		result = prime * result + ((customer == null) ? 0 : customer.hashCode());
43
		result = prime * result + ((fofoOrderItems == null) ? 0 : fofoOrderItems.hashCode());
26821 amit.gupta 44
		result = prime * result + orderId;
24440 amit.gupta 45
		result = prime * result + ((paymentOptions == null) ? 0 : paymentOptions.hashCode());
28339 tejbeer 46
		result = prime * result + poId;
47
		result = prime * result + poItemId;
24440 amit.gupta 48
		return result;
22244 ashik.ali 49
	}
28339 tejbeer 50
 
24440 amit.gupta 51
	@Override
52
	public boolean equals(Object obj) {
53
		if (this == obj)
54
			return true;
55
		if (obj == null)
56
			return false;
57
		if (getClass() != obj.getClass())
58
			return false;
59
		CreateOrderRequest other = (CreateOrderRequest) obj;
60
		if (customer == null) {
61
			if (other.customer != null)
62
				return false;
63
		} else if (!customer.equals(other.customer))
64
			return false;
65
		if (fofoOrderItems == null) {
66
			if (other.fofoOrderItems != null)
67
				return false;
68
		} else if (!fofoOrderItems.equals(other.fofoOrderItems))
69
			return false;
26821 amit.gupta 70
		if (orderId != other.orderId)
71
			return false;
24440 amit.gupta 72
		if (paymentOptions == null) {
73
			if (other.paymentOptions != null)
74
				return false;
75
		} else if (!paymentOptions.equals(other.paymentOptions))
76
			return false;
28339 tejbeer 77
		if (poId != other.poId)
78
			return false;
79
		if (poItemId != other.poItemId)
80
			return false;
24440 amit.gupta 81
		return true;
22244 ashik.ali 82
	}
28339 tejbeer 83
 
84
	public Integer getPoId() {
85
		return poId;
86
	}
87
 
88
	public void setPoId(Integer poId) {
89
		this.poId = poId;
90
	}
91
 
92
	public Integer getPoItemId() {
93
		return poItemId;
94
	}
95
 
96
	public void setPoItemId(Integer poItemId) {
97
		this.poItemId = poItemId;
98
	}
99
 
22858 ashik.ali 100
	public Set<CustomFofoOrderItem> getFofoOrderItems() {
101
		return fofoOrderItems;
21612 ashik.ali 102
	}
28339 tejbeer 103
 
22858 ashik.ali 104
	public void setFofoOrderItems(Set<CustomFofoOrderItem> fofoLineItems) {
105
		this.fofoOrderItems = fofoLineItems;
21680 ashik.ali 106
	}
28339 tejbeer 107
 
21680 ashik.ali 108
	public Set<CustomPaymentOption> getPaymentOptions() {
109
		return paymentOptions;
110
	}
28339 tejbeer 111
 
21680 ashik.ali 112
	public void setPaymentOptions(Set<CustomPaymentOption> paymentOptions) {
113
		this.paymentOptions = paymentOptions;
114
	}
28339 tejbeer 115
 
21680 ashik.ali 116
	@Override
117
	public String toString() {
28339 tejbeer 118
		return "CreateOrderRequest [customer=" + customer + ", orderId=" + orderId + ", poId=" + poId + ", poItemId="
36064 aman 119
				+ poItemId + ", fofoOrderItems=" + fofoOrderItems + ", paymentOptions=" + paymentOptions
120
				+ ", sendInvoiceOnWhatsApp=" + sendInvoiceOnWhatsApp + "]";
21680 ashik.ali 121
	}
28339 tejbeer 122
 
21612 ashik.ali 123
}