示例#1
0
 public function delete($id)
 {
     $ps = new PreparedStatement("DELETE FROM brands WHERE id = ?");
     $ps->setInt(1, $id);
     if ($this->ds->execute($ps->getSql())) {
         $productDAO = new ProductDAO($this->ds);
         $productDAO->updateBrand($id, 'NULL');
         return TRUE;
     }
     return FALSE;
 }