|
@@ -239,32 +239,50 @@ public class EsProcessEnterpriseServiceImpl extends ServiceImpl<EsProcessEnterpr
|
239
|
239
|
QueryWrapper<BizDict> queryWrapper1 = new QueryWrapper<>();
|
240
|
240
|
queryWrapper1.eq("DICT_LABEL",strings[1]);
|
241
|
241
|
List<BizDict> list1 = BizDictServiceImpl.list(queryWrapper1);
|
|
242
|
+ if(list1.isEmpty()){
|
|
243
|
+ throw new IndexOutOfBoundsException(strings[1]+"不是正确的");
|
|
244
|
+ }
|
242
|
245
|
EsProcessEnterprise.setManagementAreaProvince(list1.get(0).getId());//归口管理地区-省
|
243
|
246
|
|
244
|
247
|
QueryWrapper<BizDict> queryWrapper2 = new QueryWrapper<>();
|
245
|
248
|
queryWrapper2.eq("DICT_LABEL",strings[2]);
|
246
|
249
|
List<BizDict> list2 = BizDictServiceImpl.list(queryWrapper2);
|
|
250
|
+ if(list2.isEmpty()){
|
|
251
|
+ throw new IndexOutOfBoundsException(strings[2]+"不是正确的");
|
|
252
|
+ }
|
247
|
253
|
EsProcessEnterprise.setManagementAreaCity(list2.get(0).getId());//归口管理地区-市
|
248
|
254
|
|
249
|
255
|
QueryWrapper<BizDict> queryWrapper3 = new QueryWrapper<>();
|
250
|
256
|
queryWrapper3.eq("DICT_LABEL",strings[3]);
|
251
|
257
|
List<BizDict> list3 = BizDictServiceImpl.list(queryWrapper3);
|
|
258
|
+ if(list3.isEmpty()){
|
|
259
|
+ throw new IndexOutOfBoundsException(strings[3]+"不是正确的");
|
|
260
|
+ }
|
252
|
261
|
EsProcessEnterprise.setManagementAreaCounty(list3.get(0).getId());//归口管理地区-县
|
253
|
262
|
|
254
|
263
|
|
255
|
264
|
QueryWrapper<BizDict> queryWrapper4 = new QueryWrapper<>();
|
256
|
265
|
queryWrapper4.eq("DICT_LABEL",strings[4]);
|
257
|
266
|
List<BizDict> list4 = BizDictServiceImpl.list(queryWrapper4);
|
|
267
|
+ if(list4.isEmpty()){
|
|
268
|
+ throw new IndexOutOfBoundsException(strings[4]+"不是正确的");
|
|
269
|
+ }
|
258
|
270
|
EsProcessEnterprise.setActualAddressProvince(list4.get(0).getId());//实际经营地址-省
|
259
|
271
|
|
260
|
272
|
QueryWrapper<BizDict> queryWrapper5 = new QueryWrapper<>();
|
261
|
273
|
queryWrapper5.eq("DICT_LABEL",strings[5]);
|
262
|
274
|
List<BizDict> list5 = BizDictServiceImpl.list(queryWrapper5);
|
|
275
|
+ if(list5.isEmpty()){
|
|
276
|
+ throw new IndexOutOfBoundsException(strings[5]+"不是正确的");
|
|
277
|
+ }
|
263
|
278
|
EsProcessEnterprise.setActualAddressCity(list5.get(0).getId());//实际经营地址-市
|
264
|
279
|
|
265
|
280
|
QueryWrapper<BizDict> queryWrapper6 = new QueryWrapper<>();
|
266
|
281
|
queryWrapper6.eq("DICT_LABEL",strings[6]);
|
267
|
282
|
List<BizDict> list6 = BizDictServiceImpl.list(queryWrapper6);
|
|
283
|
+ if(list6.isEmpty()){
|
|
284
|
+ throw new IndexOutOfBoundsException(strings[6]+"不是正确的");
|
|
285
|
+ }
|
268
|
286
|
EsProcessEnterprise.setActualAddressCounty(list6.get(0).getId());//实际经营地址-县
|
269
|
287
|
|
270
|
288
|
|