implement simple overview of Quests for a Seminary
This commit is contained in:
parent
90a7d11a05
commit
60b1b01ba8
3 changed files with 135 additions and 3 deletions
|
|
@ -325,6 +325,25 @@
|
|||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get all Quests for a Seminary.
|
||||
*
|
||||
* @param int $seminaryId ID of Seminary
|
||||
* @return array Quests for this Seminary
|
||||
*/
|
||||
public function getQuestsForSeminary($seminaryId)
|
||||
{
|
||||
return $this->db->query(
|
||||
'SELECT DISTINCT quests.id, quests.questgroup_id, quests.questtype_id, quests.title, quests.url, quests.xps, quests.task, quests.right_text, quests.wrong_text, quests.questsmedia_id '.
|
||||
'FROM questgroups '.
|
||||
'INNER JOIN quests ON quests.questgroup_id = questgroups.id '.
|
||||
'WHERE questgroups.seminary_id = ?',
|
||||
'i',
|
||||
$seminaryId
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get all Quests that are linked to a Questtopic.
|
||||
*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue