Exemple #1
0
 public function __construct($database, $r_header, $r_body, $to_location, $from_location, $r_type)
 {
     $this->db = $database;
     $this->r_header = $r_header;
     $this->r_body = $r_body;
     $this->to_location = $to_location;
     $this->from_location = $from_location;
     $this->r_type = $r_type;
     $this->create_date = date('Y-m-d H:i:s');
     $this->error = true;
     parent::__construct($this->db, '', '');
     $this->init();
 }
Exemple #2
0
<?php

require_once '../../core/init.php';
$data = new requestController($db, '', '');
$requests = $data->get_data();
foreach ($requests as $request) {
    ?>
	<?php 
    $the_request = new requestController($db, htmlspecialchars($request['ID']), 'get');
    $user = new userController($db, $the_request->get_user_id(), 'get');
    ?>
	<div class="panel panel-default">
		<div class="panel-body">
			<div class="col-md-3">
				<h2><?php 
    echo $user->username();
    ?>
</h2>
				<h4><?php 
    echo $the_request->get_r_header();
    ?>
</h4>
			</div>
			<div class="col-md-3 panel-margin">
				<h4><b>To: </b> <?php 
    echo $the_request->get_to_location();
    ?>
 </h4>
				<h4><b>From: </b> <?php 
    echo $the_request->get_from_location();
    ?>
Exemple #3
0
<?php

require_once 'template/header.php';
$request_id = htmlspecialchars($_GET['id']);
$request = new requestController($db, $request_id, 'get');
$user = new userController($db, $request->get_user_id(), 'get');
?>
<div class="col-md-12">
	<div class="page-header">
  		<h1> <?php 
echo $request->get_r_header();
?>
 <small><?php 
echo $request->get_r_type();
?>
</small></h1>
	</div>
	<div class="panel panel-default">
	  <div class="panel-body">
	  	<div class="col-md-8">
	  		<div class="row">
		  		<div class="col-md-4">
		  			<h3>From: </h3> <h4><?php 
echo $request->get_from_location();
?>
</h4>
		  		</div>
			   	<div class="col-md-4">
				   	<h3>To: </h3> <h4><?php 
echo $request->get_to_location();
?>