From 11b1bf934288894da133ea54ea97854f6e56b053 Mon Sep 17 00:00:00 2001 From: Cryptotron Date: Tue, 9 Apr 2013 08:53:35 -0400 Subject: [PATCH] UI modifications & last 10 blocks hash display (+ ABE links) --- README.md | 6 ++- http/link.gif | Bin 0 -> 70 bytes testnet.js | 32 +++++++++++++++- views/index.ejs | 96 ++++++++++++++++++++++++------------------------ 4 files changed, 84 insertions(+), 50 deletions(-) create mode 100644 http/link.gif diff --git a/README.md b/README.md index 403cc06..89e4013 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,8 @@ testnet ======= -Miniature http server to play with litecoin testnet. \ No newline at end of file +Miniature HTTP server to play with litecoin testnet (also acts as a faucet). + +To run a local instance, copy config/testnet.cfg to config/testnet..cfg +and modify it with your local RPC settings. + diff --git a/http/link.gif b/http/link.gif new file mode 100644 index 0000000000000000000000000000000000000000..24c993fa161681968f46d26fab951a0b8580593e GIT binary patch literal 70 zcmZ?wbhEHb6kyFcZTVs!m @@ -50,9 +57,19 @@ function Application() { var str = ""; // --- + _.each(response.last_blocks, function(o) { + str += ""+o.height+" - "+o.hash+"
"; + }); + + $("#last_blocks").html(str); + + // --- + str = "" _.each(response.info, function(v,n) { - str += ""; + str += ""; }) str += "
"+n+""+v+"
"+n+""; + str += v; + str += "
"; $("#info").html(str); @@ -89,26 +106,8 @@ function Application() { $("#fee_response").html(jt(data)); }); }) - - $("#tx_lookup").click(function(){ - var txhash = $("#tx_input").val(); - - $.getJSON("/tx/"+txhash, function(data) { - $("#tx_info").html(jt(data)); - }); - }) - - $("#block_lookup").click(function(){ - var blockhash = $("#tx_input").val(); - - $.getJSON("/block/"+blockhash, function(data) { - $("#block_info").html(jt(data)); - }); - }) - } - $(document).ready(function() { window.app = new Application(); }); @@ -116,42 +115,45 @@ $(document).ready(function() { -
LITECOIN TESTNET NODE INTERFACE +
LITECOIN TESTNET NODE INTERFACE

---- WALLET --- -WALLET ADDRESS: -BALANCE (0 confirms): +

WALLET +WALLET ADDRESS:
+BALANCE (0 confirms):
BALANCE (1 confirms): - ---- SEND --- +
+
+
SEND TO ADDRESS: AMOUNT: - -RESPONSE: - - ---- SET TX FEE --- +

+RESPONSE:
+ +

+
+
+
SET TX FEE FEE: - -RESPONSE: - - -------------------- -LOOKUP TX HASH: - - -------------------- -LOOKUP BLOCK HASH: - - -INFO: +

+RESPONSE:
+ +

+
+
+
LAST 10 BLOCKS + +
+
+
INFO - -CONNECTED PEERS: +
+
+
CONNECTED PEERS - +
+