Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
new-api
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
acd4315d
authored
Dec 27, 2023
by
CaIon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix delete user
parent
288d7e77
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
model/user.go
+1
-1
web/src/components/UsersTable.js
+2
-2
No files found.
model/user.go
View file @
acd4315d
...
...
@@ -31,7 +31,7 @@ type User struct {
AffQuota
int
`json:"aff_quota" gorm:"type:int;default:0;column:aff_quota"`
// 邀请剩余额度
AffHistoryQuota
int
`json:"aff_history_quota" gorm:"type:int;default:0;column:aff_history"`
// 邀请历史额度
InviterId
int
`json:"inviter_id" gorm:"type:int;column:inviter_id;index"`
DeletedAt
gorm
.
DeletedAt
`
json:"deleted_at"
gorm:"index"`
DeletedAt
gorm
.
DeletedAt
`gorm:"index"`
}
// CheckUserExistOrDeleted check if user exist or deleted, if not exist, return false, nil, if deleted or exist, return true, nil
...
...
web/src/components/UsersTable.js
View file @
acd4315d
...
...
@@ -72,13 +72,13 @@ const UsersTable = () => {
},
{
title
:
'状态'
,
dataIndex
:
'status'
,
render
:
(
text
,
record
,
index
)
=>
{
return
(
<
div
>
{
record
.
deleted_a
t
!==
null
?
<
Tag
color
=
'red'
>
已注销
<
/Tag> : renderStatus
(
text
)
}
{
record
.
DeletedA
t
!==
null
?
<
Tag
color
=
'red'
>
已注销
<
/Tag> : renderStatus
(
text
)
}
<
/div>
)
;
},
},
{
title
:
''
,
dataIndex
:
'operate'
,
render
:
(
text
,
record
,
index
)
=>
(
<
div
>
{
record
.
deleted_a
t
!==
null
?
<><
/>
:
record
.
DeletedA
t
!==
null
?
<><
/>
:
<>
<
Popconfirm
title
=
"确定?"
...
...
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