<?php

//obtener el valor de ID que viene del metodo GET a traves de HTTP
$id = $_GET["id"];
echo "Eliminaci&oacute;n en proceso ....  </br>";
//incluir la libreria de Detalle_facturaDatos
include_once "Detalle_facturaDatos.php";
//creo una instancia de DemoCollector
$Detalle_facturaDatosObj = new Detalle_facturaDatos();
//Ejecuto el metodo para eliminar el objeto Demo indicando el id
$Detalle_facturaDatosObj->delete($id);
echo "<meta http-equiv='Refresh' content='1;tercera.php'>";
Exemple #2
0
          }

 

     </SCRIPT>

</HEAD>

<BODY>

<?php 
include_once "ProductoDatos.php";
include_once "Detalle_facturaDatos.php";
$id = 1;
$ProductoDatosObj = new ProductoDatos();
$Detalle_facturaDatosObj = new Detalle_facturaDatos();
?>
	 <INPUT type="button" value="Delete Row" onclick="deleteRow('dataTable');" />
     <TABLE id="dataTable" width="350px" border="1">
		<thead>
			<TR>					
						<th>Eliminar</th>
						<th style="display:none">Codigo</th>
						<th>Cantida</th>
						<th>Descripción</th>
						<th>Precio Unitario</th>
						<th>Precio Total</th>
		  </TR>
		</thead>

		<tbody>
				<a href="../index.php"><button type="button" class="botonHomeNextBack"><img src="../img/home.png" height="40" width="40" alt="px"></button></a>
				
				<a href="segunda.php"><button type="button" class="botonHomeNextBack"><img src="../img/back.png" height="40" width="40" alt="px"></button></a>


</div>
</div>
	
<?php 
//obtener el valor de ID que viene del metodo GET a traves de HTTP
$id = $_GET["id"];
include_once "Detalle_facturaDatos.php";
include_once "Detalle_factura.php";
//$id = 1;
$Detalle_facturaDatosObj = new Detalle_facturaDatos();
?>
	
<div class="fondoPantalla" style ="width = 100%">
	<div class="container">				
<h2>Editar Detalle Factura</h2>
<?php 
foreach ($Detalle_facturaDatosObj->consultaEspecific($id) as $ObjDetalle) {
    ?>
	<form action="DetalleCabeceraEditar.php" method="post" >
		<table class="table table-striped-edwin"  BORDER=10>
			<thead class="CaberaSuperiorTablaStriped">
				<tr ALIGN=center>
					<th width="10px">Nombre</th>
					<th width="10px">Texto</th>
				</tr>
<?php

$idDetalle = $_POST["idDetalle"];
$cantidad = $_POST["cantidad"];
$producto = $_POST["producto"];
$precioUni = $_POST["precioUni"];
$precioTot = $_POST["precioTot"];
echo "Edici&oacute;n en proceso ....  </br>";
include_once "Detalle_facturaDatos.php";
$Detalle_facturaDatosObj = new Detalle_facturaDatos();
$Detalle_facturaDatosObj->actualizar($idDetalle, $cantidad, $producto, $precioUni, $precioTot);
echo "Datos Actualizados id :" . $idDetalle . "  Nombre:" . $nombre . "  Cantidad:" . $cantidad . " Producto:" . $producto . " PrecioUnitario:" . $precioUni . " PrecioTotal:" . $precioTot . " </br>";
echo "<meta http-equiv='Refresh' content='2;tercera.php'>";
<html>
<head>
</head>

<body>
<div id="main">
<?php 
$secuencia = $_POST["codigo"];
$cantidad = $_POST["cantidad"];
$producto = $_POST["producto"];
$precioUni = $_POST["precioUni"];
$precioTot = $_POST["precioTot"];
$numCabFactura = $_POST["numCabFactura"];
echo "Datos Cantidad:" . $cantidad . " Producto:" . $producto . " PrecioUnitario:" . $precioUni . " PrecioTotal:" . $precioTot . " NumFactura:" . $numCabFactura . "</br>";
include_once "Detalle_facturaDatos.php";
$Detalle_facturaDatosObj = new Detalle_facturaDatos();
$Detalle_facturaDatosObj->insertar($secuencia, $cantidad, $producto, $precioUni, $precioTot, $numCabFactura);
echo "nuevo linea generada </br>";
echo "<meta http-equiv='Refresh' content='2;tercera.php'>";
?>
</div>
</body>
</html>