Git Product home page Git Product logo

sea-cinema's Introduction

This app builded with:

And already deployed on Vercel - https://sea-cinema-phi.vercel.app/

About this app

Features

  • Home page: show all movies
  • Login page: login with username and password
  • Register page: register with full name, username, age, and password
  • Movie detail page: show movie detail and show time
  • Book ticket: this feature only available for logged in user in detail movie page
  • Balance: this feature only available for logged in navbar
  • Top up Balance: this feature available in balance menu
  • Withdraw Balance: this feature available in balance menu
  • My ticket: this feature only available for logged in navbar
  • Withdraw ticket: this feature only available for logged in my ticket menu
  • Logout: this feature only available for logged in navbar

Disclaimer

  • Not all movies have show time

Develop this app

Getting Started with this App

Prerequisites

Installation

  1. Clone the repo
    git clone https://github.com/farhan15r/sea-cinema.git
  2. Install NPM packages
    npm install
    # or
    yarn install
    # or
    pnpm install
  3. Copy .env.example to .env
    cp .env.example .env
  4. Fill the .env file with your mongoDB cluster connection string
  5. Fill the ACCESS_TOKEN_KEY and REFRESH_TOKEN_KEY with your own secret key
  6. Set the ACCESS_TOKEN_AGE and REFRESH_TOKEN_AGE with your own token age

Fill mongoDB with dummy movie

  1. open src\lib\service\mongo\MoviesService.js
  2. uncomment line 13
  3. run the app
  4. the dummy movie will be filled after you open the home page (http://localhost:3000), this is running when app getting movies data from API (https://localhost:3000/api/movies)

IMPORTANT: don't forget to comment line 13 again after you filled the database with dummy movie

Run the app

  1. run the development server:

    npm run dev
    # or
    yarn dev
    # or
    pnpm dev
  2. Open http://localhost:3000 with your browser to see the result.

Fill mongoDB with dummy movie show time

  1. open src\lib\service\mongo\ShowTimesService.js
  2. go to line 102 you will see dummy function
  3. adjust the movieID, date, and time. You can get movieID in url when you open the movie detail page (http://localhost:3000/movie/[movieID])
  4. uncomment line 14
  5. run the app and open the movie detail page (http://localhost:3000/movie/[movieID])

IMPORTANT: don't forget to comment line 14 again after you filled the database with dummy movie show time

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

sea-cinema's People

Contributors

farhan15r avatar

Watchers

 avatar

sea-cinema's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.