From the course: Next.js Ecommerce: Build a Shopping Platform from Scratch

Unlock this course with a free trial

Join today to access over 25,200 courses taught by industry experts.

Section intro

Section intro

So, in this section, we're going to be adding more pages to the checkout process. We're going to have a payment method selection page where we can select PayPal, Stripe or Cash on Delivery and we're also going to have a place order page so the user can review their items and place the order and then after they place the order, they'll be taken to an order details page with the payment buttons, either PayPal payment or a Stripe credit card form. So we're going to create the payment select form and the action that the form will submit to and it will update the user's payment method in the database. And then after the payment method is done, we'll create an order schema in Prisma as well as an order item schema for each item because when a user places an order, the items will be stored in the order items table while the basic order info like the total price and stuff like that will be in the order table. Then we need to create an create order action to add the stuff to the database. And…

Contents