Commit 4833d8b062ae5b4d2e6b97edfc62af0bb8fda9fe
1 parent
0ec5198f
Code cleanup.
Committed by: Jarrett Jordaan Reviewed by: Megan Watson
Showing
6 changed files
with
10 additions
and
32 deletions
lib/actions/bulkaction.php
| @@ -49,9 +49,7 @@ require_once(KT_LIB_DIR . '/documentmanagement/documentutil.inc.php'); | @@ -49,9 +49,7 @@ require_once(KT_LIB_DIR . '/documentmanagement/documentutil.inc.php'); | ||
| 49 | require_once(KT_LIB_DIR . '/widgets/forms.inc.php'); | 49 | require_once(KT_LIB_DIR . '/widgets/forms.inc.php'); |
| 50 | 50 | ||
| 51 | require_once(KT_LIB_DIR . "/util/sanitize.inc"); | 51 | require_once(KT_LIB_DIR . "/util/sanitize.inc"); |
| 52 | - | ||
| 53 | -// // Jarrett Jordaan: Deal with bulk action | ||
| 54 | -require_once(KT_LIB_DIR . '/subscriptions/subscriptions.inc.php'); | 52 | +require_once(KT_LIB_DIR . '/subscriptions/subscriptions.inc.php'); // Deal with bulk action |
| 55 | 53 | ||
| 56 | class KTBulkAction extends KTStandardDispatcher { | 54 | class KTBulkAction extends KTStandardDispatcher { |
| 57 | var $sName; | 55 | var $sName; |
| @@ -603,7 +601,9 @@ class KTBulkAction extends KTStandardDispatcher { | @@ -603,7 +601,9 @@ class KTBulkAction extends KTStandardDispatcher { | ||
| 603 | 'form' => $this->form_complete())); | 601 | 'form' => $this->form_complete())); |
| 604 | } | 602 | } |
| 605 | 603 | ||
| 606 | - // Jarrett Jordaan: Deal with bulk actions | 604 | + /** |
| 605 | + * Deal with bulk actions | ||
| 606 | + */ | ||
| 607 | function do_notification($objects, $eventAction, $targetFolder) { | 607 | function do_notification($objects, $eventAction, $targetFolder) { |
| 608 | // Make sure there were documents/folders affected | 608 | // Make sure there were documents/folders affected |
| 609 | if ($targetFolder && count($objects) > 0 && $eventAction != '') { | 609 | if ($targetFolder && count($objects) > 0 && $eventAction != '') { |
lib/foldermanagement/folderutil.inc.php
| @@ -77,11 +77,8 @@ class KTFolderUtil { | @@ -77,11 +77,8 @@ class KTFolderUtil { | ||
| 77 | return $oFolder; | 77 | return $oFolder; |
| 78 | } | 78 | } |
| 79 | 79 | ||
| 80 | - /* | 80 | + /** |
| 81 | * Folder Add | 81 | * Folder Add |
| 82 | - * Author : Jarrett Jordaan | ||
| 83 | - * Modified : 28/04/09 | ||
| 84 | - * | ||
| 85 | * @params : KTDocumentUtil $oParentFolder | 82 | * @params : KTDocumentUtil $oParentFolder |
| 86 | * string $sFolderName | 83 | * string $sFolderName |
| 87 | * KTUser $oUser | 84 | * KTUser $oUser |
lib/import/bulkimport.inc.php
| @@ -40,8 +40,7 @@ | @@ -40,8 +40,7 @@ | ||
| 40 | require_once(KT_LIB_DIR . '/foldermanagement/folderutil.inc.php'); | 40 | require_once(KT_LIB_DIR . '/foldermanagement/folderutil.inc.php'); |
| 41 | require_once(KT_LIB_DIR . '/documentmanagement/documentutil.inc.php'); | 41 | require_once(KT_LIB_DIR . '/documentmanagement/documentutil.inc.php'); |
| 42 | require_once(KT_LIB_DIR . '/filelike/filelikeutil.inc.php'); | 42 | require_once(KT_LIB_DIR . '/filelike/filelikeutil.inc.php'); |
| 43 | -// // Jarrett Jordaan: Deal with bulk action | ||
| 44 | -require_once(KT_LIB_DIR . '/subscriptions/subscriptions.inc.php'); | 43 | +require_once(KT_LIB_DIR . '/subscriptions/subscriptions.inc.php'); // Deal with bulk action |
| 45 | 44 | ||
| 46 | class KTBulkImportManager { | 45 | class KTBulkImportManager { |
| 47 | var $oStorage; | 46 | var $oStorage; |
lib/subscriptions/subscriptions.inc.php
| @@ -97,11 +97,8 @@ class SubscriptionEvent { | @@ -97,11 +97,8 @@ class SubscriptionEvent { | ||
| 97 | * Every attempt is made to be as explicit as possible. | 97 | * Every attempt is made to be as explicit as possible. |
| 98 | */ | 98 | */ |
| 99 | 99 | ||
| 100 | - /* | 100 | + /** |
| 101 | * Notification of bulk upload | 101 | * Notification of bulk upload |
| 102 | - * Author : Jarrett Jordaan | ||
| 103 | - * Date : 27/04/09 | ||
| 104 | - * | ||
| 105 | * @params : KTDocumentUtil $oDocObjects | 102 | * @params : KTDocumentUtil $oDocObjects |
| 106 | * KTFolderUtil $oParentFolder | 103 | * KTFolderUtil $oParentFolder |
| 107 | */ | 104 | */ |
| @@ -115,11 +112,8 @@ class SubscriptionEvent { | @@ -115,11 +112,8 @@ class SubscriptionEvent { | ||
| 115 | } | 112 | } |
| 116 | } | 113 | } |
| 117 | 114 | ||
| 118 | - /* | 115 | + /** |
| 119 | * Bulk upload email notification handler | 116 | * Bulk upload email notification handler |
| 120 | - * Author : Jarrett Jordaan | ||
| 121 | - * Date : 27/04/09 | ||
| 122 | - * | ||
| 123 | * @params : User $aUsers | 117 | * @params : User $aUsers |
| 124 | * string $eventType | 118 | * string $eventType |
| 125 | * KTDocumentUtil $oDocObjects | 119 | * KTDocumentUtil $oDocObjects |
lib/users/User.inc
| @@ -461,10 +461,8 @@ class User extends KTEntity { | @@ -461,10 +461,8 @@ class User extends KTEntity { | ||
| 461 | return KTEntityUtil::getList2('User', $sWhereClause); | 461 | return KTEntityUtil::getList2('User', $sWhereClause); |
| 462 | } | 462 | } |
| 463 | 463 | ||
| 464 | - /* | ||
| 465 | - * Modified : Jarrett Jordaan | ||
| 466 | - * Added : Get new users | ||
| 467 | - * Date : 24/04/09 | 464 | + /** |
| 465 | + * Get new users | ||
| 468 | * | 466 | * |
| 469 | */ | 467 | */ |
| 470 | function getByLastLoginNever() { | 468 | function getByLastLoginNever() { |
| @@ -473,17 +471,9 @@ class User extends KTEntity { | @@ -473,17 +471,9 @@ class User extends KTEntity { | ||
| 473 | return KTEntityUtil::getList2('User', $sWhereClause, $aOptions); | 471 | return KTEntityUtil::getList2('User', $sWhereClause, $aOptions); |
| 474 | } | 472 | } |
| 475 | 473 | ||
| 476 | - /* | ||
| 477 | - * Modified : Jarrett Jordaan | ||
| 478 | - * Added : Filter out disabled users | ||
| 479 | - * Date : 24/04/09 | ||
| 480 | - * Added : Removed disabled users Filter | ||
| 481 | - * Date : 24/04/09 | ||
| 482 | - */ | ||
| 483 | function getByLastLoginAfter($dDateTime) { | 474 | function getByLastLoginAfter($dDateTime) { |
| 484 | return KTEntityUtil::getByDict('User', array( | 475 | return KTEntityUtil::getByDict('User', array( |
| 485 | 'last_login' => array('type' => 'after', 'value' => $dDateTime), | 476 | 'last_login' => array('type' => 'after', 'value' => $dDateTime), |
| 486 | -// 'disabled' => 0, | ||
| 487 | ), array('multi' => true)); | 477 | ), array('multi' => true)); |
| 488 | } | 478 | } |
| 489 | 479 |
lib/workflow/workflowtriggerinstance.inc.php
| @@ -72,8 +72,6 @@ class KTWorkflowTriggerInstance extends KTEntity { | @@ -72,8 +72,6 @@ class KTWorkflowTriggerInstance extends KTEntity { | ||
| 72 | function &get($iId) { return KTEntityUtil::get('KTWorkflowTriggerInstance', $iId); } | 72 | function &get($iId) { return KTEntityUtil::get('KTWorkflowTriggerInstance', $iId); } |
| 73 | 73 | ||
| 74 | function &createFromArray($aOptions) { | 74 | function &createFromArray($aOptions) { |
| 75 | - // Modified : Jarrett Jordaan | ||
| 76 | - // Removed Serialize, since the original is serialized already | ||
| 77 | $aOptions['configarraytext'] = $aOptions['config']; | 75 | $aOptions['configarraytext'] = $aOptions['config']; |
| 78 | unset($aOptions['config']); | 76 | unset($aOptions['config']); |
| 79 | return KTEntityUtil::createFromArray('KTWorkflowTriggerInstance', $aOptions); | 77 | return KTEntityUtil::createFromArray('KTWorkflowTriggerInstance', $aOptions); |