Flutter Riverpod Course Selling App

Created At: 2023-03-04 02:54:56 Updated At: 2024-04-18 11:11:53

I build this Flutter course selling app using Riverpod. It's great state management system which stays between Getx and BLoC. This same app has been created using Both Getx and BLoC.

Here I have used Riverpod. Let's take look at the UI

App features

  1. onboard screen
  2. email login
  3. social media login
  4. viewing course
  5. play video course
  6. upload course from backend
  7. view multiple teachers course
  8. buy course on the front end
  9. stripe payment
  10. super admin panel
  11. teacher admin panel
  12. chatting feature
  13. teacher's chatting app
  14. search feature

Riverpod source code

Get the source code of this app from the link below. This source just includes Riverpod state management. If you want Getx or BLoC, go to the top of the page.

In terms of Riverpod we have covered in the Udemy course.

  1. Provider
  2. StateProvider
  3. StateNotifierProvider
  4. AsyncNotifier
  5. Notifier with Family modifier
  6. Auth generate riverpod code
  7. Riverpod keep alive and Auto Dispose Notifier Provider
  8. Error handling with Async Notifier Provider

This course covers both old Riverpod and new Riverpod 2.0 version. So you will be able to master and maintain old code base. At the same time, you will learn how to use the new version. We also covered some good practices of architecture like MVC pattern along with how to pass ref and WidgetRef object correctly. 

Take the course on Udemy

Buymecoffee link for complete code

Other features

Riverpod has been used as state management,  rest of the features you may know about from the link below. 

Course selling app

Rest of the features are same as mentioned in the above link.

Promise

If you take the course, you will master Riverpod and Riverpod 2.0. We have also covered core concepts of dart

  1. const and final modifer and when to use them
  2. dart immuitibiliy 
  3. dart singleton class and static objects
  4. dart so called copyWith method
  5. dart different kinds of constructor
  6. arrow function 
  7. getter and setter methods in dart
  8. dart function assignment and anonymous function 
  9. passing callback function 
  10. passing ref object to different classes

Backend

We used Laravel framework for building backend and API. Backend has multi user privileges. It means there are super admins and sub admins. Teachers accounts are sub admin. Super admin can observe and assign roles to the teachers or the sub admins.

With this course, you will learn how to build token for your api and how to do authorization of user access using Sanctum package of Laravel.

We used Laravel eloquent to work with our database from controller. 

By the end of this course, you will master

  1. Laravel basics and MVC
  2. Laravel admin panel (CRUD)
  3. Laravel sanctum 
  4. Laravel restful api

Firebase

Firebase is used for email login and third party login like Google, Facebook and Apple. We also used Firebase for storing chat information of users. All the chat messages are also saved in Firebase.

Stripe payment

Stripe payment includes for course selling using webview payment. We covered in detail how to use web_hooks of Stripe and do the payment. Along the way you will learn cool tricks how to set up Stripe payment and debugging in depth.

In this course, we have a dedicated session(like 90 minutes) for talking about payment and payment gateway like Stripe. If you want to get the picture, you may take our course on Udemy or you may request to buy watermark free for 1 dollar on buymeacoffee

Version

  1. PHP > 8.2
  2. Laravel > 10
  3. Flutter > 3.0.0

Deployment guide backend

1. Download the code from buymecoffee

2. First make sure you have xampp server installed. If not click on the link install it.

3. Make sure you drag and drop laravel backend inside htdocs.

4. Make sure you have create a new database and upload the mysql database from the downloaded folder

5. After that you need to update your .env file according to your database name and your user name and password

6. Then do the following commands

  1. php artisan config:clear
  2. php artisan cache:clear
  3. php artisan route:clear
  4. php artisan serve

7. With the above command you should be able to run server from localhost. In general you would be able to access it using http://127.0.0.1:8000

8. You would be able to access the admin panel by http://127.0.0.1:8000/admin username: admin, password: admin or 123456

Frontend deployment

1. First do flutter clean and flutter pub get

2. Then make sure you change the package name of your app

3. Then you need to do flutter firebase configuration in the terminal 

4. Make sure you have keytool installed to generate sha1 and sha256 keys

5. Then generate SHA1 key for the app

6. Make sure you put the sha1 and sha256 keys in the firebase console

7. Make sure you redownload the google-service.json file in your android/app/ folder

8. You need to enable Google/Email login from Firebase Athentication

9. Then you need to put your local host address in constants.dart file 

SERVER_API_URL for this variable

10. In general for iOS localhost address default one is fine. For android it's 10.0.2.2, and make sure you have put the port number correctly. It's 8000 in general.

Install backend

Here we see how to run the backend locally

Run frontend code

Here we will see how to connect flutter app and backend and run them.

Separate teacher's from super admin panel

Upgrade and missing part

Missing video

There's a missing video between 4:45:00 to 5:00:00 in the part two. Check out the missing part here 

Working with network url for video player

Here we will see how to upgrade the deprecated api for network url of video. Go to this link and change as necessary.

Comment

  • d
    dylan

    2024-03-10 16:46:33

    Yes, I replied you and update the code. Please check it.Please redownload the code

  • H
    Huy Quang

    2024-03-03 13:49:28

    Hello, I bought the source code of the Flutter Riverpod course selling application but it can't run. Can you help me deploy it? I really need it urgently and don't know how to go about it. Hope you receive my message and reply me as soon as possible. Thank

Add Reviews