Final project in Web Application Development course at Colman, conducted by Dr. Igor Rochlin.
"Colman Games" is games shop management tool used by the company to keep track of games, customers and orders - all in just one page.
The website is divided to diffrent sections which we can reach through the sidebar.
In the dashboard section you can monitor information about the server like, OS, CPU, Uptime and number of clients connected - all of those are possible using Socket.io package used here.
Moreover, we used D3.js package in order to show different analytics of the store in a nicer way, just like Games-Categories piechart and linechart showing the growth of customers overtime. The code for the followings shown here.
Additionally, you can see in the Dashboard section some new "Gaming" related articles from the past month, brought by News API, and coded here.
In the games section you can browse between a variety of games available in the shop, search using searching tool or choose between adding a new game, editing one or deleting an old one.
Each row of data provides you the name of the game as well as the image of it, a trailer that will pop up when you click the image and some more inforamtion.
Twitter API - Whenever you'll try to add a new game, an option to post a tweet in our account will pop up, thanks to the API we used.
if (publishOnTwitter) {
// consturcting the tweet text
var msg = "New game released!\n" + req.body.gameName + " is now available on " + req.body.platform + " for $" + req.body.unitPrice + ".\nCheck it out!";
if (req.body.image) {
// tweeting along with the image of the created game, if it exists
twitterClient.tweetWithImage(msg, req.body.image);
} else {
// otherwise, tweeting just the message
twitterClient.tweet(msg);
}
}- Install Node.js.
- Install MongoDB and MongoDB Database Tools.
- Add the folders containing the MongoDB and DB Tools executables to Path in the System Environment Variables, e.g.
C:\Program Files\MongoDB\Server\5.0\bin
C:\Program Files\MongoDB\Tools\100\bin - Create the directory: C:\data\db.
- Clone this repository.
- Download game images and extract them to public/assets/games_media/images.
- Download game trailers and extract them to public/assets/games_media/videos.
- Run the following command in the Online-Video-Game-Store folder, to install all required Node packages listed in package.json:
npm install- Get a Twitter API key and tokens.
- Get a News API key.
- Create a
.envfile with the following contents in the Online-Video-Game-Store folder and add your keys and tokens within the empty quotes:
TWTR_APP_KEY=""
TWTR_APP_SECRET=""
TWTR_ACCESS_TOKEN=""
TWTR_ACCESS_SECRET=""
NEWS_API_KEY=""- Run import_data.bat.
- Start run.bat.
- Go to http://localhost:8080 in your browser. You're all set up!
