OSDN Git Service

update
authorChengcheng Zhang <943420582@qq.com>
Mon, 14 Jan 2019 08:30:28 +0000 (16:30 +0800)
committerChengcheng Zhang <943420582@qq.com>
Mon, 14 Jan 2019 08:30:28 +0000 (16:30 +0800)
assets/main.js
bytom-kit.html [new file with mode: 0644]

index 9b9ec62..7b65582 100644 (file)
@@ -1,10 +1,9 @@
 $(function(){
-  // 创建公钥按钮点击事件
-  $('#btnCreate').click(function(){
-    console.log('创建公钥');
+  $('#btnCreateNewKey').click(function(){
+    console.log('创建新密钥');
     $.ajax({
-      method: 'get',  //get or post
-      url: '/test',
+      method: 'post',  //get or post
+      url: 'http://127.0.0.1:5000/api/v1/create_entropy',
       data: {},
       dataType: 'json',
     }).done(function(data){
diff --git a/bytom-kit.html b/bytom-kit.html
new file mode 100644 (file)
index 0000000..ead5c6a
--- /dev/null
@@ -0,0 +1,47 @@
+<!DOCTYPE html>
+<html lang="en">
+
+<head>
+  <meta charset="UTF-8">
+  <meta name="viewport" content="width=device-width, initial-scale=1.0">
+  <meta http-equiv="X-UA-Compatible" content="ie=edge">
+  <title>Bytom Kit</title>
+  <link rel="stylesheet" href="./node_modules/bootstrap/dist/css/bootstrap.min.css">
+  <link rel="stylesheet" href="./assets/main.css">
+  <script src="./node_modules/jquery/dist/jquery.min.js"></script>
+  <script src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
+  <script src="./node_modules/layer/layer.js"></script>
+  <script src="./assets/main.js"></script>
+</head>
+
+<body>
+  <nav class="navbar navbar-default">
+    <div class="navbar-header">
+      <a href="#" class="navbar-brand">Bytom Kit</a>
+    </div>
+  </nav>
+  <div class="panel panel-default sc-bd">
+    <div class="panel-heading">
+      <h3 class="panel-title">Key </h3>
+    </div>
+    <div class="panel-body">
+      <form class="form-horizontal">
+        <!-- <div class="well well-sm">主网参数</div> -->
+        <div class="form-group">
+          <label class="col-sm-2 control-label">Entropy</label>
+          <div class="col-sm-10">
+            <input type="text" class="form-control" id="entropy" placeholder="16 Bytes entropy, e.g. 1db8b283eb4623e749732a341396e0c9">
+          </div>
+        </div>
+        <div class="form-group">
+          <div class="col-sm-offset-2 col-sm-10">
+            <button id="btnCteateNewKey" type="submit" class="btn btn-primary">Create New Key</button> 
+            <button id="btnReset" type="submit" class="btn btn-primary">Reset</button>
+          </div>
+        </div>
+      </form>
+    </div>
+  </div>
+</body>
+
+</html>
\ No newline at end of file