Every shopping cart needs a page to review and manage items in the basket. In this video, learn how to set up the basket.
- [Instructor] Now that we can add items to the basket,…we most probably also want to review this basket…and eventually buy the items that are in it.…For that, I already created the route.…If you click on the number of items in your basket,…you will end up on a page, and you see here…there is nothing in here which is wrong…because we know that have 15 items in the basket here.…For that we most probably…have to extend our code a little bit,…so let's look at the code for this basket.…
It's in route.…Basket…and ask it in…As you see, we have to veer up that now as well.…To make this work we press F2…to bring in a few services.…First, we add the item service const items Serviced equals…require and two levels up Item Service.…
Next, we need the basket service…that will require the service modular…services basket Service.…We need the user Service as well,…at least a little bit later, so I require that as well.…
As we know, the basket Service needs some initialization,…so add const basket equals basket Service,…and we initialize it with config.redis.client.…
- Basics of relational and nonrelational databases
- Preparing your environment
- When to use document databases
- Inserting data into MongoDB
- Basic insert operations for MongoDB
- Querying data from MongoDB with Node.js
- Using key-value stores
- Using relational databases with Node.js
- Adding MySQL and Sequelize to a project
Skill Level Intermediate
1. Get Started with Databases for Node.js
2. Prepare Your Environment
3. Use Document Databases with Node.js
4. Use Key-Value Stores with Node.js
5. Use Relational Databases with Node.js
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.