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
d859bbdf
Commit
d859bbdf
authored
Mar 18, 2025
by
fanyj
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tijiao
parent
2257ad9e
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
34 additions
and
18 deletions
+34
-18
draft.jsx
src/view/Manage/AssetDraft/draft.jsx
+2
-2
AssetAction.jsx
src/view/Manage/AssetManage/Component/AssetAction.jsx
+5
-2
AssetManageTree.jsx
src/view/Manage/AssetManage/Component/AssetManageTree.jsx
+1
-1
AssetTable.jsx
src/view/Manage/AssetManage/Component/AssetTable.jsx
+3
-6
MatchMetaInfo.tsx
src/view/Manage/AssetManage/Component/MatchMetaInfo.tsx
+14
-1
UpdateDirectoryModal.jsx
...iew/Manage/AssetManage/Component/UpdateDirectoryModal.jsx
+1
-1
index.jsx
src/view/Manage/AssetManage/index.jsx
+2
-0
SelectMeta.tsx
src/view/meta/selectmeta/SelectMeta.tsx
+1
-1
Meta.ts
src/view/meta/selectmeta/hooks/Meta.ts
+5
-4
No files found.
src/view/Manage/AssetDraft/draft.jsx
View file @
d859bbdf
...
...
@@ -587,14 +587,14 @@ const FC = (props) => {
导出
</PermissionButton>
<PermissionButton
{/*
<PermissionButton
defaultPermission={canFlow}
tip={(selectedRows||[]).length===0?'请先选择资源':''}
onClick={onFlowClick}
disabled={(selectedRows||[]).length===0}
>
送审
</PermissionButton>
</PermissionButton>
*/}
<PermissionButton
defaultPermission={canPublish}
...
...
src/view/Manage/AssetManage/Component/AssetAction.jsx
View file @
d859bbdf
...
...
@@ -304,7 +304,8 @@ const AssetAction = React.forwardRef(function (props, ref) {
const
cols
=
useMemo
(()
=>
{
let
newCols
=
[]
console
.
log
(
'columns'
,
columns
)
console
.
log
(
'businessColumns'
,
businessColumns
)
newCols
=
isStructured
?[...
columns
]:[...
businessColumns
??[]]
if
(
!
isStructured
&&
currentAction
!==
'detail'
)
{
newCols
.
push
(
businessActionCol
)
...
...
@@ -839,8 +840,10 @@ const AssetAction = React.forwardRef(function (props, ref) {
</Radio.Group>
{
action!=='add' && <Space>
{/* reference===AssetManageReference|| */}
{
(!readonly && (
reference===AssetManageReference||canEdit
)) && <React.Fragment>
(!readonly && (
canEdit&&reference!=='asset-browse'
)) && <React.Fragment>
{
currentAction==='detail' ? <Tooltip title={(assets?.existDraft)?'资源存在草稿箱中,不允许编辑':''}>
<Button onClick={onActionButtonClick} disabled={assets?.existDraft}>编辑</Button>
...
...
src/view/Manage/AssetManage/Component/AssetManageTree.jsx
View file @
d859bbdf
...
...
@@ -1017,7 +1017,7 @@ const AssetManageTree = (props) => {
checkedKeys=
{
checkedKeys
}
checkStrictly
onRightClick=
{
({
event
,
node
})
=>
{
if
(
reference
===
AssetManageReference
&&
havePermission
)
{
if
(
reference
===
AssetManageReference
&&
(
havePermission
||
addDir
)
)
{
setCurrentRightClickDir
(
node
);
setCurrentDirType
(
node
.
type
||
''
);
displayMenu
(
event
);
...
...
src/view/Manage/AssetManage/Component/AssetTable.jsx
View file @
d859bbdf
...
...
@@ -333,6 +333,7 @@ const AssetTable = (props) => {
let
[
_addAble
,
_importAble
,
_exportAble
,
_changeDirectoryAble
,
_deleteAble
,
_offlineAble
,
_addTagAble
,
_subscribeAble
,
_addDirAble
]
=
[
false
,
false
,
false
,
false
,
false
,
false
,
false
,
false
,
false
]
_addAble
=
(
permissions
??[]).
findIndex
(
item
=>
item
===
'add'
)
!==
-
1
_addDirAble
=
(
permissions
??[]).
findIndex
(
item
=>
item
===
'addDir'
)
!==
-
1
if
((
selectedRows
??[]).
length
===
0
)
{
_importAble
=
(
permissions
??[]).
findIndex
(
item
=>
item
===
'import'
)
!==
-
1
...
...
@@ -356,12 +357,12 @@ const AssetTable = (props) => {
let
[
allowChangeDirectory
,
allowDelete
,
allowOffline
,
allowAddTag
,
allowSubscribe
,
allowAddDir
]
=
[
true
,
true
,
true
,
true
,
true
,
true
]
for
(
const
row
of
selectedRows
??[])
{
console
.
log
(
'tt'
,
row
)
const
changeDirecotoryIndex
=
(
row
.
allowButtons
??[]).
findIndex
(
item
=>
item
===
'changeDir'
)
const
deleteIndex
=
(
row
.
allowButtons
??[]).
findIndex
(
item
=>
item
===
'delete'
)
const
offlineIndex
=
(
row
.
allowButtons
??[]).
findIndex
(
item
=>
item
===
'offline'
)
const
addTagIndex
=
(
row
.
allowButtons
??[]).
findIndex
(
item
=>
item
===
'addTag'
)
const
subscribeIndex
=
(
row
.
allowButtons
??[]).
findIndex
(
item
=>
item
===
'subscribe'
)
const
addDir
=
(
row
.
allowButtons
??[]).
findIndex
(
item
=>
item
===
'addDir'
)
if
(
changeDirecotoryIndex
===
-
1
)
{
allowChangeDirectory
=
false
}
...
...
@@ -377,9 +378,6 @@ const AssetTable = (props) => {
if
(
subscribeIndex
===
-
1
)
{
allowSubscribe
=
false
}
if
(
addDir
===-
1
){
allowAddDir
=
false
}
}
_changeDirectoryAble
=
allowChangeDirectory
...
...
@@ -387,13 +385,12 @@ const AssetTable = (props) => {
_offlineAble
=
allowOffline
_addTagAble
=
allowAddTag
_subscribeAble
=
allowSubscribe
_addDirAble
=
allowAddDir
return
[
_addAble
,
_importAble
,
_exportAble
,
_changeDirectoryAble
,
_deleteAble
,
_offlineAble
,
_addTagAble
,
_subscribeAble
,
_addDirAble
]
},
[
permissions
,
selectedRows
])
useEffect
(()
=>
{
setAddDir
(
adddirAble
)
setAddDir
?.
(
adddirAble
)
},[
adddirAble
])
const
realAssets
=
useMemo
(()
=>
{
...
...
src/view/Manage/AssetManage/Component/MatchMetaInfo.tsx
View file @
d859bbdf
...
...
@@ -6,6 +6,7 @@ import SelectMeta from "@/view/meta/selectmeta/SelectMeta"
import
{
pageUtil
}
from
"@/utils"
import
{
dispatch
}
from
'../../../../model'
;
import
{
showMessage
}
from
'../../../../util'
;
import
qs
from
'qs'
const
MatchMetaInfo
:
React
.
FC
<
any
>=
(
props
)
=>
{
...
...
@@ -54,6 +55,18 @@ const MatchMetaInfo:React.FC<any>=(props)=>{
}
}
const
opendetail
=
()
=>
{
const
payload
=
{
mid
:
selectData
.
metadataId
,
action
:
'metadetail'
,
type
:
'detail'
,
manager
:
false
,
activekey
:
1
,
}
window
.
open
(
`/center-home/metadetail?
${
qs
.
stringify
(
payload
)}
`
)
}
return
(
<
div
>
<
Divider
orientation=
'left'
>
关联元数据
</
Divider
>
...
...
@@ -63,7 +76,7 @@ const MatchMetaInfo:React.FC<any>=(props)=>{
labelStyle=
{
{
width
:
180
}
}
>
<
div
className=
'flex'
style=
{
{
alignItems
:
'center'
}
}
>
<
div
style=
{
{
flex
:
1
}
}
>
<
div
style=
{
{
flex
:
1
,
cursor
:
'pointer'
,
color
:
'blue'
}
}
onClick=
{
()
=>
{
opendetail
()
}
}
>
{
selectData
?.
metadataPath
}
</
div
>
<
div
style=
{
{
flex
:
'0 0 auto'
,
marginLeft
:
10
,
width
:
16
}
}
>
...
...
src/view/Manage/AssetManage/Component/UpdateDirectoryModal.jsx
View file @
d859bbdf
...
...
@@ -59,7 +59,7 @@ const UpdateDirectoryModal = (props) => {
return
(
dir
&&
dir
.
level
===
1
)
?
true
:
false
;
}
else
{
return
(
dir
&&
dir
.
level
<=
2
)
?
true
:
false
;
return
true
}
return
false
;
...
...
src/view/Manage/AssetManage/index.jsx
View file @
d859bbdf
...
...
@@ -75,6 +75,8 @@ const AssetManage = (props) => {
'middle-fullscreen'
:
assetFullScreen
});
console
.
log
(
addDir
)
return
(
<
div
className=
{
classes
}
>
<
ResizableBox
...
...
src/view/meta/selectmeta/SelectMeta.tsx
View file @
d859bbdf
...
...
@@ -66,7 +66,7 @@ const SelectMeta:React.FC<any>=(dprops)=>{
})
const
{
tablelist
,
tableload
,
tabletotal
,
changeOrder
,
changePage
,
pageable
,
changeSelect
,
selectedRowKeys
}
=
useGetMetaTableInfo
({
treeNode
:
state
.
selectNode
,
currentDomain
})
const
{
tablelist
,
tableload
,
tabletotal
,
changeOrder
,
changePage
,
pageable
,
changeSelect
,
selectedRowKeys
}
=
useGetMetaTableInfo
({
treeNode
:
state
.
selectNode
,
currentDomain
,
keyword
:
value
})
...
...
src/view/meta/selectmeta/hooks/Meta.ts
View file @
d859bbdf
...
...
@@ -56,11 +56,12 @@ export const useGetSearchType=()=>{
interface
p3
{
treeNode
:
any
,
currentDomain
:
any
,
type
?:
string
type
?:
string
,
keyword
?:
string
}
export
const
useGetMetaTableInfo
=
(
props
:
p3
)
=>
{
const
{
treeNode
,
currentDomain
,
type
=
'admin'
}
=
props
const
{
treeNode
,
currentDomain
,
type
=
'admin'
,
keyword
}
=
props
const
[
state
,
setState
]
=
useSetState
({
pageable
:{
...
...
@@ -89,7 +90,7 @@ export const useGetMetaTableInfo=(props:p3)=>{
pageNum
:
1
,
pageSize
:
20
,
}})
},[
treeNode
])
},[
treeNode
,
keyword
])
useDebounceEffect
(()
=>
{
if
(
currentDomain
.
domainId
)
...
...
@@ -107,7 +108,7 @@ export const useGetMetaTableInfo=(props:p3)=>{
system
:
treeNode
.
system
?
treeNode
.
system
:
treeNode
.
value
,
pageNum
:
state
.
pageable
.
pageNum
,
pageSize
:
state
.
pageable
.
pageSize
,
keyword
:
''
,
keyword
:
keyword
,
catalog
:
currentDomain
.
domainId
,
parentId
:
treeNode
.
path
?
treeNode
.
parentId
:
treeNode
.
value
,
...
state
.
order
,
...
...
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