-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathStorage_dash.html
148 lines (122 loc) · 4.08 KB
/
Storage_dash.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<!DOCTYPE HTML>
<html>
<head>
<title>OpenGravier</title>
<link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700' rel='stylesheet' type='text/css'>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
</head>
<style>
body{
padding:0;
margin:0;
}
fieldset{
padding: 10px;
margin-top: 30px;
}
</style>
<body>
<fieldset>
<div class="container">
<ul class="nav nav-tabs">
<li id="show_orders"><a href="#orders">ORDERS</a></li>
<li id="show_post"><a href="#addpost"> ADD POST</a></li>
<li id="view_post"><a href="#viewpost">VIEW POST</a></li>
</ul>
<div id="addpost">
<form class="horizontal" id="add_form">
<div class="form-group">
<label for="capacity" class="text-danger">CAPACITY</label>
<input type="text" class="form-control" id="capacity" placeholder="Capacity"/>
</div>
<div class="form-group">
<label for="price" class="text-danger">PRICE</label>
<input type="number" class="form-control" id="price" placeholder="Price">
</div>
<button class="btn btn-default primary" id="add_store" onclick="postStore()">SUBMIT</button>
</form>
</div>
<div class="container" id="orders">
<table class="table table-responsive table-striped table-bordered table-hover">
<!--- <thead>
<th>Orders</th></thead>
<tr><td><button id="store_accept" class="button">ACCEPT</button></td>
<td><button id="store_reach" class="button">REACHED</button></td>
<td><button id="store_outgoing" class="button">OUT FOR DELIVERY</button></td>
</tr>
-->
<thead>
<th class="text-center text-success">ORDER ID</th>
<th class="text-center text-success">QUANTITY</th>
<th class="text-center text-success">OWNER NAME</th>
<th class="text-center text-success">TRANSPORT ID</th>
</thead>
<tbody id="store_details">
<tr>
<td id="order_id"></td>
<td id="quan"></td>
<td id="owner"></td>
<td id="trans"></td>
<td><button id="store_accept" class="button btn-success" value="ACCEPT"/>ACCEPT<button id="store_decline" class="button btn-danger" value="DECLINE"/>DECLINE</td>
</tr>
</tbody>
</table>
</div>
<div class="container" id="viewpost" class="panel">
<table class="table table-responsive table-striped table-bordered">
<thead>
<th class="text-center text-success">POST ID</th>
<th class="text-center text-success">CAPACITY</th>
<th class="text-center text-success">PRICE</th>
</thead>
<tbody id="store_orders" class="text-center text-warning">
</tbody>
</table>
</div>
<script>
$(document).ready(function() {
$("#addpost").hide();
$("#orders").show();
$("#viewpost").hide();
$("#show_orders").click(function(){
$("#show_orders").addClass("text-sucess");
$("#orders").show();
$("#addpost").hide();
//$("#orders").hide();
$("#viewpost").hide();
});
$("#show_post").click(function(){
$("#show_post").addClass("text-sucess");
$("#addpost").show();
$("#orders").hide();
$("#viewpost").hide();
});
$("#view_post").click(function(){
$("#view_post").addClass("text-sucess");
$("#viewpost").show();
$("#addpost").hide();
$("#orders").hide();
});
/*
$("#store_accept").click(function(){
$("#store_decline").hide();
$("store_details").addClass("panel-danger");
});
$("#store_decline").click(function(){
$("#store_accept").hide();
$("#store_decline").hide();
$("store_details").addClass("panel-warning");
});
*/
});
</script>
</fieldset>
<script src="https://cdn.rawgit.com/ethereum/web3.js/develop/dist/web3.js"></script>
<script src="https://code.jquery.com/jquery-3.1.1.slim.min.js"></script>
<script src="storePortal.js"></script>
</body>
</html>