Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Stud.IP
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jan-Hendrik Willms
Stud.IP
Commits
ac2367fc
Commit
ac2367fc
authored
8 months ago
by
Rasmus Fuhse
Committed by
David Siegfried
8 months ago
Browse files
Options
Downloads
Patches
Plain Diff
Draft: Resolve "Neues-Passwort-Mail ist falsch"
Closes #4368 Merge request
studip/studip!3166
parent
c8d06fae
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
app/controllers/new_password.php
+30
-26
30 additions, 26 deletions
app/controllers/new_password.php
with
30 additions
and
26 deletions
app/controllers/new_password.php
+
30
−
26
View file @
ac2367fc
...
@@ -41,32 +41,36 @@ class NewPasswordController extends StudipController
...
@@ -41,32 +41,36 @@ class NewPasswordController extends StudipController
$users
=
User
::
findByEmail
(
Request
::
get
(
'mail'
));
$users
=
User
::
findByEmail
(
Request
::
get
(
'mail'
));
$user
=
$users
[
0
];
if
(
count
(
$users
)
===
1
)
{
setTempLanguage
(
$user
->
id
);
$user
=
$users
[
0
];
}
else
if
(
count
(
$users
)
>
1
)
{
// there are mutliple accounts with this mail addresses!
setTempLanguage
(
$users
[
0
]
->
id
);
$subject
=
sprintf
(
_
(
"[Stud.IP - %s] Passwortänderung angefordert"
),
// there are mutliple accounts with this mail addresses!
Config
::
get
()
->
UNI_NAME_CLEAN
$subject
=
sprintf
(
);
_
(
"[Stud.IP - %s] Passwortänderung angefordert"
),
Config
::
get
()
->
UNI_NAME_CLEAN
$mailbody
=
sprintf
(
);
_
(
"Dies ist eine Informationsmail des Stud.IP-Systems
\n
"
.
"(Studienbegleitender Internetsupport von Präsenzlehre)
\n
- %s -
\n\n
"
$mailbody
=
sprintf
(
.
"Für die Mail-Adresse %s wurde ein Link angefordert
\n
"
_
(
"Dies ist eine Informationsmail des Stud.IP-Systems
\n
"
.
"um das Passwort zurückzusetzen.
\n
"
.
"(Studienbegleitender Internetsupport von Präsenzlehre)
\n
- %s -
\n\n
"
.
"Dieser Mail-Adresse sind jedoch mehrere Zugänge zugeordnet,
\n
"
.
"Für die Mail-Adresse %s wurde ein Link angefordert
\n
"
.
"deshalb ist es nicht möglich, das Passwort hierüber zurückzusetzen.
\n
"
.
"um das Passwort zurückzusetzen.
\n
"
.
"Wenden sie sich bitte stattdessen an
\n
%s"
.
"Dieser Mail-Adresse sind jedoch mehrere Zugänge zugeordnet,
\n
"
),
.
"deshalb ist es nicht möglich, das Passwort hierüber zurückzusetzen.
\n
"
Config
::
get
()
->
UNI_NAME_CLEAN
,
.
"Wenden sie sich bitte stattdessen an
\n
%s"
$users
[
0
]
->
email
,
),
$GLOBALS
[
'UNI_CONTACT'
]
Config
::
get
()
->
UNI_NAME_CLEAN
,
);
$users
[
0
]
->
email
,
$GLOBALS
[
'UNI_CONTACT'
]
StudipMail
::
sendMessage
(
$user
->
email
,
$subject
,
$mailbody
);
);
restoreLanguage
();
StudipMail
::
sendMessage
(
$users
[
0
]
->
email
,
$subject
,
$mailbody
);
restoreLanguage
();
}
if
(
$user
)
{
if
(
$user
)
{
// spam/abuse-protection
// spam/abuse-protection
// if there are more than 5 tokens present, do NOT send another mail
// if there are more than 5 tokens present, do NOT send another mail
...
...
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