A Database Error Occurred

Error Number: 1054

Unknown column 'a.item_category' in 'where clause'

SELECT count(*) as qty, `a`.`department_id`, `c`.`department_name`, `c`.`icon_script`, `c`.`department_group`, (select media_file from web_media_file where owner_id=a.department_id and is_cover=1 and is_deleted=0 and owner_type=20012) as media_file FROM `items` `a` INNER JOIN `products` `prd` ON `prd`.`item_id` = `a`.`item_id` INNER JOIN `ref_departments` `c` ON `c`.`department_id` = `a`.`department_id` INNER JOIN `webstore_to_dept_mapping` `b` ON `b`.`department_id` = `c`.`department_id` WHERE `c`.`show_in_webstore` = 1 AND `b`.`web_store_id` = '2' AND `a`.`item_category` IN(1) AND `prd`.`deleted` = 0 GROUP BY `a`.`department_id` ORDER BY `c`.`department_name` ASC

Filename: models/Master_model.php

Line Number: 83