Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
S
sg_mail
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TYPO3
sg_mail
Commits
2081985b
Commit
2081985b
authored
7 years ago
by
Torsten Oppermann
Browse files
Options
Downloads
Patches
Plain Diff
[TASK] Fixing a language bug with backend filters and default language when sending
parent
e641090c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!3
New version 4 1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Classes/Service/BackendService.php
+3
-2
3 additions, 2 deletions
Classes/Service/BackendService.php
Classes/Service/MailTemplateService.php
+2
-2
2 additions, 2 deletions
Classes/Service/MailTemplateService.php
with
5 additions
and
4 deletions
Classes/Service/BackendService.php
+
3
−
2
View file @
2081985b
...
...
@@ -183,9 +183,9 @@ class BackendService {
$languages
=
[];
// adding default language
$languages
[]
=
[
'isocode'
=>
LocalizationUtility
::
translate
(
$languages
[]
=
[
'isocode'
=>
MailTemplateService
::
DEFAULT_LANGUAGE
,
'name'
=>
LocalizationUtility
::
translate
(
'backend.language_default'
,
'SgMail'
),
'name'
=>
LocalizationUtility
::
translate
(
'backend.language_default'
,
'SgMail'
)];
)];
foreach
(
$rows
as
$language
)
{
$languages
[]
=
[
'isocode'
=>
$language
[
'language_isocode'
],
...
...
@@ -220,6 +220,7 @@ class BackendService {
*/
public
static
function
getLanguagesForFilter
()
{
$languages
=
self
::
getLanguages
();
array_unshift
(
$languages
,
[
'isocode'
=>
''
,
'name'
=>
''
]);
$filterLanguages
=
[];
if
(
count
(
$languages
)
>
0
)
{
...
...
This diff is collapsed.
Click to expand it.
Classes/Service/MailTemplateService.php
+
2
−
2
View file @
2081985b
...
...
@@ -48,6 +48,7 @@ class MailTemplateService {
const
MARKER_TYPE_STRING
=
'String'
;
const
MARKER_TYPE_ARRAY
=
'Array'
;
const
MARKER_TYPE_OBJECT
=
'Object'
;
const
DEFAULT_LANGUAGE
=
'default'
;
/**
* @var array $registerArray
...
...
@@ -304,7 +305,6 @@ class MailTemplateService {
* @throws \TYPO3\CMS\Extbase\Persistence\Exception\IllegalObjectTypeException
*/
public
function
sendEmail
(
$isPreview
=
FALSE
)
{
if
(
TYPO3_MODE
===
'FE'
)
{
/** @var TypoScriptFrontendController $tsfe */
$tsfe
=
$GLOBALS
[
'TSFE'
];
...
...
@@ -438,7 +438,7 @@ class MailTemplateService {
*/
private
function
addMailToMailQueue
(
$extensionKey
,
$templateName
,
$subject
,
$emailBody
,
$priority
,
$sendingTime
=
0
,
$lastSendingTime
=
0
,
$language
=
'en'
,
$pid
=
0
$lastSendingTime
=
0
,
$language
=
self
::
DEFAULT_LANGUAGE
,
$pid
=
0
)
{
$mail
=
$this
->
objectManager
->
get
(
Mail
::
class
);
$mail
->
setPid
(
$pid
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment