TYPO3  7.6
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
SchedulerModuleController Class Reference
Inheritance diagram for SchedulerModuleController:
BaseScriptClass

Public Member Functions

 __construct ()
 
 init ()
 
 menuConfig ()
 
 main ()
 
 mainAction (ServerRequestInterface $request, ResponseInterface $response)
 
 render ()
 
 checkDate ($string)
 
 addMessage ($message, $severity=FlashMessage::OK)
 
- Public Member Functions inherited from BaseScriptClass
 init ()
 
 menuConfig ()
 
 mergeExternalItems ($modName, $menuKey, $menuArr)
 
 handleExternalFunctionValue ($MM_key= 'function', $MS_value=null)
 
 getExternalItemConfig ($modName, $menuKey, $value= '')
 
 checkExtObj ()
 
 checkSubExtObj ()
 
 extObjHeader ()
 
 extObjContent ()
 

Protected Member Functions

 getModuleMenu ()
 
 getModuleContent ()
 
 checkSchedulerUser ()
 
 infoScreenAction ()
 
 renderTaskProgressBar ($progress)
 
 deleteTask ()
 
 stopTask ()
 
 toggleDisableAction ()
 
 executeTasks ()
 
 makeStatusLabel (array $labels)
 
 getRegisteredClasses ()
 
 getRegisteredTaskGroups ()
 
 getTemplateMarkers ()
 
 getButtons ()
 
 getBackendUser ()
 
 getDatabaseConnection ()
 
- Protected Member Functions inherited from BaseScriptClass
 getLanguageService ()
 
 getBackendUser ()
 
 getDatabaseConnection ()
 
 getPageRenderer ()
 

Protected Attributes

 $submittedData = array()
 
 $messages = array()
 
 $cshKey
 
 $scheduler
 
 $backendTemplatePath = ''
 
 $view
 
 $moduleName = 'system_txschedulerM1'
 
 $moduleUri
 
 $moduleTemplate
 
- Protected Attributes inherited from BaseScriptClass
 $pageRenderer = null
 

Additional Inherited Members

- Public Attributes inherited from BaseScriptClass
 $MCONF = array()
 
 $id
 
 $CMD
 
 $perms_clause
 
 $MOD_MENU
 
 $MOD_SETTINGS = array()
 
 $modTSconfig
 
 $modMenu_type = ''
 
 $modMenu_dontValidateList = ''
 
 $modMenu_setDefaultList = ''
 
 $extClassConf
 
 $content = ''
 
 $doc
 
 $extObj
 

Detailed Description

Module 'TYPO3 Scheduler administration module' for the 'scheduler' extension.

Definition at line 37 of file SchedulerModuleController.php.

Constructor & Destructor Documentation

__construct ( )

Member Function Documentation

addMessage (   $message,
  $severity = FlashMessage::OK 
)
checkDate (   $string)

This method checks whether the given string can be considered a valid date or not Allowed values are anything that matches natural language (see PHP function strtotime()) or TYPO3's date syntax: HH:ii yyyy-mm-dd If the string is a valid date, the corresponding timestamp is returned. Otherwise an exception is thrown

Parameters
string$stringString to check
Returns
int Unix timestamp
Exceptions
\InvalidArgumentException
Deprecated:
since TYPO3 CMS 7, will be removed in CMS 8, as the unified datetime picker with a separate timestamp field is used.

Definition at line 1445 of file SchedulerModuleController.php.

References GeneralUtility\logDeprecatedFunction(), and GeneralUtility\trimExplode().

checkSchedulerUser ( )
protected

This method checks the status of the '_cli_scheduler' user It will differentiate between a non-existing user and an existing, but disabled user (as per enable fields)

Returns
int -1 If user doesn't exist, 0 If user exist but not enabled, 1 If user exists and is enabled

Definition at line 337 of file SchedulerModuleController.php.

References BackendUtility\BEenableFields(), BackendUtility\deleteClause(), and SchedulerModuleController\getDatabaseConnection().

deleteTask ( )
protected
executeTasks ( )
protected
getBackendUser ( )
protected

Returns the global BackendUserAuthentication object.

Returns

Definition at line 1648 of file SchedulerModuleController.php.

References $GLOBALS.

Referenced by SchedulerModuleController\deleteTask(), and SchedulerModuleController\main().

getButtons ( )
protected
getDatabaseConnection ( )
protected

Returns the database connection

Returns
DatabaseConnection

Definition at line 1658 of file SchedulerModuleController.php.

References $GLOBALS.

Referenced by SchedulerModuleController\checkSchedulerUser(), SchedulerModuleController\deleteTask(), and SchedulerModuleController\getRegisteredTaskGroups().

getModuleContent ( )
protected
getModuleMenu ( )
protected

Generates the action menu

Definition at line 173 of file SchedulerModuleController.php.

Referenced by SchedulerModuleController\main().

getRegisteredClasses ( )
protected

This method fetches a list of all classes that have been registered with the Scheduler For each item the following information is provided, as an associative array:

['extension'] => Key of the extension which provides the class ['filename'] => Path to the file containing the class ['title'] => String (possibly localized) containing a human-readable name for the class ['provider'] => Name of class that implements the interface for additional fields, if necessary

The name of the class itself is used as the key of the list array

Returns
array List of registered classes

Definition at line 1501 of file SchedulerModuleController.php.

References $GLOBALS, $list, and BaseScriptClass\getLanguageService().

Referenced by SchedulerModuleController\executeTasks(), SchedulerModuleController\getButtons(), and SchedulerModuleController\infoScreenAction().

getRegisteredTaskGroups ( )
protected

This method fetches list of all group that have been registered with the Scheduler

Returns
array List of registered groups

Definition at line 1524 of file SchedulerModuleController.php.

References $list, BackendUtility\BEenableFields(), BackendUtility\deleteClause(), and SchedulerModuleController\getDatabaseConnection().

getTemplateMarkers ( )
protected

Gets the filled markers that are used in the HTML template.

Returns
array The filled marker array

Definition at line 1557 of file SchedulerModuleController.php.

References BaseScriptClass\getLanguageService().

infoScreenAction ( )
protected

This method gathers information about all available task classes and displays it

Returns
string html

Definition at line 485 of file SchedulerModuleController.php.

References SchedulerModuleController\getRegisteredClasses().

Referenced by SchedulerModuleController\getModuleContent().

init ( )

Initializes the backend module

Returns
void

Definition at line 119 of file SchedulerModuleController.php.

References GeneralUtility\makeInstance().

Referenced by SchedulerModuleController\mainAction().

main ( )
mainAction ( ServerRequestInterface  $request,
ResponseInterface  $response 
)

Injects the request object for the current request or subrequest Simply calls main() and init() and outputs the content

Parameters
ServerRequestInterface$requestthe current request
ResponseInterface$response
Returns
ResponseInterface the response with the content

Definition at line 307 of file SchedulerModuleController.php.

References $GLOBALS, $response, MessageInterface\getBody(), SchedulerModuleController\init(), and SchedulerModuleController\main().

makeStatusLabel ( array  $labels)
protected

Generates bootstrap labels containing the label statuses

Parameters
array$labels
Returns
string

Definition at line 1230 of file SchedulerModuleController.php.

menuConfig ( )

Adds items to the ->MOD_MENU array. Used for the function menu selector.

Returns
void

Definition at line 132 of file SchedulerModuleController.php.

References BaseScriptClass\getLanguageService().

render ( )

This method actually prints out the module's HTML content

Returns
void
Deprecated:
since TYPO3 CMS 7, will be removed in TYPO3 CMS 8

Definition at line 324 of file SchedulerModuleController.php.

References BaseScriptClass\$content, and GeneralUtility\logDeprecatedFunction().

renderTaskProgressBar (   $progress)
protected

Renders the task progress bar.

Parameters
float$progressTask progress
Returns
string Progress bar markup

Definition at line 506 of file SchedulerModuleController.php.

References BaseScriptClass\getLanguageService().

stopTask ( )
protected

Clears the registered running executions from the task Note that this doesn't actually stop the running script. It just unmarks all executions.

Todo:
find a way to really kill the running task
Returns
void

Definition at line 557 of file SchedulerModuleController.php.

References SchedulerModuleController\addMessage(), AbstractMessage\ERROR, BaseScriptClass\getLanguageService(), and AbstractMessage\WARNING.

Referenced by SchedulerModuleController\getModuleContent().

toggleDisableAction ( )
protected

Toggles the disabled state of the submitted task

Returns
void

Definition at line 585 of file SchedulerModuleController.php.

Referenced by SchedulerModuleController\getModuleContent().

Member Data Documentation

$backendTemplatePath = ''
protected

Definition at line 67 of file SchedulerModuleController.php.

$cshKey
protected

Definition at line 57 of file SchedulerModuleController.php.

$messages = array()
protected

Definition at line 52 of file SchedulerModuleController.php.

$moduleName = 'system_txschedulerM1'
protected

Definition at line 79 of file SchedulerModuleController.php.

Referenced by SchedulerModuleController\__construct().

$moduleTemplate
protected

Definition at line 91 of file SchedulerModuleController.php.

$moduleUri
protected

Definition at line 84 of file SchedulerModuleController.php.

$scheduler
protected

Definition at line 62 of file SchedulerModuleController.php.

$submittedData = array()
protected

Definition at line 44 of file SchedulerModuleController.php.

$view
protected

Definition at line 72 of file SchedulerModuleController.php.