Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Administrator
/
level3-lesson20-diy4
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
c883d7a2
authored
Mar 10, 2024
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
save project
parent
1adc10cf
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
my_client.py
user.txt
my_client.py
View file @
c883d7a2
...
...
@@ -40,6 +40,9 @@ class Note(): # 便签、笔记
def
remove
(
self
):
num
=
self
.
v
.
get
()
alist
.
pop
(
num
)
content
=
json
.
dumps
(
users
)
with
open
(
"user.txt"
,
"w"
,
encoding
=
"utf-8"
)
as
file
:
file
.
write
(
content
)
self
.
canvas
.
destroy
()
app
.
show
()
...
...
@@ -103,7 +106,7 @@ def login():
name
,
password
=
app_login
.
get_input
()
user_name
=
users
.
get
(
name
)
if
user_name
!=
None
and
user_name
[
'password'
]
==
password
:
alist
=
user
[
name
][
'event'
]
alist
=
user
s
[
name
][
'event'
]
app_login
.
root
.
destroy
()
app
=
Note
()
app
.
show
()
...
...
user.txt
View file @
c883d7a2
{"admin": "admin", "python": "123456", "GXC": {"password": "2013 1125", "event": ["\u63d0\u793a1\uff1a\u53ef\u4ee5\u6dfb\u52a0\u65b0\u4efb\u52a1", "\u63d0\u793a2\uff1a\u70b9\u51fb\u9009\u62e9\u6846\uff0c\u8868\u793a\u5b8c\u6210"]}, "N": {"password": "123", "event": ["\u63d0\u793a1\uff1a\u53ef\u4ee5\u6dfb\u52a0\u65b0\u4efb\u52a1", "\u63d0\u793a2\uff1a\u70b9\u51fb\u9009\u62e9\u6846\uff0c\u8868\u793a\u5b8c\u6210"]}}
\ No newline at end of file
{"admin": "admin", "python": "123456", "GXC": {"password": "2013 1125", "event": []}, "N": {"password": "123", "event": ["\u63d0\u793a1\uff1a\u53ef\u4ee5\u6dfb\u52a0\u65b0\u4efb\u52a1", "\u63d0\u793a2\uff1a\u70b9\u51fb\u9009\u62e9\u6846\uff0c\u8868\u793a\u5b8c\u6210"]}}
\ No newline at end of file
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