Browse Source

added pages blocks, txs, addresses, and beta section

master
arnaucode 6 years ago
parent
commit
58393a26e9
14 changed files with 245 additions and 13 deletions
  1. +5
    -1
      web/app.js
  2. +4
    -1
      web/css/bootstrapMaterialDarkOverwrite.css
  3. +1
    -1
      web/css/style.css
  4. +4
    -0
      web/index.html
  5. +16
    -0
      web/views/addresses/addresses.html
  6. +24
    -0
      web/views/addresses/addresses.js
  7. +11
    -0
      web/views/beta/beta.html
  8. +14
    -0
      web/views/beta/beta.js
  9. +51
    -0
      web/views/blocks/blocks.html
  10. +24
    -0
      web/views/blocks/blocks.js
  11. +15
    -10
      web/views/sidebar.html
  12. +1
    -0
      web/views/tx/tx.html
  13. +51
    -0
      web/views/txs/txs.html
  14. +24
    -0
      web/views/txs/txs.js

+ 5
- 1
web/app.js

@ -17,7 +17,11 @@ angular.module('webApp', [
'app.network',
'app.addressNetwork',
'app.sankey',
'app.dateAnalysis'
'app.dateAnalysis',
'app.blocks',
'app.txs',
'app.addresses',
'app.beta'
]).
config(['$locationProvider', '$routeProvider', function($locationProvider, $routeProvider) {
$locationProvider.hashPrefix('!');

+ 4
- 1
web/css/bootstrapMaterialDarkOverwrite.css

@ -4,6 +4,9 @@
body {
background: #424242!important;
}
a {
color: #9575CD!important;
}
.panel-heading {
border-radius: 0px!important;
}
@ -25,7 +28,7 @@ body {
color: #ffffff!important;
}
.list-group-item a {
color: #512DA8!important;
color: #9575CD!important;
}
.list-group-item-text {
color: #9575CD!important;

+ 1
- 1
web/css/style.css

@ -32,7 +32,7 @@
/* sidebar */
.o_sidebar a {
color: white;
color: white!important;
padding: 10px;
}

+ 4
- 0
web/index.html

@ -83,6 +83,10 @@
<script src="views/addressNetwork/addressNetwork.js"></script>
<script src="views/sankey/sankey.js"></script>
<script src="views/dateAnalysis/dateAnalysis.js"></script>
<script src="views/blocks/blocks.js"></script>
<script src="views/txs/txs.js"></script>
<script src="views/addresses/addresses.js"></script>
<script src="views/beta/beta.js"></script>
</body>
</html>

+ 16
- 0
web/views/addresses/addresses.html

@ -0,0 +1,16 @@
<div class="row">
<div class="col-md-12">
<div class="panel">
<div class="panel-heading c_deepPurpleG300to500">
<h3 class="panel-title">Last addresses used</h3>
</div>
<div class="panel-body">
<div class="list-group-item" ng-repeat="address in addresses">
<div class="row-content">
<a ng-href="#!/address/{{address.hash}}" class="list-group-item-text">{{address.hash}}</a>
</div>
</div>
</div>
</div>
</div>
</div>

+ 24
- 0
web/views/addresses/addresses.js

@ -0,0 +1,24 @@
'use strict';
angular.module('app.addresses', ['ngRoute'])
.config(['$routeProvider', function($routeProvider) {
$routeProvider.when('/addresses', {
templateUrl: 'views/addresses/addresses.html',
controller: 'AddressesCtrl'
});
}])
.controller('AddressesCtrl', function($scope, $http) {
//last addr
$scope.addresses = [];
$http.get(urlapi + 'lastaddr')
.then(function(data, status, headers, config) {
console.log(data);
$scope.addresses = data.data;
}, function(data, status, headers, config) {
console.log('data error');
});
});

+ 11
- 0
web/views/beta/beta.html

@ -0,0 +1,11 @@
<div class="row">
<div class="col-sm-12">
<a ng-href="#!/network" class="btn btn-raised btn-lg c_deepPurple400">
<i class="fa fa-chain o_sidebarIcon" aria-hidden="true"></i> Network
</a>
<a ng-href="#!/sankey" class="btn btn-raised btn-lg c_deepPurple400">
<i class="fa fa-code-fork o_sidebarIcon" aria-hidden="true"></i> Sankey Diagram
</a>
<a ng-href="#!/beta" class="btn btn-raised btn-lg c_deepPurple400">Known addresses</a>
</div>
</div>

+ 14
- 0
web/views/beta/beta.js

@ -0,0 +1,14 @@
'use strict';
angular.module('app.beta', ['ngRoute'])
.config(['$routeProvider', function($routeProvider) {
$routeProvider.when('/beta', {
templateUrl: 'views/beta/beta.html',
controller: 'BetaCtrl'
});
}])
.controller('BetaCtrl', function($scope, $http, $routeParams) {
});

+ 51
- 0
web/views/blocks/blocks.html

@ -0,0 +1,51 @@
<div class="row">
<div class="col-md-12">
<div class="panel">
<div class="panel-heading c_deepPurpleG300to500">
<h3 class="panel-title">Last Tx with amount</h3>
</div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>BlockHeight</th>
<th>Txid</th>
<th>Input</th>
<th>Output</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="tx in txs">
<td style="max-width:20px; overflow:hidden;">
<a ng-href="#!/block/{{tx.blockheight}}" class="list-group-item-text">
{{tx.blockheight}}
</a>
</td>
<td style="max-width:20px; overflow:hidden;">
<a ng-href="#!/address/{{tx.from}}" class="list-group-item-text">
{{tx.txid}}
</a>
</td>
<td style="max-width:20px; overflow:hidden;">
<table><tbody><tr ng-repeat="vin in tx.vin"><td>
<a ng-href="#!/address/{{vin.address}}" class="list-group-item-text">
{{vin.address}}
</a>
:{{vin.amount}}
</td></tr></tbody></table>
</td>
<td style="max-width:20px; overflow:hidden;">
<table><tbody><tr ng-repeat="vout in tx.vout"><td>
<a ng-href="#!/address/{{vout.address}}" class="list-group-item-text">
{{vout.address}}
</a>
:{{vout.value}}
</td></tr></tbody></table>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>

+ 24
- 0
web/views/blocks/blocks.js

@ -0,0 +1,24 @@
'use strict';
angular.module('app.blocks', ['ngRoute'])
.config(['$routeProvider', function($routeProvider) {
$routeProvider.when('/blocks', {
templateUrl: 'views/blocks/blocks.html',
controller: 'BlocksCtrl'
});
}])
.controller('BlocksCtrl', function($scope, $http) {
//last tx
$scope.txs = [];
$http.get(urlapi + 'lasttx')
.then(function(data, status, headers, config) {
console.log(data);
$scope.txs = data.data;
}, function(data, status, headers, config) {
console.log('data error');
});
});

+ 15
- 10
web/views/sidebar.html

@ -11,28 +11,33 @@
</a>
</li>
<li>
<a href="#!/network">
<i class="fa fa-chain o_sidebarIcon" aria-hidden="true"></i> Network
<a href="#!/addressNetwork">
<i class="fa fa-sitemap o_sidebarIcon" aria-hidden="true"></i> Address Network
</a>
</li>
<li>
<a href="#!/addressNetwork">
<i class="fa fa-sitemap o_sidebarIcon" aria-hidden="true"></i> Address Network
<a href="#!/dateAnalysis">
<i class="fa fa-bar-chart o_sidebarIcon" aria-hidden="true"></i> Date Analysis
</a>
</li>
<li>
<a href="#!/sankey">
<i class="fa fa-code-fork o_sidebarIcon" aria-hidden="true"></i> Sankey diagram
<a href="#!/blocks">
<i class="fa fa-chain o_sidebarIcon" aria-hidden="true"></i> Blocks
</a>
</li>
<li>
<a href="#!/dateAnalysis">
<i class="fa fa-bar-chart o_sidebarIcon" aria-hidden="true"></i> Date Analysis
<a href="#!/txs">
<i class="fa fa-square-o o_sidebarIcon" aria-hidden="true"></i> Transactions
</a>
</li>
<li>
<a href="#!/addresses">
<i class="fa fa-qrcode o_sidebarIcon" aria-hidden="true"></i> Addresses
</a>
</li>
<li>
<a href="javascript:void(0)">
<i class="fa fa-area-chart o_sidebarIcon" aria-hidden="true"></i> Timeline
<a ng-href="#!/beta">
<i class="fa fa-bug o_sidebarIcon" aria-hidden="true"></i> Beta
</a>
</li>
<li>

+ 1
- 0
web/views/tx/tx.html

@ -6,6 +6,7 @@
</div>
<div class="panel-body">
<div class="col-sm-12">
BlockHeight: <a ng-href="#!/block/{{tx.blockheight}}">{{tx.blockheight}}</a>
<table class="table table-hover">
<thead>
<tr>

+ 51
- 0
web/views/txs/txs.html

@ -0,0 +1,51 @@
<div class="row">
<div class="col-md-12">
<div class="panel">
<div class="panel-heading c_deepPurpleG300to500">
<h3 class="panel-title">Last Tx with amount</h3>
</div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>BlockHeight</th>
<th>Txid</th>
<th>Input</th>
<th>Output</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="tx in txs">
<td style="max-width:20px; overflow:hidden;">
<a ng-href="#!/block/{{tx.blockheight}}" class="list-group-item-text">
{{tx.blockheight}}
</a>
</td>
<td style="max-width:20px; overflow:hidden;">
<a ng-href="#!/address/{{tx.from}}" class="list-group-item-text">
{{tx.txid}}
</a>
</td>
<td style="max-width:20px; overflow:hidden;">
<table><tbody><tr ng-repeat="vin in tx.vin"><td>
<a ng-href="#!/address/{{vin.address}}" class="list-group-item-text">
{{vin.address}}
</a>
:{{vin.amount}}
</td></tr></tbody></table>
</td>
<td style="max-width:20px; overflow:hidden;">
<table><tbody><tr ng-repeat="vout in tx.vout"><td>
<a ng-href="#!/address/{{vout.address}}" class="list-group-item-text">
{{vout.address}}
</a>
:{{vout.value}}
</td></tr></tbody></table>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>

+ 24
- 0
web/views/txs/txs.js

@ -0,0 +1,24 @@
'use strict';
angular.module('app.txs', ['ngRoute'])
.config(['$routeProvider', function($routeProvider) {
$routeProvider.when('/txs', {
templateUrl: 'views/txs/txs.html',
controller: 'TxsCtrl'
});
}])
.controller('TxsCtrl', function($scope, $http) {
//last tx
$scope.txs = [];
$http.get(urlapi + 'lasttx')
.then(function(data, status, headers, config) {
console.log(data);
$scope.txs = data.data;
}, function(data, status, headers, config) {
console.log('data error');
});
});

Loading…
Cancel
Save