Ejemplo n.º 1
0
 /**
  * Return name of table for given $storeId.
  *
  * @param integer $storeId
  * @return string
  */
 public function getMainStoreTable($storeId = \Magento\Store\Model\Store::DEFAULT_STORE_ID)
 {
     if (is_string($storeId)) {
         $storeId = intval($storeId);
     }
     if ($storeId) {
         $suffix = sprintf('store_%d', $storeId);
         $table = $this->getTable('catalog_category_flat_' . $suffix);
     } else {
         $table = parent::getMainTable();
     }
     return $table;
 }