Skip to content

Commit

Permalink
server update
Browse files Browse the repository at this point in the history
  • Loading branch information
IgolJack committed Oct 28, 2020
1 parent 42ee05e commit fc05736
Show file tree
Hide file tree
Showing 51 changed files with 5,474 additions and 6,029 deletions.
1 change: 1 addition & 0 deletions server/.gitignore → .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/node_modules
*.env
/build
21 changes: 0 additions & 21 deletions client/.gitignore

This file was deleted.

File renamed without changes.
9 changes: 6 additions & 3 deletions client/package.json → package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,13 @@
"@testing-library/user-event": "^7.1.2",
"antd": "^4.6.6",
"bootstrap": "^4.5.2",
"dotenv": "^8.2.0",
"express": "^4.17.1",
"firebase": "^7.17.1",
"firebase-admin": "^9.3.0",
"i": "^0.3.6",
"moment": "^2.29.1",
"nodemailer": "^6.4.14",
"react": "^16.13.1",
"react-big-calendar": "^0.28.1",
"react-bootstrap": "^1.3.0",
Expand All @@ -19,8 +23,7 @@
"react-scripts": "^2.1.8"
},
"scripts": {
"start": "react-scripts start",
"install": "react-scripts install",
"start": "node server.js",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
Expand All @@ -43,5 +46,5 @@
"devDependencies": {
"@babel/plugin-transform-react-jsx": "^7.10.4"
},
"proxy":"https://localhost:5000"
"proxy": "https://localhost:5000"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
12 changes: 8 additions & 4 deletions server/server.js → server.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const nodemailer = require("nodemailer");


require("dotenv").config({ path: __dirname + "/variables.env" });
require('dotenv').config({path: __dirname + "/variables.env"})


const sound_pass = process.env.SOUNDCOLOR_PASS;
const google= JSON.parse(process.env.GOOGLE);
Expand All @@ -23,16 +23,17 @@ const { request } = require("express");
const app = express();
const port = process.env.PORT || 5000;

app.use(bodyParser.json());
app.use(bodyParser.urlencoded({ extended: true }));


app.use(express.static(__dirname));
app.use(express.static(path.join(__dirname, 'build')));

//======================================================================//
//=============================GET=FIREBASE=============================//
//======================================================================//



//=================получить данные всех events [{a,b,c...}]=============//
app.get("/api/getAllEvents", (request, response) => {
db.collection("eventsCalendar")
Expand Down Expand Up @@ -294,7 +295,10 @@ transporter.sendMail(mailOptions, function(error, info){




//обслуживание html
app.get('/*', function (req, res) {
res.sendFile(path.join(__dirname, 'build', 'index.html'));
});



Expand Down
13 changes: 0 additions & 13 deletions server/now.json

This file was deleted.

Loading

0 comments on commit fc05736

Please sign in to comment.