| @@ 31-39 (lines=9) @@ | ||
| 28 | * @param $ean | |
| 29 | * @return mixed | |
| 30 | */ | |
| 31 | public function imageExists($imageName, $productId, $ean) | |
| 32 |     { | |
| 33 | $connection = $this->getConnection(); | |
| 34 | $query = $connection->select() | |
| 35 | ->from(['s' => $this->getMainTable()], ['s.ean']) | |
| 36 |             ->where('s.image = ? AND s.product_id = ? AND s.ean= ?', $imageName, $productId, $ean); | |
| 37 | $eans = $connection->fetchAll($query); | |
| 38 | return $eans; | |
| 39 | } | |
| 40 | ||
| 41 | /** | |
| 42 | * @return mixed | |
| @@ 44-52 (lines=9) @@ | ||
| 41 | /** | |
| 42 | * @return mixed | |
| 43 | */ | |
| 44 | public function getProcessedEans() | |
| 45 |     { | |
| 46 | $connection = $this->getConnection(); | |
| 47 | $query = $connection->select() | |
| 48 | ->from(['s' => $this->getMainTable()], ['s.ean']) | |
| 49 |             ->group('s.ean'); | |
| 50 | $eans = $connection->fetchAll($query); | |
| 51 | return $eans; | |
| 52 | } | |
| 53 | ||
| 54 | } | |
| 55 | ||