src/models/salesPDO.php
/**
     * delete: Esborrar una reserva en concret
     *
     * @param Id id de la reserva que volem esborrar
     **/
Esborrar una reserva en concret
@param Id id de la reserva que volem esborrar
Esborrar una reserva en concret @param Id id de la reserva que volem esborrar
public function delete($Id)
    {
        $query = 'DELETE FROM reserves WHERE Id = :Id';
        $delete = $this->sql->prepare($query);
        $result = $delete->execute([':Id' => $Id]);
        if ($delete->errorCode() !== '00000') {
            $err = $delete->errorInfo();
            $code = $delete->errorCode();
            die("Error.   {$err[0]} - {$err[1]}\n{$err[2]} $query");
        }
    }
public function delete ( $ Id ) { $ query = 'DELETE FROM reserves WHERE Id = :Id' ; $ delete = $ this -> sql -> prepare ( $ query ) ; $ result = $ delete -> execute ( [ ':Id' => $ Id ] ) ; if ( $ delete -> errorCode ( ) !== '00000' ) { $ err = $ delete -> errorInfo ( ) ; $ code = $ delete -> errorCode ( ) ; die ( " Error.    { $ err [ 0 ] }  -  { $ err [ 1 ] } \n { $ err [ 2 ] } $ query " ) ; } }
delete: Esborrar una reserva en concret
 @param Id id de la reserva que volem esborrar
delete : Esborrar una reserva en concret @param Id id de la reserva que volem esborrar