Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
csbr-daop
/
fe-data-trusted-space
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
ad0bf64f
authored
2025-06-20 10:38:30 +0800
by
fanguang
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix
1 parent
60ba939a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
28 deletions
src/api/modules/dataMetaService.ts
src/views/data_meta/standard-codetable.vue
src/api/modules/dataMetaService.ts
View file @
ad0bf64
...
...
@@ -306,4 +306,10 @@ export const deleteStandardCodeFieldsData = (params) => request({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_STANDARD_URL
}
/standard-code/data/remove-data`
,
method
:
'post'
,
data
:
params
})
/** 元数据-导出 */
export
const
exportStandardCodeData
=
(
params
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_STANDARD_URL
}
/standard-code/data/data-export`
,
method
:
'post'
,
data
:
params
})
\ No newline at end of file
...
...
src/views/data_meta/standard-codetable.vue
View file @
ad0bf64
...
...
@@ -15,7 +15,7 @@ import { download } from '@/utils/common'
import
{
getParamsList
}
from
'@/api/modules/dataAsset'
import
{
getStandardCodeList
,
saveStandardCode
,
updateStandardCode
,
getStandardCodeDetail
,
deleteStandardCode
,
getStandardCodeStandard
deleteStandardCode
,
getStandardCodeStandard
,
exportStandardCodeData
}
from
'@/api/modules/dataMetaService'
import
{
addDictionary
,
...
...
@@ -1080,32 +1080,15 @@ const uploadFile = (file) => {
}
const
exportData
=
(
type
:
any
=
null
)
=>
{
if
(
type
==
'model'
)
{
let
params
=
{
guid
:
dictGuid
.
value
}
if
(
drawerInfo
.
value
.
type
==
'add'
)
{
params
.
guid
=
fieldSheetInfo
.
value
.
guid
}
exportDictionary
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
&&
!
res
.
msg
)
{
download
(
res
,
'数据字典模板.xlsx'
,
'excel'
)
}
else
{
res
?.
msg
&&
ElMessage
.
error
(
res
?.
msg
);
}
});
}
else
{
let
params
=
{
guid
:
dictGuid
.
value
let
body
=
[
treeCurrentNodeKey
.
value
]
exportStandardCodeData
(
body
).
then
((
res
:
any
)
=>
{
if
(
res
&&
!
res
.
msg
)
{
download
(
res
,
'标准代码表.xlsx'
,
'excel'
)
}
else
{
res
?.
msg
&&
ElMessage
.
error
(
res
?.
msg
);
}
exportDictionaryFileds
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
&&
!
res
.
msg
)
{
download
(
res
,
'字典数据.xlsx'
,
'excel'
);
}
else
{
res
?.
msg
&&
ElMessage
.
error
(
res
?.
msg
);
}
});
}
})
return
}
const
importData
=
(
file
:
any
=
null
)
=>
{
...
...
@@ -1221,6 +1204,7 @@ const loadDrawer = async () => {
setCodeOptions
()
};
const
treeCurrentNodeKey
=
ref
(
''
)
const
batching
=
(
type
)
=>
{
if
(
type
==
'delete'
)
{
if
(
selectRowData
.
value
.
length
==
0
)
{
...
...
@@ -1268,6 +1252,7 @@ const nodeClick = (data) => {
nextTick
(()
=>
{
dictFiledsRef
.
value
.
standardGuid
=
data
.
value
dictFiledsRef
.
value
.
standardName
=
data
.
label
treeCurrentNodeKey
.
value
=
data
.
value
dictFiledsRef
.
value
.
getFirstPageData
()
})
}
else
{
...
...
@@ -1385,7 +1370,7 @@ const saveData = async (params) => {
drawerInfo
.
value
.
visible
=
false
}
}).
finally
(()
=>
{
drawerInfo
.
value
.
footer
.
btns
.
map
((
item
:
any
)
=>
item
.
disabled
=
tru
e
)
drawerInfo
.
value
.
footer
.
btns
.
map
((
item
:
any
)
=>
item
.
disabled
=
fals
e
)
})
}
...
...
@@ -1513,7 +1498,7 @@ onMounted(() => {
<
template
>
<div
class=
"container_wrap full flex"
>
<div
class=
"aside_wrap"
>
<div
class=
"aside_title"
>
数据字典
列表
</div>
<div
class=
"aside_title"
>
标准代码
列表
</div>
<Tree
ref=
"dictTreeRef"
:treeInfo=
"treeInfo"
@
nodeClick=
"nodeClick"
@
loadNode=
"loadTreeNode"
/>
</div>
<DictFileds
ref=
"dictFiledsRef"
v-if=
"showFiledsPage"
@
exportData=
"exportData"
/>
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment