Version 3.2.3
This commit is contained in:
1 parent
ae5c01cc78
commit
78706903a2
2641 files changed
+228363
-201264
No files matched your search
@@ -1,20 +1,14 @@
|
||||
<?php
|
||||
/**
|
||||
* <pre>
|
||||
* Invision Power Services
|
||||
* IP.Board v3.1.4
|
||||
* Task: Send the weekly digest emails
|
||||
* Last Updated: $LastChangedDate: 2010-10-20 09:03:17 -0400 (Wed, 20 Oct 2010) $
|
||||
* </pre>
|
||||
*
|
||||
* @author $Author: ips_terabyte $
|
||||
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
|
||||
* @license http://www.invisionpower.com/community/board/license.html
|
||||
* @package IP.Board
|
||||
* @subpackage Forums
|
||||
* @link http://www.invisionpower.com
|
||||
* @since 27th January 2004
|
||||
* @version $Rev: 7003 $
|
||||
* @file weeklydigest.php Task to send out the weekly digest emails
|
||||
*~TERABYTE_DOC_READY~
|
||||
* $Copyright: (c) 2001 - 2011 Invision Power Services, Inc.$
|
||||
* $License: This is NULLED!
|
||||
* $Author: bfarber $
|
||||
* @since -
|
||||
* $LastChangedDate: 2011-08-05 20:51:01 -0400 (Fri, 05 Aug 2011) $
|
||||
* @version v3.2.3
|
||||
* $Revision: 9373 $
|
||||
*/
|
||||
|
||||
if ( ! defined( 'IN_IPB' ) )
|
||||
@@ -23,65 +17,51 @@ if ( ! defined( 'IN_IPB' ) )
|
||||
exit();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @class task_item
|
||||
* @brief Task to send out the weekly digest emails
|
||||
*
|
||||
*/
|
||||
class task_item
|
||||
{
|
||||
/**
|
||||
* Parent task manager class
|
||||
* Object that stores the parent task manager class
|
||||
*
|
||||
* @var object
|
||||
* @var $class
|
||||
*/
|
||||
protected $class;
|
||||
|
||||
|
||||
/**
|
||||
* This task data
|
||||
* Array that stores the task data
|
||||
*
|
||||
* @var array
|
||||
* @var $task
|
||||
*/
|
||||
protected $task = array();
|
||||
|
||||
/**
|
||||
* Prevent logging
|
||||
*
|
||||
* @var boolean
|
||||
*/
|
||||
protected $restrict_log = false;
|
||||
protected $task = array();
|
||||
|
||||
/**
|
||||
* Registry Object Shortcuts
|
||||
*
|
||||
* @var object
|
||||
*
|
||||
* @var $registry
|
||||
* @var $lang
|
||||
*/
|
||||
protected $registry;
|
||||
protected $DB;
|
||||
protected $settings;
|
||||
protected $request;
|
||||
protected $lang;
|
||||
protected $member;
|
||||
protected $memberData;
|
||||
protected $cache;
|
||||
protected $caches;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param object ipsRegistry reference
|
||||
* @param object Parent task class
|
||||
* @param array This task data
|
||||
* @return void
|
||||
* @param object $registry Registry object
|
||||
* @param object $class Task manager class object
|
||||
* @param array $task Array with the task data
|
||||
* @return @e void
|
||||
*/
|
||||
public function __construct( ipsRegistry $registry, $class, $task )
|
||||
{
|
||||
/* Make registry objects */
|
||||
$this->registry = $registry;
|
||||
$this->DB = $this->registry->DB();
|
||||
$this->settings =& $this->registry->fetchSettings();
|
||||
$this->request =& $this->registry->fetchRequest();
|
||||
$this->lang = $this->registry->getClass('class_localization');
|
||||
$this->member = $this->registry->member();
|
||||
$this->memberData =& $this->registry->member()->fetchMemberData();
|
||||
$this->cache = $this->registry->cache();
|
||||
$this->caches =& $this->registry->cache()->fetchCaches();
|
||||
|
||||
|
||||
$this->class = $class;
|
||||
$this->task = $task;
|
||||
}
|
||||
@@ -89,7 +69,7 @@ class task_item
|
||||
/**
|
||||
* Run this task
|
||||
*
|
||||
* @return void
|
||||
* @return @e void
|
||||
*/
|
||||
public function runTask()
|
||||
{
|
||||
@@ -101,13 +81,10 @@ class task_item
|
||||
|
||||
$classToLoad = IPSLib::loadLibrary( IPSLib::getAppDir( 'forums' ) . '/sources/classes/digest.php', 'digestLibrary', 'forums' );
|
||||
$digest = new $classToLoad( $this->registry );
|
||||
$digest->digest_time = 'weekly';
|
||||
$digest->digest_type = 'topic';
|
||||
$digest->runDigest();
|
||||
|
||||
$digest->digest_time = 'weekly';
|
||||
$digest->digest_type = 'forum';
|
||||
$digest->runDigest();
|
||||
$digest->runDigest( 'weekly', 'topic' );
|
||||
|
||||
$digest->runDigest( 'weekly', 'forum' );
|
||||
|
||||
//-----------------------------------------
|
||||
// Log to log table - modify but dont delete
|
||||
|
||||
Reference in new issue
Block a user