2 Commits

Author SHA1 Message Date
root
8fefeb8b08 fix: security bugs for zhizhen 2021-08-19 17:29:10 +08:00
root
7482d0a1ae style update 2021-08-09 23:24:09 +08:00
23 changed files with 9320 additions and 2953 deletions

View File

@@ -2,7 +2,7 @@
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Cache-Control" content="no-cache"/> <meta http-equiv="Cache-Control" content="no-cache"/>
<title>数瑞智能合约在线编辑器</title> <title>智能合约在线编辑器</title>
<script src="./jqueryui1.12/jquery-2.1.4.js"></script> <script src="./jqueryui1.12/jquery-2.1.4.js"></script>
<link href="./jqueryui1.12/jquery-ui.css" rel="stylesheet"> <link href="./jqueryui1.12/jquery-ui.css" rel="stylesheet">
<script src="./jqueryui1.12/jquery-ui.js"></script> <script src="./jqueryui1.12/jquery-ui.js"></script>
@@ -134,7 +134,7 @@
<div class="col-4"> <div class="col-4">
<a class="navbar-brand" href="#"> <img alt="Brand" <a class="navbar-brand" href="#"> <img alt="Brand"
src="./images/logo-1.png" style="height: 30px;"> src="./images/logo-1.png" style="height: 30px;">
</a> <span>数瑞智能合约在线编辑器</span><input id="uploadFileInput" type="file" </a> <span>智能合约在线编辑器</span><input id="uploadFileInput" type="file"
name="file" multiple onchange="uploadFile()" style="display: none;"> name="file" multiple onchange="uploadFile()" style="display: none;">
</div> </div>
<div class="nav navbar-right userName" data-toggle="modal" <div class="nav navbar-right userName" data-toggle="modal"

View File

@@ -2,7 +2,7 @@
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Cache-Control" content="no-cache"/> <meta http-equiv="Cache-Control" content="no-cache"/>
<title>数瑞智能合约节点管理中心</title> <title>智能合约节点管理中心</title>
<script src="./jqueryui1.12/jquery-2.1.4.js"></script> <script src="./jqueryui1.12/jquery-2.1.4.js"></script>
<script src="./js/popper.min.js"></script> <script src="./js/popper.min.js"></script>
@@ -67,7 +67,7 @@
<div class="col-4"> <div class="col-4">
<a class="navbar-brand" href="#"> <img alt="Brand" <a class="navbar-brand" href="#"> <img alt="Brand"
src="./images/logo-1.png" style="height: 30px"> src="./images/logo-1.png" style="height: 30px">
</a> <span>数瑞智能合约节点管理中心</span> </a> <span>智能合约节点管理中心</span>
</div> </div>
<div class="nav navbar-right userName" data-toggle="modal" <div class="nav navbar-right userName" data-toggle="modal"
@@ -280,9 +280,7 @@
<option value="3">RARF</option> <option value="3">RARF</option>
<option value="4">RARH</option> <option value="4">RARH</option>
<option value="5">RARA</option> <option value="5">RARA</option>
<option value="6">Sharding</option> <option value="6">Shading</option>
<option value="7">SASharding</option>
<option value="8">PBFT</option>
</select> </select>
<div class="btn-group mr-3" role="group" <div class="btn-group mr-3" role="group"
style="margin-left: 2%"> style="margin-left: 2%">
@@ -506,8 +504,7 @@
</div> </div>
<input type="text" class="form-control" placeholder="输入参数" id="arg"> <input type="text" class="form-control" placeholder="输入参数" id="arg">
<input type="text" class="form-control col-2" placeholder="输入gas" <input type="text" class="form-control col-2" placeholder="输入gas" id="gasLimit">
id="gasLimit">
<div class="input-group-append"> <div class="input-group-append">
<div class="input-group-text"> <div class="input-group-text">
<input type="checkbox" id="executeContractAsDebug" <input type="checkbox" id="executeContractAsDebug"
@@ -556,8 +553,7 @@
<span class="input-group-text">参数</span> <span class="input-group-text">参数</span>
</div> </div>
<input type="text" class="form-control" placeholder="输入参数" <input type="text" class="form-control" placeholder="输入参数" id="maskArg">
id="maskArg">
<div class="input-group-append"> <div class="input-group-append">
<button onclick="getMask()" type="button" <button onclick="getMask()" type="button"
@@ -590,8 +586,7 @@
<span class="input-group-text">参数</span> <span class="input-group-text">参数</span>
</div> </div>
<input type="text" class="form-control" placeholder="输入参数" <input type="text" class="form-control" placeholder="输入参数" id="mockArg">
id="mockArg">
<div class="input-group-append"> <div class="input-group-append">
<button onclick="getMock()" type="button" <button onclick="getMock()" type="button"
@@ -1340,7 +1335,6 @@
//initWSocket(); //initWSocket();
</script> </script>
</body> </body>

