다 중 비행기표 주문 데이터 구조 만 들 기
public AirplaneCreateOrderResult createOrder(AirplaneCreateOrderBizDTO aCreateOrderBizDTO) {
AirplaneCreateOrderResult aCreateOrderResult = new AirplaneCreateOrderResult();
try {
String hasInsurance = aCreateOrderBizDTO.getHasInsurance();
String ori = aCreateOrderBizDTO.getOri();
String des = aCreateOrderBizDTO.getDes();
String fno = aCreateOrderBizDTO.getFno();
String date = aCreateOrderBizDTO.getDate();
String code = aCreateOrderBizDTO.getCode();
String seat = aCreateOrderBizDTO.getSeat();
String carrier = aCreateOrderBizDTO.getCarrier();
String flightNo = aCreateOrderBizDTO.getFlightNo();
String fromCity = aCreateOrderBizDTO.getFromCity();
String arriveCity = aCreateOrderBizDTO.getArriveCity();
String classCode = aCreateOrderBizDTO.getClassCode();
String yPrice = aCreateOrderBizDTO.getyPrice();
String classPrice = aCreateOrderBizDTO.getClassPrice();
String fuelSurTax = aCreateOrderBizDTO.getFuelSurTax();
String airportTax = aCreateOrderBizDTO.getAirportTax();
String departureDate = aCreateOrderBizDTO.getDepartureDate();
String departureTime = aCreateOrderBizDTO.getDepartureTime();
String arrivalDate = aCreateOrderBizDTO.getArrivalDate();
String arrivalTime = aCreateOrderBizDTO.getArrivalTime();
String psgId = aCreateOrderBizDTO.getPsgId();
String name = aCreateOrderBizDTO.getName();
String psgType = aCreateOrderBizDTO.getPsgType();
String cardType = aCreateOrderBizDTO.getCardType();
String cardNo = aCreateOrderBizDTO.getCardNo();
String birthDay = aCreateOrderBizDTO.getBirthDay();
// String carrierPsgId = aCreateOrderBizDTO.getCarrierPsgId();
String country = aCreateOrderBizDTO.getCountry();
String mobilePhone = aCreateOrderBizDTO.getMobilePhone();
String insueSum = aCreateOrderBizDTO.getInsueSum();
String insueFee = aCreateOrderBizDTO.getInsueFee();
String insueCnt = aCreateOrderBizDTO.getInsueCnt();
String insuePrice = aCreateOrderBizDTO.getInsuePrice();
String insueProductNo = aCreateOrderBizDTO.getInsueProductNo();
String priceId = aCreateOrderBizDTO.getPriceId();
String offerpsgType = aCreateOrderBizDTO.getOfferpsgType();
String fare = aCreateOrderBizDTO.getFare();
String agentComm = aCreateOrderBizDTO.getAgentComm();
String offerfuelSurTax = aCreateOrderBizDTO.getOfferfuelSurTax();
String offerairportTax = aCreateOrderBizDTO.getOfferairportTax();
String linker = aCreateOrderBizDTO.getLinker();
// String address = aCreateOrderBizDTO.getAddress();
String telephone = aCreateOrderBizDTO.getTelephone();
String isDomc = aCreateOrderBizDTO.getIsDomc();
String ticketLimitDate = aCreateOrderBizDTO.getTicketLimitDate();
String ticketLimitTime = aCreateOrderBizDTO.getTicketLimitTime();
String balanceMoney = aCreateOrderBizDTO.getBalanceMoney();
// String customerOrderNo = aCreateOrderBizDTO.getCustomerOrderNo();
// String customerNo = aCreateOrderBizDTO.getCustomerNo();
// String remark = aCreateOrderBizDTO.getRemark();
String payType = aCreateOrderBizDTO.getPayType();
// String linkeraddress = aCreateOrderBizDTO.getLinkeraddress();
String linkerName = aCreateOrderBizDTO.getLinkerName();
// String zip = aCreateOrderBizDTO.getZip();
String telphone = aCreateOrderBizDTO.getTelephone();
String linkermobilePhone = aCreateOrderBizDTO.getLinkermobilePhone();
String sendTime = aCreateOrderBizDTO.getSendTime();
String linkerEmail = aCreateOrderBizDTO.getLinkerEmail();
String needInvoices = aCreateOrderBizDTO.getNeedInvoices();
String invoicesSendType = aCreateOrderBizDTO.getInvoicesSendType();
String sendTktsTypeCode = aCreateOrderBizDTO.getSendTktsTypeCode();
// String isPrintSerial = aCreateOrderBizDTO.getIsPrintSerial();
String sendTktDepId = aCreateOrderBizDTO.getSendTktDepId();
String sendTktDepName = aCreateOrderBizDTO.getSendTktDepName();
// String insuranceId = aCreateOrderBizDTO.getInsuranceId();
// String shouldGath = aCreateOrderBizDTO.getShouldGath();
// String shouldPay = aCreateOrderBizDTO.getShouldPay();
// String retMoney = aCreateOrderBizDTO.getRetMoney();
// String gain = aCreateOrderBizDTO.getGain();
// String insuranceCount = aCreateOrderBizDTO.getInsuranceCount();
// String insuranceSummary = aCreateOrderBizDTO.getInsuranceSummary();
String[] spsgIdArray = psgId.split(",");
String[] nameArray = name.split(",");
String[] psgTypeArray = psgType.split(",");
String[] cardTypeArray = cardType.split(",");
String[] cardNoArray = cardNo.split(",");
String[] birthDayArray = birthDay.split(",");
String[] countryArray = country.split(",");
String[] mobilePhoneArray = mobilePhone.split(",");
String[] insueSumArray = insueSum.split(",");
String[] insueFeeArray = insueFee.split(",");
String[] insueCntArray = insueCnt.split(",");
String[] insuePriceArray = insuePrice.split(",");
String[] insueProductNoArray = insueProductNo.split(",");
String[] priceIdArray = priceId.split(",");
String[] offerpsgTypeArray = offerpsgType.split(",");
String[] fareArray = fare.split(",");
String[] agentCommArray = agentComm.split(",");
String[] offerfuelSurTaxArray = offerfuelSurTax.split(",");
String[] offerairportTaxArray = offerairportTax.split(",");
String requestXml = "<data>";
requestXml += "<checkCabinReq>";
requestXml += StringUtil.joinXmlElement("ori", ori);
requestXml += StringUtil.joinXmlElement("des", des);
requestXml += StringUtil.joinXmlElement("fno", fno);
requestXml += StringUtil.joinXmlElement("date", date);
requestXml += StringUtil.joinXmlElement("code", code);
requestXml += StringUtil.joinXmlElement("seat", seat);
requestXml += "</checkCabinReq>";
//
requestXml += "<orderReq>";
requestXml += StringUtil.joinXmlElement("hasInsurance", hasInsurance);
requestXml += "<orderFlightList>";
requestXml += "<orderFlight>";
requestXml += StringUtil.joinXmlElement("carrier", carrier);
requestXml += StringUtil.joinXmlElement("flightNo", flightNo);
requestXml += StringUtil.joinXmlElement("fromCity", fromCity);
requestXml += StringUtil.joinXmlElement("arriveCity", arriveCity);
requestXml += StringUtil.joinXmlElement("classCode", classCode);
requestXml += StringUtil.joinXmlElement("yPrice", yPrice);
requestXml += StringUtil.joinXmlElement("classPrice", classPrice);
requestXml += StringUtil.joinXmlElement("fuelSurTax", fuelSurTax);
requestXml += StringUtil.joinXmlElement("airportTax", airportTax);
requestXml += StringUtil.joinXmlElement("departureDate", departureDate);
requestXml += StringUtil.joinXmlElement("departureTime", departureTime);
requestXml += StringUtil.joinXmlElement("arrivalDate", arrivalDate);
requestXml += StringUtil.joinXmlElement("arrivalTime", arrivalTime);
requestXml += "</orderFlight>";
requestXml += "</orderFlightList>";
//
requestXml += "<passengerList>";
for (int i = 0; i < spsgIdArray.length; i++) {
requestXml += "<passengerInfo>";
requestXml += StringUtil.joinXmlElement("psgId", spsgIdArray[i]);
requestXml += StringUtil.joinXmlElement("name", nameArray[i]);
requestXml += StringUtil.joinXmlElement("psgType", psgTypeArray[i]);
requestXml += StringUtil.joinXmlElement("cardType", cardTypeArray[i]);
requestXml += StringUtil.joinXmlElement("cardNo", cardNoArray[i]);
requestXml += StringUtil.joinXmlElement("birthDay", birthDayArray[i]);
// requestXml += StringUtil.joinXmlElement("carrierPsgId", carrierPsgId);
requestXml += StringUtil.joinXmlElement("country", countryArray[i]);
requestXml += StringUtil.joinXmlElement("mobilePhone", mobilePhoneArray[i]);
requestXml += StringUtil.joinXmlElement("insueSum", insueSumArray[i]);
requestXml += StringUtil.joinXmlElement("insueFee", insueFeeArray[i]);
requestXml += StringUtil.joinXmlElement("insueCnt", insueCntArray[i]);
requestXml += StringUtil.joinXmlElement("insuePrice", insuePriceArray[i]);
requestXml += StringUtil.joinXmlElement("insueProductNo", insueProductNoArray[i]);
requestXml += "</passengerInfo>";
}
requestXml += "</passengerList>";
//
requestXml += "<priceList>";
for (int i = 0; i < priceIdArray.length; i++) {
requestXml += "<priceInfo>";
requestXml += StringUtil.joinXmlElement("priceId", priceIdArray[i]);
requestXml += StringUtil.joinXmlElement("psgType", offerpsgTypeArray[i]);
requestXml += StringUtil.joinXmlElement("fare", fareArray[i]);
requestXml += StringUtil.joinXmlElement("agentComm", agentCommArray[i]);
requestXml += StringUtil.joinXmlElement("fuelSurTax", offerfuelSurTaxArray[i]);
requestXml += StringUtil.joinXmlElement("airportTax", offerairportTaxArray[i]);
requestXml += "</priceInfo>";
}
requestXml += "</priceList>";
//
requestXml += "<orderInfo>";
for (int i = 0; i < 1; i++) {
requestXml += StringUtil.joinXmlElement("linker", linker);
// requestXml += StringUtil.joinXmlElement("address", address);
requestXml += StringUtil.joinXmlElement("telephone", telephone);
requestXml += StringUtil.joinXmlElement("isDomc", isDomc);
requestXml += StringUtil.joinXmlElement("ticketLimitDate", ticketLimitDate);
requestXml += StringUtil.joinXmlElement("ticketLimitTime", ticketLimitTime);
requestXml += StringUtil.joinXmlElement("balanceMoney", balanceMoney);
// requestXml += StringUtil.joinXmlElement("customerOrderNo", customerOrderNo);
// requestXml += StringUtil.joinXmlElement("customerNo", customerNo);
// requestXml += StringUtil.joinXmlElement("remark", remark);
}
requestXml += "</orderInfo>";
//
requestXml += "<linkerInfo>";
for (int i = 0; i < 1; i++) {
requestXml += StringUtil.joinXmlElement("payType", payType);
// requestXml += StringUtil.joinXmlElement("address", linkeraddress);
requestXml += StringUtil.joinXmlElement("linkerName", linkerName);
// requestXml += StringUtil.joinXmlElement("zip", zip);
requestXml += StringUtil.joinXmlElement("telphone", telphone);
requestXml += StringUtil.joinXmlElement("mobilePhone", linkermobilePhone);
requestXml += StringUtil.joinXmlElement("sendTime", sendTime);
requestXml += StringUtil.joinXmlElement("linkerEmail", linkerEmail);
requestXml += StringUtil.joinXmlElement("needInvoices", needInvoices);
requestXml += StringUtil.joinXmlElement("invoicesSendType", invoicesSendType);
requestXml += StringUtil.joinXmlElement("sendTktsTypeCode", sendTktsTypeCode);
// requestXml += StringUtil.joinXmlElement("isPrintSerial", isPrintSerial);
requestXml += StringUtil.joinXmlElement("sendTktDepId", sendTktDepId);
requestXml += StringUtil.joinXmlElement("sendTktDepName", sendTktDepName);
}
requestXml += "</linkerInfo>";
requestXml += "</orderReq>";
requestXml += "</data>";
String encryptCode = Md5.md5(requestXml + key);
Map<String, String> paramasMap = new HashMap<String, String>();
paramasMap.put("requestXml", requestXml);
paramasMap.put("encryptCode", encryptCode);
String xmlResult = HttpUtil.getUrlAsString(createOrderUrl, paramasMap);
if (StringUtils.isNotEmpty(xmlResult)) {
AirplaneProxyResult airplaneProxyResult = (AirplaneProxyResult) XmlUtil.xml2Object("data", xmlResult, AirplaneProxyResult.class);
if (airplaneProxyResult != null && ReturnCodeEnum.SUCCESS.getCode().equals(airplaneProxyResult.getResultCode())) {
aCreateOrderResult.setResultCode(airplaneProxyResult.getResultCode());
aCreateOrderResult.setResultMsg(airplaneProxyResult.getResultMsg());
OrderResult orderResult = airplaneProxyResult.getOrderResult();
aCreateOrderResult.setSubsOrderNo(orderResult.getSubsOrderNo());
aCreateOrderResult.setPnr(orderResult.getPnr());
aCreateOrderResult.setPassengerCount(orderResult.getPassengerCount());
aCreateOrderResult.setBalanceMoney(orderResult.getBalanceMoney());
aCreateOrderResult.setStatus(orderResult.getStatus());
aCreateOrderResult.setTicketLimitDt(orderResult.getTicketLimitDt());
aCreateOrderResult.setTicketLimitTime(orderResult.getTicketLimitTime());
orderResult = (OrderResult) XmlUtil.xml2Object("data/orderResult/priceList", xmlResult, OrderResult.class);
aCreateOrderResult.setPriceList(orderResult.getPriceList());
}
log.info(" , : " + airplaneProxyResult);
}
} catch (Exception e) {
log.error(" ", e);
}
return aCreateOrderResult;
}
이 내용에 흥미가 있습니까?
현재 기사가 여러분의 문제를 해결하지 못하는 경우 AI 엔진은 머신러닝 분석(스마트 모델이 방금 만들어져 부정확한 경우가 있을 수 있음)을 통해 가장 유사한 기사를 추천합니다:
자바 파일, 폴 더 생 성 및 삭제QQ 그룹 에서 어떤 사람 이 폴 더 의 삭 제 를 묻 자 인터넷 으로 찾 아 보 았 습 니 다. 프로그램 을 만 들 었 습 니 다. 주의해 야 할 점 은 폴 더 안의 내용 이 파일 인지 하위 폴 더 인지 판단 해 ...
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
CC BY-SA 2.5, CC BY-SA 3.0 및 CC BY-SA 4.0에 따라 라이센스가 부여됩니다.