From f35872c1c4f44aeb85e2ecfdbce349e287ff38d3 Mon Sep 17 00:00:00 2001 From: Jason Date: Mon, 27 Sep 2021 14:05:07 +0800 Subject: [PATCH] update --- src/App.vue | 14 ++++++++++++++ src/views/Home/index.vue | 14 +++++++++----- src/views/Other/analytical.vue | 29 +++++++++++++++++++++++++---- src/views/Other/broadcast.vue | 14 ++++++++++++-- src/views/Trade/detail.vue | 10 ++++++---- 5 files changed, 66 insertions(+), 15 deletions(-) diff --git a/src/App.vue b/src/App.vue index 9baabdb..d2e3a1f 100644 --- a/src/App.vue +++ b/src/App.vue @@ -54,4 +54,18 @@ a { text-decoration: none; color: #2055ca; } + +.inputTxt { + height: 250px; + vertical-align: middle; + overflow-y: auto; + width: 100%; + line-height: 14px; + word-break: break-all; + padding: 0px 11px; + background: #FFFFFF; + border-radius: 2px; + border: 2px solid rgba(235, 239, 241, 1); + font-size: 14px; +} diff --git a/src/views/Home/index.vue b/src/views/Home/index.vue index d05460a..79a2470 100644 --- a/src/views/Home/index.vue +++ b/src/views/Home/index.vue @@ -14,9 +14,8 @@
- {{ - filterHash(item.hash) - }} + + {{ filterHash(item.hash) }}
@@ -84,7 +83,13 @@ onBeforeUnmount(() => { clearInterval(Number(interval.value)) }) -const blockList = ref([]) +type HomeBlock = { + hash: string, + height: number, + txCount: number, + blockTime: number +} +const blockList = ref([]) const tradeList = ref([]) const getBlockList = () => { @@ -93,7 +98,6 @@ const getBlockList = () => { block.getHeaders(start, maxHeight.value, false).then(res => { blockList.value = res.result.items.reverse() }) - // block.getBlocks(start, maxHeight.value, false).then(res => { // res.result.items.reverse().forEach((item) => { // diff --git a/src/views/Other/analytical.vue b/src/views/Other/analytical.vue index 5a2187f..a5224a5 100644 --- a/src/views/Other/analytical.vue +++ b/src/views/Other/analytical.vue @@ -3,7 +3,7 @@ -
+

解析数据

您可以在此页面输入未签名的源数据,十六进制格式文本,将会解析成可读的格式。 @@ -13,29 +13,48 @@
解析数据 +
+
+{{ result }}
+    
+
diff --git a/src/views/Other/broadcast.vue b/src/views/Other/broadcast.vue index acd2379..328a077 100644 --- a/src/views/Other/broadcast.vue +++ b/src/views/Other/broadcast.vue @@ -2,7 +2,7 @@
-
+

广播数据

您可以在此页面输入签过名的源数据,十六进制格式文本,并将其广播到区块链网络。 @@ -21,7 +21,6 @@ import { Breadcrumb } from '@/components' import { ref } from 'vue' const data = ref('') - const decodeTransaction = () => { block.decodeRawTransaction(data.value).then(res => { console.log(res) @@ -30,6 +29,17 @@ const decodeTransaction = () => {