SQLSTATE[42S22]: Column not found: 1054 Unknown column 'theme_name' in 'where clause'
at line 151 in file classes/db/DbPDO.php
146. protected function _query($sql)
147. {
148. try {
149. return $this->link->query($sql);
150. } catch (PDOException $exception) {
151. throw new PrestaShopException($exception->getMessage(), (int) $exception->getCode(), $exception);
152. }
153. }
154.
155. /**
156. * Returns the next row from the result set.
376. {
377. if ($sql instanceof DbQuery) {
378. $sql = $sql->build();
379. }
380.
381. $this->result = $this->_query($sql);
382.
383. if (!$this->result && $this->getNumberError() == 2006) {
384. $this->connect();
385. $this->result = $this->_query($sql);
386. }
Argument [0] SELECT * FROM `ps_image_type` WHERE 1 AND `categories` = 1 AND `theme_name` = 'classic' OR `theme_name` IS NULL ORDER BY `width` DESC, `height` DESC, `name`ASC
613. || stripos($sql, 'dumpfile') !== false
614. ) {
615. throw new PrestaShopDatabaseException('Db->executeS() must be used only with select, show, explain or describe queries');
616. }
617.
618. $this->result = $this->query($sql);
619.
620. if (!$this->result) {
621. $result = false;
622. } else {
623. if (!$array) {
Argument [0] SELECT * FROM `ps_image_type` WHERE 1 AND `categories` = 1 AND `theme_name` = 'classic' OR `theme_name` IS NULL ORDER BY `width` DESC, `height` DESC, `name`ASC
108. $query = 'SELECT * FROM `' . _DB_PREFIX_ . 'image_type` ' . $where . ' ORDER BY `width` DESC, `height` DESC, `name`ASC';
109. } else {
110. $query = 'SELECT * FROM `' . _DB_PREFIX_ . 'image_type` ' . $where . ' ORDER BY `name` ASC';
111. }
112.
113. self::$images_types_cache[$type][$theme] = Db::getInstance()->executeS($query);
114. }
115.
116. return self::$images_types_cache[$type][$theme];
117. }
118.
Argument [0] SELECT * FROM `ps_image_type` WHERE 1 AND `categories` = 1 AND `theme_name` = 'classic' OR `theme_name` IS NULL ORDER BY `width` DESC, `height` DESC, `name`ASC
370. // Get current theme
371. $currentTheme = Context::getContext()->shop->theme_name;
372.
373. foreach ($objectsToRegenerate as $object) {
374. // Get all image types present on shops for this object
375. $imageTypes = ImageType::getImagesTypes($object['type'], true, $currentTheme);
376.
377. // We get the "no image available" in the folder of the object
378. $originalImagePath = implode(DIRECTORY_SEPARATOR, [
379. rtrim($object['dir'], DIRECTORY_SEPARATOR),
380. $language->getIsoCode() . '.jpg',
Argument [0] categories Argument [1] 1 Argument [2] classic
1536. $urls['actions'] = [
1537. 'logout' => $this->context->link->getPageLink('index', null, null, 'mylogout'),
1538. ];
1539.
1540. $imageRetriever = new ImageRetriever($this->context->link);
1541. $urls['no_picture_image'] = $imageRetriever->getNoPictureImage($this->context->language);
1542.
1543. $this->urls = $urls;
1544. }
1545.
1546. return $this->urls;
Argument [0] Language Object ( [id] => 1 [id_lang:protected] => [lang_associated:protected] => [id_shop:protected] => 1 [id_shop_list] => Array ( ) [get_shop_from_context:protected] => 1 [table:protected] => [identifier:protected] => [tables:protected] => Array ( ) [webserviceParameters:protected] => Array ( [objectNodeName] => language [objectsNodeName] => languages ) [image_dir:protected] => [image_format:protected] => jpg [translator:protected] => [def:protected] => Array ( [table] => lang [primary] => id_lang [fields] => Array ( [name] => Array ( [type] => 3 [validate] => isGenericName [required] => 1 [size] => 32 ) [iso_code] => Array ( [type] => 3 [validate] => isLanguageIsoCode [required] => 1 [size] => 2 ) [locale] => Array ( [type] => 3 [validate] => isLocale [size] => 5 ) [language_code] => Array ( [type] => 3 [validate] => isLanguageCode [size] => 5 ) [active] => Array ( [type] => 2 [validate] => isBool ) [is_rtl] => Array ( [type] => 2 [validate] => isBool ) [date_format_lite] => Array ( [type] => 3 [validate] => isPhpDateFormat [required] => 1 [size] => 32 ) [date_format_full] => Array ( [type] => 3 [validate] => isPhpDateFormat [required] => 1 [size] => 32 ) ) [classname] => Language ) [update_fields:protected] => [force_id] => [name] => English (English) [iso_code] => en [locale] => en-US [language_code] => en-us [date_format_lite] => m/d/Y [date_format_full] => m/d/Y H:i:s [is_rtl] => 0 [active] => 1 )
771. header('Retry-After: 3600');
772.
773. $this->setMedia();
774. $this->registerStylesheet('theme-error', '/assets/css/error.css', ['media' => 'all', 'priority' => 50]);
775. $this->context->smarty->assign([
776. 'urls' => $this->getTemplateVarUrls(),
777. 'shop' => $this->getTemplateVarShop(),
778. 'HOOK_MAINTENANCE' => Hook::exec('displayMaintenance', []),
779. 'maintenance_text' => Configuration::get('PS_MAINTENANCE_TEXT', (int) $this->context->language->id),
780. 'stylesheets' => $this->getStylesheets(),
781. ]);
469. $country = new Country((int) $infos['id_country']);
470. $this->context->country = $country;
471. }
472.
473. if (!Tools::isPHPCLI()) {
474. $this->displayMaintenancePage();
475. }
476.
477. if (!Tools::isPHPCLI() && Country::GEOLOC_FORBIDDEN == $this->restrictedCountry) {
478. $this->displayRestrictedCountryPage();
479. }
306. /**
307. * Starts the controller process (this method should not be overridden!).
308. */
309. public function run()
310. {
311. $this->init();
312. if ($this->checkAccess()) {
313. // setMedia MUST be called before postProcess
314. if (!$this->content_only && ($this->display_header || (isset($this->className) && $this->className))) {
315. $this->setMedia();
316. }
482.
483. // Execute hook dispatcher
484. Hook::exec('actionDispatcher', $params_hook_action_dispatcher);
485.
486. // Running controller
487. $controller->run();
488.
489. // Execute hook dispatcher after
490. Hook::exec('actionDispatcherAfter', $params_hook_action_dispatcher);
491. } catch (PrestaShopException $e) {
492. $e->displayMessage();
73. }
74. }
75.
76. // Prepare and trigger LEGACY front dispatcher
77. define('FRONT_LEGACY_CONTEXT', true);
78. Dispatcher::getInstance()->dispatch();