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
03480700
Commit
03480700
authored
Feb 27, 2019
by
Grandschtroumpf
Committed by
yann300
Mar 04, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
standard
parent
da888d4b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
11 deletions
+13
-11
compile-tab.js
src/app/tabs/compile-tab.js
+11
-7
compilerContainer.js
src/app/tabs/compileTab/compilerContainer.js
+2
-4
No files found.
src/app/tabs/compile-tab.js
View file @
03480700
...
...
@@ -153,7 +153,7 @@ class CompileTab {
* Section to select the compiled contract
* @param {string[]} contractList Names of the compiled contracts
*/
contractSelection
(
contractList
=
[])
{
contractSelection
(
contractList
=
[])
{
return
contractList
.
length
!==
0
?
yo
`<section class="
${
css
.
container
}
">
<!-- Select Compiler Version -->
...
...
@@ -161,7 +161,7 @@ class CompileTab {
<div class="input-group-prepend">
<label class="input-group-text" for="compiledContracts">Contract</label>
</div>
<select onchange="
${
e
=>
this
.
select
edContract
=
e
.
value
}
" id="compiledContracts" class="custom-select">
<select onchange="
${
e
=>
this
.
select
Contract
(
e
.
value
)
}
" id="compiledContracts" class="custom-select">
${
contractList
.
map
((
name
)
=>
yo
`<option value="
${
name
}
">
${
name
}
</option>`
)}
</select>
</header>
...
...
@@ -195,11 +195,11 @@ class CompileTab {
}
// TODO : Add success alert when compilation succeed
contractCompiledSuccess
()
{
contractCompiledSuccess
()
{
return
yo
``
}
// TODO : Add error alert when compilation failed
contractCompiledError
()
{
contractCompiledError
()
{
return
yo
``
}
...
...
@@ -207,7 +207,11 @@ class CompileTab {
* METHODS
*/
publish
()
{
selectContract
(
contractName
)
{
this
.
selectContract
=
contractName
}
publish
()
{
const
selectContractNames
=
this
.
_view
.
contractNames
if
(
selectContractNames
.
children
.
length
>
0
&&
selectContractNames
.
selectedIndex
>=
0
)
{
var
contract
=
this
.
data
.
contractsDetails
[
selectContractNames
.
children
[
selectContractNames
.
selectedIndex
].
innerHTML
]
...
...
@@ -234,7 +238,7 @@ class CompileTab {
}
}
details
()
{
details
()
{
const
help
=
{
'Assembly'
:
'Assembly opcodes describing the contract including corresponding solidity source code'
,
'Opcodes'
:
'Assembly opcodes describing the contract'
,
...
...
@@ -306,7 +310,7 @@ class CompileTab {
}
copyContractProperty
(
property
)
{
let
content
=
getContractProperty
(
property
)
let
content
=
this
.
getContractProperty
(
property
)
if
(
!
content
)
{
addTooltip
(
'No content available for '
+
property
)
return
...
...
src/app/tabs/compileTab/compilerContainer.js
View file @
03480700
...
...
@@ -34,7 +34,7 @@ class CompilerContainer {
/**
* Update the compilation button with the name of the current file
*/
set
currentFile
(
name
)
{
set
currentFile
(
name
)
{
if
(
!
this
.
_view
.
compilationButton
)
return
const
button
=
this
.
compilationButton
(
name
.
split
(
'/'
).
pop
())
yo
.
update
(
this
.
_view
.
compilationButton
,
button
)
...
...
@@ -92,8 +92,7 @@ class CompilerContainer {
/**************
* SUBCOMPONENT
*/
compilationButton
(
name
)
{
console
.
log
({
name
})
compilationButton
(
name
)
{
return
yo
`
<div class="
${
css
.
compilerArticle
}
">
<button class="btn btn-primary btn-block" title="Compile" onclick="
${
this
.
compile
.
bind
(
this
)}
">
...
...
@@ -102,7 +101,6 @@ class CompilerContainer {
</div>`
}
render
()
{
this
.
compileTabLogic
.
compiler
.
event
.
register
(
'compilerLoaded'
,
(
version
)
=>
this
.
setVersionText
(
version
))
this
.
fetchAllVersion
((
allversions
,
selectedVersion
)
=>
{
...
...
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