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 - Next.js Tutorial
From the course: Next.js Ecommerce: Build a Shopping Platform from Scratch
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…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
(Locked)
Section intro1m 31s
-
(Locked)
Payment method and Zod schemas9m 27s
-
(Locked)
Payment method page8m 1s
-
(Locked)
Payment method form and update13m 9s
-
(Locked)
Order and OrderItem Prisma models11m 7s
-
(Locked)
Order Zod schemas and types8m 16s
-
(Locked)
Place order page18m 5s
-
(Locked)
Create order action14m 15s
-
(Locked)
Place order form7m 37s
-
(Locked)
Order page and action8m 27s
-
(Locked)
Format utility functions8m 20s
-
(Locked)
Order details table14m 5s
-
(Locked)
-
-
-
-
-
-
-
-
-
-