| 37779 |
amit |
1 |
package com.spice.profitmandi.dao.entity.cs;
|
|
|
2 |
|
|
|
3 |
import com.spice.profitmandi.dao.convertor.LocalDateTimeAttributeConverter;
|
|
|
4 |
|
|
|
5 |
import javax.persistence.*;
|
|
|
6 |
import java.time.LocalDateTime;
|
|
|
7 |
|
|
|
8 |
/**
|
|
|
9 |
* Demo-only partner binding for a Sales person: lets them open the partner's dashboard / app.
|
|
|
10 |
* Never part of the position mapping, so it has no effect on performance or reports.
|
|
|
11 |
* Active while revokedAt is null.
|
|
|
12 |
*/
|
|
|
13 |
@Entity
|
|
|
14 |
@Table(name = "cs.demo_partner_access")
|
|
|
15 |
public class DemoPartnerAccess {
|
|
|
16 |
|
|
|
17 |
@Id
|
|
|
18 |
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
|
|
19 |
private int id;
|
|
|
20 |
|
|
|
21 |
@Column(name = "auth_user_id")
|
|
|
22 |
private int authUserId;
|
|
|
23 |
|
|
|
24 |
@Column(name = "fofo_id")
|
|
|
25 |
private int fofoId;
|
|
|
26 |
|
|
|
27 |
@Column(name = "created_by")
|
|
|
28 |
private int createdBy;
|
|
|
29 |
|
|
|
30 |
@Convert(converter = LocalDateTimeAttributeConverter.class)
|
|
|
31 |
@Column(name = "created_at")
|
|
|
32 |
private LocalDateTime createdAt;
|
|
|
33 |
|
|
|
34 |
@Column(name = "revoked_by")
|
|
|
35 |
private Integer revokedBy;
|
|
|
36 |
|
|
|
37 |
@Convert(converter = LocalDateTimeAttributeConverter.class)
|
|
|
38 |
@Column(name = "revoked_at")
|
|
|
39 |
private LocalDateTime revokedAt;
|
|
|
40 |
|
|
|
41 |
public int getId() {
|
|
|
42 |
return id;
|
|
|
43 |
}
|
|
|
44 |
|
|
|
45 |
public void setId(int id) {
|
|
|
46 |
this.id = id;
|
|
|
47 |
}
|
|
|
48 |
|
|
|
49 |
public int getAuthUserId() {
|
|
|
50 |
return authUserId;
|
|
|
51 |
}
|
|
|
52 |
|
|
|
53 |
public void setAuthUserId(int authUserId) {
|
|
|
54 |
this.authUserId = authUserId;
|
|
|
55 |
}
|
|
|
56 |
|
|
|
57 |
public int getFofoId() {
|
|
|
58 |
return fofoId;
|
|
|
59 |
}
|
|
|
60 |
|
|
|
61 |
public void setFofoId(int fofoId) {
|
|
|
62 |
this.fofoId = fofoId;
|
|
|
63 |
}
|
|
|
64 |
|
|
|
65 |
public int getCreatedBy() {
|
|
|
66 |
return createdBy;
|
|
|
67 |
}
|
|
|
68 |
|
|
|
69 |
public void setCreatedBy(int createdBy) {
|
|
|
70 |
this.createdBy = createdBy;
|
|
|
71 |
}
|
|
|
72 |
|
|
|
73 |
public LocalDateTime getCreatedAt() {
|
|
|
74 |
return createdAt;
|
|
|
75 |
}
|
|
|
76 |
|
|
|
77 |
public void setCreatedAt(LocalDateTime createdAt) {
|
|
|
78 |
this.createdAt = createdAt;
|
|
|
79 |
}
|
|
|
80 |
|
|
|
81 |
public Integer getRevokedBy() {
|
|
|
82 |
return revokedBy;
|
|
|
83 |
}
|
|
|
84 |
|
|
|
85 |
public void setRevokedBy(Integer revokedBy) {
|
|
|
86 |
this.revokedBy = revokedBy;
|
|
|
87 |
}
|
|
|
88 |
|
|
|
89 |
public LocalDateTime getRevokedAt() {
|
|
|
90 |
return revokedAt;
|
|
|
91 |
}
|
|
|
92 |
|
|
|
93 |
public void setRevokedAt(LocalDateTime revokedAt) {
|
|
|
94 |
this.revokedAt = revokedAt;
|
|
|
95 |
}
|
|
|
96 |
|
|
|
97 |
@Override
|
|
|
98 |
public String toString() {
|
|
|
99 |
return "DemoPartnerAccess{id=" + id + ", authUserId=" + authUserId + ", fofoId=" + fofoId
|
|
|
100 |
+ ", createdBy=" + createdBy + ", createdAt=" + createdAt + ", revokedBy=" + revokedBy
|
|
|
101 |
+ ", revokedAt=" + revokedAt + "}";
|
|
|
102 |
}
|
|
|
103 |
}
|