webguys-de / EasyTemplate

42 stars 13 forks source link

Error when accessing Blocks in Multi-Store Shop #37

Closed EliasKotlyar closed 7 years ago

EliasKotlyar commented 7 years ago

Hello Tobi,

we got this error when trying to access the CMS-Block Page:

SQLSTATE[23000]: Integrity constraint violation: 1052 Column 'block_id' in where clause is ambiguous, query was: SELECT main_table.* FROM cms_block AS main_table INNER JOIN cms_block_store AS store_table ON main_table.block_id = store_table.block_id WHERE (is_active = '1') AND (block_id != '4') AND (store_table.store_id IN('2', 0)) GROUP BY main_table.block_id

We fixxed it by adding the table name to the query(Webguys_Easytemplate_Model_Input_Renderer_Source_Blocks). I will provide the bugfix as a Pull-Request.

Greetings Elias