File diff suppressed because it is too large Load Diff

View File

@@ -35,11 +35,7 @@
<!--script src="./js/echartsTheme.js"></script --> <!--script src="./js/echartsTheme.js"></script -->
<!-- script src="./js/echarts-gl.min.js"></script --> <!-- script src="./js/echarts-gl.min.js"></script -->
<script src="./js/sm2.js"></script> <script src="./js/sm2.js"></script>
<script src="./js/sm3.js"></script>
<script src="./js/sm4.js"></script>
<script src="./js/sm/index.js"></script>
<script src="./js/d3.v5.min.js"></script> <script src="./js/d3.v5.min.js"></script>
<!-- script src="./js/dagre-d3.min.js"></script --> <!-- script src="./js/dagre-d3.min.js"></script -->
<script src="./js/tipsy/jquery.tipsy.min.js"></script> <script src="./js/tipsy/jquery.tipsy.min.js"></script>
@@ -68,7 +64,7 @@
} }
.projectButton.ui-state-active { .projectButton.ui-state-active {
background: #2E324C; background: #304156;
color: white; color: white;
} }
@@ -82,8 +78,8 @@
.nav-tabs .nav-link.active, .nav-tabs .nav-item.show .nav-link { .nav-tabs .nav-link.active, .nav-tabs .nav-item.show .nav-link {
color: white; color: white;
background-color: #2E324C; background-color: #304156;
border-color: #2E324C; border-color: #304156;
} }
.ui-tabs { .ui-tabs {
@@ -99,14 +95,14 @@
} }
.ui-menu-item.ui-state-active:hover { .ui-menu-item.ui-state-active:hover {
background: #2E324C; background: #304156;
color: white; color: white;
border: 1px solid #999; border: 1px solid #999;
} }
.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active, .ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active,
a.ui-button:active, .ui-button:active, .ui-button.ui-state-active:hover { a.ui-button:active, .ui-button:active, .ui-button.ui-state-active:hover {
background: #2E324C; background: #304156;
color: white; color: white;
border: 1px solid #999; border: 1px solid #999;
} }
@@ -120,7 +116,7 @@
} }
.fileLine:hover { .fileLine:hover {
background: #2E324C; background: #304156;
color: white; color: white;
cursor: pointer; cursor: pointer;
} }
@@ -139,7 +135,7 @@
<div class="col-4"> <div class="col-4">
<a class="navbar-brand" href="#"> <img alt="Brand" <a class="navbar-brand" href="#"> <img alt="Brand"
src="./images/logo-1.png" style="height: 30px"> src="./images/logo-1.png" style="height: 30px">
</a> <span>数瑞智能合约在线编辑器</span><input id="uploadFileInput" type="file" </a> <span>智能合约在线编辑器</span><input id="uploadFileInput" type="file"
name="file" multiple onchange="uploadFile()" style="display: none;"> name="file" multiple onchange="uploadFile()" style="display: none;">
</div> </div>
<div class="nav navbar-right userName" data-toggle="modal" <div class="nav navbar-right userName" data-toggle="modal"

View File

