-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
52 lines (48 loc) · 2.17 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<htmL>
<head>
<title>Cryptocurrency Balance Tracker</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/vue"></script>
<script src='./Scripts/CryptoBalanceTracker.js'></script>
<script src='./Scripts/CryptoPortfolio.js'></script>
</head>
<body>
<div id="app">
<table class="table">
<thead>
<tr>
<th scope="col">Currency</th>
<th scope="col">Units</th>
<th scope="col">Exchange</th>
<th scope="col">Current Price (USD)</th>
<th scope="col">Total (USD)</th>
<th scope="col">CurrentPrice (BTC)</th>
<th scope="col">Total (BTC)</th>
</tr>
</thead>
<tbody>
<tr v-for="entry in portfolio">
<td>{{ entry.name }} ({{ entry.symbol }})</td>
<td>{{ entry.amount }}</td>
<td>{{ entry.exchange }}</td>
<td>${{ entry.price > 1 ? entry.price.toFixed(2) :entry.price.toFixed(4) }}</td>
<td>${{ entry.total.toFixed(2) }}</td>
<td>{{ entry.price_btc.toFixed(7) }}</td>
<td>{{ entry.total_btc.toFixed(7) }}</td>
</tr>
<tr style="font-weight:bold">
<td>Totals</td>
<td></td>
<td></td>
<td></td>
<td>${{ total.toFixed(2) }}</td>
<td></td>
<td>{{ total_btc.toFixed(7) }}</td>
</tr>
</tbody>
</table>
</div>
<script src='./Scripts/balances.js'></script>
<script src='./Scripts/main.js'></script>
</body>
</html>