ILIAS
release_5-2 Revision v5.2.25-18-g3f80b828510
|
GUI class for the workflow of copying objects. More...
Public Member Functions | |
__construct ($a_parent_gui) | |
Constructor. More... | |
executeCommand () | |
Control class handling. More... | |
showTargetSelectionTree () | |
Show target selection. More... | |
showSourceSelectionTree () | |
Show target selection. More... | |
setMode ($a_mode) | |
set copy mode More... | |
getMode () | |
get copy mode More... | |
setSubMode ($a_mode) | |
getSubMode () | |
getParentObject () | |
Get parent gui object. More... | |
getType () | |
Returns $type. More... | |
setType ($type) | |
Sets $type. More... | |
setSource (array $a_source_ids) | |
Set source id. More... | |
getSource () | |
Get source id. More... | |
getSources () | |
Get sources. More... | |
getFirstSource () | |
setTarget ($a_ref_id) | |
Set single object target. More... | |
setTargets (array $a_target) | |
Set target id. More... | |
getTargets () | |
Get copy target. More... | |
getFirstTarget () | |
Get first target. More... | |
keepObjectsInClipboard () | |
Keep objects in clipboard. More... | |
copyMultipleNonContainer ($a_sources) | |
Copy multiple non container. More... | |
showSourceSearch ($a_tplvar) | |
Show init screen Normally shown below the create and import form when creating a new object. More... | |
Data Fields | |
const | SOURCE_SELECTION = 1 |
const | TARGET_SELECTION = 2 |
const | SEARCH_SOURCE = 3 |
const | SUBMODE_COMPLETE = 1 |
const | SUBMODE_CONTENT_ONLY = 2 |
const | TAB_SELECTION_TARGET_TREE = 1 |
const | TAB_SELECTION_SOURCE_TREE = 2 |
const | TAB_SELECTION_MEMBERSHIP = 3 |
const | TAB_GROUP_SC_SELECTION = 1 |
Protected Member Functions | |
init () | |
Init return, mode. More... | |
initTabs () | |
Init tabs General. More... | |
setTabs ($a_tab_group, $a_active_tab) | |
Set tabs. More... | |
adoptContent () | |
Adopt content (crs in crs, grp in grp, crs in grp or grp in crs) More... | |
initTargetSelection () | |
Init copy from repository/search list commands. More... | |
initSourceSelection () | |
Init source selection. More... | |
showSourceSelectionMembership () | |
show target selection membership More... | |
saveTarget () | |
Save target selection. More... | |
cancel () | |
Cancel workflow. More... | |
searchSource () | |
Search source. More... | |
saveSource () | |
select source object More... | |
saveSourceMembership () | |
Save selected source from membership screen. More... | |
showItemSelection () | |
copySingleObject () | |
Start cloning a single (not container) object. More... | |
copyContainerToTargets () | |
Copy to multiple targets. More... | |
showCopyProgress () | |
Show progress for copying. More... | |
updateProgress () | |
Update progress. More... | |
copyContainer ($a_target) | |
Copy a container. More... | |
sourceExists () | |
Check if there is any source object. More... | |
initFormSearch () | |
Init search form. More... | |
unsetSession () | |
Unset session variables. More... | |
Private Attributes | |
$mode = 0 | |
$sub_mode = self::SUBMODE_COMPLETE | |
$lng | |
$parent_obj = null | |
$type = '' | |
$sources = array() | |
$targets = array() | |
$targets_copy_id = array() | |
$log = null | |
GUI class for the workflow of copying objects.
Definition at line 15 of file class.ilObjectCopyGUI.php.
ilObjectCopyGUI::__construct | ( | $a_parent_gui | ) |
Constructor.
Definition at line 59 of file class.ilObjectCopyGUI.php.
References $ilCtrl, $lng, and ilLoggerFactory\getLogger().
|
protected |
Adopt content (crs in crs, grp in grp, crs in grp or grp in crs)
Definition at line 220 of file class.ilObjectCopyGUI.php.
References $_GET, $GLOBALS, initSourceSelection(), setMode(), setSubMode(), and setTarget().
|
protected |
|
protected |
Copy a container.
Definition at line 1122 of file class.ilObjectCopyGUI.php.
References $_COOKIE, $_POST, $ilCtrl, $ilErr, $ilLog, $ilUser, $options, $orig, $result, $target_type, ilObject\_lookupObjId(), ilObject\_lookupType(), array, getFirstSource(), ilObjectFactory\getInstanceByRefId(), ilLoggerFactory\getLogger(), getSources(), getSubMode(), getType(), and ilUtil\sendFailure().
Referenced by copyContainerToTargets().
|
protected |
Copy to multiple targets.
Definition at line 1038 of file class.ilObjectCopyGUI.php.
References $_SESSION, $ilCtrl, $result, ilCopyWizardOptions\_isFinished(), copyContainer(), ilLoggerFactory\getLogger(), getSources(), getTargets(), ilUtil\sendSuccess(), and showCopyProgress().
ilObjectCopyGUI::copyMultipleNonContainer | ( | $a_sources | ) |
Copy multiple non container.
array | $a_sources | array of source ref ids |
Definition at line 939 of file class.ilObjectCopyGUI.php.
References $_SESSION, $ilCtrl, $ilUser, $orig, ilCopyWizardOptions\_allocateCopyId(), ilCopyWizardOptions\_getInstance(), ilLink\_getLink(), ilObject\_lookupType(), ilRbacLog\add(), ilRbacLog\COPY_OBJECT, ilRbacLog\gatherFaPa(), getFirstTarget(), ilObjectFactory\getInstanceByRefId(), ilLoggerFactory\getLogger(), getSubMode(), getTargets(), ilRbacLog\isActive(), ilUtil\redirect(), ilUtil\sendFailure(), and ilUtil\sendSuccess().
Referenced by copySingleObject(), and saveTarget().
|
protected |
Start cloning a single (not container) object.
Definition at line 916 of file class.ilObjectCopyGUI.php.
References $ilCtrl, $ilErr, $ilUser, copyMultipleNonContainer(), getSource(), and ilUtil\sendFailure().
Referenced by saveSource(), saveSourceMembership(), and saveTarget().
ilObjectCopyGUI::executeCommand | ( | ) |
Control class handling.
Definition at line 76 of file class.ilObjectCopyGUI.php.
References $cmd, $ilCtrl, init(), and initTabs().
ilObjectCopyGUI::getFirstSource | ( | ) |
Definition at line 630 of file class.ilObjectCopyGUI.php.
Referenced by copyContainer(), init(), saveSourceMembership(), saveTarget(), searchSource(), and showItemSelection().
ilObjectCopyGUI::getFirstTarget | ( | ) |
Get first target.
Definition at line 674 of file class.ilObjectCopyGUI.php.
References $targets, and getTargets().
Referenced by copyMultipleNonContainer(), and init().
ilObjectCopyGUI::getMode | ( | ) |
get copy mode
Definition at line 556 of file class.ilObjectCopyGUI.php.
References $mode.
Referenced by setTabs(), and showItemSelection().
ilObjectCopyGUI::getParentObject | ( | ) |
Get parent gui object.
Definition at line 575 of file class.ilObjectCopyGUI.php.
References $parent_obj.
Referenced by init().
ilObjectCopyGUI::getSource | ( | ) |
Get source id.
Definition at line 616 of file class.ilObjectCopyGUI.php.
References getSources().
Referenced by copySingleObject(), init(), initTargetSelection(), keepObjectsInClipboard(), saveTarget(), showItemSelection(), and showSourceSelectionTree().
ilObjectCopyGUI::getSources | ( | ) |
Get sources.
Definition at line 625 of file class.ilObjectCopyGUI.php.
References $sources, and array.
Referenced by copyContainer(), copyContainerToTargets(), getSource(), init(), saveSource(), saveTarget(), and showItemSelection().
ilObjectCopyGUI::getSubMode | ( | ) |
Definition at line 566 of file class.ilObjectCopyGUI.php.
References $sub_mode.
Referenced by copyContainer(), copyMultipleNonContainer(), init(), saveSource(), and setTabs().
ilObjectCopyGUI::getTargets | ( | ) |
Get copy target.
Definition at line 665 of file class.ilObjectCopyGUI.php.
References $targets, and array.
Referenced by copyContainerToTargets(), copyMultipleNonContainer(), getFirstTarget(), init(), initSourceSelection(), saveSource(), saveTarget(), and showItemSelection().
ilObjectCopyGUI::getType | ( | ) |
Returns $type.
Definition at line 585 of file class.ilObjectCopyGUI.php.
References $type.
Referenced by copyContainer(), init(), initFormSearch(), searchSource(), showItemSelection(), and sourceExists().
|
protected |
Init return, mode.
Definition at line 98 of file class.ilObjectCopyGUI.php.
References $_GET, $GLOBALS, $ilCtrl, ilObject\_lookupObjId(), ilObject\_lookupType(), array, getFirstSource(), getFirstTarget(), ilLoggerFactory\getLogger(), getParentObject(), getSource(), getSources(), getSubMode(), getTargets(), getType(), setMode(), setSource(), setSubMode(), setTarget(), setTargets(), and setType().
Referenced by executeCommand().
|
protected |
Init search form.
Definition at line 1222 of file class.ilObjectCopyGUI.php.
References $ilCtrl, $lng, getType(), and ilTextInputGUI\setSize().
Referenced by searchSource(), and showSourceSearch().
|
protected |
Init source selection.
Definition at line 278 of file class.ilObjectCopyGUI.php.
References $_SESSION, $ilCtrl, $path, array, getTargets(), setTabs(), and showSourceSelectionTree().
Referenced by adoptContent().
|
protected |
Init tabs General.
Definition at line 176 of file class.ilObjectCopyGUI.php.
References $GLOBALS.
Referenced by executeCommand().
|
protected |
Init copy from repository/search list commands.
Definition at line 238 of file class.ilObjectCopyGUI.php.
References $_SESSION, $ilCtrl, $path, array, getSource(), setTargets(), and showTargetSelectionTree().
ilObjectCopyGUI::keepObjectsInClipboard | ( | ) |
Keep objects in clipboard.
Definition at line 698 of file class.ilObjectCopyGUI.php.
References $_SESSION, $ilCtrl, and getSource().
|
protected |
select source object
Definition at line 773 of file class.ilObjectCopyGUI.php.
References $_POST, $GLOBALS, $target_type, ilObject\_lookupType(), array, copySingleObject(), ilObjectFactory\getClassByType(), getSources(), getSubMode(), getTargets(), searchSource(), ilUtil\sendFailure(), setSource(), setType(), and showItemSelection().
|
protected |
Save selected source from membership screen.
Definition at line 842 of file class.ilObjectCopyGUI.php.
References $GLOBALS, ilObject\_lookupType(), array, copySingleObject(), getFirstSource(), ilUtil\sendFailure(), setSource(), setType(), and showItemSelection().
|
protected |
Save target selection.
Definition at line 451 of file class.ilObjectCopyGUI.php.
References $GLOBALS, $ilCtrl, $target_type, ilObject\_lookupObjId(), ilObject\_lookupTitle(), ilObject\_lookupType(), array, copyMultipleNonContainer(), copySingleObject(), ilObjectFactory\getClassByType(), getFirstSource(), getSource(), getSources(), getTargets(), ilUtil\sendFailure(), setTarget(), setTargets(), showItemSelection(), and showTargetSelectionTree().
|
protected |
Search source.
Definition at line 711 of file class.ilObjectCopyGUI.php.
References $_POST, $_SESSION, $GLOBALS, $ilCtrl, $lng, $res, $results, $tpl, array, getFirstSource(), getType(), initFormSearch(), QP_COMBINATION_AND, ilUtil\sendFailure(), ilUtil\sendInfo(), and ilQueryParser\setMinWordLength().
Referenced by saveSource(), and showItemSelection().
ilObjectCopyGUI::setMode | ( | $a_mode | ) |
set copy mode
int | $a_mode |
Definition at line 547 of file class.ilObjectCopyGUI.php.
Referenced by adoptContent(), and init().
ilObjectCopyGUI::setSource | ( | array | $a_source_ids | ) |
Set source id.
array | $a_source_id |
Definition at line 606 of file class.ilObjectCopyGUI.php.
Referenced by init(), saveSource(), saveSourceMembership(), and unsetSession().
ilObjectCopyGUI::setSubMode | ( | $a_mode | ) |
Definition at line 561 of file class.ilObjectCopyGUI.php.
Referenced by adoptContent(), and init().
|
protected |
Set tabs.
type | $a_tab_group | |
type | $a_active_tab |
Definition at line 191 of file class.ilObjectCopyGUI.php.
References $GLOBALS, getMode(), and getSubMode().
Referenced by initSourceSelection(), and showSourceSelectionMembership().
ilObjectCopyGUI::setTarget | ( | $a_ref_id | ) |
Set single object target.
type | $a_ref_id |
Definition at line 645 of file class.ilObjectCopyGUI.php.
References array, and setTargets().
Referenced by adoptContent(), init(), and saveTarget().
ilObjectCopyGUI::setTargets | ( | array | $a_target | ) |
Set target id.
int | $a_target |
Definition at line 656 of file class.ilObjectCopyGUI.php.
Referenced by init(), initTargetSelection(), saveTarget(), and setTarget().
ilObjectCopyGUI::setType | ( | $type | ) |
Sets $type.
object | $type |
Definition at line 596 of file class.ilObjectCopyGUI.php.
References $type.
Referenced by init(), saveSource(), and saveSourceMembership().
|
protected |
Show progress for copying.
Definition at line 1081 of file class.ilObjectCopyGUI.php.
References $_GET, and $GLOBALS.
Referenced by copyContainerToTargets().
|
protected |
Definition at line 871 of file class.ilObjectCopyGUI.php.
References $tpl, getFirstSource(), ilLoggerFactory\getLogger(), getMode(), getSource(), getSources(), getTargets(), getType(), searchSource(), ilUtil\sendFailure(), and ilUtil\sendInfo().
Referenced by saveSource(), saveSourceMembership(), and saveTarget().
ilObjectCopyGUI::showSourceSearch | ( | $a_tplvar | ) |
Show init screen Normally shown below the create and import form when creating a new object.
string | $a_tplvar | The tpl variable to fill |
Definition at line 1183 of file class.ilObjectCopyGUI.php.
References $tpl, initFormSearch(), and unsetSession().
|
protected |
show target selection membership
Definition at line 313 of file class.ilObjectCopyGUI.php.
References $GLOBALS, ilParticipants\_getMembershipByType(), ilUtil\sendInfo(), and setTabs().
ilObjectCopyGUI::showSourceSelectionTree | ( | ) |
Show target selection.
Definition at line 394 of file class.ilObjectCopyGUI.php.
References $_GET, $ilCtrl, $output, $tpl, array, getSource(), ilPasteIntoMultipleItemsExplorer\SEL_TYPE_RADIO, and ilUtil\sendInfo().
Referenced by initSourceSelection().
ilObjectCopyGUI::showTargetSelectionTree | ( | ) |
Show target selection.
Definition at line 336 of file class.ilObjectCopyGUI.php.
References $ilCtrl, $lng, $output, $t, $tpl, array, ilUtil\getImagePath(), and ilUtil\sendInfo().
Referenced by initTargetSelection(), and saveTarget().
|
protected |
Check if there is any source object.
Definition at line 1211 of file class.ilObjectCopyGUI.php.
References $ilUser, ilUtil\_getObjectsByOperations(), and getType().
|
protected |
Unset session variables.
Definition at line 1251 of file class.ilObjectCopyGUI.php.
References $_SESSION, array, and setSource().
Referenced by showSourceSearch().
|
protected |
Update progress.
Definition at line 1100 of file class.ilObjectCopyGUI.php.
References $options, ilCopyWizardOptions\_getInstance(), exit, and ilLoggerFactory\getLogger().
|
private |
Definition at line 36 of file class.ilObjectCopyGUI.php.
Referenced by __construct(), initFormSearch(), searchSource(), and showTargetSelectionTree().
|
private |
Definition at line 52 of file class.ilObjectCopyGUI.php.
|
private |
Definition at line 33 of file class.ilObjectCopyGUI.php.
Referenced by getMode().
|
private |
Definition at line 38 of file class.ilObjectCopyGUI.php.
Referenced by getParentObject().
|
private |
Definition at line 42 of file class.ilObjectCopyGUI.php.
Referenced by getSources().
|
private |
Definition at line 34 of file class.ilObjectCopyGUI.php.
Referenced by getSubMode().
|
private |
Definition at line 45 of file class.ilObjectCopyGUI.php.
Referenced by getFirstTarget(), and getTargets().
|
private |
Definition at line 46 of file class.ilObjectCopyGUI.php.
|
private |
Definition at line 40 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::SEARCH_SOURCE = 3 |
Definition at line 19 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::SOURCE_SELECTION = 1 |
Definition at line 17 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::SUBMODE_COMPLETE = 1 |
Definition at line 21 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::SUBMODE_CONTENT_ONLY = 2 |
Definition at line 22 of file class.ilObjectCopyGUI.php.
Referenced by ilContainer\cloneAllObject().
const ilObjectCopyGUI::TAB_GROUP_SC_SELECTION = 1 |
Definition at line 30 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::TAB_SELECTION_MEMBERSHIP = 3 |
Definition at line 27 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::TAB_SELECTION_SOURCE_TREE = 2 |
Definition at line 26 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::TAB_SELECTION_TARGET_TREE = 1 |
Definition at line 25 of file class.ilObjectCopyGUI.php.
const ilObjectCopyGUI::TARGET_SELECTION = 2 |
Definition at line 18 of file class.ilObjectCopyGUI.php.