@@ -58,7 +58,7 @@
} }
.projectButton.ui-state-active { .projectButton.ui-state-active {
background: #2E324C; background: #304156;
color: white; color: white;
} }
@@ -72,8 +72,8 @@
.nav-tabs .nav-link.active, .nav-tabs .nav-item.show .nav-link { .nav-tabs .nav-link.active, .nav-tabs .nav-item.show .nav-link {
color: white; color: white;
background-color: #2E324C; background-color: #304156;
border-color: #2E324C; border-color: #304156;
} }
.ui-tabs { .ui-tabs {
@@ -89,14 +89,14 @@
} }
.ui-menu-item.ui-state-active:hover { .ui-menu-item.ui-state-active:hover {
background: #2E324C; background: #304156;
color: white; color: white;
border: 1px solid #999; border: 1px solid #999;
} }
.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active, .ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active,
a.ui-button:active, .ui-button:active, .ui-button.ui-state-active:hover { a.ui-button:active, .ui-button:active, .ui-button.ui-state-active:hover {
background: #2E324C; background: #304156;
color: white; color: white;
border: 1px solid #999; border: 1px solid #999;
} }
@@ -110,7 +110,7 @@
} }
.fileLine:hover { .fileLine:hover {
background: #2E324C; background: #304156;
color: white; color: white;
cursor: pointer; cursor: pointer;
} }

File diff suppressed because one or more lines are too long

View File

@@ -9,7 +9,7 @@
border: 1px solid rgba(0, 0, 0, .125); border: 1px solid rgba(0, 0, 0, .125);
border-radius: 5px; border-radius: 5px;
background: white; background: white;
color: #2E324C; color: #304156;
} }
.userName:hover { .userName:hover {
@@ -22,17 +22,17 @@
#horiNav { #horiNav {
padding-top: 10px; padding-top: 10px;
border: 1px solid rgba(0, 0, 0, .05); border: 1px solid rgba(0, 0, 0, .05);
background: #f8f9fa; background: #e9f6ff;
} }
#outputNav { #outputNav {
padding-top: 10px; padding-top: 10px;
border: 1px solid rgba(0, 0, 0, .05); border: 1px solid rgba(0, 0, 0, .05);
background: #f8f9fa; background: #e9f6ff;
} }
div .card { div .card {
background: #f8f9fa; background: #e9f6ff;
} }
#main { #main {
@@ -85,16 +85,16 @@ div .card {
.projectLine.collapsed { .projectLine.collapsed {
background: #D5D6DB; background: #D5D6DB;
color: #2E324C; color: #304156;
} }
.projectLine { .projectLine {
background: #2E324C; background: #304156;
color: white; color: white;
} }
.projectLine.collapsed:hover { .projectLine.collapsed:hover {
background: #2E324C; background: #304156;
color: white; color: white;
} }
@@ -111,7 +111,7 @@ div .card {
} }
.headerFooter { .headerFooter {
background: #2E324C; background: #304156;
color: white; color: white;
} }

BIN
images/logo-1.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 37 KiB

BIN
images/logo.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 118 KiB

View File

@@ -85,7 +85,7 @@
padding-bottom: 30px; padding-bottom: 30px;
width: 28%; width: 28%;
cursor: hand; cursor: hand;
background: #2E324C; background: #304156;
color: white; color: white;
} }
@@ -100,7 +100,7 @@
</style> </style>
</header> </header>
<body style="background: #2E324C; color: white;"> <body style="background: #304156; color: white;">
<div <div
style="width: 90%; max-width: 1000px; min-width: 850px; margin: 0 auto; margin-top: 3%;"> style="width: 90%; max-width: 1000px; min-width: 850px; margin: 0 auto; margin-top: 3%;">
<div style="width: 20%; float: right; margin-right: 0%"> <div style="width: 20%; float: right; margin-right: 0%">

File diff suppressed because it is too large Load Diff

View File

