Subversion Repositories SmartDukaan

Rev

Rev 28493 | Rev 32222 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
28299 tejbeer 1
package com.spice.profitmandi.dao.entity.warehouse;
2
 
3
import javax.persistence.Column;
4
import javax.persistence.Entity;
5
import javax.persistence.GeneratedValue;
6
import javax.persistence.GenerationType;
7
import javax.persistence.Id;
8
import javax.persistence.Table;
9
 
10
@Entity
32074 tejbeer 11
@Table(name = "warehouse.supplier")
28299 tejbeer 12
public class Supplier {
13
 
32074 tejbeer 14
    @Id
15
    @Column(name = "id", unique = true, updatable = false)
16
    @GeneratedValue(strategy = GenerationType.IDENTITY)
17
    private int id; // required
28493 tejbeer 18
 
32074 tejbeer 19
    private String name; // required
28493 tejbeer 20
 
32074 tejbeer 21
    private String phone; // required
22
    private String fax; // required
23
    private String tin;
24
    private String pan; // required
25
    private String headName; // required
26
    private String headDesignation; // required
27
    private String headEmail; // required
28
    private String contactName; // required
29
    private String contactPhone; // required
30
    private String contactFax; // required
31
    private String contactEmail; // required
32
    private String registeredAddress; // required
33
    private String communicationAddress; // required
34
    private int stateId; // required
35
    private int poValidityLimit; // required
36
    private String gstin; // required
37
    private String tnc;
38
    @Column(name = "status")
39
    private boolean status;
28493 tejbeer 40
 
32074 tejbeer 41
    public boolean isStatus() {
42
        return status;
43
    }
28493 tejbeer 44
 
32074 tejbeer 45
    public void setStatus(boolean status) {
46
        this.status = status;
47
    }
28493 tejbeer 48
 
32074 tejbeer 49
    public int getId() {
50
        return id;
51
    }
28493 tejbeer 52
 
32074 tejbeer 53
    public void setId(int id) {
54
        this.id = id;
55
    }
28493 tejbeer 56
 
32074 tejbeer 57
    public String getName() {
58
        return name;
59
    }
28493 tejbeer 60
 
32074 tejbeer 61
    public void setName(String name) {
62
        this.name = name;
63
    }
28493 tejbeer 64
 
32074 tejbeer 65
    public String getPhone() {
66
        return phone;
67
    }
28493 tejbeer 68
 
32074 tejbeer 69
    public void setPhone(String phone) {
70
        this.phone = phone;
71
    }
28493 tejbeer 72
 
32074 tejbeer 73
    public String getFax() {
74
        return fax;
75
    }
28493 tejbeer 76
 
32074 tejbeer 77
    public void setFax(String fax) {
78
        this.fax = fax;
79
    }
28493 tejbeer 80
 
32074 tejbeer 81
    public String getTin() {
82
        return tin;
83
    }
28493 tejbeer 84
 
32074 tejbeer 85
    public void setTin(String tin) {
86
        this.tin = tin;
87
    }
28493 tejbeer 88
 
32074 tejbeer 89
    public String getPan() {
90
        return pan;
91
    }
28493 tejbeer 92
 
32074 tejbeer 93
    public void setPan(String pan) {
94
        this.pan = pan;
95
    }
28493 tejbeer 96
 
32074 tejbeer 97
    public String getHeadName() {
98
        return headName;
99
    }
28493 tejbeer 100
 
32074 tejbeer 101
    public void setHeadName(String headName) {
102
        this.headName = headName;
103
    }
28493 tejbeer 104
 
32074 tejbeer 105
    public String getHeadDesignation() {
106
        return headDesignation;
107
    }
28493 tejbeer 108
 
32074 tejbeer 109
    public void setHeadDesignation(String headDesignation) {
110
        this.headDesignation = headDesignation;
111
    }
28493 tejbeer 112
 
32074 tejbeer 113
    public String getHeadEmail() {
114
        return headEmail;
115
    }
28493 tejbeer 116
 
32074 tejbeer 117
    public void setHeadEmail(String headEmail) {
118
        this.headEmail = headEmail;
119
    }
28493 tejbeer 120
 
32074 tejbeer 121
    public String getContactName() {
122
        return contactName;
123
    }
28493 tejbeer 124
 
32074 tejbeer 125
    public void setContactName(String contactName) {
126
        this.contactName = contactName;
127
    }
28493 tejbeer 128
 
32074 tejbeer 129
    public String getContactPhone() {
130
        return contactPhone;
131
    }
28493 tejbeer 132
 
32074 tejbeer 133
    public void setContactPhone(String contactPhone) {
134
        this.contactPhone = contactPhone;
135
    }
28493 tejbeer 136
 
32074 tejbeer 137
    public String getContactFax() {
138
        return contactFax;
139
    }
28493 tejbeer 140
 
32074 tejbeer 141
    public void setContactFax(String contactFax) {
142
        this.contactFax = contactFax;
143
    }
28493 tejbeer 144
 
32074 tejbeer 145
    public String getContactEmail() {
146
        return contactEmail;
147
    }
28493 tejbeer 148
 
32074 tejbeer 149
    public void setContactEmail(String contactEmail) {
150
        this.contactEmail = contactEmail;
151
    }
28493 tejbeer 152
 
32074 tejbeer 153
    public String getRegisteredAddress() {
154
        return registeredAddress;
155
    }
28493 tejbeer 156
 
32074 tejbeer 157
    public void setRegisteredAddress(String registeredAddress) {
158
        this.registeredAddress = registeredAddress;
159
    }
28493 tejbeer 160
 
32074 tejbeer 161
    public String getCommunicationAddress() {
162
        return communicationAddress;
163
    }
28493 tejbeer 164
 
32074 tejbeer 165
    public void setCommunicationAddress(String communicationAddress) {
166
        this.communicationAddress = communicationAddress;
167
    }
28493 tejbeer 168
 
32074 tejbeer 169
    public int getStateId() {
170
        return stateId;
171
    }
28493 tejbeer 172
 
32074 tejbeer 173
    public void setStateId(int stateId) {
174
        this.stateId = stateId;
175
    }
28493 tejbeer 176
 
32074 tejbeer 177
    public int getPoValidityLimit() {
178
        return poValidityLimit;
179
    }
28493 tejbeer 180
 
32074 tejbeer 181
    public void setPoValidityLimit(int poValidityLimit) {
182
        this.poValidityLimit = poValidityLimit;
183
    }
28493 tejbeer 184
 
32074 tejbeer 185
    public String getGstin() {
186
        return gstin;
187
    }
28493 tejbeer 188
 
32074 tejbeer 189
    public void setGstin(String gstin) {
190
        this.gstin = gstin;
191
    }
28493 tejbeer 192
 
32074 tejbeer 193
    public String getTnc() {
194
        return tnc;
195
    }
28493 tejbeer 196
 
32074 tejbeer 197
    public void setTnc(String tnc) {
198
        this.tnc = tnc;
199
    }
28493 tejbeer 200
 
32074 tejbeer 201
    public Supplier() {
202
        super();
203
        // TODO Auto-generated constructor stub
204
    }
28493 tejbeer 205
 
32074 tejbeer 206
    @Override
207
    public String toString() {
208
        return "Supplier [id=" + id + ", name=" + name + ", phone=" + phone + ", fax=" + fax + ", tin=" + tin + ", pan=" + pan + ", headName=" + headName + ", headDesignation=" + headDesignation + ", headEmail=" + headEmail + ", contactName=" + contactName + ", contactPhone=" + contactPhone + ", contactFax=" + contactFax + ", contactEmail=" + contactEmail + ", registeredAddress=" + registeredAddress + ", communicationAddress=" + communicationAddress + ", stateId=" + stateId + ", poValidityLimit=" + poValidityLimit + ", gstin=" + gstin + ", tnc=" + tnc + "]";
209
    }
28493 tejbeer 210
 
32074 tejbeer 211
    @Override
212
    public int hashCode() {
213
        final int prime = 31;
214
        int result = 1;
215
        result = prime * result + ((communicationAddress == null) ? 0 : communicationAddress.hashCode());
216
        result = prime * result + ((contactEmail == null) ? 0 : contactEmail.hashCode());
217
        result = prime * result + ((contactFax == null) ? 0 : contactFax.hashCode());
218
        result = prime * result + ((contactName == null) ? 0 : contactName.hashCode());
219
        result = prime * result + ((contactPhone == null) ? 0 : contactPhone.hashCode());
220
        result = prime * result + ((fax == null) ? 0 : fax.hashCode());
221
        result = prime * result + ((gstin == null) ? 0 : gstin.hashCode());
222
        result = prime * result + ((headDesignation == null) ? 0 : headDesignation.hashCode());
223
        result = prime * result + ((headEmail == null) ? 0 : headEmail.hashCode());
224
        result = prime * result + ((headName == null) ? 0 : headName.hashCode());
225
        result = prime * result + id;
226
        result = prime * result + ((name == null) ? 0 : name.hashCode());
227
        result = prime * result + ((pan == null) ? 0 : pan.hashCode());
228
        result = prime * result + ((phone == null) ? 0 : phone.hashCode());
229
        result = prime * result + poValidityLimit;
230
        result = prime * result + ((registeredAddress == null) ? 0 : registeredAddress.hashCode());
231
        result = prime * result + stateId;
232
        result = prime * result + ((tin == null) ? 0 : tin.hashCode());
233
        result = prime * result + ((tnc == null) ? 0 : tnc.hashCode());
234
        return result;
235
    }
28493 tejbeer 236
 
32074 tejbeer 237
    @Override
238
    public boolean equals(Object obj) {
239
        if (this == obj)
240
            return true;
241
        if (obj == null)
242
            return false;
243
        if (getClass() != obj.getClass())
244
            return false;
245
        Supplier other = (Supplier) obj;
246
        if (communicationAddress == null) {
247
            if (other.communicationAddress != null)
248
                return false;
249
        } else if (!communicationAddress.equals(other.communicationAddress))
250
            return false;
251
        if (contactEmail == null) {
252
            if (other.contactEmail != null)
253
                return false;
254
        } else if (!contactEmail.equals(other.contactEmail))
255
            return false;
256
        if (contactFax == null) {
257
            if (other.contactFax != null)
258
                return false;
259
        } else if (!contactFax.equals(other.contactFax))
260
            return false;
261
        if (contactName == null) {
262
            if (other.contactName != null)
263
                return false;
264
        } else if (!contactName.equals(other.contactName))
265
            return false;
266
        if (contactPhone == null) {
267
            if (other.contactPhone != null)
268
                return false;
269
        } else if (!contactPhone.equals(other.contactPhone))
270
            return false;
271
        if (fax == null) {
272
            if (other.fax != null)
273
                return false;
274
        } else if (!fax.equals(other.fax))
275
            return false;
276
        if (gstin == null) {
277
            if (other.gstin != null)
278
                return false;
279
        } else if (!gstin.equals(other.gstin))
280
            return false;
281
        if (headDesignation == null) {
282
            if (other.headDesignation != null)
283
                return false;
284
        } else if (!headDesignation.equals(other.headDesignation))
285
            return false;
286
        if (headEmail == null) {
287
            if (other.headEmail != null)
288
                return false;
289
        } else if (!headEmail.equals(other.headEmail))
290
            return false;
291
        if (headName == null) {
292
            if (other.headName != null)
293
                return false;
294
        } else if (!headName.equals(other.headName))
295
            return false;
296
        if (id != other.id)
297
            return false;
298
        if (name == null) {
299
            if (other.name != null)
300
                return false;
301
        } else if (!name.equals(other.name))
302
            return false;
303
        if (pan == null) {
304
            if (other.pan != null)
305
                return false;
306
        } else if (!pan.equals(other.pan))
307
            return false;
308
        if (phone == null) {
309
            if (other.phone != null)
310
                return false;
311
        } else if (!phone.equals(other.phone))
312
            return false;
313
        if (poValidityLimit != other.poValidityLimit)
314
            return false;
315
        if (registeredAddress == null) {
316
            if (other.registeredAddress != null)
317
                return false;
318
        } else if (!registeredAddress.equals(other.registeredAddress))
319
            return false;
320
        if (stateId != other.stateId)
321
            return false;
322
        if (tin == null) {
323
            if (other.tin != null)
324
                return false;
325
        } else if (!tin.equals(other.tin))
326
            return false;
327
        if (tnc == null) {
328
            if (other.tnc != null)
329
                return false;
330
        } else if (!tnc.equals(other.tnc))
331
            return false;
332
        return true;
333
    }
28299 tejbeer 334
 
335
}