|
@@ -1007,7 +1007,7 @@ public class CustomerApiController {
|
|
|
mp.put("id",json.getString("_id"));
|
|
|
JSONObject jsonOb = JSON.parseObject(json.getString("_source"));
|
|
|
mp.putAll(JSON.parseObject(json.getString("_source"),Map.class));
|
|
|
- customer.setScustId(jsonOb.getString("scustid"));
|
|
|
+ customer.setScustId("\t"+jsonOb.getString("scustid"));
|
|
|
customer.setCustId(jsonOb.getString("custid"));
|
|
|
customer.setName(jsonOb.getString("name"));
|
|
|
customer.setSex("0".equals(jsonOb.getString("gender"))?"男":"女");
|
|
@@ -1027,22 +1027,22 @@ public class CustomerApiController {
|
|
|
String birthday = jsonOb.getString("birthday");
|
|
|
mp.put("birthday", birthday);
|
|
|
mp.put("age",DateUtils.getAge(DateUtils.dateTime(DateUtils.YYYY_MM_DD,birthday)));
|
|
|
- customer.setBirthDay(birthday);
|
|
|
+ customer.setBirthDay("\t"+birthday);
|
|
|
customer.setAge(DateUtils.getAge(DateUtils.dateTime(DateUtils.YYYY_MM_DD,birthday)));
|
|
|
}
|
|
|
|
|
|
if(mp.containsKey("idcard")){
|
|
|
customer.setIdType("身份证");
|
|
|
- customer.setIdCard(jsonOb.getString("idcard"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("idcard"));
|
|
|
}else if(mp.containsKey("passport")){
|
|
|
customer.setIdType("护照");
|
|
|
- customer.setIdCard(jsonOb.getString("passport"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("passport"));
|
|
|
}else if(mp.containsKey("dlicense")){
|
|
|
customer.setIdType("驾驶证");
|
|
|
- customer.setIdCard(jsonOb.getString("dlicense"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("dlicense"));
|
|
|
}else if(mp.containsKey("othernumber")){
|
|
|
customer.setIdType("其它证件类型");
|
|
|
- customer.setIdCard(jsonOb.getString("othernumber"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("othernumber"));
|
|
|
}
|
|
|
|
|
|
if(mp.containsKey("custclass")){
|
|
@@ -1129,7 +1129,7 @@ public class CustomerApiController {
|
|
|
@GetMapping("/exportSameZero")
|
|
|
public void exportSameZero(HttpServletResponse response, HttpServletRequest request)
|
|
|
{
|
|
|
- logger.info("导出三要素进时间:"+DateUtils.getTime());
|
|
|
+ logger.info("导出四要素进时间:"+DateUtils.getTime());
|
|
|
|
|
|
try{
|
|
|
|
|
@@ -1157,28 +1157,28 @@ public class CustomerApiController {
|
|
|
mp.put("id",json.getString("_id"));
|
|
|
JSONObject jsonOb = JSON.parseObject(json.getString("_source"));
|
|
|
mp.putAll(JSON.parseObject(json.getString("_source"),Map.class));
|
|
|
- customer.setScustId(jsonOb.getString("scustid"));
|
|
|
+ customer.setScustId("\t"+jsonOb.getString("scustid"));
|
|
|
customer.setName(jsonOb.getString("name"));
|
|
|
customer.setSex("0".equals(jsonOb.getString("gender"))?"男":"女");
|
|
|
if(mp.containsKey("birthday")){
|
|
|
String birthday = jsonOb.getString("birthday").length()>10?jsonOb.getString("birthday").substring(0,10):jsonOb.getString("birthday");
|
|
|
mp.put("birthday", birthday);
|
|
|
- customer.setBirthDay(birthday);
|
|
|
+ customer.setBirthDay("\t"+birthday);
|
|
|
customer.setAge(DateUtils.getAge(DateUtils.dateTime(DateUtils.YYYY_MM_DD_HH_MM_SS,jsonOb.getString("birthday"))));
|
|
|
}
|
|
|
|
|
|
if(mp.containsKey("idcard")){
|
|
|
customer.setIdType("身份证");
|
|
|
- customer.setIdCard(jsonOb.getString("idcard"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("idcard"));
|
|
|
}else if(mp.containsKey("passport")){
|
|
|
customer.setIdType("护照");
|
|
|
- customer.setIdCard(jsonOb.getString("passport"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("passport"));
|
|
|
}else if(mp.containsKey("dlicense")){
|
|
|
customer.setIdType("驾驶证");
|
|
|
- customer.setIdCard(jsonOb.getString("dlicense"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("dlicense"));
|
|
|
}else if(mp.containsKey("othernumber")){
|
|
|
customer.setIdType("其它证件类型");
|
|
|
- customer.setIdCard(jsonOb.getString("othernumber"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("othernumber"));
|
|
|
}
|
|
|
|
|
|
customers.add(customer);
|
|
@@ -1201,9 +1201,9 @@ public class CustomerApiController {
|
|
|
header.put("sex", "性别");
|
|
|
header.put("birthDay", "出生日期");
|
|
|
CsvUtil.export(request, response, "customer", header, customers);
|
|
|
- logger.info("导出三要素出时间:"+DateUtils.getTime());
|
|
|
+ logger.info("导出四要素出时间:"+DateUtils.getTime());
|
|
|
}catch (Exception e){
|
|
|
- logger.info("导出三要素出错:"+DateUtils.getTime());
|
|
|
+ logger.info("导出四要素出错:"+DateUtils.getTime());
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
|
|
@@ -1245,7 +1245,7 @@ public class CustomerApiController {
|
|
|
mp.put("id",json.getString("_id"));
|
|
|
JSONObject jsonOb = JSON.parseObject(json.getString("_source"));
|
|
|
mp.putAll(JSON.parseObject(json.getString("_source"),Map.class));
|
|
|
- customer.setScustId(jsonOb.getString("scustid"));
|
|
|
+ customer.setScustId("\t"+jsonOb.getString("scustid"));
|
|
|
customer.setName(jsonOb.getString("name"));
|
|
|
customer.setSex("0".equals(jsonOb.getString("gender"))?"男":"女");
|
|
|
if(mp.containsKey("birthday")){
|
|
@@ -1257,16 +1257,16 @@ public class CustomerApiController {
|
|
|
|
|
|
if(mp.containsKey("idcard")){
|
|
|
customer.setIdType("身份证");
|
|
|
- customer.setIdCard(jsonOb.getString("idcard"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("idcard"));
|
|
|
}else if(mp.containsKey("passport")){
|
|
|
customer.setIdType("护照");
|
|
|
- customer.setIdCard(jsonOb.getString("passport"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("passport"));
|
|
|
}else if(mp.containsKey("dlicense")){
|
|
|
customer.setIdType("驾驶证");
|
|
|
- customer.setIdCard(jsonOb.getString("dlicense"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("dlicense"));
|
|
|
}else if(mp.containsKey("othernumber")){
|
|
|
customer.setIdType("其它证件类型");
|
|
|
- customer.setIdCard(jsonOb.getString("othernumber"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("othernumber"));
|
|
|
}
|
|
|
|
|
|
customers.add(customer);
|
|
@@ -1333,28 +1333,28 @@ public class CustomerApiController {
|
|
|
mp.put("id",json.getString("_id"));
|
|
|
JSONObject jsonOb = JSON.parseObject(json.getString("_source"));
|
|
|
mp.putAll(JSON.parseObject(json.getString("_source"),Map.class));
|
|
|
- customer.setScustId(jsonOb.getString("scustid"));
|
|
|
+ customer.setScustId("\t"+jsonOb.getString("scustid"));
|
|
|
customer.setName(jsonOb.getString("name"));
|
|
|
customer.setSex("0".equals(jsonOb.getString("gender"))?"男":"女");
|
|
|
if(mp.containsKey("birthday")){
|
|
|
String birthday = jsonOb.getString("birthday").length()>10?jsonOb.getString("birthday").substring(0,10):jsonOb.getString("birthday");
|
|
|
mp.put("birthday", birthday);
|
|
|
- customer.setBirthDay(birthday);
|
|
|
+ customer.setBirthDay("\t"+birthday);
|
|
|
customer.setAge(DateUtils.getAge(DateUtils.dateTime(DateUtils.YYYY_MM_DD_HH_MM_SS,jsonOb.getString("birthday"))));
|
|
|
}
|
|
|
|
|
|
if(mp.containsKey("idcard")){
|
|
|
customer.setIdType("身份证");
|
|
|
- customer.setIdCard(jsonOb.getString("idcard"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("idcard"));
|
|
|
}else if(mp.containsKey("passport")){
|
|
|
customer.setIdType("护照");
|
|
|
- customer.setIdCard(jsonOb.getString("passport"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("passport"));
|
|
|
}else if(mp.containsKey("dlicense")){
|
|
|
customer.setIdType("驾驶证");
|
|
|
- customer.setIdCard(jsonOb.getString("dlicense"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("dlicense"));
|
|
|
}else if(mp.containsKey("othernumber")){
|
|
|
customer.setIdType("其它证件类型");
|
|
|
- customer.setIdCard(jsonOb.getString("othernumber"));
|
|
|
+ customer.setIdCard("\t"+jsonOb.getString("othernumber"));
|
|
|
}
|
|
|
|
|
|
customers.add(customer);
|