test.txt
7.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.18.1</version>
<configuration>
<skipTests>true</skipTests>
</configuration>
</plugin>
56f6ae575b174aa59c607242a34d9502
分单结果批量调整满足条件
1.失效件:
(1)保单进入失效月次月至失效日起两年内;
(2)失效原因满足下列其中一项:
保全:未在规定宽限期内缴纳续期保费;
保全:借款本金和利息和超过保单现金价值;
保全:保单的现金价值不足以垫缴保费;
(3)保单渠道与收展服务人员岗位相匹配。
2.缓缴件
(1)保单有效状态的长险(万能险);
(2)保单渠道与收展服务人员岗位相匹配。
"UIWL_AN1","UIED_AN1","UIAN_DN1","UIAN_EN1","UBWL_AN1","UBEN_AN1","UBED_CN1"
https://www.jianshu.com/p/01a6a61d9e02
public void setUser(String userName)
{
grasBranchAssignRuleMapper.setUser(userName);
}
<parameterMap id="stsReturn_param" type="java.lang.String">
<parameter property="userName" jdbcType="VARCHAR" javaType="java.lang.String" mode="IN"></parameter>
</parameterMap>
<update id="setUser" parameterMap="stsReturn_param">
call gracde.gra_sys_package.set_user(?)
</update>
failed to start component [standarEngine [Tomcat] .StandardHost[localhost]]
/**
* 自动分单
*/
@Override
public void autoAllot() {
//"0005"——动态分单机构参数
GrasSysConfig grasSysConfig=oracleGrasSysConfigService.selectByConfigCode("0005");
if(grasSysConfig==null || grasSysConfig.getconfigOption()==null){
//根据3级机构级别查询机构
assignPolicyByLevel(MyConstant.BRANCH_LEVEL_03);
//根据2级机构级别查询机构
assignPolicyByLevel(MyConstant.BRANCH_LEVEL_02);
//根据1级机构级别查询机构
assignPolicyByLevel(MyConstant.BRANCH_LEVEL_01);
}else{
String[] branchList=grasSysConfig.getconfigOption().split(",");
for (String branchCode : branchList)
{
List<BranchInfo> branchCodeList= branchInfoService.queryBranchByParentBranch(branchCode);
executeAllotByLevel(branchCodeList);
logUtils.info("自动分单 ————试点机构分单:"+branchCode);
}
}
//自动同步
resultCheckService.autoResultBack();
}
private void assignPolicyByLevel(String level){
List<BranchInfo> branchList = branchInfoService.queryBranchByLevel(level);
executeAllotByLevel(branchList);
logUtils.info("自动分单-----分单机构级别:"+level);
}
@Override
public List<JSONObject> testSearch(List<JSONObject> jsonObject){
SearchSourceBuilder searchSourceBuilder=new SearchSourceBuilder();
BoolQueryBuilder boolQuery=new BoolQueryBuilder();
//AggregationBuilder aggregationBuilder = AggregationBuilders.cardinality("distinct").field("po_policy_no");
List<JSONObject> resultList=new ArrayList<JSONObject>();
for (JSONObject jsonObject2 : jsonObject)
{
String policyNos = jsonObject2.getString("policyNo");
//aggregationBuilder = AggregationBuilders.cardinality("distinct").field("_id");
boolQuery.filter(QueryBuilders.termsQuery("po_policy_no",policyNos));
//boolQuery.filter(QueryBuilders.termQuery("pp_prod_seq", "2"));
SumAggregationBuilder pp_modal_total_prem = AggregationBuilders.sum("pp_modal_total_prem").field("pp_modal_total_prem");
searchSourceBuilder.query(boolQuery).aggregation(pp_modal_total_prem);
try{
Search search=new Search.Builder(searchSourceBuilder.toString())
.addIndex("policyproinfo").addType(MyConstant.ES_TYPE)
.setParameter(Parameters.SIZE,8000).setParameter(Parameters.SCROLL,"5m")
.build();
//执行查询
logUtils.info("统计数据查询语句:"+searchSourceBuilder.toString());
JestResult result = client.execute(search);
// handleResult(resultList, result);
System.out.println(result);
List<JSONObject> selectList = result.getSourceAsObjectList(JSONObject.class);
//第一次查询的结果要先处理
for (JSONObject object : selectList) {
object.put("service_emp_no", jsonObject2.getString("servicerNo"));
object.put("rnpsi_assign_mode", jsonObject2.getString("assignRule"));
object.put("rnpsi_last_assign_user", jsonObject2.getString("lastAssignUser"));
//object.put("rnpsi_last_assign_date", DateUtil.getDateTimeFormat(jsonObject2.getString("lastAssignDate")));
bir=new Date();
System.out.println(bir);
//object.put("rnpsi_last_assign_date", bir);
object.put("rnpsi_orphan_mark", "0");
resultList.add(object);
}
}catch (Exception e){
logUtils.error(e);
}
}
System.out.println(insertBulk1(resultList));
return resultList;
}
private boolean insertBulk1(Object object)
{
//是否批量插入的判断
if (object.getClass().equals(List.class) || object.getClass().equals(ArrayList.class))
{
List<JSONObject> realObj = (List) object;
//构建批量插入的操作类 bulk 索引根据类名小写 type设定为doc
//最新的es里面可能会废除type的设定 一个index就装一种类型的对象
try
{
Bulk.Builder bulk = new Bulk.Builder();
//构造批量数据
for (JSONObject jsonObject :realObj){
System.out.println("参数:"+jsonObject);
String id=jsonObject.getString("po_policy_no")+"+"+String.valueOf(jsonObject.getInteger("pp_prod_seq"));
System.out.println("id:"+id);
Index index = new Index.Builder(jsonObject).index("policyproinfo").type(MyConstant.ES_TYPE).id(id).build();
bulk.addAction(index);
}
//执行结果
return client.execute(bulk.build()).isSucceeded();
}
catch (IOException e)
{
logUtils.error(e.getMessage());
return false;
}
}
return false;
}
JSONObject jsonObject=new JSONObject();
List<JSONObject> policyNolist=new ArrayList<JSONObject>();
for (Object object : paramArray)
{
jsonObject=(JSONObject)object;
for(String policyNo:policys){
if(policyNo.equals(jsonObject.get("policyNo"))){
policyNolist.add(jsonObject);
break;
}
}
}
//更新es
testSearch(policyNolist);