Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
I
install.api
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Script
install.api
Commits
846d2e8b
Commit
846d2e8b
authored
Mar 12, 2020
by
金凯强
🎨
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug修复
设置登录信息加强 host_ip的写入
parent
afb1759e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
authorization_service.py
app/authorization/authorization_service.py
+3
-1
conncetion_service.py
app/conncetion/conncetion_service.py
+3
-3
No files found.
app/authorization/authorization_service.py
View file @
846d2e8b
...
...
@@ -27,7 +27,9 @@ class AuthorizationService(HSBaseUCService):
:param json_data:
:return:
'''
session_info
=
json
.
dumps
(
json_data
)
user_name
=
json_data
.
get
(
'user_name'
)
password
=
json_data
.
get
(
'password'
)
session_info
=
json
.
dumps
({
'user_name'
:
user_name
,
'password'
:
password
})
with
open
(
session_info_path
,
'w'
)
as
f
:
f
.
write
(
session_info
)
...
...
app/conncetion/conncetion_service.py
View file @
846d2e8b
...
...
@@ -34,7 +34,7 @@ class ConnectionService(HSBaseUCService):
if
id
:
update_sql
=
'''update project_info
set project_no=:project_no,db_ip=:db_ip,db_port=:db_port,db_user=:db_user
,db_password=:db_password,mes_db_name=:mes_db_name,tiip_db_name=:tiip_db_name
,db_password=:db_password,mes_db_name=:mes_db_name,tiip_db_name=:tiip_db_name
,host_ip=:host_ip
where id=:id'''
session
.
exec_sql
(
update_sql
,
json_data
)
...
...
@@ -43,10 +43,10 @@ where id=:id'''
json_data
[
'id'
]
=
id
insert_sql
=
'''insert into project_info
(id,project_no,db_ip,db_port,db_user
,db_password,mes_db_name,tiip_db_name)
,db_password,mes_db_name,tiip_db_name
,host_ip
)
values
(:id,:project_no,:db_ip,:db_port,:db_user
,:db_password,:mes_db_name,:tiip_db_name)'''
,:db_password,:mes_db_name,:tiip_db_name
,:host_ip
)'''
session
.
exec_sql
(
insert_sql
,
json_data
)
data
=
session
.
retrive_sql
(
'select * from project_info where id=:id'
,
...
...
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