Skip to content

Lightweight cross-platform application for managing Blog database in PostgreSQL client. Built with Electron, Javascript, and a lot of coffee.

License

Notifications You must be signed in to change notification settings

Vykp00/MediaDB-Manager

Repository files navigation

MediaDB Manager Current Version

Node Version Npm Version PostgreSQL Electron

MediaDB Manager is a light-weight database management system for our Blog database on PostgreSQL that offer an effortless way to manage your database. The queries executions and features should be user-friendly and limits users' errors and harmful actions that can affect the quality of the main database systems.

Main Usages:

  • View the most popular groups and posts.
  • View Group Table, Comment Table, and User Table
  • Removal of comments from posts
  • Addition of users to groups they are not part of a.k.a New Membership.
  • Update the group name and description.

Table Of Content

screen

Support Platforms

The application have been tested on Windows 10 (H22H2), Ubuntu 22.04.4 LTS (Jammy Jellyfish), and MacOS (Sonoma 14.3.1).

Installation

Required packages

Important prerequisites
First, make sure that you have the following prerequisites installed:
  • NodeJS 20.11.1 LTS (Recommend install NodeJS with nvm to prevent future version conflict. We highly reccommend you use latest LTS version with Electron release)
  • PostgreSQL
  1. Fork or clone the repository and install dependencies
git clone https://github.com/Vykp00/MediaDB-Manager.git
cd MediaDB-Manager
npm install
  1. Configure PostgreSQL database This application will search this database by defaults so you need to setup the following details on your PostgreSQL:
    • user/owner: postgres,
    • host: localhost,
    • database: blog,
    • password: Qwerty1234,
    • port: 5432

    Query to create your own table:
-- Create user table 
CREATE TABLE "user" ( 
    userID varchar(128) PRIMARY KEY, 
    name varchar(50), 
    email varchar(320), 
    password varchar(128) 
);

-- Create group table 
CREATE TABLE "group" ( 
    groupID varchar(128) PRIMARY KEY, 
    name varchar(128), 
    description varchar(1024) 
);

-- Create post table 
CREATE TABLE post ( 
    postID varchar(128) PRIMARY KEY, 
    userID varchar(128), 
    groupID varchar(128), 
    title varchar(60), 
    text text, 
    date date, 
    FOREIGN KEY (userID) REFERENCES "user" (userID) ON DELETE CASCADE, 
    FOREIGN KEY (groupID) REFERENCES "group" (groupID) ON DELETE CASCADE 
); 

-- Create comment table 
CREATE TABLE comment ( 
    commentID varchar(128) PRIMARY KEY, 
    text text, 
    date date, 
    userID varchar(128), 
    postID varchar(128), 
    FOREIGN KEY (userID) REFERENCES "user" (userID) ON DELETE CASCADE, 
    FOREIGN KEY (postID) REFERENCES post (postID) ON DELETE CASCADE 

); 

-- Create membership table 
CREATE TABLE membership ( 
    userID varchar(128), 
    groupID varchar(128), 
    joinDate date,
    PRIMARY KEY (userID, groupID), 
    FOREIGN KEY (userID) REFERENCES "user" (userID) ON DELETE CASCADE, 
    FOREIGN KEY (groupID) REFERENCES "group" (groupID) ON DELETE CASCADE 
); 

Media ERD Diagram

3. Start the server

npm run start

Packaging

To package the application.

npm run make

Some usefule materials:
Electron - Packaging your Application
Electron Forge

License

The Studio.ai web application is licensed under the terms of the Apache 2.0 license and is available for free.

About

Lightweight cross-platform application for managing Blog database in PostgreSQL client. Built with Electron, Javascript, and a lot of coffee.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published