|
ILIAS
release_9 Revision v9.13-25-g2c18ec4c24f
|
Class Forum core functions for forum. More...
Collaboration diagram for ilForum:Public Member Functions | |
| __construct () | |
| setForumId (int $a_obj_id) | |
| setForumRefId (int $a_ref_id) | |
| getForumId () | |
| getForumRefId () | |
| setDbTable (string $dbTable) | |
| getDbTable () | |
| setMDB2WhereCondition (string $query_string, array $data_type, array $data_value) | |
| getMDB2Query () | |
| getMDB2DataValue () | |
| getMDB2DataType () | |
| setPageHits (int $pageHits) | |
| getPageHits () | |
| getOneTopic () | |
| getOneThread () | |
| generateThread (ilForumTopic $thread, string $message, bool $notify, bool $notify_posts, bool $status=true, bool $withFirstVisibleEntry=true) | |
| moveThreads (array $thread_ids, ilObjForum $src_forum, int $target_obj_id) | |
| postCensorship (ilObjForum $forum, string $message, int $pos_pk, int $cens=0) | |
| deletePost ($postIdOrRecord, bool $raiseEvents=true) | |
| getAllThreads (int $a_topic_id, array $params=[], int $limit=0, int $offset=0) | |
| getNumberOfPublishedUserPostings (int $usr_id, bool $post_activation_required) | |
| getUserStatistics (bool $post_activation_required) | |
| getRootPostIdByThread (int $a_thread_id) | |
| getModerators () | |
| countUserArticles (int $a_user_id) | |
| countActiveUserArticles (int $a_user_id) | |
| convertDate (string $date) | |
| addPostTree (int $a_tree_id, int $a_node_id=-1, string $a_date='') | |
| insertPostNode (int $a_node_id, int $a_parent_id, int $tree_id, string $a_date='') | |
| insert node under parent node More... | |
| getPostDepth (int $a_node_id, int $tree_id) | |
| getFirstPostNode (int $tree_id) | |
| getPostNode (int $post_id) | |
| fetchPostNodeData (stdClass $a_row) | |
| getSubPathIdsForNode (ilForumPost $post) | |
| deletePostTree (array $a_node) | |
| updateVisits (int $ID) | |
| prepareText (string $text, int $edit=0, string $quote_user='', string $type='') | |
| getImportName () | |
| setImportName (string $a_import_name) | |
| enableForumNotification (int $user_id) | |
| disableForumNotification (int $user_id) | |
| isForumNotificationEnabled (int $user_id) | |
| isThreadNotificationEnabled (int $user_id, int $thread_id) | |
| mergeThreads (int $source_id, int $target_id) | |
Static Public Member Functions | |
| static | _getModerators (int $a_ref_id) |
| static | _isModerator (int $a_ref_id, int $a_usr_id) |
| static | getSortedThreadSubjects (int $a_obj_id, int $a_sort_mode=self::SORT_DATE) |
| static | _lookupObjIdForForumId (int $a_for_id) |
Data Fields | |
| ilLanguage | $lng |
| ilErrorHandling | $error |
| ilDBInterface | $db |
| ilObjUser | $user |
| ilSetting | $settings |
Static Protected Attributes | |
| static array | $moderators_by_ref_id_map = [] |
Private Member Functions | |
| deletePostFiles (array $a_ids) | |
Private Attributes | |
| const | SORT_TITLE = 1 |
| const | SORT_DATE = 2 |
| const | DEFAULT_PAGE_HITS = 30 |
| ilAppEventHandler | $event |
| string | $dbTable |
| string | $className = 'ilForum' |
| string | $mdb2Query = '' |
| array | $mdb2DataValue = [] |
| array | $mdb2DataType = [] |
| string | $txtQuote1 = "[quote]" |
| string | $txtQuote2 = "[/quote]" |
| string | $replQuote1 = '<blockquote class="ilForumQuote">' |
| string | $replQuote2 = '</blockquote>' |
| int | $pageHits = self::DEFAULT_PAGE_HITS |
| int | $id |
| int | $ref_id |
| string | $import_name = '' |
Class Forum core functions for forum.
Definition at line 27 of file class.ilForum.php.
| ilForum::__construct | ( | ) |
Definition at line 56 of file class.ilForum.php.
References $DIC, ILIAS\Repository\lng(), ILIAS\Repository\settings(), and ILIAS\Repository\user().
Here is the call graph for this function:
|
static |
Definition at line 1067 of file class.ilForum.php.
References $DIC, and ilObject\_lookupTitle().
Referenced by ilObjForum\getAllForumParticipants(), ilForumNotificationDataProvider\getPostActivationRecipients(), and ilForumSettingsGUI\showMembers().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Definition at line 1083 of file class.ilForum.php.
Referenced by ilObjForumGUI\renderDraftContent(), ilObjForumGUI\renderPostContent(), and ilForumExportGUI\renderPostHtml().
Here is the caller graph for this function:
|
static |
Definition at line 1644 of file class.ilForum.php.
Referenced by ilObjMediaObject\getParentObjectIdForUsage(), ilForumDraftsDerivedTaskProvider\getTasks(), ilObjForumGUI\mergeThreadsObject(), and ilForumTopic\movePosts().
Here is the caller graph for this function:| ilForum::addPostTree | ( | int | $a_tree_id, |
| int | $a_node_id = -1, |
||
| string | $a_date = '' |
||
| ) |
Definition at line 1128 of file class.ilForum.php.
Referenced by getOneThread().
Here is the caller graph for this function:| ilForum::convertDate | ( | string | $date | ) |
Definition at line 1123 of file class.ilForum.php.
References ilDatePresentation\formatDate(), and IL_CAL_DATETIME.
Referenced by ilObjForumGUI\renderDraftContent(), and ilObjForumGUI\renderPostContent().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::countActiveUserArticles | ( | int | $a_user_id | ) |
Definition at line 1107 of file class.ilForum.php.
References $res, getForumId(), and ILIAS\Repository\user().
Referenced by ilObjForumGUI\showUserObject().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::countUserArticles | ( | int | $a_user_id | ) |
Definition at line 1092 of file class.ilForum.php.
References $res, and getForumId().
Referenced by ilObjForumGUI\showUserObject().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::deletePost | ( | $postIdOrRecord, | |
| bool | $raiseEvents = true |
||
| ) |
| int|array<string,mixed> | $postIdOrRecord |
Definition at line 529 of file class.ilForum.php.
References $post, $res, ilObjForum\_deleteReadEntries(), ilObjMediaObject\_exists(), ilObjMediaObject\_getMobsOfObject(), ilObjMediaObject\_removeUsage(), deletePostFiles(), deletePostTree(), ilNewsItem\getFirstNewsIdForContext(), getForumId(), getForumRefId(), getPostNode(), getSubPathIdsForNode(), and ILIAS\Repository\int().
Referenced by ilObjForumGUI\deletePostingObject(), mergeThreads(), and ilObjForumGUI\performDeleteThreadsObject().
Here is the call graph for this function:
Here is the caller graph for this function:
|
private |
| int[] | $a_ids |
Definition at line 1501 of file class.ilForum.php.
References getForumId().
Referenced by deletePost().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::deletePostTree | ( | array | $a_node | ) |
Definition at line 1347 of file class.ilForum.php.
References $res, and ILIAS\Repository\int().
Referenced by deletePost().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::disableForumNotification | ( | int | $user_id | ) |
Definition at line 1577 of file class.ilForum.php.
Referenced by ilObjForumGUI\disableForumNotificationObject().
Here is the caller graph for this function:| ilForum::enableForumNotification | ( | int | $user_id | ) |
Definition at line 1522 of file class.ilForum.php.
References $res, and isForumNotificationEnabled().
Referenced by ilObjForumGUI\enableForumNotificationObject().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::fetchPostNodeData | ( | stdClass | $a_row | ) |
Definition at line 1278 of file class.ilForum.php.
References ilObject\_exists(), ILIAS\Repository\int(), and ILIAS\Repository\lng().
Referenced by getFirstPostNode(), and getPostNode().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::generateThread | ( | ilForumTopic | $thread, |
| string | $message, | ||
| bool | $notify, | ||
| bool | $notify_posts, | ||
| bool | $status = true, |
||
| bool | $withFirstVisibleEntry = true |
||
| ) |
Definition at line 285 of file class.ilForum.php.
References $message, $notify, ilForumTopic\enableNotification(), ilForumTopic\getCreateDate(), ilForumTopic\getDisplayUserId(), ilForumTopic\getForumId(), ilForumTopic\getId(), getImportName(), ilForumTopic\getSubject(), ilForumTopic\getThrAuthorId(), ilForumTopic\getUserAlias(), ilForumTopic\insert(), ilForumTopic\setCreateDate(), and ilForumTopic\setImportName().
Referenced by ilObjForumGUI\createEmptyThread(), and ilObjForumGUI\createThread().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::getAllThreads | ( | int | $a_topic_id, |
| array | $params = [], |
||
| int | $limit = 0, |
||
| int | $offset = 0 |
||
| ) |
Definition at line 736 of file class.ilForum.php.
References $data, $params, $res, getForumId(), ilForumProperties\getInstance(), ILIAS\Repository\int(), and ILIAS\Repository\user().
Here is the call graph for this function:| ilForum::getDbTable | ( | ) |
| ilForum::getFirstPostNode | ( | int | $tree_id | ) |
Definition at line 1245 of file class.ilForum.php.
References $res, and fetchPostNodeData().
Referenced by ilObjForumGUI\performDeleteThreadsObject().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::getForumId | ( | ) |
Definition at line 78 of file class.ilForum.php.
References $id.
Referenced by countActiveUserArticles(), countUserArticles(), ilObjForumGUI\createEmptyThread(), ilObjForumGUI\createThread(), deletePost(), deletePostFiles(), getAllThreads(), getNumberOfPublishedUserPostings(), getOneThread(), getUserStatistics(), ilObjForumGUI\initHeaderAction(), mergeThreads(), ilObjForumGUI\mergeThreadsObject(), ilObjForumGUI\publishDraftObject(), ilObjForumGUI\saveAsDraftObject(), ilObjForumGUI\savePostObject(), ilObjForumGUI\saveThreadAsDraftObject(), and ilObjForumGUI\viewThreadObject().
Here is the caller graph for this function:| ilForum::getForumRefId | ( | ) |
Definition at line 83 of file class.ilForum.php.
References $ref_id.
Referenced by deletePost(), getModerators(), getOneThread(), and postCensorship().
Here is the caller graph for this function:| ilForum::getImportName | ( | ) |
Definition at line 1512 of file class.ilForum.php.
References $import_name.
Referenced by generateThread(), and getOneThread().
Here is the caller graph for this function:| ilForum::getMDB2DataType | ( | ) |
Definition at line 121 of file class.ilForum.php.
Referenced by getOneThread(), getOneTopic(), and updateVisits().
Here is the caller graph for this function:| ilForum::getMDB2DataValue | ( | ) |
Definition at line 116 of file class.ilForum.php.
Referenced by getOneThread(), getOneTopic(), and updateVisits().
Here is the caller graph for this function:| ilForum::getMDB2Query | ( | ) |
Definition at line 111 of file class.ilForum.php.
Referenced by getOneThread(), getOneTopic(), and updateVisits().
Here is the caller graph for this function:| ilForum::getModerators | ( | ) |
Definition at line 1059 of file class.ilForum.php.
References getForumRefId().
Here is the call graph for this function:| ilForum::getNumberOfPublishedUserPostings | ( | int | $usr_id, |
| bool | $post_activation_required | ||
| ) |
Definition at line 945 of file class.ilForum.php.
References $res, and getForumId().
Here is the call graph for this function:| ilForum::getOneThread | ( | ) |
Definition at line 165 of file class.ilForum.php.
References $message, $notify, ilRTE\_replaceMediaObjectImageSrc(), addPostTree(), getForumId(), getForumRefId(), getImportName(), ilForumProperties\getInstance(), ilObjectFactory\getInstanceByRefId(), getMDB2DataType(), getMDB2DataValue(), getMDB2Query(), insertPostNode(), NEWS_NOTICE, NEWS_USERS, and prepareText().
Here is the call graph for this function:| ilForum::getOneTopic | ( | ) |
Definition at line 141 of file class.ilForum.php.
References $res, ForumDto\getEmptyInstance(), ForumDto\getInstanceFromArray(), getMDB2DataType(), getMDB2DataValue(), and getMDB2Query().
Referenced by ilObjForumGUI\createEmptyThread(), ilObjForumGUI\createThread(), ilObjForumGUI\deletePostingObject(), ilObjForumGUI\mergeThreadsObject(), moveThreads(), ilObjForumGUI\saveAsDraftObject(), ilObjForumGUI\savePostObject(), and ilObjForumGUI\saveThreadAsDraftObject().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::getPageHits | ( | ) |
Definition at line 136 of file class.ilForum.php.
References $pageHits.
Referenced by ilObjForumGUI\viewThreadObject().
Here is the caller graph for this function:| ilForum::getPostDepth | ( | int | $a_node_id, |
| int | $tree_id | ||
| ) |
Definition at line 1227 of file class.ilForum.php.
References $res.
Referenced by insertPostNode().
Here is the caller graph for this function:| ilForum::getPostNode | ( | int | $post_id | ) |
Definition at line 1260 of file class.ilForum.php.
References $res, and fetchPostNodeData().
Referenced by deletePost(), and mergeThreads().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::getRootPostIdByThread | ( | int | $a_thread_id | ) |
|
static |
Definition at line 1621 of file class.ilForum.php.
References $DIC, $res, and ILIAS\Repository\int().
Referenced by ilObjForumSearchResultTableGUI\parse(), and ilForumExportGUI\printPost().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::getSubPathIdsForNode | ( | ilForumPost | $post | ) |
Definition at line 1328 of file class.ilForum.php.
References $res, ilForumPost\getLft(), ilForumPost\getRgt(), ilForumPost\getTreeId(), ILIAS\Repository\int(), and ilDBConstants\T_INTEGER.
Referenced by deletePost().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::getUserStatistics | ( | bool | $post_activation_required | ) |
Definition at line 977 of file class.ilForum.php.
References $data, $res, getForumId(), ILIAS\Repository\int(), ilPersonalProfileMode\PROFILE_ENABLED_GLOBAL, ilPersonalProfileMode\PROFILE_ENABLED_LOGGED_IN_USERS, and ILIAS\Repository\user().
Here is the call graph for this function:| ilForum::insertPostNode | ( | int | $a_node_id, |
| int | $a_parent_id, | ||
| int | $tree_id, | ||
| string | $a_date = '' |
||
| ) |
insert node under parent node
Definition at line 1161 of file class.ilForum.php.
References $res, getPostDepth(), and ILIAS\Repository\int().
Referenced by getOneThread().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::isForumNotificationEnabled | ( | int | $user_id | ) |
Definition at line 1588 of file class.ilForum.php.
References $res.
Referenced by enableForumNotification(), and ilObjForumGUI\initHeaderAction().
Here is the caller graph for this function:| ilForum::isThreadNotificationEnabled | ( | int | $user_id, |
| int | $thread_id | ||
| ) |
Definition at line 1603 of file class.ilForum.php.
References $res.
Referenced by ilObjForumGUI\initReplyEditForm().
Here is the caller graph for this function:| ilForum::mergeThreads | ( | int | $source_id, |
| int | $target_id | ||
| ) |
Definition at line 1656 of file class.ilForum.php.
References $ilDB, deletePost(), getForumId(), getPostNode(), ilObjForum\mergeForumUserRead(), ilForumPost\mergePosts(), ilForumNotification\mergeThreadNotifications(), and ilForumPostsTree\updateTargetRootRgt().
Referenced by ilObjForumGUI\performMergeThreadsObject().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::moveThreads | ( | array | $thread_ids, |
| ilObjForum | $src_forum, | ||
| int | $target_obj_id | ||
| ) |
| int[] | $thread_ids |
Definition at line 349 of file class.ilForum.php.
References $res, ILIAS\Survey\Mode\getId(), ilObject\getId(), getOneTopic(), ILIAS\Repository\lng(), and setMDB2WhereCondition().
Here is the call graph for this function:| ilForum::postCensorship | ( | ilObjForum | $forum, |
| string | $message, | ||
| int | $pos_pk, | ||
| int | $cens = 0 |
||
| ) |
Definition at line 467 of file class.ilForum.php.
References $res, ilNewsItem\getFirstNewsIdForContext(), getForumRefId(), prepareText(), and ILIAS\Repository\user().
Referenced by ilObjForumGUI\handleCensorship().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::prepareText | ( | string | $text, |
| int | $edit = 0, |
||
| string | $quote_user = '', |
||
| string | $type = '' |
||
| ) |
Definition at line 1421 of file class.ilForum.php.
References $replQuote2, $txtQuote2, ilMathJax\getInstance(), and ILIAS\Repository\lng().
Referenced by ilObjForumGUI\addActivationFormModal(), ilObjForumGUI\doHistoryCheck(), ilObjForumGUI\editThreadDraftObject(), getOneThread(), ilObjForumGUI\getQuotationHTMLAsynchObject(), postCensorship(), ilObjForumGUI\renderDraftContent(), ilObjForumGUI\renderPostContent(), and ilObjForumGUI\savePostObject().
Here is the call graph for this function:
Here is the caller graph for this function:| ilForum::setDbTable | ( | string | $dbTable | ) |
Definition at line 88 of file class.ilForum.php.
References $dbTable.
Referenced by ilObjForumGUI\createEmptyThread(), and ilObjForumGUI\createThread().
Here is the caller graph for this function:| ilForum::setForumId | ( | int | $a_obj_id | ) |
Definition at line 68 of file class.ilForum.php.
Referenced by ilObjForumGUI\confirmDeleteThreadDraftsObject(), ilObjForumGUI\createEmptyThread(), ilObjForumGUI\createThread(), ilObjForumGUI\deletePostingObject(), ilObjForumGUI\disableForumNotificationObject(), ilObjForumGUI\editThreadDraftObject(), ilObjForumGUI\enableForumNotificationObject(), ilObjForumGUI\initHeaderAction(), ilObjForumGUI\mergeThreadsObject(), ilObjForumGUI\performDeleteThreadsObject(), ilObjForumGUI\performMergeThreadsObject(), ilObjForumGUI\saveThreadAsDraftObject(), and ilObjForumGUI\showUserObject().
Here is the caller graph for this function:| ilForum::setForumRefId | ( | int | $a_ref_id | ) |
Definition at line 73 of file class.ilForum.php.
Referenced by ilObjForumGUI\createEmptyThread(), ilObjForumGUI\createThread(), ilObjForumGUI\deletePostingObject(), ilObjForumGUI\editThreadDraftObject(), ilObjForumGUI\initHeaderAction(), ilObjForumGUI\mergeThreadsObject(), ilObjForumGUI\performDeleteThreadsObject(), ilObjForumGUI\performMergeThreadsObject(), ilObjForumGUI\saveThreadAsDraftObject(), and ilObjForumGUI\showUserObject().
Here is the caller graph for this function:| ilForum::setImportName | ( | string | $a_import_name | ) |
Definition at line 1517 of file class.ilForum.php.
| ilForum::setMDB2WhereCondition | ( | string | $query_string, |
| array | $data_type, | ||
| array | $data_value | ||
| ) |
Definition at line 102 of file class.ilForum.php.
Referenced by ilObjForumGUI\createEmptyThread(), ilObjForumGUI\createThread(), ilObjForumGUI\deletePostingObject(), moveThreads(), ilObjForumGUI\publishDraftObject(), ilObjForumGUI\saveAsDraftObject(), ilObjForumGUI\savePostObject(), ilObjForumGUI\saveThreadAsDraftObject(), and ilObjForumGUI\viewThreadObject().
Here is the caller graph for this function:| ilForum::setPageHits | ( | int | $pageHits | ) |
| ilForum::updateVisits | ( | int | $ID | ) |
Definition at line 1400 of file class.ilForum.php.
References ilSession\get(), getMDB2DataType(), getMDB2DataValue(), getMDB2Query(), and ilSession\set().
Referenced by ilObjForumGUI\createEmptyThread(), and ilObjForumGUI\createThread().
Here is the call graph for this function:
Here is the caller graph for this function:
|
private |
Definition at line 38 of file class.ilForum.php.
| ilDBInterface ilForum::$db |
Definition at line 52 of file class.ilForum.php.
|
private |
Definition at line 37 of file class.ilForum.php.
Referenced by getDbTable(), and setDbTable().
| ilErrorHandling ilForum::$error |
Definition at line 51 of file class.ilForum.php.
|
private |
Definition at line 36 of file class.ilForum.php.
|
private |
Definition at line 47 of file class.ilForum.php.
Referenced by getForumId().
|
private |
Definition at line 49 of file class.ilForum.php.
Referenced by getImportName().
| ilLanguage ilForum::$lng |
Definition at line 50 of file class.ilForum.php.
|
private |
Definition at line 41 of file class.ilForum.php.
|
private |
Definition at line 40 of file class.ilForum.php.
|
private |
Definition at line 39 of file class.ilForum.php.
|
staticprotected |
Definition at line 34 of file class.ilForum.php.
|
private |
Definition at line 46 of file class.ilForum.php.
Referenced by getPageHits(), and setPageHits().
|
private |
Definition at line 48 of file class.ilForum.php.
Referenced by getForumRefId().
|
private |
Definition at line 44 of file class.ilForum.php.
|
private |
Definition at line 45 of file class.ilForum.php.
Referenced by prepareText().
| ilSetting ilForum::$settings |
Definition at line 54 of file class.ilForum.php.
|
private |
Definition at line 42 of file class.ilForum.php.
|
private |
Definition at line 43 of file class.ilForum.php.
Referenced by prepareText().
| ilObjUser ilForum::$user |
Definition at line 53 of file class.ilForum.php.
|
private |
Definition at line 31 of file class.ilForum.php.
|
private |
Definition at line 30 of file class.ilForum.php.
|
private |
Definition at line 29 of file class.ilForum.php.