You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- <?php
- /*
- Author:XM
- Compeny:Spiders Travel
- */
- require_once '../Common/Mysql.php';
- $pdo=conn();
- $order_id = isset($_POST["order_id"]) ? $_POST["order_id"] : false;
- $per_price = isset($_POST["per_price"]) ? $_POST["per_price"] : false;
- $order_ticket_num = isset($_POST["ticket_num"]) ? $_POST["ticket_num"] : false;
-
- if( $order_id == false || $per_price == false || $order_ticket_num == false ) {
- echo "change price failed";
- exit();
- }
-
- $all_price = $per_price * $order_ticket_num;
-
- $pdo_update = conn();
- $sql_update = " UPDATE order_main SET ORDER_PRICE={$per_price} WHERE PARENT_ORDER_ID={$order_id} ";
- $pdo_update->exec($sql_update);
-
- $sql_update = " UPDATE order_main SET ORDER_PRICE={$all_price} WHERE ORDER_ID={$order_id} ";
- $pdo_update->exec($sql_update);
-
- echo "change price success";
- exit();
|