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
0bf01bc7
Commit
0bf01bc7
authored
Dec 04, 2021
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
资产删除不要的回收站代码
parent
e1fb04ff
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
16 deletions
+9
-16
App.js
src/App.js
+0
-1
index.jsx
src/view/Manage/AssetBrowse/index.jsx
+1
-1
AssetTree.jsx
src/view/Manage/AssetManage/Component/AssetTree.jsx
+8
-13
AssetMount.jsx
src/view/Manage/AssetRecycle/Component/AssetMount.jsx
+0
-1
No files found.
src/App.js
View file @
0bf01bc7
...
...
@@ -72,7 +72,6 @@ export class App extends React.Component {
reference
=
'metadata'
readOnly
=
{
true
}
showCustom
=
{
false
}
showTrash
=
{
false
}
checkable
=
{
true
}
onCheck
=
{(
values
)
=>
{
callback
&&
callback
(
values
);
...
...
src/view/Manage/AssetBrowse/index.jsx
View file @
0bf01bc7
...
...
@@ -29,7 +29,7 @@ const AssetBrowse = (props) => {
return
(
<
div
className=
{
classes
}
>
<
div
className=
'left'
>
<
AssetTree
onSelect=
{
onTreeSelect
}
showTrash=
{
false
}
readOnly
{
...
props
}
/>
<
AssetTree
onSelect=
{
onTreeSelect
}
readOnly
{
...
props
}
/>
</
div
>
<
div
className=
'tree-toggle-wrap'
>
<
div
className=
'tree-toggle'
onClick=
{
treeToggleClick
}
>
...
...
src/view/Manage/AssetManage/Component/AssetTree.jsx
View file @
0bf01bc7
...
...
@@ -13,7 +13,7 @@ import './AssetTree.less';
const
AssetTree
=
(
props
)
=>
{
const
{
readOnly
=
false
,
checkable
=
false
,
onSelect
,
className
,
onCheck
,
tableId
,
reference
=
''
,
showCustom
=
true
,
showTrash
=
true
}
=
props
;
const
{
readOnly
=
false
,
checkable
=
false
,
onSelect
,
className
,
onCheck
,
tableId
,
reference
=
''
,
showCustom
=
true
}
=
props
;
const
[
keyword
,
setKeyword
]
=
useState
(
''
);
const
[
loading
,
setLoading
]
=
useState
(
false
);
const
[
treeData
,
setTreeData
]
=
useState
([]);
...
...
@@ -96,9 +96,6 @@ const AssetTree = (props) => {
if
(
!
showCustom
)
{
newData
=
(
newData
||
[]).
filter
(
item
=>
item
.
type
!==
'custom'
);
}
if
(
!
showTrash
)
{
newData
=
(
newData
||
[]).
filter
(
item
=>
item
.
type
!==
'RecycleBin'
);
}
setTreeData
(
newData
);
...
...
@@ -238,7 +235,7 @@ const AssetTree = (props) => {
}
const
addDir
=
()
=>
{
if
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin'
)
return
;
if
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
)
return
;
setUpdateDirectoryAction
(
'add'
);
setUpdateDirectoryModalVisible
(
true
);
...
...
@@ -246,8 +243,6 @@ const AssetTree = (props) => {
const
editDir
=
()
=>
{
if
(
currentDirType
===
'RecycleBin'
)
return
;
if
((
currentDirType
||
''
)
===
''
)
{
setUpdateDirectoryAction
(
'edit'
);
...
...
@@ -266,7 +261,7 @@ const AssetTree = (props) => {
}
const
importDir
=
()
=>
{
if
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin'
)
return
;
if
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
)
return
;
setImportDirectoryVisible
(
true
);
}
...
...
@@ -292,7 +287,7 @@ const AssetTree = (props) => {
}
const
deleteDir
=
()
=>
{
if
(
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin'
)
return
;
if
(
currentDirType
===
'custom'
)
return
;
if
(
currentDirId
)
{
modal
.
confirm
({
...
...
@@ -465,16 +460,16 @@ const AssetTree = (props) => {
}
}
>
<
Tooltip
title=
"新增目录"
>
<
PlusOutlined
onClick=
{
addDir
}
style=
{
{
fontSize
:
16
,
cursor
:
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin'
)?
'not-allowed'
:
'pointer'
,
color
:
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin
'
)?
'#bfbfbf'
:
''
}
}
/>
<
PlusOutlined
onClick=
{
addDir
}
style=
{
{
fontSize
:
16
,
cursor
:
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
)?
'not-allowed'
:
'pointer'
,
color
:
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom
'
)?
'#bfbfbf'
:
''
}
}
/>
</
Tooltip
>
<
Tooltip
title=
"修改"
className=
'ml-3'
>
<
EditOutlined
onClick=
{
editDir
}
style=
{
{
fontSize
:
16
,
cursor
:
(
currentDirType
===
'RecycleBin'
)?
'not-allowed'
:
'pointer'
,
color
:
(
currentDirType
===
'RecycleBin'
)?
'#bfbfbf'
:
'
'
}
}
/>
<
EditOutlined
onClick=
{
editDir
}
style=
{
{
fontSize
:
16
,
cursor
:
'pointer
'
}
}
/>
</
Tooltip
>
<
Tooltip
title=
"刷新"
className=
'ml-3'
>
<
SyncOutlined
onClick=
{
refreshTree
}
style=
{
{
fontSize
:
16
,
cursor
:
'pointer'
}
}
/>
</
Tooltip
>
<
Tooltip
title=
"导入"
className=
'ml-3'
>
<
ImportOutlined
onClick=
{
importDir
}
style=
{
{
fontSize
:
16
,
cursor
:(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin'
)?
'not-allowed'
:
'pointer'
,
color
:
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin
'
)?
'#bfbfbf'
:
''
}
}
/>
<
ImportOutlined
onClick=
{
importDir
}
style=
{
{
fontSize
:
16
,
cursor
:(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom'
)?
'not-allowed'
:
'pointer'
,
color
:
(
currentDirType
===
'custom-root'
||
currentDirType
===
'custom
'
)?
'#bfbfbf'
:
''
}
}
/>
</
Tooltip
>
<
Dropdown
overlay=
{
exportMenu
}
placement=
"bottomLeft"
className=
'ml-3'
>
<
Tooltip
title=
"导出"
>
...
...
@@ -482,7 +477,7 @@ const AssetTree = (props) => {
</
Tooltip
>
</
Dropdown
>
<
Tooltip
title=
"删除"
className=
'ml-3'
>
<
DeleteOutlined
onClick=
{
deleteDir
}
style=
{
{
fontSize
:
16
,
cursor
:(
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin'
)?
'not-allowed'
:
'pointer'
,
color
:
(
currentDirType
===
'custom'
||
currentDirType
===
'RecycleBin
'
)?
'#bfbfbf'
:
''
}
}
/>
<
DeleteOutlined
onClick=
{
deleteDir
}
style=
{
{
fontSize
:
16
,
cursor
:(
currentDirType
===
'custom'
)?
'not-allowed'
:
'pointer'
,
color
:
(
currentDirType
===
'custom
'
)?
'#bfbfbf'
:
''
}
}
/>
</
Tooltip
>
<
Tooltip
title=
"自定义"
className=
'ml-3'
>
<
SettingOutlined
onClick=
{
customDir
}
style=
{
{
fontSize
:
16
,
cursor
:
'pointer'
}
}
/>
...
...
src/view/Manage/AssetRecycle/Component/AssetMount.jsx
View file @
0bf01bc7
...
...
@@ -62,7 +62,6 @@ const AssetMount = (props) => {
readOnly=
{
true
}
checkable=
{
true
}
showCustom=
{
false
}
showTrash=
{
false
}
onCheck=
{
onCheck
}
tableId=
{
(
refrence
===
'asset-manage'
&&
(
ids
||
[].
length
>
0
))?
ids
[
0
]:
''
}
reference=
'mount'
...
...
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