-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathappointment_admin.php
102 lines (82 loc) · 4.6 KB
/
appointment_admin.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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title> Happy Paws Clinic </title>
<link rel="stylesheet" href="css//appointements-design.css">
</head>
<?php include 'header.php';
include 'database_connect.php'; ?>
<body class="body_appointements" style="background-image: url(image//design19.png); ">
<h1 class="title_appointements">
Appointments
</h1>
<?php
$date_now= date("Y-m-d");
echo '
<h2 >
Upcoming
</h2>';
$sql_request_appointement = "select * from request_appointement where day>'$date_now'";
$Result_request_appointement = mysqli_query($conn, $sql_request_appointement);
$counts=1;
while ($row_request_appointement = mysqli_fetch_object($Result_request_appointement))
{
if($row_request_appointement->status=="accept")
{
echo '
<ul>
<div>
<li>
<details>
<summary> Appointment '.$counts.' </summary>
<ul>
<li>Date : '.$row_request_appointement->day.'</li>
<li>Time :'.$row_request_appointement->time.'</li>
<li>Pet nama :'.$row_request_appointement->pet.'</li>
<li>Service:'.$row_request_appointement->service.'</li>
</ul>
</details>
</li>
</div>
</ul>';
$counts=$counts+1;
}
}
echo '
<h2>
Prevoius
</h2> ';
$sql_request_appointement = "select * from request_appointement where day<'$date_now' ";
$Result_request_appointement = mysqli_query($conn, $sql_request_appointement);
$count_pre=1;
while ($row_request_appointement = mysqli_fetch_object($Result_request_appointement))
{
if($row_request_appointement->status=="accept")
{
echo '
<ul>
<div>
<li>
<details>
<summary> Appointment:'.$count_pre.'
<a href="review_admin.php?id_request='.$row_request_appointement->id.'" target="_blank" class="r-icon1" title="go review your last appointement">
<img src="image//review.png" alt="review icon" height="30" width="30"></a>
</summary>
<ul>
<li>Date : '.$row_request_appointement->day.'</li>
<li>Time :'.$row_request_appointement->time.'</li>
<li>Pet nama :'.$row_request_appointement->pet.'</li>
<li>Service:'.$row_request_appointement->service.'</li>
</ul>
</details>
</li>
</div>
</ul>
';
$count_pre=$count_pre+1;
}
}
?>
</body>
</html>