ILIAS
trunk Revision v11.0_alpha-2638-g80c1d007f79
|
A news item can be created by different sources. More...
Public Member Functions | |
__construct (int $a_id=0) | |
setId (int $a_id) | |
getId () | |
setTitle (string $a_title) | |
getTitle () | |
setContent (string $a_content) | |
getContent () | |
setContextObjId (int $a_context_obj_id) | |
getContextObjId () | |
setContextObjType (string $a_context_obj_type) | |
getContextObjType () | |
setContextSubObjId (int $a_context_sub_obj_id) | |
getContextSubObjId () | |
setContextSubObjType (?string $a_context_sub_obj_type) | |
getContextSubObjType () | |
setContentType (string $a_content_type="text") | |
getContentType () | |
setCreationDate (string $a_creation_date) | |
getCreationDate () | |
setUpdateDate (string $a_update_date) | |
getUpdateDate () | |
setUserId (int $a_user_id) | |
getUserId () | |
setUpdateUserId (int $a_val) | |
getUpdateUserId () | |
setVisibility (string $a_visibility="users") | |
getVisibility () | |
setContentLong (string $a_content_long) | |
getContentLong () | |
setPriority (int $a_priority=1) | |
getPriority () | |
setContentIsLangVar (bool $a_content_is_lang_var=false) | |
getContentIsLangVar () | |
setMobId (int $a_mob_id) | |
getMobId () | |
setPlaytime (string $a_playtime) | |
getPlaytime () | |
setLimitation (bool $a_limitation) | |
Set Limitation for number of items. More... | |
getLimitation () | |
setContentTextIsLangVar (bool $a_val=false) | |
getContentTextIsLangVar () | |
setMobPlayCounter (int $a_val) | |
getMobPlayCounter () | |
setMobDownloadCounter (int $a_val) | |
getMobDownloadCounter () | |
setContentHtml (bool $a_val) | |
getContentHtml () | |
read () | |
Read item from database. More... | |
create () | |
Create. More... | |
update (bool $a_as_new=false) | |
Update item in database. More... | |
getNewsForRefId (int $a_ref_id, bool $a_only_public=false, bool $a_stopnesting=false, $a_time_period=0, bool $a_prevent_aggregation=true, bool $a_forum_group_sequences=false, bool $a_no_auto_generated=false, bool $a_ignore_date_filter=false, ?int $a_user_id=null, int $a_limit=0, array $a_excluded=[]) | |
Get News For Ref Id. More... | |
getAggregatedNewsData (int $a_ref_id, bool $a_only_public=false, $a_time_period=0, bool $a_prevent_aggregation=false, string $a_starting_date="", bool $a_no_auto_generated=false, ?int $a_user_id=null, int $a_limit=0, array $a_exclude=[]) | |
Get news aggregation (e.g. More... | |
setContext (int $a_obj_id, string $a_obj_type, int $a_sub_obj_id=0, string $a_sub_obj_type="") | |
Set context for news. More... | |
queryNewsForContext (bool $a_for_rss_use=false, $a_time_period=0, string $a_starting_date="", bool $a_no_auto_generated=false, bool $a_oldest_first=false, int $a_limit=0, array $a_exclude=[]) | |
Query news for a context. More... | |
checkNewsExistsForObjects (array $objects, $a_time_period=1) | |
queryNewsForMultipleContexts (array $a_contexts, bool $a_for_rss_use=false, $a_time_period=0, string $a_starting_date="", bool $a_no_auto_generated=false, ?int $a_user_id=null, int $a_limit=0, array $a_exclude=[]) | |
delete () | |
Delete news item. More... | |
deliverMobFile (string $a_purpose="Standard", bool $a_increase_download_cnt=false) | |
Deliver mob file. More... | |
increaseDownloadCounter () | |
Increase download counter. More... | |
increasePlayCounter () | |
Increase play counter. More... | |
Static Public Member Functions | |
static | _getNewsItemsOfUser (int $a_user_id, bool $a_only_public=false, bool $a_prevent_aggregation=false, int $a_per=0, array &$a_cnt=[], bool $no_auto_generated=false, array $excluded=[], int $a_limit=0) |
Get all news items for a user. More... | |
static | queryNewsByIds (array $a_news_ids) |
Query news data by news ids. More... | |
static | _setRead (int $a_user_id, int $a_news_id) |
Set item read. More... | |
static | _setUnread (int $a_user_id, int $a_news_id) |
Set item unread. More... | |
static | mergeNews (array $n1, array $n2) |
Merges two sets of news. More... | |
static | _getDefaultVisibilityForRefId (int $a_ref_id) |
Get default visibility for reference id. More... | |
static | getNewsOfContext (int $a_context_obj_id, string $a_context_obj_type, int $a_context_sub_obj_id=0, string $a_context_sub_obj_type="") |
Get all news of a context. More... | |
static | deleteNewsOfContext (int $a_context_obj_id, string $a_context_obj_type, int $a_context_sub_obj_id=0, string $a_context_sub_obj_type="") |
Delete all news of a context. More... | |
static | _lookupTitle (int $a_news_id) |
Lookup News Title. More... | |
static | _lookupVisibility (int $a_news_id) |
Lookup News Visibility. More... | |
static | _lookupMobId (int $a_news_id) |
Lookup mob id. More... | |
static | filterObjIdsPerNews (array $a_obj_ids, $a_time_period=0, string $a_starting_date="", string $a_ending_date='', bool $ignore_period=false) |
Checks whether news are available for. More... | |
static | determineNewsTitleByNewsId (int $a_news_id, int $a_agg_ref_id=0, array $a_aggregation=[]) |
Determine title for news item entry. More... | |
static | determineNewsTitle (string $a_context_obj_type, string $a_title, bool $a_content_is_lang_var, int $a_agg_ref_id=0, array $a_aggregation=[], ?ilLanguage $lng=null) |
Determine title for news item entry. More... | |
static | determineNewsContent (string $a_context_obj_type, string $a_content, bool $a_is_lang_var, ?ilLanguage $lng=null) |
Determine new content. More... | |
static | getFirstNewsIdForContext (int $a_context_obj_id, string $a_context_obj_type, int $a_context_sub_obj_id=0, string $a_context_sub_obj_type="") |
Get first new id of news set related to a certain context. More... | |
static | getLastNewsIdForContext (int $a_context_obj_id, string $a_context_obj_type, int $a_context_sub_obj_id=0, string $a_context_sub_obj_type="", bool $a_only_today=false) |
Get last news id of news set related to a certain context. More... | |
static | _lookupMediaObjectUsages (int $a_mob_id) |
Lookup media object usage(s) More... | |
static | _lookupContextObjId (int $a_news_id) |
Context Object ID. More... | |
static | _lookupDefaultPDPeriod () |
static | _lookupUserPDPeriod (int $a_user_id) |
static | _lookupRSSPeriod () |
static | setPrivateFeedId (int $a_userId) |
static | getPrivateFeedId () |
static | prepareNewsDataFromCache (array $a_cres) |
Prepare news data from cache. More... | |
Protected Member Functions | |
aggregateForums (array $news, bool $a_group_posting_sequence=false) | |
aggregateFiles (array $news, int $a_ref_id) | |
getAggregatedChildNewsData (int $a_ref_id, bool $a_only_public=false, int $a_time_period=0, bool $a_prevent_aggregation=false, string $a_starting_date="", bool $a_no_auto_generated=false, array $a_excluded=[]) | |
Get news aggregation for child objects (e.g. More... | |
Static Protected Member Functions | |
static | handleTimePeriod ($a_time_period) |
Convert time period for DB-queries. More... | |
Protected Attributes | |
MediaObjectManager | $media_manager |
int | $mob_cnt_play = 0 |
ilDBInterface | $db |
ilTree | $tree |
ilAccessHandler | $access |
ilObjectDataCache | $obj_data_cache |
ilObjUser | $user |
ilLanguage | $lng |
ilCtrl | $ctrl |
int | $id = 0 |
string | $title = "" |
string | $content = "" |
bool | $content_html = false |
int | $context_obj_id = 0 |
string | $context_obj_type = "" |
int | $context_sub_obj_id = 0 |
string | $context_sub_obj_type = null |
string | $content_type = "text" |
string | $creation_date = "" |
string | $update_date = "" |
int | $user_id = 0 |
int | $update_user_id = 0 |
string | $visibility = "users" |
string | $content_long = "" |
int | $priority = 1 |
bool | $content_is_lang_var = false |
int | $mob_id = 0 |
string | $playtime = "" |
bool | $content_text_is_lang_var = false |
ilLogger | $log |
Private Attributes | |
int | $mob_cnt_download = 0 |
bool | $limitation = false |
ilGlobalTemplateInterface | $main_tpl |
Static Private Attributes | |
static int | $privFeedId = 0 |
A news item can be created by different sources.
E.g. when a new forum posting is created, or when a change in a learning module is announced.
Please note that this class contains a lot of deprectated functions that will be move to other classes in the future. Please avoid to use these functions. This class should be a pure data class without persistence in the future.
Definition at line 42 of file class.ilNewsItem.php.
ilNewsItem::__construct | ( | int | $a_id = 0 | ) |
Definition at line 79 of file class.ilNewsItem.php.
References $DIC, ILIAS\Repository\access(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), read(), setId(), and ILIAS\Repository\user().
|
static |
Get default visibility for reference id.
Definition at line 1386 of file class.ilNewsItem.php.
References $DIC, $path, $visibility, ilBlockSetting\_lookup(), ilTree\getPathFull(), and ilTree\isInTree().
Referenced by ilNewsForContextBlockGUI\addToSettingsForm(), createProperties(), ilObjForum\createSettings(), ilNewsItemGUI\getEditForm(), and ilNewsForContextBlockGUI\initSettingsForm().
|
static |
Get all news items for a user.
Definition at line 503 of file class.ilNewsItem.php.
References $data, $DIC, $ref_id, ilObject\_getAllReferences(), ilParticipants\_getMembershipByType(), ilObject\_lookupObjId(), ilObjUser\_lookupPref(), ilObject\_lookupType(), ILIAS\Repository\int(), and ilArrayUtil\sortArray().
Referenced by ilUserFeedWriter\__construct(), ILIAS\News\Dashboard\DashboardNewsManager\getContextOptions(), ILIAS\News\Timeline\TimelineManager\getNewsData(), ilPDNewsBlockGUI\getNewsData(), and ILIAS\News\Dashboard\DashboardNewsManager\getNewsForOverview().
|
static |
Context Object ID.
Definition at line 1821 of file class.ilNewsItem.php.
Referenced by ilNewsItemGUI\executeCommand(), ilMediaObjectUsagesTableGUI\fillRow(), ilObjMediaObject\getParentObjectIdForUsage(), and ilNewsForContextBlockGUI\showNews().
|
static |
Definition at line 1840 of file class.ilNewsItem.php.
Referenced by ilPDNewsBlockGUI\editSettings(), ILIAS\News\Dashboard\DashboardNewsManager\getPeriodOptions(), ilObjNewsSettingsGUI\getSettingsForm(), and ilPDNewsTableGUI\initFilter().
|
static |
Lookup media object usage(s)
Definition at line 1797 of file class.ilNewsItem.php.
Referenced by ilObjMediaObject\lookupUsages().
|
static |
Lookup mob id.
Definition at line 1548 of file class.ilNewsItem.php.
Referenced by ilNewsExporter\getXmlExportHeadDependencies().
|
static |
Definition at line 1882 of file class.ilNewsItem.php.
Referenced by ilObjectFeedWriter\__construct(), ilUserFeedWriter\__construct(), ILIAS\MetaData\OERHarvester\Settings\Settings\SettingsGUI\getEditForm(), and ilObjNewsSettingsGUI\getSettingsForm().
|
static |
Lookup News Title.
Definition at line 1513 of file class.ilNewsItem.php.
|
static |
Definition at line 1854 of file class.ilNewsItem.php.
References ilBlockSetting\_lookup().
Referenced by ilPDNewsBlockGUI\editSettings(), ILIAS\News\Dashboard\DashboardNewsManager\getDashboardNewsPeriod(), ilPDNewsBlockGUI\getNewsData(), and ilPDNewsTableGUI\initFilter().
|
static |
Lookup News Visibility.
Definition at line 1530 of file class.ilNewsItem.php.
References $DIC, $ilDB, and NEWS_USERS.
Referenced by ilObjMediaObjectAccess\checkAccessMob(), and ilMobStakeholder\checkAccessMobUsage().
|
static |
Set item read.
Definition at line 1318 of file class.ilNewsItem.php.
Referenced by ilNewsForContextBlockGUI\showNews().
|
static |
Set item unread.
Definition at line 1347 of file class.ilNewsItem.php.
|
protected |
Definition at line 890 of file class.ilNewsItem.php.
Referenced by getAggregatedChildNewsData(), and getAggregatedNewsData().
|
protected |
Definition at line 842 of file class.ilNewsItem.php.
References null.
Referenced by getNewsForRefId().
ilNewsItem::checkNewsExistsForObjects | ( | array | $objects, |
$a_time_period = 1 |
|||
) |
string | int | $a_time_period |
Definition at line 1186 of file class.ilNewsItem.php.
References $db, $ilDB, $q, and ILIAS\Repository\int().
ilNewsItem::create | ( | ) |
Create.
Definition at line 384 of file class.ilNewsItem.php.
References $db, $ilDB, getContent(), getContentHtml(), getContentIsLangVar(), getContentLong(), getContentTextIsLangVar(), getContentType(), getContextObjId(), getContextObjType(), getContextSubObjId(), getContextSubObjType(), getId(), getLimitation(), getMobId(), getPlaytime(), getPriority(), getTitle(), getUpdateUserId(), getUserId(), getVisibility(), ilUtil\now(), and setId().
Referenced by ILIAS\News\Items\NewsItemManager\save().
ilNewsItem::delete | ( | ) |
Delete news item.
Definition at line 1426 of file class.ilNewsItem.php.
References $db, $ilDB, ilObject\_exists(), getId(), and getMobId().
Referenced by ilNewsTimelineGUI\remove().
|
static |
Delete all news of a context.
Definition at line 1493 of file class.ilNewsItem.php.
Referenced by ilObjTest\addToNewsOnOnline(), ilBlogPosting\delete(), ilPageObject\delete(), and ilBlogPosting\unpublish().
ilNewsItem::deliverMobFile | ( | string | $a_purpose = "Standard" , |
bool | $a_increase_download_cnt = false |
||
) |
Deliver mob file.
Definition at line 1912 of file class.ilNewsItem.php.
References ilObjMediaObject\_getDirectory(), getMobId(), increaseDownloadCounter(), and ilUtil\redirect().
|
static |
Determine new content.
Definition at line 1698 of file class.ilNewsItem.php.
References $DIC, ilLanguage\loadLanguageModule(), ilObjectPlugin\lookupTxtById(), and ilLanguage\txt().
Referenced by ilObjectFeedWriter\__construct(), ilUserFeedWriter\__construct(), ilPDNewsTableGUI\fillRow(), ilNewsDefaultRendererGUI\getDetailContent(), and ilMembershipCronNotifications\run().
|
static |
Determine title for news item entry.
Definition at line 1631 of file class.ilNewsItem.php.
References $DIC, ilObjectPlugin\lookupTxtById(), and ilLanguage\txt().
Referenced by ilObjectFeedWriter\__construct(), ilUserFeedWriter\__construct(), ilPDNewsTableGUI\fillRow(), ilNewsForContextBlockGUI\getInfoForData(), ilNewsTimelineItemGUI\render(), ilMembershipCronNotifications\run(), and ilNewsForContextBlockGUI\showNews().
|
static |
|
static |
Checks whether news are available for.
array | $a_obj_ids | |
string | int | $a_time_period |
Definition at line 1567 of file class.ilNewsItem.php.
|
protected |
Get news aggregation for child objects (e.g.
for categories)
Definition at line 922 of file class.ilNewsItem.php.
References $access, $data, $ref_id, $tree, aggregateFiles(), ilTree\getChilds(), getNewsForRefId(), null, queryNewsForMultipleContexts(), and ilArrayUtil\sortArray().
Referenced by getNewsForRefId().
ilNewsItem::getAggregatedNewsData | ( | int | $a_ref_id, |
bool | $a_only_public = false , |
||
$a_time_period = 0 , |
|||
bool | $a_prevent_aggregation = false , |
||
string | $a_starting_date = "" , |
||
bool | $a_no_auto_generated = false , |
||
?int | $a_user_id = null , |
||
int | $a_limit = 0 , |
||
array | $a_exclude = [] |
||
) |
Get news aggregation (e.g.
for courses, groups)
string | int | $a_time_period |
Definition at line 735 of file class.ilNewsItem.php.
References $access, $data, $obj_data_cache, $ref_id, $tree, aggregateFiles(), ilTree\getNodeData(), ilTree\getSubTree(), ILIAS\Repository\int(), ilObjectActivation\preloadData(), queryNewsForMultipleContexts(), and ilArrayUtil\sortArray().
Referenced by getNewsForRefId().
ilNewsItem::getContent | ( | ) |
Definition at line 125 of file class.ilNewsItem.php.
References $content.
Referenced by create(), and update().
ilNewsItem::getContentHtml | ( | ) |
Definition at line 339 of file class.ilNewsItem.php.
References $content_html.
Referenced by create(), and update().
ilNewsItem::getContentIsLangVar | ( | ) |
Definition at line 263 of file class.ilNewsItem.php.
References $content_is_lang_var.
Referenced by create(), and update().
ilNewsItem::getContentLong | ( | ) |
Definition at line 242 of file class.ilNewsItem.php.
References $content_long.
Referenced by create(), and update().
ilNewsItem::getContentTextIsLangVar | ( | ) |
Definition at line 309 of file class.ilNewsItem.php.
References $content_text_is_lang_var.
Referenced by create(), and update().
ilNewsItem::getContentType | ( | ) |
Definition at line 175 of file class.ilNewsItem.php.
References $content_type.
Referenced by create(), and update().
ilNewsItem::getContextObjId | ( | ) |
Definition at line 135 of file class.ilNewsItem.php.
References $context_obj_id.
Referenced by create(), queryNewsForContext(), and update().
ilNewsItem::getContextObjType | ( | ) |
Definition at line 145 of file class.ilNewsItem.php.
References $context_obj_type.
Referenced by create(), queryNewsForContext(), and update().
ilNewsItem::getContextSubObjId | ( | ) |
Definition at line 155 of file class.ilNewsItem.php.
References $context_sub_obj_id.
Referenced by create(), queryNewsForContext(), and update().
ilNewsItem::getContextSubObjType | ( | ) |
Definition at line 165 of file class.ilNewsItem.php.
References $context_sub_obj_type.
Referenced by create(), queryNewsForContext(), and update().
ilNewsItem::getCreationDate | ( | ) |
|
static |
Get first new id of news set related to a certain context.
Definition at line 1726 of file class.ilNewsItem.php.
Referenced by ilObjTest\addToNewsOnOnline(), ilForum\deletePost(), ilForumTopic\movePosts(), ilForum\postCensorship(), and ilObjForumGUI\savePostObject().
ilNewsItem::getId | ( | ) |
Definition at line 105 of file class.ilNewsItem.php.
References $id.
Referenced by create(), delete(), ilObjMediaCastGUI\determinePlaytimeObject(), increaseDownloadCounter(), increasePlayCounter(), read(), ilNewsTimelineItemGUI\renderMedia(), ilNewsTimelineItemGUI\renderMediaModal(), ILIAS\News\Items\NewsItemManager\save(), and update().
|
static |
Get last news id of news set related to a certain context.
Definition at line 1755 of file class.ilNewsItem.php.
References $DIC, $id, $ilDB, ILIAS\Repository\int(), and ilUtil\now().
Referenced by ILIAS\Blog\News\NewsManager\handle(), and ilWikiPage\updateNews().
ilNewsItem::getLimitation | ( | ) |
Definition at line 299 of file class.ilNewsItem.php.
References $limitation.
Referenced by create().
ilNewsItem::getMobDownloadCounter | ( | ) |
Definition at line 329 of file class.ilNewsItem.php.
References $mob_cnt_download.
Referenced by increaseDownloadCounter(), and update().
ilNewsItem::getMobId | ( | ) |
Definition at line 273 of file class.ilNewsItem.php.
References $mob_id.
Referenced by create(), delete(), deliverMobFile(), ilObjMediaCastGUI\determinePlaytimeObject(), ilNewsTimelineItemGUI\getMediaPath(), ilObjMediaCastGUI\initAddCastItemForm(), update(), and ilObjMediaCastGUI\updateCastItemObject().
ilNewsItem::getMobPlayCounter | ( | ) |
Definition at line 319 of file class.ilNewsItem.php.
References $mob_cnt_play.
Referenced by increasePlayCounter(), and update().
ilNewsItem::getNewsForRefId | ( | int | $a_ref_id, |
bool | $a_only_public = false , |
||
bool | $a_stopnesting = false , |
||
$a_time_period = 0 , |
|||
bool | $a_prevent_aggregation = true , |
||
bool | $a_forum_group_sequences = false , |
||
bool | $a_no_auto_generated = false , |
||
bool | $a_ignore_date_filter = false , |
||
?int | $a_user_id = null , |
||
int | $a_limit = 0 , |
||
array | $a_excluded = [] |
||
) |
Get News For Ref Id.
string | int | $a_time_period | |
int | $a_limit | currently only supported for groups and courses |
int[] | $a_excluded currently only supported for groups and courses (news ids) |
Definition at line 612 of file class.ilNewsItem.php.
References ilBlockSetting\_lookup(), ilContainer\_lookupContainerSetting(), ilObject\_lookupObjId(), ilObject\_lookupType(), aggregateForums(), getAggregatedChildNewsData(), getAggregatedNewsData(), and NEWS_PUBLIC.
Referenced by getAggregatedChildNewsData(), and ilNewsItemGUI\getNewsForContextTable().
|
static |
Get all news of a context.
Definition at line 1454 of file class.ilNewsItem.php.
ilNewsItem::getPlaytime | ( | ) |
Definition at line 286 of file class.ilNewsItem.php.
References $playtime.
Referenced by create(), and update().
ilNewsItem::getPriority | ( | ) |
Definition at line 252 of file class.ilNewsItem.php.
References $priority.
Referenced by ILIAS\News\Access\NewsAccess\canEdit(), create(), and update().
|
static |
Definition at line 1903 of file class.ilNewsItem.php.
ilNewsItem::getTitle | ( | ) |
Definition at line 115 of file class.ilNewsItem.php.
References $title.
Referenced by create(), and update().
ilNewsItem::getUpdateDate | ( | ) |
ilNewsItem::getUpdateUserId | ( | ) |
Definition at line 215 of file class.ilNewsItem.php.
References $update_user_id.
Referenced by create(), and update().
ilNewsItem::getUserId | ( | ) |
Definition at line 205 of file class.ilNewsItem.php.
References $user_id.
Referenced by ILIAS\News\Access\NewsAccess\canEdit(), create(), and update().
ilNewsItem::getVisibility | ( | ) |
Definition at line 229 of file class.ilNewsItem.php.
References $visibility.
Referenced by create(), and update().
|
staticprotected |
Convert time period for DB-queries.
string | int | $a_time_period |
Definition at line 1025 of file class.ilNewsItem.php.
ilNewsItem::increaseDownloadCounter | ( | ) |
Increase download counter.
Definition at line 1947 of file class.ilNewsItem.php.
References $db, $ilDB, getId(), getMobDownloadCounter(), and setMobDownloadCounter().
Referenced by deliverMobFile().
ilNewsItem::increasePlayCounter | ( | ) |
Increase play counter.
Definition at line 1966 of file class.ilNewsItem.php.
References $db, $ilDB, getId(), getMobPlayCounter(), and setMobPlayCounter().
|
static |
Merges two sets of news.
Definition at line 1371 of file class.ilNewsItem.php.
References $id.
|
static |
Prepare news data from cache.
Definition at line 1984 of file class.ilNewsItem.php.
References $data, $DIC, $ilDB, and ILIAS\Repository\int().
Referenced by ilPDNewsBlockGUI\__construct(), and ilNewsForContextBlockGUI\__construct().
|
static |
Query news data by news ids.
int[] | $a_news_ids |
Definition at line 1168 of file class.ilNewsItem.php.
Referenced by ilMembershipCronNotificationsData\loadMissingNews().
ilNewsItem::queryNewsForContext | ( | bool | $a_for_rss_use = false , |
$a_time_period = 0 , |
|||
string | $a_starting_date = "" , |
||
bool | $a_no_auto_generated = false , |
||
bool | $a_oldest_first = false , |
||
int | $a_limit = 0 , |
||
array | $a_exclude = [] |
||
) |
Query news for a context.
string | int | $a_time_period |
Definition at line 1045 of file class.ilNewsItem.php.
References $db, $ilDB, $user, ilBlockSetting\_lookup(), getContextObjId(), getContextObjType(), getContextSubObjId(), getContextSubObjType(), ILIAS\Repository\int(), and NEWS_PUBLIC.
Referenced by ilNewsItemGUI\getNewsForContextBlock(), and ilNewsItemGUI\getNewsForContextTable().
ilNewsItem::queryNewsForMultipleContexts | ( | array | $a_contexts, |
bool | $a_for_rss_use = false , |
||
$a_time_period = 0 , |
|||
string | $a_starting_date = "" , |
||
bool | $a_no_auto_generated = false , |
||
?int | $a_user_id = null , |
||
int | $a_limit = 0 , |
||
array | $a_exclude = [] |
||
) |
string | int | $a_time_period |
Definition at line 1216 of file class.ilNewsItem.php.
References $db, $ilDB, $user, ilBlockSetting\_lookup(), ILIAS\Repository\int(), and NEWS_PUBLIC.
Referenced by getAggregatedChildNewsData(), and getAggregatedNewsData().
ilNewsItem::read | ( | ) |
Read item from database.
Definition at line 348 of file class.ilNewsItem.php.
References $db, $ilDB, getId(), setContent(), setContentHtml(), setContentIsLangVar(), setContentLong(), setContentTextIsLangVar(), setContentType(), setContextObjId(), setContextObjType(), setContextSubObjId(), setContextSubObjType(), setCreationDate(), setMobDownloadCounter(), setMobId(), setMobPlayCounter(), setPlaytime(), setPriority(), setTitle(), setUpdateDate(), setUpdateUserId(), setUserId(), and setVisibility().
Referenced by __construct().
ilNewsItem::setContent | ( | string | $a_content | ) |
Definition at line 120 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setContentHtml | ( | bool | $a_val | ) |
Definition at line 334 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setContentIsLangVar | ( | bool | $a_content_is_lang_var = false | ) |
Definition at line 257 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setContentLong | ( | string | $a_content_long | ) |
string | $a_content_long | Long content of news |
Definition at line 237 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setContentTextIsLangVar | ( | bool | $a_val = false | ) |
Definition at line 304 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setContentType | ( | string | $a_content_type = "text" | ) |
Definition at line 170 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setContext | ( | int | $a_obj_id, |
string | $a_obj_type, | ||
int | $a_sub_obj_id = 0 , |
||
string | $a_sub_obj_type = "" |
||
) |
Set context for news.
Definition at line 1009 of file class.ilNewsItem.php.
References setContextObjId(), setContextObjType(), setContextSubObjId(), and setContextSubObjType().
ilNewsItem::setContextObjId | ( | int | $a_context_obj_id | ) |
Definition at line 130 of file class.ilNewsItem.php.
Referenced by ilNewsItemGUI\getNewsForContextBlock(), ilNewsItemGUI\getNewsForContextTable(), read(), and setContext().
ilNewsItem::setContextObjType | ( | string | $a_context_obj_type | ) |
Definition at line 140 of file class.ilNewsItem.php.
Referenced by ilNewsItemGUI\getNewsForContextBlock(), ilNewsItemGUI\getNewsForContextTable(), read(), and setContext().
ilNewsItem::setContextSubObjId | ( | int | $a_context_sub_obj_id | ) |
Definition at line 150 of file class.ilNewsItem.php.
Referenced by ilNewsItemGUI\getNewsForContextBlock(), ilNewsItemGUI\getNewsForContextTable(), read(), and setContext().
ilNewsItem::setContextSubObjType | ( | ?string | $a_context_sub_obj_type | ) |
Definition at line 160 of file class.ilNewsItem.php.
Referenced by ilNewsItemGUI\getNewsForContextBlock(), ilNewsItemGUI\getNewsForContextTable(), read(), and setContext().
ilNewsItem::setCreationDate | ( | string | $a_creation_date | ) |
Definition at line 180 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setId | ( | int | $a_id | ) |
Definition at line 100 of file class.ilNewsItem.php.
Referenced by __construct(), and create().
ilNewsItem::setLimitation | ( | bool | $a_limitation | ) |
Set Limitation for number of items.
Definition at line 294 of file class.ilNewsItem.php.
ilNewsItem::setMobDownloadCounter | ( | int | $a_val | ) |
Definition at line 324 of file class.ilNewsItem.php.
Referenced by increaseDownloadCounter(), and read().
ilNewsItem::setMobId | ( | int | $a_mob_id | ) |
Definition at line 268 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setMobPlayCounter | ( | int | $a_val | ) |
Definition at line 314 of file class.ilNewsItem.php.
Referenced by increasePlayCounter(), and read().
ilNewsItem::setPlaytime | ( | string | $a_playtime | ) |
string | $a_playtime | Play Time, hh:mm:ss (of attached media file) |
Definition at line 281 of file class.ilNewsItem.php.
Referenced by ilObjMediaCastGUI\determinePlaytimeObject(), and read().
ilNewsItem::setPriority | ( | int | $a_priority = 1 | ) |
Definition at line 247 of file class.ilNewsItem.php.
Referenced by read().
|
static |
Definition at line 1895 of file class.ilNewsItem.php.
Referenced by ilObjectFeedWriter\__construct().
ilNewsItem::setTitle | ( | string | $a_title | ) |
Definition at line 110 of file class.ilNewsItem.php.
Referenced by read(), and ilNewsTimelineGUI\update().
ilNewsItem::setUpdateDate | ( | string | $a_update_date | ) |
Definition at line 190 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setUpdateUserId | ( | int | $a_val | ) |
Definition at line 210 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setUserId | ( | int | $a_user_id | ) |
Definition at line 200 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::setVisibility | ( | string | $a_visibility = "users" | ) |
string | $a_visibility | Access level of news. |
Definition at line 223 of file class.ilNewsItem.php.
Referenced by read().
ilNewsItem::update | ( | bool | $a_as_new = false | ) |
Update item in database.
bool | $a_as_new | If true, creation date is set "now" |
Definition at line 461 of file class.ilNewsItem.php.
References $db, $ilDB, getContent(), getContentHtml(), getContentIsLangVar(), getContentLong(), getContentTextIsLangVar(), getContentType(), getContextObjId(), getContextObjType(), getContextSubObjId(), getContextSubObjType(), getId(), getMobDownloadCounter(), getMobId(), getMobPlayCounter(), getPlaytime(), getPriority(), getTitle(), getUpdateUserId(), getUserId(), getVisibility(), ILIAS\Repository\int(), and ilUtil\now().
Referenced by ILIAS\News\Items\NewsItemManager\save().
|
protected |
Definition at line 49 of file class.ilNewsItem.php.
Referenced by getAggregatedChildNewsData(), and getAggregatedNewsData().
|
protected |
Definition at line 56 of file class.ilNewsItem.php.
Referenced by getContent().
|
protected |
Definition at line 57 of file class.ilNewsItem.php.
Referenced by getContentHtml().
|
protected |
Definition at line 70 of file class.ilNewsItem.php.
Referenced by getContentIsLangVar().
|
protected |
Definition at line 68 of file class.ilNewsItem.php.
Referenced by getContentLong().
|
protected |
Definition at line 75 of file class.ilNewsItem.php.
Referenced by getContentTextIsLangVar().
|
protected |
Definition at line 62 of file class.ilNewsItem.php.
Referenced by getContentType().
|
protected |
Definition at line 58 of file class.ilNewsItem.php.
Referenced by getContextObjId().
|
protected |
Definition at line 59 of file class.ilNewsItem.php.
Referenced by getContextObjType().
|
protected |
Definition at line 60 of file class.ilNewsItem.php.
Referenced by getContextSubObjId().
|
protected |
Definition at line 61 of file class.ilNewsItem.php.
Referenced by getContextSubObjType().
|
protected |
Definition at line 63 of file class.ilNewsItem.php.
Referenced by getCreationDate().
|
protected |
Definition at line 53 of file class.ilNewsItem.php.
|
protected |
Definition at line 47 of file class.ilNewsItem.php.
Referenced by checkNewsExistsForObjects(), create(), delete(), increaseDownloadCounter(), increasePlayCounter(), queryNewsForContext(), queryNewsForMultipleContexts(), read(), and update().
|
protected |
Definition at line 54 of file class.ilNewsItem.php.
Referenced by getId(), getLastNewsIdForContext(), and mergeNews().
|
private |
Definition at line 74 of file class.ilNewsItem.php.
Referenced by getLimitation().
|
protected |
Definition at line 52 of file class.ilNewsItem.php.
|
protected |
Definition at line 77 of file class.ilNewsItem.php.
|
private |
Definition at line 76 of file class.ilNewsItem.php.
|
protected |
Definition at line 45 of file class.ilNewsItem.php.
|
private |
Definition at line 44 of file class.ilNewsItem.php.
Referenced by getMobDownloadCounter().
|
protected |
Definition at line 46 of file class.ilNewsItem.php.
Referenced by getMobPlayCounter().
|
protected |
Definition at line 71 of file class.ilNewsItem.php.
Referenced by getMobId().
|
protected |
Definition at line 50 of file class.ilNewsItem.php.
Referenced by getAggregatedNewsData().
|
protected |
Definition at line 72 of file class.ilNewsItem.php.
Referenced by getPlaytime().
|
protected |
Definition at line 69 of file class.ilNewsItem.php.
Referenced by getPriority().
|
staticprivate |
Definition at line 73 of file class.ilNewsItem.php.
|
protected |
Definition at line 55 of file class.ilNewsItem.php.
Referenced by getTitle().
|
protected |
Definition at line 48 of file class.ilNewsItem.php.
Referenced by getAggregatedChildNewsData(), and getAggregatedNewsData().
|
protected |
Definition at line 64 of file class.ilNewsItem.php.
Referenced by getUpdateDate().
|
protected |
Definition at line 66 of file class.ilNewsItem.php.
Referenced by getUpdateUserId().
|
protected |
Definition at line 51 of file class.ilNewsItem.php.
Referenced by queryNewsForContext(), and queryNewsForMultipleContexts().
|
protected |
Definition at line 65 of file class.ilNewsItem.php.
Referenced by getUserId().
|
protected |
Definition at line 67 of file class.ilNewsItem.php.
Referenced by _getDefaultVisibilityForRefId(), and getVisibility().