Subversion Repositories SmartDukaan

Rev

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

Rev 35275 Rev 35289
Line 1... Line 1...
1
package com.spice.profitmandi.dao.entity.trialUser;
1
package com.spice.profitmandi.dao.entity.fofo;
2
 
2
 
3
import com.spice.profitmandi.common.model.ProfitMandiConstants;
3
import com.spice.profitmandi.common.model.ProfitMandiConstants;
4
 
4
 
5
import javax.persistence.*;
5
import javax.persistence.*;
6
import java.time.LocalDateTime;
6
import java.time.LocalDateTime;
-
 
7
import java.util.Objects;
7
 
8
 
8
@Entity
9
@Entity
9
@Table(name = "fofo.trial_form")
10
@Table(name = "fofo.trial_form")
10
public class TrialOnBoarding {
11
public class TrialForm {
11
 
12
 
12
    @Id
13
    @Id
13
    @GeneratedValue(strategy = GenerationType.IDENTITY)
14
    @GeneratedValue(strategy = GenerationType.IDENTITY)
14
    @Column(name = "id")
15
    @Column(name = "id")
15
    private int id;
16
    private int id;
Line 51... Line 52...
51
    private String state;
52
    private String state;
52
 
53
 
53
    @Column(name = "pincode", nullable = false, length = 6)
54
    @Column(name = "pincode", nullable = false, length = 6)
54
    private String pincode;
55
    private String pincode;
55
 
56
 
56
    // Trial Information
-
 
57
    @Column(name = "trial_start_date")
-
 
58
    private LocalDateTime trialStartDate;
-
 
59
 
-
 
60
    @Column(name = "trial_end_date")
-
 
61
    private LocalDateTime trialEndDate;
-
 
62
 
57
 
63
    @Column(name = "status", length = 20)
58
    @Column(name = "status", length = 20)
-
 
59
    @Enumerated(EnumType.STRING)
64
    private ProfitMandiConstants.Status status; // ACTIVE, EXPIRED, CONVERTED
60
    private ProfitMandiConstants.Status status;
65
 
61
 
66
    @Column(name = "created_on")
62
    @Column(name = "created_on")
67
    private LocalDateTime createdOn;
63
    private LocalDateTime createdOn;
68
 
64
 
69
    @Column(name = "updated_on")
65
    @Column(name = "updated_on")
70
    private LocalDateTime updatedOn;
66
    private LocalDateTime updatedOn;
71
 
67
 
72
    public TrialOnBoarding() {
68
    public TrialForm() {
73
    }
69
    }
74
 
70
 
75
    public TrialOnBoarding(int id, String firstName, String lastName, String email, String mobile, Integer panDocumentId, Integer aadhaarDocumentId, String gstNumber, String businessName, String addressLine1, String addressLine2, String city, String state, String pincode, LocalDateTime trialStartDate, LocalDateTime trialEndDate, ProfitMandiConstants.Status status, LocalDateTime createdOn, LocalDateTime updatedOn) {
71
    public TrialForm(int id, String firstName, String lastName, String email, String mobile, Integer panDocumentId, Integer aadhaarDocumentId, String gstNumber, String businessName, String addressLine1, String addressLine2, String city, String state, String pincode, LocalDateTime trialStartDate, LocalDateTime trialEndDate, ProfitMandiConstants.Status status, LocalDateTime createdOn, LocalDateTime updatedOn) {
76
        this.id = id;
72
        this.id = id;
77
        this.firstName = firstName;
73
        this.firstName = firstName;
78
        this.lastName = lastName;
74
        this.lastName = lastName;
79
        this.email = email;
75
        this.email = email;
80
        this.mobile = mobile;
76
        this.mobile = mobile;
Line 85... Line 81...
85
        this.addressLine1 = addressLine1;
81
        this.addressLine1 = addressLine1;
86
        this.addressLine2 = addressLine2;
82
        this.addressLine2 = addressLine2;
87
        this.city = city;
83
        this.city = city;
88
        this.state = state;
84
        this.state = state;
89
        this.pincode = pincode;
85
        this.pincode = pincode;
90
        this.trialStartDate = trialStartDate;
-
 
91
        this.trialEndDate = trialEndDate;
-
 
92
        this.status = status;
86
        this.status = status;
93
        this.createdOn = createdOn;
87
        this.createdOn = createdOn;
94
        this.updatedOn = updatedOn;
88
        this.updatedOn = updatedOn;
95
    }
89
    }
96
 
90
 
Line 204... Line 198...
204
 
198
 
205
    public void setPincode(String pincode) {
199
    public void setPincode(String pincode) {
206
        this.pincode = pincode;
200
        this.pincode = pincode;
207
    }
201
    }
208
 
202
 
209
    public LocalDateTime getTrialStartDate() {
-
 
210
        return trialStartDate;
-
 
211
    }
-
 
212
 
-
 
213
    public void setTrialStartDate(LocalDateTime trialStartDate) {
-
 
214
        this.trialStartDate = trialStartDate;
-
 
215
    }
-
 
216
 
-
 
217
    public LocalDateTime getTrialEndDate() {
-
 
218
        return trialEndDate;
-
 
219
    }
-
 
220
 
-
 
221
    public void setTrialEndDate(LocalDateTime trialEndDate) {
-
 
222
        this.trialEndDate = trialEndDate;
-
 
223
    }
-
 
224
 
-
 
225
    public ProfitMandiConstants.Status getStatus() {
203
    public ProfitMandiConstants.Status getStatus() {
226
        return status;
204
        return status;
227
    }
205
    }
228
 
206
 
229
    public void setStatus(ProfitMandiConstants.Status status) {
207
    public void setStatus(ProfitMandiConstants.Status status) {
Line 243... Line 221...
243
    }
221
    }
244
 
222
 
245
    public void setUpdatedOn(LocalDateTime updatedOn) {
223
    public void setUpdatedOn(LocalDateTime updatedOn) {
246
        this.updatedOn = updatedOn;
224
        this.updatedOn = updatedOn;
247
    }
225
    }
-
 
226
 
-
 
227
    @Override
-
 
228
    public String toString() {
-
 
229
        return "TrialForm{" +
-
 
230
                "id=" + id +
-
 
231
                ", firstName='" + firstName + '\'' +
-
 
232
                ", lastName='" + lastName + '\'' +
-
 
233
                ", email='" + email + '\'' +
-
 
234
                ", mobile='" + mobile + '\'' +
-
 
235
                ", panDocumentId=" + panDocumentId +
-
 
236
                ", aadhaarDocumentId=" + aadhaarDocumentId +
-
 
237
                ", gstNumber='" + gstNumber + '\'' +
-
 
238
                ", businessName='" + businessName + '\'' +
-
 
239
                ", addressLine1='" + addressLine1 + '\'' +
-
 
240
                ", addressLine2='" + addressLine2 + '\'' +
-
 
241
                ", city='" + city + '\'' +
-
 
242
                ", state='" + state + '\'' +
-
 
243
                ", pincode='" + pincode + '\'' +
-
 
244
                ", status=" + status +
-
 
245
                ", createdOn=" + createdOn +
-
 
246
                ", updatedOn=" + updatedOn +
-
 
247
                '}';
-
 
248
    }
-
 
249
 
-
 
250
    @Override
-
 
251
    public boolean equals(Object o) {
-
 
252
        if (o == null || getClass() != o.getClass()) return false;
-
 
253
        TrialForm trialForm = (TrialForm) o;
-
 
254
        return id == trialForm.id && Objects.equals(firstName, trialForm.firstName) && Objects.equals(lastName, trialForm.lastName) && Objects.equals(email, trialForm.email) && Objects.equals(mobile, trialForm.mobile) && Objects.equals(panDocumentId, trialForm.panDocumentId) && Objects.equals(aadhaarDocumentId, trialForm.aadhaarDocumentId) && Objects.equals(gstNumber, trialForm.gstNumber) && Objects.equals(businessName, trialForm.businessName) && Objects.equals(addressLine1, trialForm.addressLine1) && Objects.equals(addressLine2, trialForm.addressLine2) && Objects.equals(city, trialForm.city) && Objects.equals(state, trialForm.state) && Objects.equals(pincode, trialForm.pincode) && status == trialForm.status && Objects.equals(createdOn, trialForm.createdOn) && Objects.equals(updatedOn, trialForm.updatedOn);
-
 
255
    }
-
 
256
 
-
 
257
    @Override
-
 
258
    public int hashCode() {
-
 
259
        return Objects.hash(id, firstName, lastName, email, mobile, panDocumentId, aadhaarDocumentId, gstNumber, businessName, addressLine1, addressLine2, city, state, pincode, status, createdOn, updatedOn);
-
 
260
    }
248
}
261
}