<div class="col-sm-12"> <div class="right"> <a href="addUser.php">Add Users</a> | <a href="rooms.php">Rooms</a> </div> </div> </div> <!-- All Will Write Their Code Here --> <div class="row"> <div class="row table-responsive"> <?php if (isset($_GET['del_id'])) { $del_id = $_GET['del_id']; if ($validate->checkNotNull($del_id)) { if ($validate->checkNumeric($del_id)) { if ($validate->checkID($del_id)) { if ($orders->checkFoundOrdersForId($del_id)) { ?> <div class="alert alert-danger text-center">Cannot Delete This User Becous he already Get Orders</div><?php } else { $users->delete($del_id); } } else { echo "No User Found With This Data"; } } else { header("location:home.php"); } } else { header("location:home.php");
if (isset($_GET['insRoom'])) { ?> <div class="modal fade bs-example-modal-lg" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel"> <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span >×</span></button> <h4 class="modal-title text-left">Add New Room</h4> </div> <div class="modal-body "> <?php if (isset($_POST['addRoomBtn'])) { $roomNum = $_POST['roomNum']; //Check if is not Null if ($validate->checkNotNull($roomNum)) { if ($validate->checkNumeric($roomNum)) { if ($rooms->checkRoomNum($roomNum)) { if ($rooms->addRoom($roomNum)) { header("location:rooms.php?action=Insert Sucsessful Completed"); } else { ?> <p class="alert alert-danger">Some Things Wrong in Connection With DataBase Try Again Later</p> <?php } } else { ?> <p class="alert alert-danger">This Room Inserted To The DataBase Befor</p> <?php } } else { ?>
</div><!-- /.modal-content --> </div><!-- /.modal-dialog --> </div> <?php } ?> <!-- End Of The Action Complete Pop Up --> <!-- Edit Order (deliver It ) Pop Up --> <?php if (isset($_GET['deliver'])) { $orderNum = $_GET['deliver']; if ($validate->checkNotNull($orderNum)) { if ($validate->checkNumeric($orderNum)) { if ($orders->checkOrderStatus($orderNum, 3)) { ?> <div class="modal fade bs-example-modal-lg" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel"> <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span >×</span></button> <h4 class="modal-title text-left">Deliver Order</h4> </div> <div class="modal-body "> <?php if (isset($_POST['deliverOrderBtn'])) { if ($orders->deliverOrder($orderNum)) { header("location:orders.php?action=Orders Delivered Succssesfilly"); } else {