Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
szse
Overview
Overview
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
zhaochengxiang
szse
Commits
1af4b7b0
Commit
1af4b7b0
authored
Dec 08, 2023
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug fix
parent
8f163018
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
10 deletions
+17
-10
index.jsx
src/view/Manage/AssetDraft/index.jsx
+5
-3
ExchangeOwner.jsx
src/view/Manage/Model/Component/ExchangeOwner.jsx
+11
-6
SelectUsers.jsx
src/view/Manage/Model/Component/SelectUsers.jsx
+1
-1
No files found.
src/view/Manage/AssetDraft/index.jsx
View file @
1af4b7b0
...
...
@@ -299,9 +299,11 @@ const FC = (props) => {
<Tooltip title={((selectedRows??[]).length === 0) ? '请先选择资产' : ''}>
<Button onClick={onExportClick} disabled={(selectedRows??[]).length === 0}>导出</Button>
</Tooltip>
<Tooltip title={((selectedRows??[]).length === 0) ? '请先选择资产' : ''}>
<Button onClick={onPublishClick} disabled={(selectedRows??[]).length === 0}>发布</Button>
</Tooltip>
{
isAdmin && <Tooltip title={((selectedRows??[]).length === 0) ? '请先选择资产' : ''}>
<Button onClick={onPublishClick} disabled={(selectedRows??[]).length === 0}>发布</Button>
</Tooltip>
}
<Tooltip title={((selectedRows??[]).length === 0) ? '请先选择资产' : ''}>
<Button onClick={onDeletesClick} disabled={(selectedRows??[]).length === 0}>删除</Button>
</Tooltip>
...
...
src/view/Manage/Model/Component/ExchangeOwner.jsx
View file @
1af4b7b0
...
...
@@ -8,6 +8,7 @@ import './ExchangeOwner.less';
const
FC
=
({
visible
,
id
,
onCancel
})
=>
{
const
[
service
,
setService
]
=
useState
(
undefined
);
const
[
loading
,
setLoading
]
=
useState
(
false
);
const
[
loadingOwners
,
setLoadingOwners
]
=
useState
(
false
);
const
[
owners
,
setOwners
]
=
useState
(
undefined
);
const
[
currentOwner
,
setCurrentOwner
]
=
useState
(
undefined
);
...
...
@@ -37,12 +38,15 @@ const FC = ({ visible, id, onCancel }) => {
}
const
getOwners
=
()
=>
{
setLoadingOwners
(
true
);
dispatch
({
type
:
'pds.getOwners'
,
callback
:
(
data
)
=>
{
setLoadingOwners
(
false
);
setOwners
(
data
);
},
error
:
()
=>
{
setLoadingOwners
(
false
);
}
})
}
...
...
@@ -59,9 +63,9 @@ const FC = ({ visible, id, onCancel }) => {
}
}
const
cancel
=
()
=>
{
const
cancel
=
(
refresh
=
false
)
=>
{
reset
();
onCancel
?.();
onCancel
?.(
refresh
);
}
const
onOk
=
()
=>
{
...
...
@@ -76,7 +80,7 @@ const FC = ({ visible, id, onCancel }) => {
},
callback
:
()
=>
{
setLoading
(
false
);
onCancel
?.
(
true
);
cancel
(
true
);
},
error
:
()
=>
{
setLoading
(
false
);
...
...
@@ -87,12 +91,13 @@ const FC = ({ visible, id, onCancel }) => {
const
reset
=
()
=>
{
setService
(
undefined
);
setLoading
(
false
);
setLoadingOwners
(
false
);
}
const
footer
=
[
<
Button
key=
"0"
onClick=
{
cancel
}
onClick=
{
()
=>
{
cancel
()
}
}
>
取消
</
Button
>,
...
...
@@ -112,7 +117,7 @@ const FC = ({ visible, id, onCancel }) => {
title=
'更换管理人'
width=
{
800
}
destroyOnClose
onCancel=
{
cancel
}
onCancel=
{
()
=>
{
cancel
()
}
}
footer=
{
footer
}
>
<
Spin
spinning=
{
loading
}
>
...
...
@@ -131,7 +136,7 @@ const FC = ({ visible, id, onCancel }) => {
<
Space
>
<
div
>
管理人:
</
div
>
<
div
style=
{
{
width
:
200
}
}
>
<
SelectUsers
type=
'edit'
users=
{
owners
}
value=
{
currentOwner
}
onChange=
{
onOwnerChange
}
/>
<
SelectUsers
type=
'edit'
loading=
{
loadingOwners
}
users=
{
owners
}
value=
{
currentOwner
}
onChange=
{
onOwnerChange
}
/>
</
div
>
</
Space
>
</
Spin
>
...
...
src/view/Manage/Model/Component/SelectUsers.jsx
View file @
1af4b7b0
...
...
@@ -8,7 +8,7 @@ const {Option} = Select
const
SelectUser
:
React
.
FC
=
(
props
)
=>
{
const
{
value
,
onChange
,
users
,
type
,
loading
,
terms
,
publishedValue
}
=
props
const
{
value
,
onChange
,
users
,
type
,
loading
=
false
,
terms
,
publishedValue
}
=
props
const
[
searchValue
,
setSearchValue
]
=
useState
(
undefined
)
...
...
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