@@ -1,165 +0,0 @@
<html>
<header>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Cache-Control" content="no-cache"/>
<title>北大数瑞数联网网关</title>
<script src="./jqueryui1.12/jquery-2.1.4.js"></script>
<style>
.halfDiv {
float: left;
width: 100%;
height: 100%;
}
.projectTreeDiv {
height: auto;
padding: 0;
}
.halfDivRight {
float: left;
width: 100%;
height: 100%;
}
.ui-tabs {
padding: 0;
}
.ui-accordion .ui-accordion-content {
padding: 0;
}
#tabs-1 {
display: none;
}
.ui-tabs .ui-tabs-panel {
padding: 0;
}
.context-menu-root {
z-index: 10;
}
#projectDiv {
height: 83%;
width: 20%;
border: 0px solid grey;
float: left;
}
.CodeMirror {
height: auto
}
.logoimg {
width: auto;
height: auto;
max-width: 100%;
max-height: 100%;
}
input {
height: 32px;
}
.sendTransInput {
background-color: #f0e4e4;
border-radius: 5px;
margin: 5px;
width: 15%;
margin-left: 4%;
border: 0px;
}
.normalDiv {
float: left;
text-align: center;
border-radius: 5px;
margin: 2%;
padding: 5px;
padding-top: 30px;
padding-bottom: 30px;
width: 45%;
cursor: hand;
background: #2E324C;
color: white;
}
.iconimg {
width: auto;
height: auto;
max-width: 48px;
max-height: 48px;
vertical-align: middle;
filter: invert(100%);
}
</style>
</header>
<body style="background: #2E324C; color: white;">
<div
style="width: 90%; max-width: 1000px; min-width: 850px; margin: 0 auto; margin-top: 3%;">
<div style="width: 20%; float: right; margin-right: 0%">
<img src="./images/logo.png" class="logoimg"></img>
</div>
<div
style="width: fit-content; margin: 0; font-size: 200%; background-color: white; color: black; border-radius: 10px; float: left; padding: 10px;">
&nbsp;&nbsp;导航&nbsp;&nbsp;
</div>
<div
style="width: 100%; margin-top: 2%; float: left; background-color: white; border-radius: 10px;">
<div class="normalDiv" onclick="jumpTo('./OnlineIDE.html')">
<img src="./images/index/web.png" class="iconimg"></img><br/>
<span style="vertical-align: middle">网关接入管理</span>
</div>
<div class="normalDiv" onclick="jumpTo('./NodePortal_Gateway.html')">
<img src="./images/index/analysis.png" class="iconimg"></img><br/>
<span style="vertical-align: middle">网关配置管理</span>
</div>
</div>
<script>
jumpTo = function (addr) {
document.location.href = addr;
};
</script>
<br/>
<div style="width: fit-content; margin-top: 2%; float: right; border-radius: 10px; font-size: 50%">
Icons made by
<a href="https://www.flaticon.com/authors/monkik"
title="monkik" style="color: white;">monkik</a>
from
<a href="https://www.flaticon.com/" title="Flaticon"
style="color: white;">www.flaticon.com</a>
</div>
</div>
</body>
</html>
<!--
============ NodeCenter的一些链接其中39.106.6.6监听的是1817端口。 查看节点是否启动
http://39.106.6.6:18001/SCIDE/NodeCenter?action=ping 查看NodeCenter当前连接的节点
http://39.106.6.6:18001/SCIDE/NodeCenter?action=listCMInfo
刷新NodeCenter已连接节点的合约数据
http://39.106.6.6:18001/SCIDE/NodeCenter?action=updateContract
检查节点是否已连接,删除断开连接的节点
http://39.106.6.6:18001/SCIDE/NodeCenter?action=checkAlive
获取某个合约的日志数量
http://39.106.6.6:18001/SCIDE/NodeCenter?action=getLogSize&contractID=BDCoin
获取某个合约的日志从第offset条取count条
http://39.106.6.6:18001/SCIDE/NodeCenter?action=requestLog&contractID=BDCoin&offset=16&count=10
获取某个合约的日志取最新的count条
http://39.106.6.6:18001/SCIDE/NodeCenter?action=requestLastLog&contractID=BDCoin&count=10
-->

BIN
jqueryui1.12/.index.html.swp Executable file

Binary file not shown.

9214
jqueryui1.12/jquery-2.1.4.js vendored Normal file → Executable file

File diff suppressed because one or more lines are too long

View File

@@ -262,7 +262,7 @@ function showNodeTrustUnits(obj) {
} }
}; };
let html = "<table class='table display row-border' id='trustNodesUnitTabDivTab'>" + let html = "<table class='table display row-border' id='trustNodesUnitTabDivTab'>" +
"<thead><tr><th>序号</th><th>ID</th><th>类型</th><th>创建者</th><th>节点数目</th><th>节点列表</th></tr></thead>" + "<thead><tr><th>序号</th><th>ID</th><th>类型</th><th>创建者</th><th>节点数目</th><th>节点公钥</th></tr></thead>" +
"<tbody>"; "<tbody>";
const tableTail = "</tbody></table>"; const tableTail = "</tbody></table>";
if (global.nodeUnits) { if (global.nodeUnits) {
@@ -275,7 +275,7 @@ function showNodeTrustUnits(obj) {
<td>TCP</td> <td>TCP</td>
<td>${global.nodeUnits[i].key.substring(0, at_ - 1)}</td> <td>${global.nodeUnits[i].key.substring(0, at_ - 1)}</td>
<td>${nodes.length}</td> <td>${nodes.length}</td>
<td>${nodes.map(x => x.nodeName).sort().join(',')}</td> <td>${JSON.stringify(nodes)}</td>
</tr>` </tr>`
} }
} }

