-
Notifications
You must be signed in to change notification settings - Fork 0
/
listadoVehiculo.php
75 lines (65 loc) · 2.26 KB
/
listadoVehiculo.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
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Listado</title>
<script>
function confirmar() {
if (confirm('Esta seguro que desea borrar')) {
return true;
} else {
return false;
}
}
</script>
</head>
<body>
<a href="modificar.php?documento=68">Modificar Usuario </a>
<table border="1">
<thead>
<tr>
<th>Placa</th>
<th>Modelo</th>
<th>Marca</th>
<th>Color</th>
<th>Estado</th>
<th>Precio</th>
<th>Usuario</th>
<th>Categoria</th>
</tr>
</thead>
<tbody>
<?php
require 'modelo.dao/VehiculoDao.php';
require 'modelo.dto/VehiculoDto.php';
require 'utilidades/Conexion.php';
$uDao = new VehiculoDao();
$allusers = $uDao->listarTodos();
foreach($allusers as $user) {?>
<tr><td><?php echo $user['placa']; ?> </td>
<td><?php echo $user['modelo']; ?> </td>
<td><?php echo $user['marca']; ?> </td>
<td><?php echo $user['color']; ?> </td>
<td><?php echo $user['estado']; ?> </td>
<td><?php echo $user['precio']; ?> </td>
<td><?php echo $user['usuario']; ?> </td>
<td><?php echo $user['categoria']; ?> </td>
</tr>
<?php
}?>
</tbody>
</table>
<?php
if (isset($_GET['mensaje'])) {
?>
<div class="row"><br><br>
<div class="col-md-6"></div>
<div class="col-md-1 text-center"><h4><?php echo $mensaje = $_GET['mensaje']?></h4></div>
<div class="col-md-5"></div>
</div>
<?php
}
?>
<div class="col-md-3 btn btn-success"><a href="registroVehiculo.php" class="form-control">Registrarse</a></div>
</body>
</html>