mirror of
https://github.com/Manuel83/craftbeerpi3
synced 2026-08-10 02:55:27 +02:00
First Refactoring
- Major API Changes in Core Module - Will be changed further. Still work in progress
This commit is contained in:
+23
-1
@@ -1 +1,23 @@
|
||||
import endpoints
|
||||
from flask import Blueprint
|
||||
|
||||
from modules.core.core import cbpi
|
||||
|
||||
react = Blueprint('ui', __name__, template_folder='templates', static_folder='static')
|
||||
|
||||
@cbpi.addon.core.initializer(order=10)
|
||||
def init(cbpi):
|
||||
cbpi._app.register_blueprint(react, url_prefix='/ui')
|
||||
|
||||
|
||||
@react.route('/', methods=["GET"])
|
||||
def index():
|
||||
return react.send_static_file("index.html")
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,25 +0,0 @@
|
||||
from flask import Blueprint
|
||||
|
||||
from modules import cbpi
|
||||
|
||||
react = Blueprint('react', __name__, template_folder='templates', static_folder='static')
|
||||
|
||||
@cbpi.initalizer(order=10)
|
||||
def init(cbpi):
|
||||
cbpi.app.register_blueprint(react, url_prefix='/ui')
|
||||
|
||||
|
||||
|
||||
|
||||
@react.route('/', methods=["GET"])
|
||||
def index():
|
||||
return react.send_static_file("index.html")
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
+48
-44
File diff suppressed because one or more lines are too long
@@ -17,5 +17,6 @@
|
||||
<div id="root" ></div>
|
||||
<script src="static/bundle.js" type="text/javascript"></script>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user