Code Monkey home page Code Monkey logo

ses-swe's Introduction

This is a simple point of sales application for a technical interview assignment.

Deployed Demo

Test application is deployed at : https://ses-swe.vercel.app/

Getting Started

First, run the development server:

npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev

SQL Database Intialisation Scripts

CREATE SCHEMA IF NOT EXISTS pos
    AUTHORIZATION postgres;

CREATE SEQUENCE IF NOT EXISTS pos.order_id_seq
    INCREMENT 1
    START 1
    MINVALUE 1
    MAXVALUE 9223372036854775807
    CACHE 1;

ALTER SEQUENCE pos.order_id_seq
    OWNER TO postgres;

CREATE SEQUENCE IF NOT EXISTS pos.product_id_seq
    INCREMENT 1
    START 1
    MINVALUE 1
    MAXVALUE 9223372036854775807
    CACHE 1;

ALTER SEQUENCE pos.product_id_seq
    OWNER TO postgres;

CREATE TABLE IF NOT EXISTS pos.product
(
    product_id integer NOT NULL DEFAULT nextval('pos.product_id_seq'::regclass),
    price integer NOT NULL,
    product_name character varying COLLATE pg_catalog."default" NOT NULL,
    CONSTRAINT product_pkey PRIMARY KEY (product_id)
)

TABLESPACE pg_default;

ALTER TABLE IF EXISTS pos.product
    OWNER to postgres;

CREATE TABLE IF NOT EXISTS pos."order"
(
    order_id integer NOT NULL DEFAULT nextval('pos.order_id_seq'::regclass),
    product_id integer NOT NULL,
    quantity integer NOT NULL,
    CONSTRAINT order_pkey PRIMARY KEY (order_id),
    CONSTRAINT fk_order_product FOREIGN KEY (product_id)
        REFERENCES pos.product (product_id) MATCH SIMPLE
        ON UPDATE NO ACTION
        ON DELETE NO ACTION
)

TABLESPACE pg_default;

ALTER TABLE IF EXISTS pos."order"
    OWNER to postgres;

ses-swe's People

Contributors

hqjb91 avatar

Watchers

 avatar

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.