Skip to content

Commit

Permalink
[BUGFIX] configuration fetching for admin edit notify mails
Browse files Browse the repository at this point in the history
Merge pull request #614 from in2code-de/fix/admin-edit-notify
  • Loading branch information
sbusemann authored Nov 11, 2024
2 parents e28ff04 + 370b0a0 commit 370a8c6
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 36 deletions.
65 changes: 33 additions & 32 deletions .FemanagerFeaturesList.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,41 +3,42 @@
## Funktionen

### Frontend-User Registration
| Feature | State in TYPO3v12 |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------|
| One step registration with autologin | not working |
| Main configuration with Flexform | working |
| User confirmation (Double-Opt In) (optional) | working |
| Administration confirmation (optional) | working |
| Refuse and Silent Refuse | working |
| Fill email field with username (optional) | working |
| Redirect with TypoScript standardWrap (optional) | working |
| Prefill Formfields via TypoScript standardWrap (optional) | working |
| Multiple Validation Possibilities (JavaScript and PHP) (required, email, min, max, intOnly, lettersOnly, unicodeLettersOnly, uniqueInPage, uniqueInDb, mustInclude(number,letter,special), inList(1,2,3)) | working |
| Same PHP Methods for JavaScript and PHP Validation | working |
| Simply extend validation methods with your extension | working |
| Override a lot of Email settings with TypoScript if needed | working |
| Set mail attachments or embeded images | working |
| Override field values on every single step (e.g. push user to usergroup1 and if he is ready confimed push him to usergroup2) | working |
| Send user values to a third party software (e.g. a CRM like salesforce) | working |
| Store values in other database tables (e.g. tt_address) | working |
| Add Captcha (sr_freecap) for spam prevention | cannot be tested at the moment |
| Feature | State in TYPO3v12 |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------|
| One step registration with autologin | working |
| Main configuration with Flexform | working |
| User confirmation (Double-Opt In) (optional) | working |
| Administration confirmation (optional) | working |
| Refuse and Silent Refuse | working |
| Fill email field with username (optional) | working |
| Redirect with TypoScript standardWrap (optional) | working |
| Prefill Formfields via TypoScript standardWrap (optional) | working |
| Multiple Validation Possibilities (JavaScript and PHP) (required, email, min, max, intOnly, lettersOnly, unicodeLettersOnly, uniqueInPage, uniqueInDb, mustInclude(number,letter,special), inList(1,2,3)) | working |
| Same PHP Methods for JavaScript and PHP Validation | working |
| Simply extend validation methods with your extension | working |
| Override a lot of Email settings with TypoScript if needed | working |
| Set mail attachments or embeded images | working |
| Override field values on every single step (e.g. push user to usergroup1 and if he is ready confimed push him to usergroup2) | working |
| Send user values to a third party software (e.g. a CRM like salesforce) | working |
| Store values in other database tables (e.g. tt_address) | working |
| Add Captcha (sr_freecap) for spam prevention | not tested |

### Edit Profile

| Feature | State in TYPO3v12 |
|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------|
| Main configuration with Flexform | worming |
| Administration confirmation for change request (optional) | working |
| Refuse and Silent Refuse | working |
| Fill email field with username (optional) | working |
| Prefill Formfields via TypoScript standardWrap (optional) | working |
| Multiple Validation Possibilities (JavaScript and PHP) (required, email, min, max, intOnly, lettersOnly, unicodeLettersOnly, uniqueInPage, uniqueInDb, mustInclude(number,letter,special), inList(1,2,3)) | working |
| Same PHP Methods for JavaScript and PHP Validation | working |
| Simply extend validation methods with your extension | working |
| Override a lot of Email settings with TypoScript if needed | working |
| Set mail attachments or embeded images | working |
| Delete profile with TypoScript redirect | working |
| Feature | State in TYPO3v12 | Testcase URL |
|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------|------------------------------------------------------|
| Main configuration with Flexform | worming | |
| Administration confirmation for change request (optional) | working | |
| Refuse and Silent Refuse | working | |
| Fill email field with username (optional) | working | |
| Prefill Formfields via TypoScript standardWrap (optional) | working | |
| Multiple Validation Possibilities (JavaScript and PHP) (required, email, min, max, intOnly, lettersOnly, unicodeLettersOnly, uniqueInPage, uniqueInDb, mustInclude(number,letter,special), inList(1,2,3)) | working | |
| Same PHP Methods for JavaScript and PHP Validation | working | |
| Simply extend validation methods with your extension | working | |
| Override a lot of Email settings with TypoScript if needed | working | |
| Set mail attachments or embeded images | working | |
| Delete profile with TypoScript redirect | working | |
| Notify Admin on changes | working | https://femanager8.ddev.site/edit/small/admin-notify |

### Invitation

Expand Down
4 changes: 2 additions & 2 deletions Classes/Controller/AbstractController.php
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,9 @@ public function updateAllConfirmed(User $user)
'updateNotify',
StringUtility::makeEmailArray(
ConfigurationUtility::getValue(
'edit/email/createUserNotify/notifyAdmin/receiver/email/value',
'edit./email./notifyAdmin./receiver./email./value',
$this->config
) ?: ConfigurationUtility::getValue('edit/notifyAdmin', $this->config),
) ?: ConfigurationUtility::getValue('edit./notifyAdmin', $this->config),
$this->settings['edit']['email']['notifyAdmin']['receiver']['name']['value'] ?? null
),
StringUtility::makeEmailArray($user->getEmail(), $user->getUsername()),
Expand Down
4 changes: 2 additions & 2 deletions Classes/Utility/ConfigurationUtility.php
Original file line number Diff line number Diff line change
Expand Up @@ -192,10 +192,10 @@ public static function getValue($key, $config)
public static function notifyAdminAboutEdits($config)
{
if (self::getValue(
'edit/notifyAdmin',
'edit/email/notifyAdmin',
$config
) || self::getValue(
'edit/email/createUserNotify/notifyAdmin/receiver/email/value',
'edit/email/notifyAdmin/receiver/email/value',
$config
)) {
return true;
Expand Down

0 comments on commit 370a8c6

Please sign in to comment.