Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

order_detail.php 1.4 KiB

il y a 3 ans
123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?php
  2. require_once "../Common/Config.php";
  3. $orderno=$_GET['orderno'];
  4. $sql="SP_GET_ORDER_DETAIL '{$orderno}'";
  5. $pdo = new PDO("sqlsrv:Server=".HOST.";Database=".DB, USER, PASSWORD);//5.6版本pdo连接sqlsrv
  6. $result=$pdo->query($sql);
  7. $rowset = $result->fetchAll(PDO::FETCH_ASSOC);
  8. $errcode=$rowset[0]["ERRCODE"];
  9. $data=array(
  10. "code"=>$rowset[0]["ERRCODE"],
  11. "info"=>$rowset[0]["ERRINFO"]
  12. );
  13. if ($errcode ==0){
  14. foreach ($rowset as $v){
  15. $val=array();
  16. $val["order_no"]=$v["MAIN_ID"];
  17. $val["order_time"]=$v["ORDER_TIME"];
  18. $val["order_status"]=$v["ORDER_STATUS"];
  19. $val["prod_code"]=$v["PROD_CODE"];
  20. $val["prod_name"]=$v["PROD_NAME"];
  21. $val["price"]=$v["PRICE"];
  22. $val["start_area"]=$v["START_AREA"];
  23. $val["end_area"]=$v["END_AREA"];
  24. $val["go_info"]=$v["GO_INFO"];
  25. $val["back_info"]=$v["BACK_INFO"];
  26. $val["direction"]=$v["DIRECTION"];
  27. $val["run_days"]=$v["RUN_DAYS"];
  28. $val["need_pay"]=$v["NEED_PAY"];
  29. $val["pay_second"]=$v["PAY_SECOND"];
  30. $val["if_bus"]=$v["IF_BUS"];
  31. $val["if_hotel"]=$v["IF_HOTEL"];
  32. $val["if_sightspot"]=$v["IF_SIGHTSPOT"];
  33. $val["direction"]=$v["DIRECTION"];
  34. $val["customer_name"]=$v["CUSTOMER_NAME"];
  35. $val["customer_mobile"]=$v["CUSTOMER_MOBILE"];
  36. $val["customer_id"]=$v["CUSTOMER_ID"];
  37. $val["get_ticket"]=$v["GET_TICKET"];
  38. $val["ticket_list"]=$v["TICKET_LIST"];
  39. $data["order_list"][]=$val;
  40. }
  41. }
  42. echo json_encode($data);