diff --git a/Classes/Domain/Service/SendMailService.php b/Classes/Domain/Service/SendMailService.php index 05fbb88..29a7966 100644 --- a/Classes/Domain/Service/SendMailService.php +++ b/Classes/Domain/Service/SendMailService.php @@ -1,7 +1,6 @@ setTo( - array( + [ 'anotheremail@domain.org' => 'receiverName' - ) + ] ); } } diff --git a/Classes/Domain/Validator/ZipValidator.php b/Classes/Domain/Validator/ZipValidator.php index 21dfa9b..4b04f45 100755 --- a/Classes/Domain/Validator/ZipValidator.php +++ b/Classes/Domain/Validator/ZipValidator.php @@ -11,11 +11,11 @@ class ZipValidator * Check if given number is higher than in configuration * * @param string $value - * @param string $validationConfiguration + * @param string $validationConfig * @return bool */ - public function validate100($value, $validationConfiguration) + public function validate100($value, $validationConfig) { - return is_numeric($value) && $value >= $validationConfiguration; + return is_numeric($value) && $value >= $validationConfig; } } diff --git a/ext_emconf.php b/ext_emconf.php index 3b6198a..ad7480f 100755 --- a/ext_emconf.php +++ b/ext_emconf.php @@ -10,35 +10,36 @@ * writing. "version" and "dependencies" must not be touched! ***************************************************************/ -$EM_CONF[$_EXTKEY] = array ( - 'title' => 'powermailextended', - 'description' => 'Sample Extension to extend powermail: Add new validators, Add new Fieldtypes or Add new Field Properties', - 'category' => 'plugin', - 'shy' => 0, - 'version' => '3.0.0', - 'dependencies' => '', - 'conflicts' => '', - 'priority' => '', - 'loadOrder' => '', - 'module' => '', - 'state' => 'beta', - 'uploadfolder' => 0, - 'createDirs' => 'uploads/tx_powermail', - 'modify_tables' => '', - 'clearcacheonload' => 0, - 'lockType' => '', - 'author' => 'Powermail dev team', - 'author_email' => 'alexander.kellner@in2code.de', - 'author_company' => 'in2code.de', - 'CGLcompliance' => '', - 'CGLcompliance_note' => '', - 'constraints' => array( - 'depends' => array( - 'typo3' => '7.6.0-8.99.99', - 'powermail' => '3.0.0-3.99.99', - ), - 'conflicts' => array(), - 'suggests' => array(), - ), - '_md5_values_when_last_written' => '', -); +$EM_CONF[$_EXTKEY] = [ + 'title' => 'powermailextended', + 'description' => 'Sample Extension to extend powermail: + Add new validators, Add new Fieldtypes or Add new Field Properties', + 'category' => 'plugin', + 'shy' => 0, + 'version' => '3.0.0', + 'dependencies' => '', + 'conflicts' => '', + 'priority' => '', + 'loadOrder' => '', + 'module' => '', + 'state' => 'beta', + 'uploadfolder' => 0, + 'createDirs' => 'uploads/tx_powermail', + 'modify_tables' => '', + 'clearcacheonload' => 0, + 'lockType' => '', + 'author' => 'Powermail dev team', + 'author_email' => 'alexander.kellner@in2code.de', + 'author_company' => 'in2code.de', + 'CGLcompliance' => '', + 'CGLcompliance_note' => '', + 'constraints' => [ + 'depends' => [ + 'typo3' => '7.6.0-8.99.99', + 'powermail' => '3.0.0-3.99.99', + ], + 'conflicts' => [], + 'suggests' => [], + ], + '_md5_values_when_last_written' => '', +]; diff --git a/ext_localconf.php b/ext_localconf.php index 9574015..4cb173a 100755 --- a/ext_localconf.php +++ b/ext_localconf.php @@ -3,22 +3,24 @@ * Register some Slots */ /** @var \TYPO3\CMS\Extbase\SignalSlot\Dispatcher $signalSlotDispatcher */ -$signalSlotDispatcher = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Extbase\\SignalSlot\Dispatcher'); +$signalSlotDispatcher = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance( + \TYPO3\CMS\Extbase\SignalSlot\Dispatcher::class +); // Manipulate a value before sending //$signalSlotDispatcher->connect( -// 'In2code\Powermail\Controller\FormController', -// 'createActionBeforeRenderView', -// 'In2code\Powermailextended\Controller\FormController', -// 'manipulateMailObjectOnCreate', -// FALSE +// 'In2code\Powermail\Controller\FormController', +// 'createActionBeforeRenderView', +// 'In2code\Powermailextended\Controller\FormController', +// 'manipulateMailObjectOnCreate', +// false //); // Change receiver mail //$signalSlotDispatcher->connect( -// 'In2code\Powermail\Domain\Service\SendMailService', -// 'sendTemplateEmailBeforeSend', -// 'In2code\Powermailextended\Domain\Service\SendMailService', -// 'manipulateMail', -// FALSE +// 'In2code\Powermail\Domain\Service\SendMailService', +// 'sendTemplateEmailBeforeSend', +// 'In2code\Powermailextended\Domain\Service\SendMailService', +// 'manipulateMail', +// false //); diff --git a/ext_tables.php b/ext_tables.php index db1d946..213b11a 100644 --- a/ext_tables.php +++ b/ext_tables.php @@ -3,39 +3,36 @@ * Include Static TypoScript */ \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addStaticFile( - $_EXTKEY, - 'Configuration/TypoScript', - 'Powermail Addition (after Powermail Template)' + $_EXTKEY, + 'Configuration/TypoScript', + 'Powermail Addition (after Powermail Template)' ); /** * extend powermail fields tx_powermail_domain_model_field */ -$tempColumns = array ( - 'tx_powermailextended_powermail_text' => array( - 'exclude' => 1, - 'label' => 'Text before field', - 'config' => array ( - 'type' => 'text', - 'cols' => '32', - 'rows' => '2' - ) - ), - 'tx_powermailextended_powermail_readonly' => array( - 'exclude' => 1, - 'label' => 'Readonly', - 'config' => array ( - 'type' => 'check' - ) - ), -); -\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTCAcolumns( - 'tx_powermail_domain_model_field', - $tempColumns -); +$tempColumns = [ + 'tx_powermailextended_powermail_text' => [ + 'exclude' => 1, + 'label' => 'Text before field', + 'config' => [ + 'type' => 'text', + 'cols' => '32', + 'rows' => '2' + ] + ], + 'tx_powermailextended_powermail_readonly' => [ + 'exclude' => 1, + 'label' => 'Readonly', + 'config' => [ + 'type' => 'check' + ] + ], +]; +\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTCAcolumns('tx_powermail_domain_model_field', $tempColumns); \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addToAllTCAtypes( - 'tx_powermail_domain_model_field', - '--div--;Powermailextended, tx_powermailextended_powermail_text, tx_powermailextended_powermail_readonly', - '', - 'after:own_marker_select' + 'tx_powermail_domain_model_field', + '--div--;Powermailextended, tx_powermailextended_powermail_text, tx_powermailextended_powermail_readonly', + '', + 'after:own_marker_select' );