function BotchaRecipebookAbstract::getRecipesByStatus in BOTCHA Spam Prevention 6.2
Same name and namespace in other branches
- 7.2 controller/botcha_recipebook.controller.inc \BotchaRecipebookAbstract::getRecipesByStatus()
Get the list of recipes by status of spam checking.
Parameters
string $status:
Return value
array
1 call to BotchaRecipebookAbstract::getRecipesByStatus()
- BotchaRecipebookAbstract::handle in controller/
botcha_recipebook.controller.inc - Handle form depending on the result of spam check.
File
- controller/
botcha_recipebook.controller.inc, line 225 - Controller layer of the BotchaRecipebook objects.
Class
- BotchaRecipebookAbstract
- @file Controller layer of the BotchaRecipebook objects.
Code
function getRecipesByStatus($status) {
$recipes_list = array();
foreach ($this
->getRecipes() as $recipe_id => $recipe) {
if ($recipe
->getStatus() == $status) {
$recipes_list[$recipe_id] = $recipe;
}
}
return $recipes_list;
}