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
da4ae542
authored
2025-06-20 17:28:01 +0800
by
fanguang
Committed by
lihua
2025-06-30 14:34:01 +0800
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix
1 parent
810307b0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
44 additions
and
11 deletions
src/views/data_meta/standard-codetable.vue
src/views/data_meta/standard-codetable.vue
View file @
da4ae54
...
...
@@ -489,7 +489,7 @@ const drawerInfo: any = ref({
btns
:
[
{
type
:
'default'
,
label
:
'取消'
,
value
:
'cancel'
},
{
type
:
'primary'
,
label
:
'保存'
,
value
:
'submit'
,
visible
:
true
},
{
type
:
'primary'
,
label
:
'保存并添加数据'
,
value
:
's
ubmit
'
,
visible
:
true
},
{
type
:
'primary'
,
label
:
'保存并添加数据'
,
value
:
's
aveAndAdd
'
,
visible
:
true
},
]
},
})
...
...
@@ -575,7 +575,7 @@ const getCodeRuleData = () => {
const
treePromise
=
ref
();
const
getTreeData
=
(
needClick
=
false
,
currData
=
{})
=>
{
getParamsList
({
dictType
:
'标准类型'
}).
then
((
res
:
any
)
=>
{
return
getParamsList
({
dictType
:
'标准类型'
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
===
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
[]
data
.
forEach
(
item
=>
{
...
...
@@ -864,7 +864,7 @@ const tableBtnClick = (scope, btn) => {
drawerInfo
.
value
.
modalClass
=
type
==
'edit'
?
''
:
'wrap_width_auto'
drawerInfo
.
value
.
type
=
type
drawerInfo
.
value
.
footer
.
btns
.
forEach
(
item
=>
{
if
(
item
.
value
===
'submit'
)
{
if
(
item
.
value
===
'submit'
||
item
.
value
===
'saveAndAdd'
)
{
item
.
visible
=
type
===
'detail'
?
false
:
true
}
})
...
...
@@ -1094,6 +1094,10 @@ const loadDrawer = async () => {
}
})
formTable
.
value
.
tableInfo
.
fields
=
fields
formItems
.
value
.
forEach
(
item
=>
{
item
.
default
=
''
item
.
disabled
=
false
})
formInfo
.
value
.
formInfo
.
items
=
formItems
.
value
formTableData
.
value
=
JSON
.
parse
(
JSON
.
stringify
(
orginData
))
formTable
.
value
.
tableInfo
.
data
=
formTableData
.
value
...
...
@@ -1103,6 +1107,9 @@ const loadDrawer = async () => {
formTable
.
value
.
tableInfo
.
actionInfo
.
show
=
true
formTable
.
value
.
tableTool
.
visible
=
true
drawerInfo
.
value
.
container
.
contents
=
contents
.
value
[
'add'
]
drawerInfo
.
value
.
footer
.
btns
.
forEach
(
item
=>
{
item
.
visible
=
true
})
drawerInfo
.
value
.
visible
=
true
console
.
log
(
'table'
,
formTable
.
value
)
console
.
log
(
'formInfo'
,
formInfo
)
...
...
@@ -1263,7 +1270,8 @@ const setDetailInfo = (type) => {
drawerInfo
.
value
.
container
.
contents
=
contents
.
value
[
'add'
]
drawerInfo
.
value
.
visible
=
true
// if (row.typeCode)
formItems
.
value
.
find
(
v
=>
v
.
field
===
'hierarchy'
)[
'visible'
]
=
row
.
typeCode
==
1
?
false
:
true
setCodeOptions
()
}
...
...
@@ -1275,12 +1283,13 @@ const saveData = async (params, btnValue) => {
request
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
===
proxy
.
$passCode
)
{
ElMessage
.
success
(
'操作成功'
)
getTreeData
()
drawerInfo
.
value
.
visible
=
false
if
(
btnValue
===
'saveAndAdd'
)
{
// 跳转代码详情
toStandardCodeDetail
(
res
.
data
)
}
getTreeData
().
then
(()
=>
{
drawerInfo
.
value
.
visible
=
false
if
(
btnValue
===
'saveAndAdd'
)
{
// 跳转代码详情
toStandardCodeDetail
(
res
.
data
)
}
})
}
else
{
ElMessage
.
error
(
res
.
msg
)
}
...
...
@@ -1289,7 +1298,31 @@ const saveData = async (params, btnValue) => {
})
}
function
toStandardCodeDetail
(
guid
)
{
if
(
drawerInfo
.
value
.
type
===
'add'
)
{
getStandardCodeDetail
(
guid
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
let
{
guid
,
standardName
}
=
res
.
data
showFiledsPage
.
value
=
true
nextTick
(()
=>
{
dictFiledsRef
.
value
.
standardGuid
=
guid
dictFiledsRef
.
value
.
standardName
=
standardName
treeCurrentNodeKey
.
value
=
guid
dictFiledsRef
.
value
.
getFirstPageData
()
})
}
})
}
else
{
console
.
log
(
'currentData'
,
currTableData
.
value
)
let
{
guid
,
standardName
}
=
currTableData
.
value
showFiledsPage
.
value
=
true
nextTick
(()
=>
{
dictFiledsRef
.
value
.
standardGuid
=
guid
dictFiledsRef
.
value
.
standardName
=
standardName
treeCurrentNodeKey
.
value
=
guid
dictFiledsRef
.
value
.
getFirstPageData
()
})
}
}
const
scrollTable
=
(
rowInfo
)
=>
{
...
...
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