A centralized platform for sharing recommendations and ratings for all media types with friends!
All review cards will be displayed showing the media title and info. The review "ALOTL" or "NOTALOTL" represents a good review or bad review.
After successfully logging in you can create a review card with the option to update or delete your review.
All review cards now displaying your recently created review cards.
CREATE TABLE "public.User" (
"_id" serial(255) NOT NULL,
"username" varchar(15) NOT NULL UNIQUE,
"password" TEXT NOT NULL,
CONSTRAINT "User_pk" PRIMARY KEY ("_id")
) WITH (
OIDS=FALSE
);
CREATE TABLE "public.Media" (
"_id" serial(255) NOT NULL,
"type" varchar(5) NOT NULL,
"title" serial(255) NOT NULL,
CONSTRAINT "Media_pk" PRIMARY KEY ("_id")
) WITH (
OIDS=FALSE
);
CREATE TABLE "public.reviews" (
"_id" serial NOT NULL,
"user_id" int NOT NULL,
"media_id" int NOT NULL,
"review" varchar(255) NOT NULL,
"rating" int NOT NULL,
CONSTRAINT "reviews_pk" PRIMARY KEY ("_id")
) WITH (
OIDS=FALSE
);
ALTER TABLE "reviews" ADD CONSTRAINT "reviews_fk0" FOREIGN KEY ("user_id") REFERENCES "User"("_id");
ALTER TABLE "reviews" ADD CONSTRAINT "reviews_fk1" FOREIGN KEY ("media_id") REFERENCES "Media"("_id");
{
username: 'username'
password: 'password'
}
Status 200 // Means Good
Status 400 // Means Error