diff --git a/static/js/rustico.js b/static/js/rustico.js index bbc18db..a5169a9 100644 --- a/static/js/rustico.js +++ b/static/js/rustico.js @@ -28,7 +28,11 @@ $(document).ready(function () { }) socket.on("connect", function(socket) { - console.log("Connected"); + $("#connectedtoast").toast("show") + }); + + socket.on("disconnect", function(socket) { + $("#disconnectedtoast").toast("show") }); socket.on("new_tick", function(data) { diff --git a/templates/index.html b/templates/index.html index 415e60f..ff05983 100644 --- a/templates/index.html +++ b/templates/index.html @@ -15,111 +15,122 @@ Hello world! -
+
-
-
-
-
-

Current price:

-
-
-
-

USD XXXX.XX

-
-
-

- Last updated 3 mins ago -

+
+
+
+
+

Current price:

-
-
- -
-
-
-
-

Open positions:

-
+
- - - - - - - - - - - - - - - - - - - -
IDDateAmountP/LActions
101/01/2020BTC +1.00001.00 % - -
+

USD XXXX.XX

+

+ Last updated 3 mins ago +

+
+
-
-
-
-

Open orders:

-
-
- - - - - - - - - - - - - - - - - -
IDDateAmountP/L
101/01/2020BTC +1.00001.00 %
-
+
+
+
+
+

Open positions:

+
+
+ + + + + + + + + + + + + + + + + + + +
IDDateAmountP/LActions
101/01/2020BTC +1.00001.00 % + +
-
-
-
- +
+
+
+

Open orders:

+
+
+ + + + + + + + + + + + + + + + + +
IDDateAmountP/L
101/01/2020BTC +1.00001.00 %
-
+ -
+
+
+
+ +
+
+
+
+ +
+ + Connected! +
+ + + + - + + + + \ No newline at end of file