Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
212ee80
inital commit
WildcherryBazzaire Dec 14, 2018
696c045
already did
WildcherryBazzaire Dec 19, 2018
ad89f90
Merge pull request #1 from WildcherryBazzaire/FrontEnd
TimsTomatos Dec 19, 2018
4917fd5
oo
TimsTomatos Dec 19, 2018
29630e4
added values in backend
TimsTomatos Dec 19, 2018
4ceac96
ppf
TimsTomatos Dec 20, 2018
995cb0b
oof
WildcherryBazzaire Dec 21, 2018
802558e
Merge pull request #2 from WildcherryBazzaire/tim
WildcherryBazzaire Dec 21, 2018
55a46b5
changed the database location and still working on the images and 3D@
WildcherryBazzaire Jan 2, 2019
d1cb1d6
Merge pull request #3 from WildcherryBazzaire/FrontEnd
WildcherryBazzaire Jan 3, 2019
8617bf6
ooga booga
WildcherryBazzaire Jan 9, 2019
8872bb5
Merge pull request #4 from WildcherryBazzaire/FrontEnd
TimsTomatos Jan 9, 2019
c953314
ye
TimsTomatos Jan 9, 2019
6ec3ea3
Fixed the Put and Delete Routes
TimsTomatos Jan 9, 2019
381523b
updated vue components
WildcherryBazzaire Jan 11, 2019
d4d9e5d
got the images working
WildcherryBazzaire Jan 12, 2019
6a88dbe
woomy
WildcherryBazzaire Jan 14, 2019
0eb0aa6
added the delete route
TimsTomatos Jan 14, 2019
0085228
Delete config.json
WildcherryBazzaire Jan 16, 2019
8675d2f
hiding config
WildcherryBazzaire Jan 16, 2019
02ea735
Merge pull request #5 from WildcherryBazzaire/master
WildcherryBazzaire Jan 16, 2019
3b253fe
Merge pull request #6 from WildcherryBazzaire/FrontEnd
TimsTomatos Jan 16, 2019
8e2c718
neatdo
WildcherryBazzaire Jan 16, 2019
75ae112
neatdo
WildcherryBazzaire Jan 16, 2019
6ac2c2e
delete works
WildcherryBazzaire Jan 16, 2019
37b601c
oof
WildcherryBazzaire Jan 16, 2019
8d09218
ooga booga
WildcherryBazzaire Jan 16, 2019
87d5168
Fixed some CSS
TimsTomatos Jan 16, 2019
ce7b162
Merge branch 'tim' of https://github.com/WildcherryBazzaire/movie-lis…
TimsTomatos Jan 16, 2019
050b0fa
Merge branch 'master' of https://github.com/WildcherryBazzaire/movie-…
TimsTomatos Jan 17, 2019
7ba6f10
Merge pull request #7 from WildcherryBazzaire/tim
TimsTomatos Jan 17, 2019
0887bbe
neat
WildcherryBazzaire Jan 18, 2019
f454e58
finally making it live! LOL
WildcherryBazzaire Apr 23, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"presets": [
["env", { "modules": false }],
"stage-3"
]
}
9 changes: 9 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 2
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# package directories
node_modules
jspm_packages
backend
# Serverless directories
.serverless
16 changes: 16 additions & 0 deletions backend/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"table": "movies",
"host": "jrdevleague.cb9co1xxtizk.us-west-2.rds.amazonaws.com",
"database": "whs_alex",
"user": "agent_8",
"password": "woomy",
"port": 5432,


"table2": "login",
"host2": "jrdevleague.cb9co1xxtizk.us-west-2.rds.amazonaws.com",
"database2": "whs_alex",
"user2": "agent_8",
"password2": "woomy",
"port2": "5432"
}
46 changes: 46 additions & 0 deletions backend/login_routes/mdelete.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
'use strict' //do not know what this does
const Pool = require('pg-pool'); //get PG pool for pool
const config = require('../config.json');

const { //gets variables from config.json
table,
host,
database,
user,
password,
port
} = config;

const pool = new Pool({ //makes a new Postgres instance
host,
database,
user,
password,
port,
idleTimeoutMillis: 1000
});

module.exports.deleteMovie = (event, context, callback) => {
let {value} = event.body;
const deleteSomeMovie = `DELETE FROM ${table} WHERE name= $1 ;`; //commands postgres to get data from table

pool.connect()
.then(client => {
client.release();
return client.query(deleteSomeMovie,[value]);
})
.then(data => {
const response = {
statusCode: 200,
headers: {
'Access-Control-Allow-Origin': '*',
'Access-Control-Allow-Credentials': true
},
body: JSON.stringify({
message: data,
input: event,
}),
};
callback(null, response);
});
};
Empty file added backend/login_routes/mpost.js
Empty file.
2 changes: 2 additions & 0 deletions backend/login_routes/mput.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
'use strict'
const
46 changes: 46 additions & 0 deletions backend/routes/delete.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
'use strict' //do not know what this does
const Pool = require('pg-pool'); //get PG pool for pool
const config = require('../config.json');

