Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
Login
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
kranthi.kumar
Login
Commits
8c34b5b4
Commit
8c34b5b4
authored
Jan 29, 2021
by
kranthi.kumar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update login_service.py
parent
5f2d2c09
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
scripts/service/login_service.py
scripts/service/login_service.py
+2
-2
No files found.
scripts/service/login_service.py
View file @
8c34b5b4
...
@@ -29,10 +29,10 @@ try:
...
@@ -29,10 +29,10 @@ try:
# collecting user details from registration.html
# collecting user details from registration.html
data
=
{
"Name"
:
request
.
form
[
"name"
],
"Phone number"
:
request
.
form
[
"number"
],
"Mail id"
:
request
.
form
[
"mail"
],
data
=
{
"Name"
:
request
.
form
[
"name"
],
"Phone number"
:
request
.
form
[
"number"
],
"Mail id"
:
request
.
form
[
"mail"
],
"User Id"
:
request
.
form
[
"user_id"
],
"User Id"
:
request
.
form
[
"user_id"
],
"Password"
:
bcrypt
.
hashpw
((
request
.
form
[
"password"
])
.
encode
(
'utf8'
),
bcrypt
.
gensalt
())
}
"Password"
:
request
.
form
[
"password"
]
}
if
request
.
form
[
"password"
]
==
request
.
form
[
"r_password"
]:
if
request
.
form
[
"password"
]
==
request
.
form
[
"r_password"
]:
# sending data to the database.
# sending data to the database.
result
=
mongodb_object
.
insert
(
data
,
request
.
form
[
"user_id"
])
result
=
mongodb_object
.
insert
(
data
,
request
.
form
[
"user_id"
]
,
request
.
form
[
"password"
]
)
if
result
==
1
:
if
result
==
1
:
# works when user is successfully register
# works when user is successfully register
flash
(
"you have successfully register. you can login here :"
)
flash
(
"you have successfully register. you can login here :"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment