tailieunhanh - Beginning PHP and MySQL E-Commerce From Novice to Professional phần 9

Trả lại quay trở lại trả lời kết quả;} hành vi tập tin như thế này: Khi chúng ta nạp trong trình duyệt, kịch bản làm cho một yêu cầu preauthentication và yêu cầu thực hiện và sau đó lưu các yêu cầu preauthentication, phản ứng, và thực hiện dữ liệu XML trong phiên: | Simpo PDF Merge and Split Unregistered Version - http CHAPTER 17 STORING CUSTOMER ORDERS 563 WHERE order_id orderld WHERE order_id orderld -- Clear the shopping cart CALL shopping_cart_empty inCartId -- Return the Order ID SELECT orderId END 9. Modify the orders_get_order_info stored procedure by deleting the old version and creating a new one don t forget to set the delimiter to -- Drop orders_get_order_info stored procedure DROP PROCEDURE orders_get_order_info -- Create orders_get_order_info stored procedure CREATE PROCEDURE orders_get_order_info IN inOrderId INT BEGIN SELECT FROM orders o INNER JOIN tax t ON INNER JOIN shipping s ON WHERE inOrderId END 10. Execute this code which adds the orders_get_shipping_info stored procedure to the tshirtshop database -- Create orders_get_shipping_info stored procedure CREATE PROCEDURE orders_get_shipping_info IN inShippingRegionId INT BEGIN SELECT shipping_id shipping_type shipping_cost shipping_region_id FROM shipping WHERE shipping_region_id inShippingRegionId END Modifying the Business Tier To work with the new database tables and stored procedures we need to make several changes to business . We must modify CreateOrder in ShoppingCart to configure tax and shipping for new orders as well. Simpo PDF Merge and Split Unregistered Version - http 564 CHAPTER 17 STORING CUSTOMER ORDERS Exercise Updating the Business Tier 1. Modify the CreateOrder method in business follows Create a new order public static function CreateOrder customerId shippingId taxId Build SQL query sql CALL shopping_cart_create_order cart_id customer_id shipping_id tax_id Build the parameters array params array cart_id self GetCartId .

TỪ KHÓA LIÊN QUAN