376d3231
张志伟
✨ 主动放弃跟进 100%
|
1
2
|
package cn.fw.valhalla.domain.query;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
3
|
import cn.fw.valhalla.common.utils.DateUtil;
|
376d3231
张志伟
✨ 主动放弃跟进 100%
|
4
5
6
|
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
|
8f67fa34
张志伟
🚀 v1.0.1 跟进池
|
7
8
|
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.math.NumberUtils;
|
116bb810
张志伟
|
9
|
import org.springframework.util.CollectionUtils;
|
c4fb2fa5
张志伟
✨ 公共池接口 100%
|
10
|
|
93f85ef8
张志伟
|
11
12
13
|
import java.time.Instant;
import java.time.LocalDateTime;
import java.time.ZoneId;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
14
|
import java.util.Date;
|
116bb810
张志伟
|
15
|
import java.util.List;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
16
|
import java.util.Objects;
|
116bb810
张志伟
|
17
18
|
import java.util.stream.Collectors;
import java.util.stream.Stream;
|
376d3231
张志伟
✨ 主动放弃跟进 100%
|
19
20
21
22
23
24
25
26
27
28
|
/**
* 档案查询条件
*
* @author kurisu
*/
@Data
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
|
39e85d50
张志伟
|
29
|
public class FollowPoolQueryVO extends PoolQuery {
|
376d3231
张志伟
✨ 主动放弃跟进 100%
|
30
|
private Integer type;
|
e7aefdc4
张志伟
|
31
32
33
34
35
36
37
38
|
/**
* 贷款期客户
*/
private Boolean loanCustomer;
/**
* 跟进开始时间(区间)
*/
private String followStartTime;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
39
40
41
|
/**
* 跟进状态
*/
|
116bb810
张志伟
|
42
|
private String state;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
43
|
/**
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
44
45
|
* 二次分配
*/
|
e7aefdc4
张志伟
|
46
|
private Boolean redistribution;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
47
|
/**
|
e7aefdc4
张志伟
|
48
|
* 战败类型
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
49
50
|
*/
private Integer initiative;
|
8f3f3243
张志伟
feature(*): 修复bug
|
51
52
53
|
/**
* 来源[公共池线索用]
*/
|
652ffd0e
张志伟
|
54
|
private String source;
|
a4a33c06
张志伟
|
55
|
private String closeTime;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
56
|
|
e7aefdc4
张志伟
|
57
58
|
public Integer getLoanCustomer() {
if (Objects.isNull(loanCustomer)) {
|
8f67fa34
张志伟
🚀 v1.0.1 跟进池
|
59
60
|
return null;
}
|
e7aefdc4
张志伟
|
61
|
return loanCustomer ? 1 : 0;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
62
63
64
|
}
public Integer getRedistribution() {
|
8f67fa34
张志伟
🚀 v1.0.1 跟进池
|
65
66
67
|
if (Objects.isNull(redistribution)) {
return null;
}
|
e7aefdc4
张志伟
|
68
|
return redistribution ? 1 : 0;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
69
70
|
}
|
e7aefdc4
张志伟
|
71
72
73
74
75
76
77
|
public Date getStartTime1() {
if (StringUtils.isBlank(followStartTime)) {
return null;
}
String[] times = followStartTime.split(",");
if (StringUtils.isNotBlank(times[0]) && NumberUtils.isDigits(times[0])) {
LocalDateTime localDateTime = Instant.ofEpochMilli(NumberUtils.toLong(times[0])).atZone(ZoneId.systemDefault()).toLocalDateTime();
|
8f67fa34
张志伟
🚀 v1.0.1 跟进池
|
78
|
return DateUtil.getBeginInTime(DateUtil.localDateTime2Date(localDateTime));
|
c4fb2fa5
张志伟
✨ 公共池接口 100%
|
79
|
}
|
e7aefdc4
张志伟
|
80
|
return null;
|
7b007468
张志伟
🚀 v1.0.1 跟进池
|
81
82
|
}
|
e7aefdc4
张志伟
|
83
84
85
86
87
|
public Date getStartTime2() {
if (StringUtils.isBlank(followStartTime)) {
return null;
}
String[] times = followStartTime.split(",");
|
790c2e65
张志伟
:construction_wor...
|
88
|
if (times.length < TIME_STR_LENGTH) {
|
e7aefdc4
张志伟
|
89
90
91
92
93
94
95
96
97
|
return null;
}
if (StringUtils.isNotBlank(times[1]) && NumberUtils.isDigits(times[1])) {
LocalDateTime localDateTime = Instant.ofEpochMilli(NumberUtils.toLong(times[1])).atZone(ZoneId.systemDefault()).toLocalDateTime();
return DateUtil.getEndInTime(DateUtil.localDateTime2Date(localDateTime));
}
return null;
}
|
a4a33c06
张志伟
|
98
99
|
public Date getCloseTime1() {
if (StringUtils.isBlank(closeTime)) {
|
e7aefdc4
张志伟
|
100
101
|
return null;
}
|
a4a33c06
张志伟
|
102
|
String[] times = closeTime.split(",");
|
e7aefdc4
张志伟
|
103
104
105
106
107
108
109
|
if (StringUtils.isNotBlank(times[0]) && NumberUtils.isDigits(times[0])) {
LocalDateTime localDateTime = Instant.ofEpochMilli(NumberUtils.toLong(times[0])).atZone(ZoneId.systemDefault()).toLocalDateTime();
return DateUtil.getBeginInTime(DateUtil.localDateTime2Date(localDateTime));
}
return null;
}
|
a4a33c06
张志伟
|
110
111
|
public Date getCloseTime2() {
if (StringUtils.isBlank(closeTime)) {
|
e7aefdc4
张志伟
|
112
113
|
return null;
}
|
a4a33c06
张志伟
|
114
|
String[] times = closeTime.split(",");
|
790c2e65
张志伟
:construction_wor...
|
115
|
if (times.length < TIME_STR_LENGTH) {
|
e7aefdc4
张志伟
|
116
117
118
119
|
return null;
}
if (StringUtils.isNotBlank(times[1]) && NumberUtils.isDigits(times[1])) {
LocalDateTime localDateTime = Instant.ofEpochMilli(NumberUtils.toLong(times[1])).atZone(ZoneId.systemDefault()).toLocalDateTime();
|
8f67fa34
张志伟
🚀 v1.0.1 跟进池
|
120
|
return DateUtil.getEndInTime(DateUtil.localDateTime2Date(localDateTime));
|
c4fb2fa5
张志伟
✨ 公共池接口 100%
|
121
|
}
|
e7aefdc4
张志伟
|
122
|
return null;
|
c4fb2fa5
张志伟
✨ 公共池接口 100%
|
123
|
}
|
116bb810
张志伟
|
124
|
|
116bb810
张志伟
|
125
126
127
128
129
130
131
|
public List<Integer> getState() {
if (StringUtils.isBlank(state)) {
return null;
}
List<Integer> stateList = Stream.of(state.split(",")).filter(cn.fw.valhalla.common.utils.StringUtils::isNumber).map(Integer::valueOf).collect(Collectors.toList());
return CollectionUtils.isEmpty(stateList) ? null : stateList;
}
|
652ffd0e
张志伟
|
132
133
134
135
136
137
138
139
|
public List<Integer> getSource() {
if (StringUtils.isBlank(source)) {
return null;
}
List<Integer> sourceList = Stream.of(source.split(",")).filter(cn.fw.valhalla.common.utils.StringUtils::isNumber).map(Integer::valueOf).collect(Collectors.toList());
return CollectionUtils.isEmpty(sourceList) ? null : sourceList;
}
|
376d3231
张志伟
✨ 主动放弃跟进 100%
|
140
|
}
|