Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
60f8e228
Commit
60f8e228
authored
Oct 16, 2017
by
ninabreznik
Committed by
yann300
Nov 23, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes to Terminal buttons
parent
745eb889
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
28 deletions
+29
-28
app.js
src/app.js
+4
-4
txLogger.js
src/app/execution/txLogger.js
+20
-20
run-tab.js
src/app/tabs/run-tab.js
+5
-4
No files found.
src/app.js
View file @
60f8e228
...
@@ -221,10 +221,10 @@ function run () {
...
@@ -221,10 +221,10 @@ function run () {
var
unit
=
'ether'
// default
var
unit
=
'ether'
// default
if
(
selectedUnit
===
'ether'
)
{
if
(
selectedUnit
===
'ether'
)
{
unit
=
'ether'
unit
=
'ether'
}
else
if
(
selectedUnit
===
'
microether
'
)
{
}
else
if
(
selectedUnit
===
'
finney
'
)
{
unit
=
'
microether
'
unit
=
'
finney
'
}
else
if
(
selectedUnit
===
'
m
wei'
)
{
}
else
if
(
selectedUnit
===
'
g
wei'
)
{
unit
=
'
m
wei'
unit
=
'
g
wei'
}
else
if
(
selectedUnit
===
'wei'
)
{
}
else
if
(
selectedUnit
===
'wei'
)
{
unit
=
'wei'
unit
=
'wei'
}
}
...
...
src/app/execution/txLogger.js
View file @
60f8e228
...
@@ -20,6 +20,9 @@ var css = csjs`
...
@@ -20,6 +20,9 @@ var css = csjs`
align-items: end;
align-items: end;
justify-content: space-between;
justify-content: space-between;
}
}
.txLog {
width: 75;
}
.tx {
.tx {
color:
${
styles
.
terminal
.
text_Title_TransactionLog
}
;
color:
${
styles
.
terminal
.
text_Title_TransactionLog
}
;
font-weight: bold;
font-weight: bold;
...
@@ -45,19 +48,16 @@ var css = csjs`
...
@@ -45,19 +48,16 @@ var css = csjs`
.buttons {
.buttons {
display: flex;
display: flex;
}
}
.debug {
${
styles
.
terminal
.
button_Log_Debug
}
}
.details {
${
styles
.
terminal
.
button_Log_Details
}
}
.debug, .details {
.debug, .details {
color:
${
styles
.
terminal
.
link_Debug
}
;
text-decoration: underline;
font-weight: bold;
min-height: 18px;
min-height: 18px;
max-height: 18px;
max-height: 18px;
width: 45px;
width: 55px;
min-width: 45px;
min-width: 55px;
font-size: 10px;
margin-left: 5px;
margin-left: 5px;
cursor: pointer;
}
}
.clipboardCopy {
.clipboardCopy {
margin-right: 0.5em;
margin-right: 0.5em;
...
@@ -157,8 +157,8 @@ function renderKnownTransaction (self, data) {
...
@@ -157,8 +157,8 @@ function renderKnownTransaction (self, data) {
<div class="
${
css
.
log
}
">
<div class="
${
css
.
log
}
">
${
context
(
self
,
{
from
,
to
,
data
})}
${
context
(
self
,
{
from
,
to
,
data
})}
<div class=
${
css
.
buttons
}
>
<div class=
${
css
.
buttons
}
>
<
button class=
${
css
.
details
}
onclick=
${
txDetails
}
>Details</button
>
<
div class=
${
css
.
details
}
onclick=
${
txDetails
}
>Details</div
>
<
button class=
${
css
.
debug
}
onclick=
${
debug
}
>Debug</button
>
<
div class=
${
css
.
debug
}
onclick=
${
debug
}
>Debug</div
>
</div>
</div>
</div>
</div>
</span>
</span>
...
@@ -206,10 +206,10 @@ function renderCall (self, data) {
...
@@ -206,10 +206,10 @@ function renderCall (self, data) {
var
tx
=
yo
`
var
tx
=
yo
`
<span id="tx
${
data
.
tx
.
hash
}
">
<span id="tx
${
data
.
tx
.
hash
}
">
<div class="
${
css
.
log
}
">
<div class="
${
css
.
log
}
">
<span><span class=
${
css
.
tx
}
>[call]</span> from:
${
from
}
, to:
${
to
}
, data:
${
input
}
, return: </span>
<span
class=
${
css
.
txLog
}
><span class=
${
css
.
tx
}
>[call]</span> from:
${
from
}
, to:
${
to
}
, data:
${
input
}
, return: </span>
<div class=
${
css
.
buttons
}
>
<div class=
${
css
.
buttons
}
>
<
button class=
${
css
.
details
}
onclick=
${
txDetails
}
>Details</button
>
<
div class=
${
css
.
debug
}
onclick=
${
debug
}
>Debug</div
>
<
button class=
${
css
.
debug
}
onclick=
${
debug
}
>Debug</button
>
<
div class=
${
css
.
details
}
onclick=
${
txDetails
}
>Details</div
>
</div>
</div>
</div>
</div>
<div>
${
JSON
.
stringify
(
typeConversion
.
stringify
(
data
.
resolvedData
.
decodedReturnValue
),
null
,
'
\
t'
)}
</div>
<div>
${
JSON
.
stringify
(
typeConversion
.
stringify
(
data
.
resolvedData
.
decodedReturnValue
),
null
,
'
\
t'
)}
</div>
...
@@ -253,8 +253,8 @@ function renderUnknownTransaction (self, data) {
...
@@ -253,8 +253,8 @@ function renderUnknownTransaction (self, data) {
<div class="
${
css
.
log
}
">
<div class="
${
css
.
log
}
">
${
context
(
self
,
{
from
,
to
,
data
})}
${
context
(
self
,
{
from
,
to
,
data
})}
<div class=
${
css
.
buttons
}
>
<div class=
${
css
.
buttons
}
>
<
button class=
${
css
.
details
}
onclick=
${
txDetails
}
>Details</button
>
<
div class=
${
css
.
details
}
onclick=
${
txDetails
}
>Details</div
>
<
button class=
${
css
.
debug
}
onclick=
${
debug
}
>Debug</button
>
<
div class=
${
css
.
debug
}
onclick=
${
debug
}
>Debug</div
>
</div>
</div>
</div>
</div>
</span>
</span>
...
@@ -284,7 +284,7 @@ function renderUnknownTransaction (self, data) {
...
@@ -284,7 +284,7 @@ function renderUnknownTransaction (self, data) {
}
}
function
renderEmptyBlock
(
self
,
data
)
{
function
renderEmptyBlock
(
self
,
data
)
{
return
yo
`<span><span class='
${
css
.
tx
}
'>[block:
${
data
.
block
.
number
}
- 0 transactions]</span></span>`
return
yo
`<span
class=
${
css
.
txLog
}
><span class='
${
css
.
tx
}
'>[block:
${
data
.
block
.
number
}
- 0 transactions]</span></span>`
}
}
function
context
(
self
,
opts
)
{
function
context
(
self
,
opts
)
{
...
@@ -300,13 +300,13 @@ function context (self, opts) {
...
@@ -300,13 +300,13 @@ function context (self, opts) {
var
i
=
data
.
tx
.
transactionIndex
var
i
=
data
.
tx
.
transactionIndex
var
value
=
val
?
typeConversion
.
toInt
(
val
)
:
0
var
value
=
val
?
typeConversion
.
toInt
(
val
)
:
0
if
(
executionContext
.
getProvider
()
===
'vm'
)
{
if
(
executionContext
.
getProvider
()
===
'vm'
)
{
return
yo
`<span><span class=
${
css
.
tx
}
>[vm]</span> from:
${
from
}
, to:
${
to
}
, value:
${
value
}
wei, data:
${
input
}
,
${
logs
}
logs, hash:
${
hash
}
</span>`
return
yo
`<span
class=
${
css
.
txLog
}
><span class=
${
css
.
tx
}
>[vm]</span> from:
${
from
}
, to:
${
to
}
, value:
${
value
}
wei, data:
${
input
}
,
${
logs
}
logs, hash:
${
hash
}
</span>`
}
else
if
(
executionContext
.
getProvider
()
!==
'vm'
&&
data
.
resolvedData
)
{
}
else
if
(
executionContext
.
getProvider
()
!==
'vm'
&&
data
.
resolvedData
)
{
return
yo
`<span><span class='
${
css
.
tx
}
'>[block:
${
block
}
txIndex:
${
i
}
]</span> from:
${
from
}
, to:
${
to
}
, value:
${
value
}
wei,
${
logs
}
logs, data:
${
input
}
, hash:
${
hash
}
</span>`
return
yo
`<span
class=
${
css
.
txLog
}
><span class='
${
css
.
tx
}
'>[block:
${
block
}
txIndex:
${
i
}
]</span> from:
${
from
}
, to:
${
to
}
, value:
${
value
}
wei,
${
logs
}
logs, data:
${
input
}
, hash:
${
hash
}
</span>`
}
else
{
}
else
{
to
=
helper
.
shortenHexData
(
to
)
to
=
helper
.
shortenHexData
(
to
)
hash
=
helper
.
shortenHexData
(
data
.
tx
.
blockHash
)
hash
=
helper
.
shortenHexData
(
data
.
tx
.
blockHash
)
return
yo
`<span><span class='
${
css
.
tx
}
'>[block:
${
block
}
txIndex:
${
i
}
]</span> from:
${
from
}
, to:
${
to
}
, value:
${
value
}
wei</span>`
return
yo
`<span
class=
${
css
.
txLog
}
><span class='
${
css
.
tx
}
'>[block:
${
block
}
txIndex:
${
i
}
]</span> from:
${
from
}
, to:
${
to
}
, value:
${
value
}
wei</span>`
}
}
}
}
...
...
src/app/tabs/run-tab.js
View file @
60f8e228
...
@@ -91,6 +91,7 @@ var css = csjs`
...
@@ -91,6 +91,7 @@ var css = csjs`
}
}
.contractNames {
.contractNames {
${
styles
.
rightPanel
.
runTab
.
dropdown_RunTab
}
${
styles
.
rightPanel
.
runTab
.
dropdown_RunTab
}
width: 100%;
}
}
.subcontainer {
.subcontainer {
display: flex;
display: flex;
...
@@ -274,8 +275,8 @@ function contractDropdown (appAPI, appEvents, instanceContainer) {
...
@@ -274,8 +275,8 @@ function contractDropdown (appAPI, appEvents, instanceContainer) {
</div>
</div>
<div class="
${
css
.
buttons
}
">
<div class="
${
css
.
buttons
}
">
<div class="
${
css
.
button
}
">
<div class="
${
css
.
button
}
">
${
createButtonInput
}
${
createButtonInput
}
<div class="
${
css
.
create
}
" onclick=
${
function
()
{
createInstance
()
}
} >Create</div>
<div class="
${
css
.
create
}
" onclick=
${
function
()
{
createInstance
()
}
} >Create</div>
</div>
</div>
<div class="
${
css
.
button
}
">
<div class="
${
css
.
button
}
">
${
atAddressButtonInput
}
${
atAddressButtonInput
}
...
@@ -425,8 +426,8 @@ function settings (appAPI, appEvents) {
...
@@ -425,8 +426,8 @@ function settings (appAPI, appEvents) {
<input type="text" class="
${
css
.
col2_1
}
" id="value" value="0" title="Enter the value and choose the unit">
<input type="text" class="
${
css
.
col2_1
}
" id="value" value="0" title="Enter the value and choose the unit">
<select name="unit" class="
${
css
.
col2_2
}
" id="unit">
<select name="unit" class="
${
css
.
col2_2
}
" id="unit">
<option data-unit="wei">wei</option>
<option data-unit="wei">wei</option>
<option data-unit="
mwei">m
wei</option>
<option data-unit="
gwei">g
wei</option>
<option data-unit="
microether">microether
</option>
<option data-unit="
finney">finney
</option>
<option data-unit="ether">ether</option>
<option data-unit="ether">ether</option>
</select>
</select>
</div>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment