예제 #1
0
 /**
  * Removes all associated product ids with given category id
  * 
  * @param string $id Category's id
  * @return array
  */
 public function removeAllProductsByCategoryId($id)
 {
     $ids = $this->productMapper->fetchProductIdsByCategoryId($id);
     if (!empty($ids)) {
         foreach ($ids as $id) {
             //@TODO test it
             $this->removeAllById($id);
         }
     }
     return true;
 }