basic menu bar added

This commit is contained in:
Satinder Grewal 2017-06-24 18:01:59 +12:00
parent b6515fec20
commit 9e7af9f74e
3 changed files with 74 additions and 2 deletions

5
css/custom.css Normal file
View File

@ -0,0 +1,5 @@
.navmenu_top {
-webkit-box-shadow: 0px 0px 15px 0px rgba(163,163,163,1);
-moz-box-shadow: 0px 0px 15px 0px rgba(163,163,163,1);
box-shadow: 0px 0px 15px 0px rgba(163,163,163,1);
}

View File

@ -9,6 +9,7 @@
<!-- Bootstrap --> <!-- Bootstrap -->
<link href="css/bootstrap.min.css" rel="stylesheet"> <link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/custom.css" rel="stylesheet">
<style type="text/css"> <style type="text/css">
.table-fixed thead { .table-fixed thead {
@ -36,8 +37,39 @@
<![endif]--> <![endif]-->
</head> </head>
<body> <body>
<h3 style="text-align: center;">EasyDEX - Ugly GUI</h3>
<div class="container-fluid"> <!-- Section: Navigation Menu -->
<nav class="navbar navbar-default navbar-fixed-top navmenu_top">
<div class="container-fluid">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand">BarterDEX</a>
</div>
<!-- Collect the nav links, forms, and other content for toggling -->
<div class="collapse navbar-collapse" id="dexnav-collapse">
<ul class="nav navbar-nav dexnav_top_l">
<li class="active"><a href="javascript:void(0)" class="dexnav_exchange">Exchange</a></li>
<li><a href="javascript:void(0)" class="dexnav_balances">Balances</a></li>
</ul>
<ul class="nav navbar-nav navbar-right" style="display: none;">
<li><a href="javascript:void(0)">Link</a></li>
</ul>
</div><!-- /.navbar-collapse -->
</div><!-- /.container-fluid -->
</nav>
<!-- Section: Navigation Menu END -->
<h3 style="text-align: center; margin-top: 60px;">BarterDEX - Ugly GUI</h3>
<!-- Section: Exchange -->
<div class="container-fluid section section-exchange">
<div class="row"> <div class="row">
<div class="col-sm-2"> <div class="col-sm-2">
@ -264,6 +296,15 @@
</div> </div>
</div> </div>
</div>
<!-- Section: Exchange END -->
<!-- Section: Balances -->
<div class="container-fluid section section-balances" style="display: none;">
<div class="row"><h1 style="text-align: center; font-weight: 200">BALANCES, DEPOSITS &amp; WITHDRAWALS</h1></div>
</div>
<!-- Section: Balances END -->
<!-- jQuery (necessary for Bootstrap's JavaScript plugins) --> <!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
<script src="js/jquery.min.js"></script> <script src="js/jquery.min.js"></script>

View File

@ -1,4 +1,25 @@
$('.dexnav_exchange').click(function(e){
e.preventDefault();
//console.log('exchange menu clicked');
$('.section').hide();
$('.section-exchange').show();
$('.dexnav_top_l li').removeClass('active');
//$(this).parent().get( 0 ).addClass('active');
$(this).parent().addClass(" active");
});
$('.dexnav_balances').click(function(e){
e.preventDefault();
//console.log('balances menu clicked');
$('.section').hide();
$('.section-balances').show();
$('.dexnav_top_l li').removeClass('active');
//$(this).parent().get( 0 ).addClass('active');
$(this).parent().addClass(" active");
});
$('.dexratio-btn').click(function() { $('.dexratio-btn').click(function() {
var _dexratio = $('.dexratio-val').val(); var _dexratio = $('.dexratio-val').val();
@ -324,6 +345,7 @@ function get_price(base,rel) {
console.log(data); console.log(data);
if (!data.userpass === false) { if (!data.userpass === false) {
console.log('first marketmaker api call execution after marketmaker started.') console.log('first marketmaker api call execution after marketmaker started.')
sessionStorage.setItem('mm_userdata', data);
sessionStorage.setItem('mm_userpass', data.userpass); sessionStorage.setItem('mm_userpass', data.userpass);
sessionStorage.setItem('mm_mypubkey', data.mypubkey); sessionStorage.setItem('mm_mypubkey', data.mypubkey);
get_price(base,rel) get_price(base,rel)
@ -366,6 +388,7 @@ function get_marketmaker_userpass() {
console.log(data); console.log(data);
if (!data.userpass === false) { if (!data.userpass === false) {
console.log('first marketmaker api call execution after marketmaker started.') console.log('first marketmaker api call execution after marketmaker started.')
sessionStorage.setItem('mm_userdata', data);
sessionStorage.setItem('mm_userpass', data.userpass); sessionStorage.setItem('mm_userpass', data.userpass);
sessionStorage.setItem('mm_mypubkey', data.mypubkey); sessionStorage.setItem('mm_mypubkey', data.mypubkey);
get_marketmaker_userpass() get_marketmaker_userpass()
@ -396,6 +419,7 @@ $('.refresh_inv_table').click(function() {
data = inv_kmd_data data = inv_kmd_data
if (!data.userpass === false) { if (!data.userpass === false) {
console.log('first marketmaker api call execution after marketmaker started.') console.log('first marketmaker api call execution after marketmaker started.')
sessionStorage.setItem('mm_userdata', data);
sessionStorage.setItem('mm_userpass', data.userpass); sessionStorage.setItem('mm_userpass', data.userpass);
sessionStorage.setItem('mm_mypubkey', data.mypubkey); sessionStorage.setItem('mm_mypubkey', data.mypubkey);
$( ".inv_btn[data-coin='"+ coin +"']" ).trigger( "click" ); $( ".inv_btn[data-coin='"+ coin +"']" ).trigger( "click" );
@ -571,6 +595,7 @@ $('.inv_btn').click(function() {
console.log(data); console.log(data);
if (!data.userpass === false) { if (!data.userpass === false) {
console.log('first marketmaker api call execution after marketmaker started.') console.log('first marketmaker api call execution after marketmaker started.')
sessionStorage.setItem('mm_userdata', data);
sessionStorage.setItem('mm_userpass', data.userpass); sessionStorage.setItem('mm_userpass', data.userpass);
sessionStorage.setItem('mm_mypubkey', data.mypubkey); sessionStorage.setItem('mm_mypubkey', data.mypubkey);
$( ".inv_btn[data-coin='"+ coin +"']" ).trigger( "click" ); $( ".inv_btn[data-coin='"+ coin +"']" ).trigger( "click" );
@ -749,6 +774,7 @@ var check_orderbook = setInterval(function() {
//console.log(data); //console.log(data);
if (!data.userpass === false) { if (!data.userpass === false) {
console.log('first marketmaker api call execution after marketmaker started.') console.log('first marketmaker api call execution after marketmaker started.')
sessionStorage.setItem('mm_userdata', JSON.stringify(data));
sessionStorage.setItem('mm_userpass', data.userpass); sessionStorage.setItem('mm_userpass', data.userpass);
sessionStorage.setItem('mm_mypubkey', data.mypubkey); sessionStorage.setItem('mm_mypubkey', data.mypubkey);
} else { } else {