Skip to content
Snippets Groups Projects
Commit 84f8e590 authored by david timothy panjaitan's avatar david timothy panjaitan
Browse files

Merge branch 'develop' into 'AdminEndpoints'

# Conflicts:
#   app.py
parents 99e38b84 f286533b
2 merge requests!5Develop,!2Admin endpoints
Pipeline #12531 failed with stage
from flask import Flask, render_template from flask import Flask, render_template
from flask import request, jsonify from flask import request, jsonify
from flask_cors import CORS
from database.database import mongo from database.database import mongo
from modules.login import login_route from modules.login import login_route
from modules.comment import comment_route from modules.comment import comment_route
...@@ -15,6 +16,9 @@ app.register_blueprint(login_route) ...@@ -15,6 +16,9 @@ app.register_blueprint(login_route)
app.register_blueprint(register_route) app.register_blueprint(register_route)
app.register_blueprint(comment_route) app.register_blueprint(comment_route)
app.register_blueprint(admin_route) app.register_blueprint(admin_route)
cors = CORS(app)
@app.route("/api/") @app.route("/api/")
def hello(): def hello():
return "Backend server dari proyek VIS-MASY" return "Backend server dari proyek VIS-MASY"
......
MONGODB_DB = "viz-masy" MONGODB_DB = "viz-masy"
MONGODB_HOST = "localhost" MONGODB_HOST = "localhost"
MONGODB_PORT = 27017 MONGODB_PORT = 27017
SECRET_KEY = "13516075_13516063" SECRET_KEY = "13516075_13516063"
\ No newline at end of file CORS_HEADERS = "Content-Type"
\ No newline at end of file
...@@ -2,4 +2,12 @@ ...@@ -2,4 +2,12 @@
Backend server untuk proyek VIS-MASY yang dibuat dengan python flask. Backend server untuk proyek VIS-MASY yang dibuat dengan python flask.
Server ini akan menyediakan api yang menangani akun-akun pengguna dan pemrosesan data. Server ini akan menyediakan api yang menangani akun-akun pengguna dan pemrosesan data.
\ No newline at end of file
## Dependency
```
pip install flask
pip install flask_mongoengine
pip install PyJWT
```
\ No newline at end of file
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment