Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
basic
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
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
xrm
basic
Commits
c5cf678c
Commit
c5cf678c
authored
4 years ago
by
Tom Lutzenberger
Browse files
Options
Downloads
Patches
Plain Diff
#1058862: Adjust password validation to tools-API
parent
2a9f65a1
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
entity/Employee_entity/entityfields/password/onValidation.js
+2
-2
2 additions, 2 deletions
entity/Employee_entity/entityfields/password/onValidation.js
entity/Usersettings_entity/entityfields/jpassword/onValidation.js
+2
-2
2 additions, 2 deletions
...sersettings_entity/entityfields/jpassword/onValidation.js
with
4 additions
and
4 deletions
entity/Employee_entity/entityfields/password/onValidation.js
+
2
−
2
View file @
c5cf678c
...
...
@@ -8,11 +8,11 @@ import("system.vars");
if
(
vars
.
get
(
"
$sys.recordstate
"
)
==
neon
.
OPERATINGSTATE_NEW
)
{
let
newPassword
=
vars
.
get
(
"
$local.value
"
);
let
policyMessages
=
tools
.
validatePasswordPolicies
(
newPassword
);
let
policyMessages
=
tools
.
validatePasswordPolicies
(
newPassword
,
""
);
let
messages
=
[];
if
(
newPassword
)
{
if
(
Object
.
keys
(
policyMessages
)
.
length
>
0
)
{
if
(
policyMessages
.
length
>
0
)
{
for
(
let
msg
in
policyMessages
)
{
messages
.
push
(
policyMessages
[
msg
]);
}
...
...
This diff is collapsed.
Click to expand it.
entity/Usersettings_entity/entityfields/jpassword/onValidation.js
+
2
−
2
View file @
c5cf678c
...
...
@@ -6,7 +6,7 @@ import("system.vars");
let
newPassword
=
vars
.
get
(
"
$local.value
"
);
let
currentPassword
=
vars
.
get
(
"
$field.currentPassword
"
);
let
policyMessages
=
tools
.
validatePasswordPolicies
(
newPassword
);
let
policyMessages
=
tools
.
validatePasswordPolicies
(
newPassword
,
vars
.
get
(
"
$sys.user
"
)
);
let
messages
=
[];
if
(
newPassword
)
{
...
...
@@ -14,7 +14,7 @@ if(newPassword) {
result
.
string
(
translate
.
text
(
"
New password must not be the same as the current password
"
));
}
if
(
Object
.
keys
(
policyMessages
)
.
length
>
0
)
{
if
(
policyMessages
.
length
>
0
)
{
for
(
let
msg
in
policyMessages
)
{
messages
.
push
(
policyMessages
[
msg
]);
}
...
...
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