|
@@ -0,0 +1,798 @@
|
|
|
|
+package info.aspirecn.iov.yysj.check.info.common;
|
|
|
|
+import info.aspirecn.cloud.yysj.commons.lang.Constants;
|
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
|
+import org.apache.commons.lang.StringUtils;
|
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
+import org.springframework.stereotype.Component;
|
|
|
|
+
|
|
|
|
+import java.io.IOException;
|
|
|
|
+import java.text.ParseException;
|
|
|
|
+import java.text.SimpleDateFormat;
|
|
|
|
+import java.time.LocalDateTime;
|
|
|
|
+import java.time.format.DateTimeFormatter;
|
|
|
|
+import java.util.*;
|
|
|
|
+import java.util.regex.Matcher;
|
|
|
|
+import java.util.regex.Pattern;
|
|
|
|
+
|
|
|
|
+@Component
|
|
|
|
+@Slf4j
|
|
|
|
+public class TransferParam {
|
|
|
|
+
|
|
|
|
+ private static final String DATE_YYYYMMDD = "(([0-9]{3}[1-9]|[0-9]{2}[1-9][0-9]{1}|[0-9]{1}[1-9][0-9]{2}|[1-9][0-9]{3})(((0[13578]|1[02])(0[1-9]|[12][0-9]|3[01]))|((0[469]|11)(0[1-9]|[12][0-9]|30))|(02(0[1-9]|[1][0-9]|2[0-8]))))|((([0-9]{2})(0[48]|[2468][048]|[13579][26])|((0[48]|[2468][048]|[3579][26])00))0229)";
|
|
|
|
+ private static final String WEIGHT_000 = "([0-9]){0,}.[0-9]{3}";
|
|
|
|
+ /*
|
|
|
|
+ * {"vehicleNumber":"新A93293","licensePlateTypeCode":"2","vehicleTonnage":"0"}*/
|
|
|
|
+ @Autowired
|
|
|
|
+ private Property property;
|
|
|
|
+ public Map<String,Object> getCustomBody( Map<String, String> paramMap,String productId,Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ Map<String,Object> customBody =new HashMap<String,Object>();
|
|
|
|
+ if ("01".equals(productId)) {//行驶证验证
|
|
|
|
+
|
|
|
|
+ customBody=clxszyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("03".equals(productId)) {//驾驶证验证
|
|
|
|
+
|
|
|
|
+ customBody=ryjszyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("04".equals(productId)) {//人员从业资格验证
|
|
|
|
+
|
|
|
|
+ customBody=rycyzgyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("02".equals(productId)) {//车辆营运验证
|
|
|
|
+
|
|
|
|
+ customBody=clyyyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("10".equals(productId)) {//企业经营许可验证 经营许可证号
|
|
|
|
+
|
|
|
|
+ customBody=qyyyxkyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("09".equals(productId)) {//车辆入网验证
|
|
|
|
+
|
|
|
|
+ customBody=clrwyz(paramMap,emptyList);
|
|
|
|
+ }if ("07".equals(productId)) {//托运人身份验证(个人)
|
|
|
|
+
|
|
|
|
+ customBody=tyrsfyz_person(paramMap,emptyList);
|
|
|
|
+ }if ("08".equals(productId)) {//托运人身份验证(企业)
|
|
|
|
+
|
|
|
|
+ customBody=tyrsfyz_enterprise(paramMap,emptyList);
|
|
|
|
+ }if ("05".equals(productId)) {//装货点车辆定位验证
|
|
|
|
+
|
|
|
|
+ customBody= zhdwyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("06".equals(productId)) {//卸货点车辆定位验证
|
|
|
|
+
|
|
|
|
+ customBody= xhdwyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("12".equals(productId)) {//超载验证(核载验证)
|
|
|
|
+
|
|
|
|
+ customBody=czyz(paramMap,emptyList,errorList);
|
|
|
|
+ }if ("13".equals(productId)) {//司机上下线
|
|
|
|
+
|
|
|
|
+ customBody=sjsxx(paramMap,emptyList,errorList);
|
|
|
|
+ }else if(Constants.OtherRquestUrl.IDLENTITYVERIFICATION.getValue().equals(productId)){//身份核验
|
|
|
|
+ String req_id=paramMap.get(Constants.req_id);
|
|
|
|
+ if(StringUtils.isEmpty(req_id)) {
|
|
|
|
+ emptyList.add(Constants.req_id);
|
|
|
|
+ }
|
|
|
|
+ paramMap.clear();
|
|
|
|
+ customBody.put("reqID",req_id);
|
|
|
|
+ return customBody;
|
|
|
|
+ }else if(Constants.OtherRquestUrl.LIVINGURL.getValue().equals(productId)){//身份核验
|
|
|
|
+ String req_id=paramMap.get(Constants.req_id);
|
|
|
|
+ if(StringUtils.isEmpty(req_id)){
|
|
|
|
+ emptyList.add(Constants.req_id);
|
|
|
|
+ }
|
|
|
|
+ String appe_id_code=paramMap.get(Constants.appe_id_code);
|
|
|
|
+ if(StringUtils.isEmpty(appe_id_code)){
|
|
|
|
+ emptyList.add(Constants.appe_id_code);
|
|
|
|
+ }
|
|
|
|
+ String eid_voucher=paramMap.get(Constants.eid_voucher);
|
|
|
|
+ if(StringUtils.isEmpty(eid_voucher)){
|
|
|
|
+ emptyList.add(Constants.eid_voucher);
|
|
|
|
+ }
|
|
|
|
+ String longitudeDegree=paramMap.get(Constants.Long_degree);
|
|
|
|
+
|
|
|
|
+ String lat_degree=paramMap.get(Constants.lat_degree);
|
|
|
|
+ paramMap.clear();
|
|
|
|
+ customBody.put("reqID",req_id);
|
|
|
|
+ customBody.put("appeIdCode",appe_id_code);
|
|
|
|
+ customBody.put("eidVoucher",eid_voucher);
|
|
|
|
+ if(StringUtils.isNotEmpty(longitudeDegree)){
|
|
|
|
+ customBody.put("longitudeDegree",longitudeDegree);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isNotEmpty(lat_degree)){
|
|
|
|
+ customBody.put("latitudeDegree",lat_degree);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ return customBody;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ return customBody;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ //校验项一 车辆行驶证验证 行驶证信息查询查询
|
|
|
|
+ public Map<String,Object> clxszyz(Map<String,String> requestMap, Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ String vehicleNumber=requestMap.get(Constants.car_vehicleNumber);
|
|
|
|
+ String vehicleType = requestMap.get(Constants.car_vehicleType);
|
|
|
|
+ String owner = requestMap.get(Constants.car_owner);
|
|
|
|
+ String vin = requestMap.get(Constants.car_vin);
|
|
|
|
+ String registerDate = requestMap.get(Constants.car_registerDate);
|
|
|
|
+ if(StringUtils.isEmpty(vehicleNumber)){
|
|
|
|
+ emptyList.add(Constants.car_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(vin)){
|
|
|
|
+ emptyList.add(Constants.car_vin);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(vehicleType)){
|
|
|
|
+ emptyList.add(Constants.car_vehicleType);
|
|
|
|
+ }
|
|
|
|
+ Pattern pattern = Pattern.compile(DATE_YYYYMMDD);
|
|
|
|
+ if(StringUtils.isEmpty(registerDate)){
|
|
|
|
+ emptyList.add(Constants.car_registerDate);
|
|
|
|
+ }else if(!pattern.matcher(registerDate).matches()){
|
|
|
|
+ errorList.add(Constants.car_registerDate);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ if(StringUtils.isEmpty(owner)){
|
|
|
|
+ emptyList.add(Constants.car_owner);
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0){
|
|
|
|
+
|
|
|
|
+ Map<String, Object> vehicleInfoMap = new HashMap<String,Object>();
|
|
|
|
+ vehicleInfoMap.put(Constants.clxszyz_carNumber,vehicleNumber);
|
|
|
|
+ vehicleInfoMap.put(Constants.clxszyz_carType,vehicleType);
|
|
|
|
+ vehicleInfoMap.put(Constants.clxszyz_name,owner);
|
|
|
|
+ vehicleInfoMap.put(Constants.car_vin,vin);
|
|
|
|
+ vehicleInfoMap.put(Constants.car_registerDate,registerDate);
|
|
|
|
+ return vehicleInfoMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ //校验项二 人员驾驶证验证
|
|
|
|
+ public Map<String,Object> ryjszyz(Map<String,String> requestMap,Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ String vehicleNumber=requestMap.get(Constants.driver_driverLicenseNumber);
|
|
|
|
+ String name = requestMap.get(Constants.driver_driverNamer);
|
|
|
|
+ String vehicleClass= requestMap.get(Constants.driver_vehicleClass);
|
|
|
|
+ String validPeriodFrom= requestMap.get(Constants.driver_validPeriodFrom);
|
|
|
|
+ String validPeriodTo=requestMap.get(Constants.driver_validPeriodTo);
|
|
|
|
+ Pattern pattern = Pattern.compile(DATE_YYYYMMDD);
|
|
|
|
+ if(StringUtils.isEmpty(vehicleNumber)){
|
|
|
|
+ emptyList.add(Constants.driver_driverLicenseNumber);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(name)){
|
|
|
|
+ emptyList.add(Constants.driver_driverNamer);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(vehicleClass)){
|
|
|
|
+ emptyList.add(Constants.driver_vehicleClass);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(validPeriodFrom)){
|
|
|
|
+ emptyList.add(Constants.driver_validPeriodFrom);
|
|
|
|
+ }else if(!pattern.matcher(validPeriodFrom).matches()){
|
|
|
|
+ errorList.add(Constants.driver_validPeriodFrom);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(validPeriodTo)){
|
|
|
|
+ emptyList.add(Constants.driver_validPeriodTo);
|
|
|
|
+ }else if(!pattern.matcher(validPeriodTo).matches()){
|
|
|
|
+ errorList.add(Constants.driver_validPeriodTo);
|
|
|
|
+ }
|
|
|
|
+ /* if ((!StringUtils.isEmpty(validPeriodFrom) && !pattern.matcher(validPeriodFrom).matches()) || (!StringUtils.isEmpty(validPeriodTo) && !pattern.matcher(validPeriodTo).matches())) {
|
|
|
|
+ throw new ResultCodeException(Constants.ResultDesc.PARAMERROR.getCode(), Constants.ResultDesc.PARAMERROR.getValue(), "驾驶证开始结束时间不正确");
|
|
|
|
+ }*/
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ Map<String, Object> vehicleInfoMap = new HashMap<String, Object>();
|
|
|
|
+ vehicleInfoMap.put(Constants.ryjszyz_driveNo, vehicleNumber);
|
|
|
|
+ vehicleInfoMap.put(Constants.ryjszyz_name, name);
|
|
|
|
+ vehicleInfoMap.put(Constants.driver_vehicleClass,vehicleClass);
|
|
|
|
+ vehicleInfoMap.put(Constants.driver_validPeriodFrom, validPeriodFrom);
|
|
|
|
+ vehicleInfoMap.put(Constants.driver_validPeriodTo,validPeriodTo);
|
|
|
|
+ return vehicleInfoMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+ /*
|
|
|
|
+ * 校验行三 人员从业资格验证 查询人员信息接口*/
|
|
|
|
+ public Map<String,Object> rycyzgyz(Map<String,String> requestMap,Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ String driverName=requestMap.get(Constants.driver_driverNamer);
|
|
|
|
+ String qualificationCertificate=requestMap.get(Constants.driver_qualificationCertificate);
|
|
|
|
+ String provinceCode=requestMap.get(Constants.driver_provinceCode);
|
|
|
|
+ String qualificationCertificateFrom=requestMap.get(Constants.driver_qualificationCertificateFrom);
|
|
|
|
+ String qualificationCertificateTo=requestMap.get(Constants.driver_qualificationCertificateTo);
|
|
|
|
+ Pattern pattern = Pattern.compile(DATE_YYYYMMDD);
|
|
|
|
+ if(StringUtils.isEmpty(driverName)){
|
|
|
|
+ emptyList.add(Constants.driver_driverNamer);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(qualificationCertificate)){
|
|
|
|
+ emptyList.add(Constants.driver_qualificationCertificate);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(provinceCode)){
|
|
|
|
+ emptyList.add(Constants.driver_provinceCode);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(qualificationCertificateFrom)){
|
|
|
|
+ emptyList.add(Constants.driver_qualificationCertificateFrom);
|
|
|
|
+ }else if(!pattern.matcher(qualificationCertificateFrom).matches()){
|
|
|
|
+ errorList.add(Constants.driver_qualificationCertificateFrom);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(qualificationCertificateTo)){
|
|
|
|
+ emptyList.add(Constants.driver_qualificationCertificateTo);
|
|
|
|
+ }else if(!pattern.matcher(qualificationCertificateTo).matches()){
|
|
|
|
+ errorList.add(Constants.driver_qualificationCertificateTo);
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+ Map<String, Object> vehicleInfoMap = new HashMap<String, Object>();
|
|
|
|
+ vehicleInfoMap.put(Constants.rycyzgyz_nameOfPerson, driverName);
|
|
|
|
+ vehicleInfoMap.put(Constants.rycyzgyz_qualificationCertificateNumber, qualificationCertificate);
|
|
|
|
+ vehicleInfoMap.put(Constants.rycyzgyz_provinceCode, provinceCode);
|
|
|
|
+ vehicleInfoMap.put(Constants.rycyzgyz_periodStartDate, qualificationCertificateFrom);
|
|
|
|
+ vehicleInfoMap.put(Constants.rycyzgyz_periodEndDate, qualificationCertificateTo);
|
|
|
|
+ return vehicleInfoMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+ /*
|
|
|
|
+ * 校验项四 车辆营运验证*/
|
|
|
|
+ public Map<String,Object> clyyyz(Map<String,String> requestMap,Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ String vehicleNumber=requestMap.get(Constants.car_vehicleNumber);
|
|
|
|
+ String roadTransportCertificateNumber=requestMap.get(Constants.car_roadTransport);
|
|
|
|
+ String vehiclePlateColorCode=requestMap.get(Constants.car_vehiclePlateColorCode);
|
|
|
|
+ String roadTransportCertificateValidPeriodFrom=requestMap.get(Constants.car_roadTransportCertificateValidPeriodFrom);
|
|
|
|
+ String roadTransportCertificateValidPeriodTo=requestMap.get(Constants.car_roadTransportCertificateValidPeriodTo);
|
|
|
|
+ if(StringUtils.isEmpty(vehicleNumber)){
|
|
|
|
+ emptyList.add(Constants.car_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(roadTransportCertificateNumber)){
|
|
|
|
+ emptyList.add(Constants.car_roadTransport);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(vehiclePlateColorCode)){
|
|
|
|
+ emptyList.add(Constants.car_vehiclePlateColorCode);
|
|
|
|
+ }
|
|
|
|
+ Pattern pattern = Pattern.compile(DATE_YYYYMMDD);
|
|
|
|
+ if(StringUtils.isEmpty(roadTransportCertificateValidPeriodFrom)){
|
|
|
|
+ emptyList.add(Constants.car_roadTransportCertificateValidPeriodFrom);
|
|
|
|
+ }else if(!pattern.matcher(roadTransportCertificateValidPeriodFrom).matches()){
|
|
|
|
+ errorList.add(Constants.car_roadTransportCertificateValidPeriodFrom);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(roadTransportCertificateValidPeriodTo)){
|
|
|
|
+ emptyList.add(Constants.car_roadTransportCertificateValidPeriodTo);
|
|
|
|
+ }else if(!pattern.matcher(roadTransportCertificateValidPeriodTo).matches()){
|
|
|
|
+ errorList.add(Constants.car_roadTransportCertificateValidPeriodTo);
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+ Map<String, Object> vehicleInfoMap = new HashMap<String, Object>();
|
|
|
|
+ vehicleInfoMap.put(Constants.clyyyz_vehicleNumber, vehicleNumber);
|
|
|
|
+ vehicleInfoMap.put(Constants.clyyyz_roadTransportCertificateNumber, roadTransportCertificateNumber);
|
|
|
|
+ vehicleInfoMap.put(Constants.clyyyz_licensePlateTypeCode, vehiclePlateColorCode);
|
|
|
|
+ vehicleInfoMap.put(Constants.clyyyz_periodStartDate, roadTransportCertificateValidPeriodFrom);
|
|
|
|
+ vehicleInfoMap.put(Constants.clyyyz_periodEndDate, roadTransportCertificateValidPeriodTo);
|
|
|
|
+ return vehicleInfoMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+ public Map<String,Object> qyyyxkyz(Map<String,String> requestMap,Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ String carrier=requestMap.get(Constants.bill_carrier);
|
|
|
|
+ String permitNumber=requestMap.get(Constants.bill_permitNumber);
|
|
|
|
+ //String unifiedSocialCreditIdentifier=requestMap.get(Constants.bill_unifiedSocialCreditIdentifier);
|
|
|
|
+ /*String permitValidPeriodFrom=requestMap.get(Constants.bill_permitValidPeriodFrom);
|
|
|
|
+ String permitValidPeriodTo=requestMap.get(Constants.bill_permitValidPeriodTo);
|
|
|
|
+ Pattern pattern = Pattern.compile(DATE_YYYYMMDD);*/
|
|
|
|
+ if(StringUtils.isEmpty(carrier)){
|
|
|
|
+ emptyList.add(Constants.bill_carrier);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(permitNumber)){
|
|
|
|
+ emptyList.add(Constants.bill_permitNumber);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ /* if(StringUtils.isEmpty(permitValidPeriodFrom)){
|
|
|
|
+ emptyList.add(Constants.bill_permitValidPeriodFrom);
|
|
|
|
+ }else if(!pattern.matcher(permitValidPeriodFrom).matches()){
|
|
|
|
+ errorList.add(Constants.bill_permitValidPeriodFrom);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(permitValidPeriodTo)){
|
|
|
|
+ emptyList.add(Constants.bill_permitValidPeriodTo);
|
|
|
|
+ }else if(!pattern.matcher(permitValidPeriodTo).matches()){
|
|
|
|
+ errorList.add(Constants.bill_permitValidPeriodTo);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(unifiedSocialCreditIdentifier)){
|
|
|
|
+ emptyList.add(Constants.bill_unifiedSocialCreditIdentifier);
|
|
|
|
+ }*/
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+ Map<String, Object> vehicleInfoMap = new HashMap<String, Object>();
|
|
|
|
+ vehicleInfoMap.put(Constants.bill_carrier, carrier);
|
|
|
|
+ vehicleInfoMap.put(Constants.bill_permitNumber, permitNumber);
|
|
|
|
+ /*vehicleInfoMap.put(Constants.bill_unifiedSocialCreditIdentifier, unifiedSocialCreditIdentifier);
|
|
|
|
+ vehicleInfoMap.put(Constants.bill_permitValidPeriodFrom, permitValidPeriodFrom);
|
|
|
|
+ vehicleInfoMap.put(Constants.bill_permitValidPeriodTo, permitValidPeriodTo);
|
|
|
|
+ */
|
|
|
|
+ return vehicleInfoMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ //校验项六 车辆入网验证
|
|
|
|
+ public Map<String,Object> clrwyz(Map<String,String> requestMap,Set<String> emptyList) throws IOException, ResultCodeException {
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ Object vehicleInfo=requestMap.get(Constants.bill_vehicleInfo);
|
|
|
|
+ String vehicleNumber ="";
|
|
|
|
+ String vehiclePlateColorCode ="";
|
|
|
|
+ if(vehicleInfo==null || !(vehicleInfo instanceof LinkedHashMap)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo);
|
|
|
|
+ }else if(vehicleInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> vehicleInfoMap = (Map)vehicleInfo;
|
|
|
|
+ vehicleNumber = vehicleInfoMap.get(Constants.bill_vehicleNumber);
|
|
|
|
+ if(StringUtils.isEmpty(vehicleNumber)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ vehiclePlateColorCode = vehicleInfoMap.get(Constants.bill_vehiclePlateColorCode);
|
|
|
|
+ if(StringUtils.isEmpty(vehiclePlateColorCode)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehiclePlateColorCode);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0) {
|
|
|
|
+ Map<String, Object> vehicleInfoMap = new HashMap<String,Object>();
|
|
|
|
+ vehicleInfoMap.put(Constants.clrw_vehicleNumber,vehicleNumber);
|
|
|
|
+ vehicleInfoMap.put(Constants.clrw_licensePlateTypeCode,vehiclePlateColorCode);
|
|
|
|
+ return vehicleInfoMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+ //校验项七 托运人身份验证(个人)
|
|
|
|
+ public Map<String,Object> tyrsfyz_person(Map<String,String> requestMap,Set<String> emptyList) throws IOException, ResultCodeException {
|
|
|
|
+ Object consignorInfo = requestMap.get(Constants.bill_consignorInfo);
|
|
|
|
+ String consignor="";
|
|
|
|
+ String consignorID="";
|
|
|
|
+ if(consignorInfo==null){
|
|
|
|
+ emptyList.add(Constants.bill_consignorInfo);
|
|
|
|
+ }else {
|
|
|
|
+ if (consignorInfo instanceof LinkedHashMap) {
|
|
|
|
+ Map<String, String> consignorInfoMap = (Map) consignorInfo;
|
|
|
|
+ consignor = consignorInfoMap.get(Constants.bill_consignor);
|
|
|
|
+ consignorID = consignorInfoMap.get(Constants.bill_ConsignorID);
|
|
|
|
+ }
|
|
|
|
+ if (StringUtils.isEmpty(consignor)) {
|
|
|
|
+ emptyList.add(Constants.bill_consignorInfo+"."+Constants.bill_consignor);
|
|
|
|
+ }
|
|
|
|
+ if (StringUtils.isEmpty(consignorID)) {
|
|
|
|
+ emptyList.add(Constants.bill_consignorInfo+"."+Constants.bill_ConsignorID);
|
|
|
|
+ }
|
|
|
|
+ if (emptyList.size() == 0) {
|
|
|
|
+ Map<String, Object> infoMap = new HashMap<String, Object>();
|
|
|
|
+ infoMap.put(Constants.persontyr_name, consignor);
|
|
|
|
+ infoMap.put(Constants.persontyr_idCode, consignorID);
|
|
|
|
+ return infoMap;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+ //校验项八 托运人身份验证(企业)
|
|
|
|
+ public Map<String,Object> tyrsfyz_enterprise(Map<String,String> requestMap,Set<String> emptyList) throws IOException, ResultCodeException {
|
|
|
|
+ Object consignorInfo = requestMap.get(Constants.bill_consignorInfo);
|
|
|
|
+ String consignor="";
|
|
|
|
+ String consignorID="";
|
|
|
|
+ if(consignorInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> consignorInfoMap = (Map)consignorInfo;
|
|
|
|
+ consignor = consignorInfoMap.get(Constants.bill_consignor);
|
|
|
|
+ consignorID=consignorInfoMap.get(Constants.bill_ConsignorID);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(consignor)){
|
|
|
|
+ emptyList.add(Constants.bill_consignorInfo+"."+Constants.bill_consignor);
|
|
|
|
+ }
|
|
|
|
+ if(StringUtils.isEmpty(consignorID)){
|
|
|
|
+ emptyList.add(Constants.bill_consignorInfo+"."+Constants.bill_ConsignorID);
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0) {
|
|
|
|
+ Map<String, Object> infoMap = new HashMap<String, Object>();
|
|
|
|
+ infoMap.put(Constants.bill_carrier, consignor);
|
|
|
|
+ //infoMap.put(Constants.enterpricetyr_creditCode, consignorID);
|
|
|
|
+ return infoMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+ //校验项六 装货点车辆定位验证
|
|
|
|
+ public Map<String,Object> zhdwyz(Map<String,String> requestMap, Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ Object vehicleInfo=requestMap.get(Constants.bill_vehicleInfo);
|
|
|
|
+ String vehicleNumber ="";
|
|
|
|
+ Map<String, Object> resultMap = new HashMap<String,Object>();
|
|
|
|
+ String countrySubdivisionCode="";
|
|
|
|
+ if(vehicleInfo==null || !(vehicleInfo instanceof LinkedHashMap)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo);
|
|
|
|
+ }else if(vehicleInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> vehicleInfoMap = (Map)vehicleInfo;
|
|
|
|
+ vehicleNumber = vehicleInfoMap.get(Constants.bill_vehicleNumber);
|
|
|
|
+ if(StringUtils.isEmpty(vehicleNumber)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ Object consignorInfo=requestMap.get(Constants.bill_consignorInfo);
|
|
|
|
+ if(consignorInfo==null || !(consignorInfo instanceof LinkedHashMap)){
|
|
|
|
+ emptyList.add(Constants.bill_consignorInfo);
|
|
|
|
+ }else if(consignorInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> consignorInfoMap = (Map)consignorInfo;
|
|
|
|
+ countrySubdivisionCode = consignorInfoMap.get(Constants.bill_countrySubdivisionCode);
|
|
|
|
+ if(StringUtils.isEmpty(countrySubdivisionCode)){
|
|
|
|
+ emptyList.add(Constants.bill_consignorInfo+"."+Constants.bill_countrySubdivisionCode);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ String despatchActualDateTime = requestMap.get(Constants.bill_despatchActualDateTime);
|
|
|
|
+
|
|
|
|
+ if(StringUtils.isEmpty(despatchActualDateTime)){
|
|
|
|
+ emptyList.add(Constants.bill_despatchActualDateTime);
|
|
|
|
+ }else if(!checkDateTime(despatchActualDateTime,"yyyyMMddHHmmss")){
|
|
|
|
+ errorList.add(Constants.bill_despatchActualDateTime);
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+ resultMap.put(Constants.zh_xh_vehicleNumber,vehicleNumber);
|
|
|
|
+ resultMap.put(Constants.zh_xh_countrySubdivisionCode,countrySubdivisionCode);
|
|
|
|
+ resultMap.put(Constants.zh_xh_dateTime,transferDate(despatchActualDateTime,"yyyyMMddHHmmss","yyyy-MM-dd HH:mm:ss"));
|
|
|
|
+ return resultMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ //校验项六 卸货点车辆定位验证
|
|
|
|
+ public Map<String,Object> xhdwyz(Map<String,String> requestMap, Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ Object vehicleInfo=requestMap.get(Constants.bill_vehicleInfo);
|
|
|
|
+ String vehicleNumber ="";
|
|
|
|
+ Map<String, Object> resultMap = new HashMap<String,Object>();
|
|
|
|
+ String countrySubdivisionCode="";
|
|
|
|
+ if(vehicleInfo==null || !(vehicleInfo instanceof LinkedHashMap)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo);
|
|
|
|
+ }else if(vehicleInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> vehicleInfoMap = (Map)vehicleInfo;
|
|
|
|
+ vehicleNumber = vehicleInfoMap.get(Constants.bill_vehicleNumber);
|
|
|
|
+ if(StringUtils.isEmpty(vehicleNumber)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ Object consigneeInfo=requestMap.get(Constants.bill_consigneeInfo);
|
|
|
|
+ if(consigneeInfo==null || !(consigneeInfo instanceof LinkedHashMap)){
|
|
|
|
+ emptyList.add(Constants.bill_consigneeInfo);
|
|
|
|
+ }else if(consigneeInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> consigneeInfoMap = (Map)consigneeInfo;
|
|
|
|
+ countrySubdivisionCode = consigneeInfoMap.get(Constants.bill_countrySubdivisionCode);
|
|
|
|
+ if(StringUtils.isEmpty(countrySubdivisionCode)){
|
|
|
|
+ emptyList.add(Constants.bill_consigneeInfo+"."+Constants.bill_countrySubdivisionCode);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ String goodsReceiptDateTime = requestMap.get(Constants.bill_goodsReceiptDateTime);
|
|
|
|
+
|
|
|
|
+ if(StringUtils.isEmpty(goodsReceiptDateTime)){
|
|
|
|
+ emptyList.add(Constants.bill_goodsReceiptDateTime);
|
|
|
|
+ }else if(!checkDateTime(goodsReceiptDateTime,"yyyyMMddHHmmss")){
|
|
|
|
+ errorList.add(Constants.bill_goodsReceiptDateTime);
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+ resultMap.put(Constants.zh_xh_vehicleNumber,vehicleNumber);
|
|
|
|
+ resultMap.put(Constants.zh_xh_countrySubdivisionCode,countrySubdivisionCode);
|
|
|
|
+ resultMap.put(Constants.zh_xh_dateTime,transferDate(goodsReceiptDateTime,"yyyyMMddHHmmss","yyyy-MM-dd HH:mm:ss"));
|
|
|
|
+
|
|
|
|
+ return resultMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ //校验项六 超载验证(核载验证)
|
|
|
|
+ public Map<String,Object> czyz(Map<String,String> requestMap, Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ Object vehicleInfo=requestMap.get(Constants.bill_vehicleInfo);
|
|
|
|
+ String vehicleNumber ="";
|
|
|
|
+ String vehiclePlateColorCode ="";
|
|
|
|
+ double weightTotal = 0.0;
|
|
|
|
+ Map<String, Object> resultMap = new HashMap<String,Object>();
|
|
|
|
+ if(vehicleInfo==null || !(vehicleInfo instanceof LinkedHashMap)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo);
|
|
|
|
+ }else if(vehicleInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> vehicleInfoMap = (Map)vehicleInfo;
|
|
|
|
+ vehicleNumber = vehicleInfoMap.get(Constants.bill_vehicleNumber);
|
|
|
|
+ if(StringUtils.isEmpty(vehicleNumber)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ vehiclePlateColorCode = vehicleInfoMap.get(Constants.car_vehiclePlateColorCode);
|
|
|
|
+ if(StringUtils.isEmpty(vehiclePlateColorCode)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.car_vehiclePlateColorCode);
|
|
|
|
+ }
|
|
|
|
+ Object goodsInfos = vehicleInfoMap.get(Constants.bill_goodsInfo);
|
|
|
|
+ if(goodsInfos ==null){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_goodsInfo);
|
|
|
|
+ }else{
|
|
|
|
+ Pattern pattern = Pattern.compile(WEIGHT_000);
|
|
|
|
+ if(goodsInfos instanceof ArrayList){
|
|
|
|
+ List<Object> goodInfoList = (List)goodsInfos;
|
|
|
|
+ for(Object goodInfo : goodInfoList){
|
|
|
|
+ if(goodInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> goodInfoMap = (Map<String,String>)goodInfo;
|
|
|
|
+ String weightStr = goodInfoMap.get(Constants.bill_goodsInfo_weight);
|
|
|
|
+
|
|
|
|
+ Matcher matcher = pattern.matcher(weightStr);
|
|
|
|
+ if(!matcher.matches()){
|
|
|
|
+ errorList.add(Constants.bill_vehicleInfo+"."+Constants.bill_goodsInfo+"."+Constants.bill_goodsInfo_weight);
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ double weight = Double.parseDouble(weightStr);
|
|
|
|
+ weightTotal +=weight;
|
|
|
|
+ }else{
|
|
|
|
+ errorList.add(Constants.bill_vehicleInfo+"."+Constants.bill_goodsInfo+"."+Constants.bill_goodsInfo_weight);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ }else{
|
|
|
|
+ errorList.add(Constants.bill_vehicleInfo+"."+Constants.bill_goodsInfo);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+ resultMap.put(Constants.zlhy_vehicleNumber,vehicleNumber);
|
|
|
|
+ resultMap.put(Constants.zlhy_licensePlateTypeCode,vehiclePlateColorCode);
|
|
|
|
+ resultMap.put(Constants.zlhy_vehicleTonnage,String.valueOf(weightTotal));
|
|
|
|
+ return resultMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ //校验项十四 司机上下线
|
|
|
|
+ public Map<String,Object> sjsxx(Map<String,String> requestMap, Set<String> emptyList,Set<String> errorList) throws IOException, ResultCodeException {
|
|
|
|
+ String shippingNoteNumber=requestMap.get(Constants.bill_shipping_note_number);
|
|
|
|
+ if(StringUtils.isEmpty(shippingNoteNumber)){
|
|
|
|
+ emptyList.add(Constants.bill_shipping_note_number);
|
|
|
|
+ }
|
|
|
|
+ String despatchActualDateTime=requestMap.get(Constants.bill_despatchActualDateTime);
|
|
|
|
+ if(StringUtils.isEmpty(despatchActualDateTime)){
|
|
|
|
+ emptyList.add(Constants.bill_despatchActualDateTime);
|
|
|
|
+ }else {
|
|
|
|
+ try {
|
|
|
|
+ SimpleDateFormat yMdHms = new SimpleDateFormat("yyyyMMddHHmmss");
|
|
|
|
+ SimpleDateFormat yMdHmsResult = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
|
|
|
+ despatchActualDateTime = yMdHmsResult.format(yMdHms.parse(despatchActualDateTime));
|
|
|
|
+ } catch (ParseException ex) {
|
|
|
|
+ log.error("解析发货时间异常:{}", ex);
|
|
|
|
+ errorList.add(Constants.bill_despatchActualDateTime);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ String driverName="";
|
|
|
|
+ String driverLicense="";
|
|
|
|
+ List<Map> resultDriver = new ArrayList<Map>();
|
|
|
|
+ Object vehicleInfo=requestMap.get(Constants.bill_vehicleInfo);
|
|
|
|
+ Map<String, Object> resultMap = new HashMap<String,Object>();
|
|
|
|
+ if(vehicleInfo==null || !(vehicleInfo instanceof LinkedHashMap)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo);
|
|
|
|
+ }else if(vehicleInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> vehicleInfoMap = (Map)vehicleInfo;
|
|
|
|
+ Object drivers = vehicleInfoMap.get(Constants.bill_driver);
|
|
|
|
+
|
|
|
|
+ if(drivers==null || !(drivers instanceof ArrayList)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver);
|
|
|
|
+ }else if(drivers instanceof ArrayList){
|
|
|
|
+ List<Object> driverList = (List)drivers;
|
|
|
|
+ if(driverList.size()<1){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver);
|
|
|
|
+ }else{
|
|
|
|
+ for(Object driverInfo : driverList){
|
|
|
|
+ Map<String,String> driverMap = new HashMap<String,String>();
|
|
|
|
+ if(driverInfo instanceof LinkedHashMap){
|
|
|
|
+ Map<String,String> driverInfoMap = (Map<String,String>)driverInfo;
|
|
|
|
+ driverName = driverInfoMap.get(Constants.bill_driver_name);
|
|
|
|
+ if(StringUtils.isEmpty(driverName)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver+"."+Constants.bill_driver_name);
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ driverLicense = driverInfoMap.get(Constants.bill_driver_License);
|
|
|
|
+ if(StringUtils.isEmpty(driverLicense)){
|
|
|
|
+ emptyList.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver+"."+Constants.bill_driver_License);
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ driverMap.put(Constants.sjsxx_name,driverName);
|
|
|
|
+ driverMap.put(Constants.sjsxx_idCode,driverLicense);
|
|
|
|
+ resultDriver.add(driverMap);
|
|
|
|
+ }else{
|
|
|
|
+ errorList.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ if(emptyList.size()==0 && errorList.size()==0) {
|
|
|
|
+ resultMap.put(Constants.sjsxx_bill_no,shippingNoteNumber);
|
|
|
|
+
|
|
|
|
+ resultMap.put(Constants.sjsxx_drivers,resultDriver);
|
|
|
|
+ resultMap.put(Constants.sjsxx_despatchActualDateTime,despatchActualDateTime);
|
|
|
|
+ return resultMap;
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ public static boolean checkDateTime(String str,String pattern) {
|
|
|
|
+ DateTimeFormatter dtf = DateTimeFormatter.ofPattern(pattern);
|
|
|
|
+ boolean flag = true;
|
|
|
|
+ try {
|
|
|
|
+ LocalDateTime.parse(str, dtf);
|
|
|
|
+ } catch (Exception e) {
|
|
|
|
+ flag = false;
|
|
|
|
+ }
|
|
|
|
+ return flag;
|
|
|
|
+ }
|
|
|
|
+ public static String transferDate(String str,String oldpattern,String newPattern) {
|
|
|
|
+ DateTimeFormatter dtf = DateTimeFormatter.ofPattern(oldpattern);
|
|
|
|
+ DateTimeFormatter newdtf = DateTimeFormatter.ofPattern(newPattern);
|
|
|
|
+ try {
|
|
|
|
+ String result = newdtf.format(dtf.parse(str));
|
|
|
|
+ return result;
|
|
|
|
+ } catch (Exception e) {
|
|
|
|
+ log.error("Exception:{}",e);
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ public Set<String> resultTransferParam(String productCode,Set<String> list){
|
|
|
|
+ Set<String> result = new HashSet<String>();
|
|
|
|
+ if ("04".equals(productCode)) {
|
|
|
|
+ //人员从业资格验证
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.rycyzgyz_nameOfPerson.equals(param)) {
|
|
|
|
+ result.add(Constants.driver_driverNamer);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.rycyzgyz_qualificationCertificateNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.driver_qualificationCertificate);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.rycyzgyz_provinceCode.equals(param)) {
|
|
|
|
+ result.add(Constants.driver_provinceCode);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.rycyzgyz_periodStartDate.equals(param)) {
|
|
|
|
+ result.add(Constants.driver_qualificationCertificateFrom);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.rycyzgyz_periodEndDate.equals(param)) {
|
|
|
|
+ result.add(Constants.driver_qualificationCertificateTo);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ }else if ("02".equals(productCode)) {//车辆营运验证
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.clyyyz_vehicleNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.car_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.clyyyz_licensePlateTypeCode.equals(param)) {
|
|
|
|
+ result.add(Constants.car_vehiclePlateColorCode);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.clyyyz_roadTransportCertificateNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.car_roadTransport);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.clyyyz_periodStartDate.equals(param)) {
|
|
|
|
+ result.add(Constants.car_roadTransportCertificateValidPeriodFrom);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.clyyyz_periodEndDate.equals(param)) {
|
|
|
|
+ result.add(Constants.car_roadTransportCertificateValidPeriodTo);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }else if ("10".equals(productCode)) {//企业经营许可验证 经营许可证号
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.qyyyxkz_carrier.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_carrier);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.qyyyxkz_permitNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_permitNumber);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.qyyyxkz_provinceCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_carrier);
|
|
|
|
+ /* result.add(Constants.bill_unifiedSocialCreditIdentifier);*/
|
|
|
|
+ }
|
|
|
|
+ /* if (Constants.clyyyz_periodStartDate.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_permitValidPeriodFrom);
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ if (Constants.clyyyz_periodEndDate.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_permitValidPeriodTo);
|
|
|
|
+
|
|
|
|
+ }*/
|
|
|
|
+ if (Constants.qyyyxkz_name.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_carrier);
|
|
|
|
+ }
|
|
|
|
+ /* if (Constants.qyyyxkz_creditCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_unifiedSocialCreditIdentifier);
|
|
|
|
+ }*/
|
|
|
|
+ }
|
|
|
|
+ }else if ("09".equals(productCode)) {//车辆入网验证
|
|
|
|
+
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.clrw_vehicleNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.clrw_licensePlateTypeCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehiclePlateColorCode);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }else if ("07".equals(productCode)) {//托运人身份验证(个人)
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.persontyr_name.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_consignorInfo+"."+Constants.bill_consignor);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.persontyr_idCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_consignorInfo+"."+Constants.bill_ConsignorID);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ }else if ("08".equals(productCode)) {//托运人身份验证(企业)
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.enterpricetyr_name.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_consignorInfo+"."+Constants.bill_consignor);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.enterpricetyr_creditCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_consignorInfo+"."+Constants.bill_ConsignorID);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }else if ("05".equals(productCode)) {//装货点车辆定位验证
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.zh_xh_vehicleNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.zh_xh_countrySubdivisionCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_consignorInfo+"."+Constants.bill_countrySubdivisionCode);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.zh_xh_dateTime.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_despatchActualDateTime);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }else if ("06".equals(productCode)) {//卸货点车辆定位验证
|
|
|
|
+
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.zh_xh_vehicleNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.zh_xh_countrySubdivisionCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_consigneeInfo+"."+Constants.bill_countrySubdivisionCode);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.zh_xh_dateTime.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_goodsReceiptDateTime);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }else if ("12".equals(productCode)) {//超载核验
|
|
|
|
+
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.zlhy_vehicleNumber.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_vehicleNumber);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.zlhy_licensePlateTypeCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.car_vehiclePlateColorCode);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.zlhy_vehicleTonnage.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_goodsInfo+"."+Constants.bill_goodsInfo_weight);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }else if ("13".equals(productCode)) {//司机上下线
|
|
|
|
+ for (String param : list) {
|
|
|
|
+
|
|
|
|
+ if (Constants.sjsxx_bill_no.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_shipping_note_number);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.sjsxx_name.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver+"."+Constants.bill_driver_name);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.sjsxx_idCode.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver+"."+Constants.bill_driver_License);
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ if(Constants.sjsxx_H1.equals(param)){
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver+"."+Constants.bill_driver_License);
|
|
|
|
+ result.add(Constants.bill_vehicleInfo+"."+Constants.bill_driver+"."+Constants.bill_driver_name);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.sjsxx_dateTime.equals(param)||Constants.sjsxx_despatchActualDateTime.equals(param)) {
|
|
|
|
+ result.add(Constants.bill_despatchActualDateTime);
|
|
|
|
+ }
|
|
|
|
+ if (Constants.sjsxx_consistent.equals(param)) {
|
|
|
|
+ result.add("活体核验结果");
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }else{
|
|
|
|
+ result= list;
|
|
|
|
+ }
|
|
|
|
+ return result;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+}
|