-
Notifications
You must be signed in to change notification settings - Fork 0
/
order_list.php
242 lines (165 loc) · 7.3 KB
/
order_list.php
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
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
<!DOCTYPE html>
<?php
?>
<html>
<!-- Mirrored from velikorodnov.com/html/homeshop/orders_list.html by HTTrack Website Copier/3.x [XR&CO'2014], Fri, 22 Jan 2016 16:29:04 GMT -->
<head>
<!-- Meta Tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Title -->
<title>HomeShop - HTML Template</title>
<!-- Fonts -->
<link href='http://fonts.googleapis.com/css?family=Roboto:400,300,300italic,400italic,500,700,900,700italic,500italic' rel='stylesheet' type='text/css'>
<!-- Stylesheets -->
<link rel="stylesheet" href="css/bootstrap.min.css">
<link rel="stylesheet" href="css/perfect-scrollbar.css">
<link rel="stylesheet" href="css/style.css">
<link rel="stylesheet" href="css/flexslider.css" type="text/css" media="screen" />
<link rel="stylesheet" href="css/fontello.css">
<link rel="stylesheet" href="css/animation.css">
<link rel="stylesheet" href="css/chosen.css">
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
<link rel="stylesheet" href="css/ie.css">
<![endif]-->
<!--[if IE 7]>
<link rel="stylesheet" href="css/fontello-ie7.css">
<![endif]-->
</head>
<body>
<!-- Container -->
<div class="container">
<!-- Header -->
<?php
$p="";
if(basename(__DIR__)!="bhai"){
$p="../";
}
session_start();
if(isset($_SESSION['user']) && $_SESSION['userType']==1){include($p."Templates/loggedin_header.php");}
else {header('Location:login/login.php');}
//if(isset($_SESSION['user'])){include($p."Templates/loggedin_header.php");}
//else {include($p."Templates/header.php");}
$order= new Order();
?>
<!-- /Header -->
<form method="post" id="orderListForm" name="orderListForm">
<input type="text" name="txtId123456" id="txtId123456" hidden>
<!-- Content -->
<div class="row content">
<div class="col-lg-12 col-md-12 col-sm-12">
<div class="breadcrumbs">
<p><a href="main1.php">Home</a> <i class="icons icon-right-dir"></i> Orders</p>
</div>
</div>
<!-- Main Content -->
<section class="main-content col-lg-9 col-md-9 col-sm-9">
<div class="row">
<!-- Heading -->
<div class="col-lg-12 col-md-12 col-sm-12">
<div class="carousel-heading">
<h4>Orders List</h4>
<div class="carousel-arrows">
<a href="#"><i class="icons icon-reply"></i></a>
</div>
</div>
</div>
<!-- /Heading -->
</div>
<div class="row">
<div class="col-lg-12 col-md-12 col-sm-12">
<table class="order-table">
<tr>
<th>Order Number</th>
<th>Order Date</th>
<th class="order-status">Delivered To</th>
<th class="order-status">Phone</th>
<th class="order-status">Address</th>
<th class="order-status">Status</th>
<th class="order-status">Delivery Time</th>
<th>Total</th>
</tr>
<?php
if(isset($_SESSION["user"])){
$productInfo=null;
$productInfo=$order->getNewOrdersDetails1($_SESSION["user"]);
foreach($productInfo as $data){
?>
<tr>
<td>
<input type="button" name ="update " class="btn btn-info update" value="<?php echo $_SESSION['currentOrderId']=$data["ID"]; ?>" onClick="setId(<?php echo $data["ID"]; ?>)" />
</td>
<td><p><?php echo $data["time"];?></p></td>
<td><p><?php echo $data["name"];?></p></td>
<td><p><?php echo $data["phone"];?></p></td>
<td><p><?php echo $data["address"];?></p></td>
<td><p><?php if($data["status"]==0){echo "Not Delivered";}elseif ($data["status"]==1){echo "Delivered";}?></p></td>
<td><p><?php echo $data["dtime"];?></p></td>
<td><span class="price"><?php echo $data["price"]." PKR";?></span></td>
</tr>
<?php } } ?>
</table>
</div>
</div>
</section>
<!-- /Main Content -->
<!-- Sidebar -->
<aside class="sidebar col-lg-3 col-md-3 col-sm-3 right-sidebar">
<!-- Categories -->
<?php include($p."Templates/sidebar.php"); ?>
<!-- /Categories -->
</aside>
<!-- /Sidebar -->
</div>
<!-- /Content -->
</form>
<!-- Banner -->
<?php include($p."Templates/footer.php");?>
<!-- Footer -->
<div id="back-to-top">
<i class="icon-up-dir"></i>
</div>
</div>
<!-- Container -->
<!-- JavaScript -->
<script src="js/modernizr.min.js"></script>
<script src="js/jquery-1.11.0.min.js"></script>
<script type="text/javascript" src="js/jquery-ui.min.js"></script>
<script type="text/javascript" src="js/jquery.raty.min.js"></script>
<!-- Scroll Bar -->
<script src="js/perfect-scrollbar.min.js"></script>
<!-- Cloud Zoom -->
<script src="js/zoomsl-3.0.min.js"></script>
<!-- FancyBox -->
<script src="js/jquery.fancybox.pack.js"></script>
<!-- jQuery REVOLUTION Slider -->
<script type="text/javascript" src="js/jquery.themepunch.plugins.min.js"></script>
<script type="text/javascript" src="js/jquery.themepunch.revolution.min.js"></script>
<!-- FlexSlider -->
<script defer src="js/flexslider.min.js"></script>
<!-- IOS Slider -->
<script src = "js/jquery.iosslider.min.js"></script>
<!-- noUi Slider -->
<script src="js/jquery.nouislider.min.js"></script>
<!-- Owl Carousel -->
<script src="js/owl.carousel.min.js"></script>
<!-- Cloud Zoom -->
<script src="js/zoomsl-3.0.min.js"></script>
<!-- SelectJS -->
<script src="js/chosen.jquery.min.js" type="text/javascript"></script>
<!-- Main JS -->
<script defer src="js/bootstrap.min.js"></script>
<script src="js/main-script.js"></script>
</body>
<!-- Mirrored from velikorodnov.com/html/homeshop/orders_list.html by HTTrack Website Copier/3.x [XR&CO'2014], Fri, 22 Jan 2016 16:29:04 GMT -->
</html>
<script>
function setId(Id){
$("#txtId123456").val(Id);
}
$(".update").click(function(){
$("#orderListForm").attr("action","order_info.php");
$("#orderListForm").submit();
});
</script>