View File

@@ -137,7 +137,7 @@ ${table[i].name}
</tr>` </tr>`
} }
html += tableTail; html += tableTail;
html = "<h5 class='card-title'>DO实例列表</h5>" + html; html = "<h5 class='card-title'>合约实例列表</h5>" + html;
ciTabDiv.html(html); ciTabDiv.html(html);
$("#ciTabDivTab").DataTable( $("#ciTabDivTab").DataTable(
@@ -400,7 +400,7 @@ function executeContract() {
console.log(request.arg); console.log(request.arg);
const gasLimit = $('#gasLimit').val()/1; const gasLimit = $('#gasLimit').val()/1;
var toSign = request.contractID + "|" var toSign = request.contractID + "|"
+ request.operation + "|" + request.arg; + request.operation + "|" + arg ;
if (gasLimit>0){ if (gasLimit>0){
request.gasLimit = gasLimit; request.gasLimit = gasLimit;
toSign+= "|" + gasLimit; toSign+= "|" + gasLimit;
@@ -474,7 +474,6 @@ function getMask() {
localStorage.setItem("persisArg", JSON.stringify(request)); localStorage.setItem("persisArg", JSON.stringify(request));
global.wssocket.send(JSON.stringify(request)); global.wssocket.send(JSON.stringify(request));
} }
function setMask() { function setMask() {
const argDiv = $('#maskArg')[0]; const argDiv = $('#maskArg')[0];
const request = {}; const request = {};

View File

@@ -274,7 +274,7 @@ function getControlWsUrl(host) {
} }
path += "SCExecutor"; path += "SCExecutor";
if (isBaaS) { if (isBaaS) {
path = "/SCIDE/SCExecutor" path = path.replace("ide/", "")
} }
return prefix + host + path; return prefix + host + path;
} }
@@ -316,8 +316,8 @@ function onNodeLogin(data) {
console.log("onNodeLogin"); console.log("onNodeLogin");
pubkeyDialogVue.myRole = data.data; pubkeyDialogVue.myRole = data.data;
global.myRole = data.data; global.myRole = data.data;
loadNodeConfig();
loadUserMan(); loadUserMan();
loadNodeConfig();
} }
function apply() { function apply() {

View File

@@ -127,7 +127,15 @@ function getControlWsUrl(host) {
if (document.location.href.startsWith("https")) { if (document.location.href.startsWith("https")) {
prefix = "wss://"; prefix = "wss://";
} }
path = "/SCIDE/SCExecutor"; let path = document.location.pathname.lastIndexOf("/");
path = document.location.pathname.substr(0, path + 1);
if (path.indexOf("SCIDE") < 0) {
path += "SCIDE/";
}
path += "SCExecutor";
if (isBaaS) {
path = path.replace("ide/", "")
}
return prefix + host + path; return prefix + host + path;
} }

View File

@@ -75,7 +75,9 @@ var getControlWsUrl = function (host) {
var prefix = "ws://"; var prefix = "ws://";
if (document.location.href.startsWith("https")) if (document.location.href.startsWith("https"))
prefix = "wss://"; prefix = "wss://";
var path = "/SCIDE/SCExecutor"; var path = document.location.pathname.lastIndexOf("/");
path = document.location.pathname.substr(0, path + 1);
path += "SCExecutor";
return prefix + host + path; return prefix + host + path;
}; };
var initWSocket = function () { var initWSocket = function () {

View File

@@ -158,20 +158,20 @@ var onStartContract = function(obj) {
}; };
// 集群启动合约 // 集群启动合约
function startContractUnits(place) { var startContractUnits = function(place) {
// ZYX // ZYX
const unitsID = $("#selectUnits")[0].value.split("_")[1]; var unitsID = $("#selectUnits")[0].value.split("_")[1];
if (!unitsID || unitsID === "选择节点集群") { if(unitsID == undefined || unitsID == "选择节点集群"){
myToast("提示","请选择节点集群!"); myToast("提示","请选择节点集群!");
return; return;
} }
let peersID = ""; var peersID = "";
for (let i in global.units[unitsID]) { for ( var i in global.units[unitsID]) {
peersID += global.units[unitsID][i].pubKey + ","; peersID += global.units[unitsID][i].pubKey + ",";
} }
const request = {}; var request = {};
request.action = "startContractMultiPoint"; request.action = "startContractMultiPoint";
request.peersID = peersID; request.peersID = peersID;
@@ -181,13 +181,8 @@ function startContractUnits(place) {
myToast("提示","请选择集群合约模式!"); myToast("提示","请选择集群合约模式!");
return; return;
} }
request.selectUnitNum = Number($("#selectUnitNum")[0].value);
if (!request.selectUnitNum || isNaN(request.selectUnitNum)) {
myToast("提示", "请填写集群规模!");
return;
}
request.projectName = global.ypkName; request.projectName = global.ypkName;
if (!request.projectName || request.projectName == "请选择ypk文件") { if (request.projectName==undefined || request.projectName == "请选择ypk文件"){
myToast("提示","请选择合约!"); myToast("提示","请选择合约!");
return; return;
} }
@@ -195,7 +190,7 @@ function startContractUnits(place) {
request.sponsorPeerID = global.peerID; //peerID of the node request.sponsorPeerID = global.peerID; //peerID of the node
console.log(request); console.log(request);
global.wssocket.send(JSON.stringify(request)); global.wssocket.send(JSON.stringify(request));
} };
var onStartTrustfulContract = function(obj) { var onStartTrustfulContract = function(obj) {
console.log(obj); console.log(obj);

View File

@@ -3,7 +3,7 @@ function getDateDaysBefore(daysAgo) {
return new Date(dateStr).getTime() - daysAgo * 24 * 3600 * 1000; return new Date(dateStr).getTime() - daysAgo * 24 * 3600 * 1000;
} }
let primaryColor = "#2E324C"; let primaryColor = "#304156";
// ======Vue start // ======Vue start
let headerVue = ""; let headerVue = "";

View File

@@ -176,6 +176,8 @@ var getControlWsUrl = function(host) {
var prefix = "ws://"; var prefix = "ws://";
if (document.location.href.startsWith("https")) if (document.location.href.startsWith("https"))
prefix = "wss://"; prefix = "wss://";
var path = "/SCIDE/SCExecutor"; var path = document.location.pathname.lastIndexOf("/");
path = document.location.pathname.substr(0, path + 1);
path += "SCExecutor";
return prefix + host + path; return prefix + host + path;
}; };

View File

@@ -173,13 +173,9 @@ function importContractInstanceCodeByDOI() {
} }
function openInClient() { function openInClient() {
let path = document.location.pathname.lastIndexOf("/ide");
if (path > 0)
path = document.location.pathname.substr(0, path + 1);
else path = "/";
window.open(isBaaS ? window.open(isBaaS ?
`${location.origin}${path}client/BaaSClient.html${location.search}` : `${location.origin}/client/BaaSClient.html${location.search}` :
`${location.origin}${path}client/bdwareclient.html?self=true&` + `${location.origin}/client/bdwareclient.html?self=true&` +
`contract=${mainVue.contracts[selectedContract.value].id}`); `contract=${mainVue.contracts[selectedContract.value].id}`);
} }
@@ -224,7 +220,7 @@ function executeContract() {
const arg = executeContractArgInput.value; const arg = executeContractArgInput.value;
const gasLimit = $('#gasLimit').val()/1; const gasLimit = $('#gasLimit').val()/1;
request.pubkey = sm2Key.publicKey; request.pubkey = sm2Key.publicKey;
let toSign = request.contractID + "|" var toSign = request.contractID + "|"
+ request.operation + "|" + arg ; + request.operation + "|" + arg ;
if (gasLimit>0){ if (gasLimit>0){
request.gasLimit = gasLimit; request.gasLimit = gasLimit;