ILIAS
release_4-3 Revision
|
Handles object exports to ECS. More...
Public Member Functions | |
__construct (ilObject $a_content_object) | |
Constructor. | |
getContentObject () | |
Get content object. | |
addSettingsToForm (ilPropertyFormGUI $a_form, $a_type) | |
Fill ECS export settings "multiple servers". | |
handleSettingsUpdate () | |
Update ECS Export Settings. | |
handleContentUpdate () | |
Update ECS Content. | |
doDelete (ilECSSetting $a_server, ilECSExport $a_export_settings) | |
Delete ECS resource. |
Static Public Member Functions | |
static | getInstanceByObject (ilObject $a_content_obj) |
Get settings handler for repository object. | |
static | _handleDelete (array $a_subbtree_nodes) |
handle delete Objects that are moved to the trash call ECS-Remove |
Data Fields | |
const | MAIL_SENDER = 6 |
Protected Member Functions | |
getECSObjectType () | |
Get ECS resource identifier, e.g. | |
isActive () | |
Is ECS (for current object) active? | |
handleSettingsForServer (ilECSSetting $a_server, $a_export, $a_mids) | |
Save ECS settings (add- update- deleteResource) | |
doAdd (ilECSSetting $a_server, ilECSExport $a_export_settings, array $a_mids) | |
Add resource to ECS. | |
doUpdate (ilECSSetting $a_server, ilECSExport $a_export_settings, array $a_mids=null) | |
Update ECS resource. | |
getParticipants ($a_server_id, $a_econtent_id) | |
Get participants for server and ecs resource. | |
sendNewContentNotification (ilECSSetting $a_server, $a_econtent_id) | |
send notifications about new EContent | |
handlePermissionUpdate (ilECSSetting $server) | |
getJsonCore ($a_etype) | |
Build core json structure. | |
addMetadataToJson (&$a_json, ilECSSetting $a_server, array $a_definition) | |
Add advanced metadata to json (export) | |
buildJson (ilECSSetting $a_server) | |
Build resource-specific json. |
Protected Attributes | |
$content_obj |
Handles object exports to ECS.
Definition at line 13 of file class.ilECSObjectSettings.php.
ilECSObjectSettings::__construct | ( | ilObject | $a_content_object | ) |
Constructor.
ilObject | $a_content_object |
Definition at line 24 of file class.ilECSObjectSettings.php.
|
static |
handle delete Objects that are moved to the trash call ECS-Remove
array | $a_subbtree_nodes |
Definition at line 477 of file class.ilECSObjectSettings.php.
References $content_obj, $server, ilECSExport\getExportedIds(), ilECSExport\getExportServerIds(), ilECSServerSettings\getInstance(), getInstanceByObject(), ilObjectFactory\getInstanceByRefId(), and ilECSSetting\getInstanceByServerId().
Referenced by ilRepUtil\deleteObjects().
|
protected |
Add advanced metadata to json (export)
object | $a_json | |
ilECSSetting | $a_server | |
array | $a_definition |
Definition at line 668 of file class.ilECSObjectSettings.php.
References ilAdvancedMDValues\_getValuesByObjId(), ilECSDataMappingSettings\getInstanceByServerId(), ilECSSetting\getServerId(), ilECSDataMappingSetting\MAPPING_EXPORT, ilECSUtils\TYPE_ARRAY, ilECSUtils\TYPE_INT, ilECSUtils\TYPE_STRING, and ilECSUtils\TYPE_TIMEPLACE.
Referenced by ilECSCourseSettings\buildJson().
ilECSObjectSettings::addSettingsToForm | ( | ilPropertyFormGUI | $a_form, |
$a_type | |||
) |
Fill ECS export settings "multiple servers".
to be used in ilObject->initEditForm()
ilPropertyFormGUI | $a_form |
Definition at line 113 of file class.ilECSObjectSettings.php.
References $GLOBALS, $lng, ilECSExport\_isExported(), ilPropertyFormGUI\addItem(), getContentObject(), getECSObjectType(), ilECSParticipantSettings\getExportableParticipants(), ilECSExport\getExportServerIds(), ilECSEContentDetails\getInstance(), isActive(), ilFormPropertyGUI\setRequired(), ilCheckboxInputGUI\setValue(), and ilCheckboxGroupInputGUI\setValue().
|
abstractprotected |
Build resource-specific json.
ilECSSetting | $a_server |
Reimplemented in ilECSCategorySettings, ilECSCourseSettings, ilECSFileSettings, ilECSGlossarySettings, ilECSGroupSettings, ilECSLearningModuleSettings, ilECSTestSettings, and ilECSWikiSettings.
Referenced by doAdd(), and doUpdate().
|
protected |
Add resource to ECS.
ilECSSetting | $a_server | |
ilECSExport | $a_export_settings | |
array | $a_mids |
Definition at line 373 of file class.ilECSObjectSettings.php.
References $ilLog, buildJson(), getECSObjectType(), handlePermissionUpdate(), ilECSConnector\HEADER_MEMBERSHIPS, ilECSExport\save(), sendNewContentNotification(), ilECSExport\setEContentId(), and ilECSExport\setExported().
Referenced by handleSettingsForServer().
ilECSObjectSettings::doDelete | ( | ilECSSetting | $a_server, |
ilECSExport | $a_export_settings | ||
) |
Delete ECS resource.
as it is called from self::_handleDelete() it has to be public...
type | $a_server_id |
ilECSConnectorException |
Definition at line 442 of file class.ilECSObjectSettings.php.
References $ilLog, ilECSExport\getEContentId(), getECSObjectType(), ilECSExport\isExported(), ilECSExport\save(), and ilECSExport\setExported().
Referenced by handleSettingsForServer().
|
protected |
Update ECS resource.
ilECSSetting | $a_server | |
ilECSExport | $a_export_settings | |
array | $a_mids |
ilECSConnectorException |
Definition at line 406 of file class.ilECSObjectSettings.php.
References $ilLog, buildJson(), ilECSExport\getEContentId(), getECSObjectType(), getParticipants(), ilECSSetting\getServerId(), handlePermissionUpdate(), and ilECSConnector\HEADER_MEMBERSHIPS.
Referenced by handleContentUpdate(), and handleSettingsForServer().
ilECSObjectSettings::getContentObject | ( | ) |
Get content object.
Definition at line 73 of file class.ilECSObjectSettings.php.
References $content_obj.
Referenced by addSettingsToForm(), and getJsonCore().
|
abstractprotected |
Get ECS resource identifier, e.g.
"/campusconnect/courselinks"
Reimplemented in ilECSCategorySettings, ilECSCourseSettings, ilECSFileSettings, ilECSGlossarySettings, ilECSGroupSettings, ilECSLearningModuleSettings, ilECSTestSettings, and ilECSWikiSettings.
Referenced by addSettingsToForm(), doAdd(), doDelete(), doUpdate(), getParticipants(), and sendNewContentNotification().
|
static |
Get settings handler for repository object.
ilObject | $a_content_obj |
Definition at line 35 of file class.ilECSObjectSettings.php.
References ilObject\getType().
Referenced by _handleDelete().
|
protected |
Build core json structure.
string | $a_etype |
Definition at line 646 of file class.ilECSObjectSettings.php.
References ilLink\_getLink(), and getContentObject().
Referenced by ilECSCategorySettings\buildJson(), ilECSWikiSettings\buildJson(), ilECSTestSettings\buildJson(), ilECSLearningModuleSettings\buildJson(), ilECSGroupSettings\buildJson(), ilECSGlossarySettings\buildJson(), ilECSFileSettings\buildJson(), and ilECSCourseSettings\buildJson().
|
protected |
Get participants for server and ecs resource.
int | $a_server_id | |
int | $a_econtent_id |
Definition at line 516 of file class.ilECSObjectSettings.php.
References getECSObjectType(), and ilECSEContentDetails\getInstance().
Referenced by doUpdate().
ilECSObjectSettings::handleContentUpdate | ( | ) |
Update ECS Content.
to be used AFTER metadata-/content-updates
Definition at line 323 of file class.ilECSObjectSettings.php.
References $ilLog, $server, doUpdate(), ilECSExport\getExportServerIds(), ilECSSetting\getInstanceByServerId(), and isActive().
|
protected |
Definition at line 624 of file class.ilECSObjectSettings.php.
References $GLOBALS, ilRbacReview\_getOperationIdsByName(), and ilECSSetting\getGlobalRole().
Referenced by doAdd(), and doUpdate().
|
protected |
Save ECS settings (add- update- deleteResource)
ilECSSetting | $a_server | |
bool | $a_export | |
array | array of participant mids |
ilECSConnectorException |
Definition at line 274 of file class.ilECSObjectSettings.php.
References doAdd(), doDelete(), doUpdate(), and ilECSSetting\getServerId().
Referenced by handleSettingsUpdate().
ilECSObjectSettings::handleSettingsUpdate | ( | ) |
Update ECS Export Settings.
Processes post data from addSettingstoForm() to be used in ilObject->update() AFTER object data has been updated
Definition at line 213 of file class.ilECSObjectSettings.php.
References $_POST, $server, ilECSParticipantSettings\getExportServers(), ilECSSetting\getInstanceByServerId(), handleSettingsForServer(), isActive(), and ilUtil\sendFailure().
|
protected |
Is ECS (for current object) active?
Definition at line 90 of file class.ilECSObjectSettings.php.
References ilECSServerSettings\getInstance(), and ilECSImport\lookupServerId().
Referenced by addSettingsToForm(), handleContentUpdate(), and handleSettingsUpdate().
|
protected |
send notifications about new EContent
Definition at line 544 of file class.ilECSObjectSettings.php.
References $ilLog, $lang, ilMail\_getAutoGeneratedMessageString(), ilLanguageFactory\_getLanguage(), ilLink\_getStaticLink(), ilECSSetting\getApprovalRecipients(), ilECSSetting\getApprovalRecipientsAsString(), getECSObjectType(), ilECSEContentDetails\getInstance(), ilECSCommunityReader\getInstanceByServerId(), and ilECSSetting\getServerId().
Referenced by doAdd().
|
protected |
Definition at line 15 of file class.ilECSObjectSettings.php.
Referenced by _handleDelete(), and getContentObject().
const ilECSObjectSettings::MAIL_SENDER = 6 |
Definition at line 17 of file class.ilECSObjectSettings.php.