const { //gets variables from config.json
table,
host,
database,
user,
password,
port
} = config;

const pool = new Pool({ //makes a new Postgres instance
host,
database,
user,
password,
port,
idleTimeoutMillis: 1000
});

module.exports.deleteMovie = (event, context, callback) => {
let {value} = event.body;
const deleteSomeMovie = `DELETE FROM ${table} WHERE name= $1 ;`; //commands postgres to get data from table

pool.connect()
.then(client => {
client.release();
return client.query(deleteSomeMovie,[value]);
})
.then(data => {
const response = {
statusCode: 200,
headers: {
'Access-Control-Allow-Origin': '*',
'Access-Control-Allow-Credentials': true
},
body: JSON.stringify({
message: data,
input: event,
}),
};
callback(null, response);
});
};
45 changes: 45 additions & 0 deletions backend/routes/get.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
'use strict' //do not know what this does
const Pool = require('pg-pool'); //get PG pool for pool
const config = require('../config.json');

const { //gets variables from config.json
table,
host,
database,
user,
password,
port
} = config;

const pool = new Pool({ //makes a new Postgres instance
host,
database,
user,
password,
port,
idleTimeoutMillis: 1000
});

module.exports.getMovie = (event, context, callback) => {
const getAllMovies = `SELECT * FROM ${table}`; //commands postgres to get data from table

pool.connect()
.then(client => {
client.release();
return client.query(getAllMovies);
})
.then(data => {
const response = {
statusCode: 200,
headers: {
'Access-Control-Allow-Origin': '*',
'Access-Control-Allow-Credentials': true
},
body: JSON.stringify({
message: data,
input: event,
}),
};
callback(null, response);
});
};
46 changes: 46 additions & 0 deletions backend/routes/post.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
'use strict' //do not know what this does
const Pool = require('pg-pool'); //get PG pool for pool
const config = require('../config.json');

const { //gets variables from config.json
table,
host,
database,
user,
password,
port
} = config;

const pool = new Pool({ //makes a new Postgres instance
host,
database,
user,
password,
port,
idleTimeoutMillis: 1000
});

module.exports.postMovie = (event, context, callback) => {
let {name, rating, comment} = event.body;
const postSomeMovie = `INSERT INTO ${table} VALUES(DEFAULT,$1,$2,$3);`; //commands postgres to get data from table

pool.connect()
.then(client => {
client.release();
return client.query(postSomeMovie,[name,rating,comment]);
})
.then(data => {
const response = {
statusCode: 200,
headers: {
'Access-Control-Allow-Origin': '*',
'Access-Control-Allow-Credentials': true
},
body: JSON.stringify({
message: data,
input: event,
}),
};
callback(null, response);
});
};
60 changes: 60 additions & 0 deletions backend/routes/put.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
'use strict' //do not know what this does
const Pool = require('pg-pool'); //get PG pool for pool
const config = require('../config.json');

const { //gets variables from config.json
table,
host,
database,
user,
password,
port
} = config;

const pool = new Pool({ //makes a new Postgres instance
host,
database,
user,
password,
port,
idleTimeoutMillis: 1000
});

module.exports.putMovie = (event, context, callback) => {
let {oldMovie,newMovie} = event.body;
const putSomeMovie = `UPDATE ${table} SET name = $1 WHERE name = $2;`; //commands postgres to get data from table

pool.connect()
.then(client => {
client.release();
return client.query(putSomeMovie,[newMovie,oldMovie]);
})
.then(data => {
const response = {
statusCode: 200,
headers: {
'Access-Control-Allow-Origin': '*',
'Access-Control-Allow-Credentials': true
},
body: JSON.stringify({
message: data,
input: event,
}),
};


callback(null, response);
});
};

/*
{
"table": "movies",
"host": "jrdevleague.cb9co1xxtizk.us-west-2.rds.amazonaws.com",
"database": "whs_tim_kunta_kinte_jameson",
"user": "jrdevleague",
"password": "jrD3vLeague!",
"port": 5432
}
YOU FUCKIN SUCK !!!
*/
Binary file added dist/background.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions dist/build.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/build.js.map

Large diffs are not rendered by default.

11 changes: 11 additions & 0 deletions dist/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>movie_project</title>
</head>
<body>
<div id="app"></div>
<script src="./build.js"></script>
</body>
</html>
Binary file added dist/missing.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dist/rating_squid_filled.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dist/rating_squid_trans.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>movie_project</title>
</head>
<body>
<div id="app"></div>
<script src="/dist/build.js"></script>
</body>
</html>
Loading