recete post

This commit is contained in:
Thibault GUILLAUME 2015-09-01 18:26:54 +02:00
parent 43d8bb341f
commit 3027ce71f1

View File

@ -314,11 +314,16 @@ class CmsPsPost extends ObjectModel {
return array();
$infos = $this->getRelationsExtra($id_group);
return Db::getInstance()->executeS('
SELECT p.id_cmsps_extrafields_value as id, p.value as content
FROM `'._DB_PREFIX_.'cmsps_extrafields_value_lang` p
WHERE p.id_cmsps_extrafields_value IN ('.implode(',', $infos).')'
);
if ($infos) {
return Db::getInstance()->executeS('
SELECT p.id_cmsps_extrafields_value as id, p.value as content
FROM `'._DB_PREFIX_.'cmsps_extrafields_value_lang` p
WHERE p.id_cmsps_extrafields_value IN ('.implode(',', $infos).')'
);
} else {
return array();
}
}