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
ba1ce28d
authored
2025-11-28 15:49:05 +0800
by
lihua
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Revert "产品地域回显和添加服务包不能添加重复"
This reverts commit
c68dce9b
.
1 parent
c68dce9b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
27 deletions
src/components/Table/index.vue
src/views/data_asset/registerCatalogCreate.vue
src/components/Table/index.vue
View file @
ba1ce28
...
...
@@ -406,7 +406,6 @@ onMounted(() => {
v-for=
"opt in editForm[item.field].getOptions ? editForm[item.field].getOptions(scope) : editForm[item.field].options"
:label=
"editForm[item.field]?.props?.label ? opt[editForm[item.field].props.label] : opt.label"
:value=
"editForm[item.field]?.props?.value ? opt[editForm[item.field].props.value] : opt.value"
:disabled=
"editForm[item.field]?.props?.disabled ? opt[editForm[item.field].props.disabled] : opt.disabled"
:key=
"editForm[item.field]?.props?.value ? opt[editForm[item.field].props.value] : opt.value"
/>
</el-select>
<el-input
v-else-if=
"
...
...
src/views/data_asset/registerCatalogCreate.vue
View file @
ba1ce28
...
...
@@ -695,17 +695,6 @@ const productData: any = ref([]);
const
apiList
:
any
=
ref
([]);
const
getAPIOptions
=
(
scope
)
=>
{
apiList
.
value
.
forEach
(
a
=>
{
if
(
a
.
guid
!=
scope
.
row
.
guid
&&
productData
.
value
.
some
(
p
=>
p
.
apiGuid
==
a
.
guid
))
{
a
.
disabled
=
true
;
}
else
{
a
.
disabled
=
false
;
}
})
return
apiList
.
value
;
}
/** 基本信息的入参定义表格配置 */
const
productTableInfo
=
ref
({
id
:
"input-product-table"
,
...
...
@@ -713,11 +702,9 @@ const productTableInfo = ref({
fields
:
[
{
label
:
"序号"
,
type
:
"index"
,
width
:
TableColumnWidth
.
INDEX
,
align
:
"center"
},
{
label
:
"服务名称"
,
field
:
"apiGuid"
,
width
:
180
,
required
:
true
,
columClass
:
'edit-colum'
,
type
:
'edit'
},
{
label
:
"API类型"
,
field
:
"apiType"
,
width
:
100
,
getName
:
(
scope
)
=>
{
{
label
:
"API类型"
,
field
:
"apiType"
,
width
:
100
,
getName
:
(
scope
)
=>
{
return
scope
.
row
.
apiType
&&
apiTypes
.
find
(
a
=>
a
.
value
==
scope
.
row
.
apiType
)?.
label
||
'--'
;
}
},
}
},
{
label
:
"API地址"
,
field
:
"requestUrl"
,
minWidth
:
240
},
{
label
:
"描述"
,
field
:
"apiDescription"
,
width
:
300
},
],
...
...
@@ -727,14 +714,14 @@ const productTableInfo = ref({
type
:
'select'
,
field
:
'apiGuid'
,
default
:
''
,
getOptions
:
(
scope
)
=>
getAPIOptions
(
scope
)
,
options
:
apiList
.
value
,
props
:
{
label
:
'apiName'
,
value
:
'guid'
,
disabled
:
'disabled'
},
placeholder
:
'请选择'
,
clearable
:
tru
e
,
clearable
:
fals
e
,
filterable
:
true
},
},
...
...
@@ -805,7 +792,7 @@ onActivated(() => {
getValidApi
().
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
apiList
.
value
=
res
.
data
||
[];
// productTableInfo.value.editInfo.apiGuid.getOptions = (scope) => getAPIOptions(scope)
;
productTableInfo
.
value
.
editInfo
.
apiGuid
.
options
=
apiList
.
value
;
}
else
{
proxy
.
$ElMessage
.
error
(
res
.
msg
);
}
...
...
@@ -851,7 +838,7 @@ onBeforeMount(() => {
item
.
default
=
''
;
if
(
item
.
children
?.
length
)
{
item
.
children
[
0
].
visible
=
true
;
//
item.children[0].default = [detailInfo.value.coverageArea[0]] as any;
item
.
children
[
0
].
default
=
[
detailInfo
.
value
.
coverageArea
[
0
]]
as
any
;
let
p
:
any
=
[];
detailInfo
.
value
.
coverageArea
?.
forEach
(
area
=>
{
if
(
p
.
includes
(
area
[
0
]))
{
...
...
@@ -894,7 +881,7 @@ onBeforeMount(() => {
baseInfoFormRules
.
value
.
damName
[
1
]
=
checkExistName
(
checkedInfo
.
value
,
existDamName
,
detailInfo
.
value
,
'damName'
);
})
setTimeout
(()
=>
{
baseInfoFormRef
.
value
.
ruleFormRef
?
.
clearValidate
([
'sceneDescription'
,
'subjectDomain'
,
'coverageAreas'
,
'isPublicData'
,
'dataSources'
,
'propertyDescription'
,
'sceneLimit'
]);
baseInfoFormRef
.
value
.
ruleFormRef
.
clearValidate
([
'sceneDescription'
,
'subjectDomain'
,
'coverageAreas'
,
'isPublicData'
,
'dataSources'
,
'propertyDescription'
,
'sceneLimit'
]);
},
0
);
assetDataTableInfo
.
value
.
data
=
detailInfo
.
value
.
damCatalogTableInfo
;
productData
.
value
=
detailInfo
.
value
.
associationApiInfo
?.
map
(
d
=>
{
...
...
@@ -1234,17 +1221,16 @@ const handleImportSave = (val) => {
<Form
ref=
"baseInfoFormRef"
:itemList=
"baseInfoFormItems"
formId=
"base-info-form"
:rules=
"baseInfoFormRules"
@
selectChange=
"baseSelectChange"
@
checkboxChange=
"handleBaseInfoCheckboxChange"
col=
"col3"
/>
</ContentWrap>
<ContentWrap
v-if=
"baseInfoFormRef?.formInline?.damType == '2'"
id=
"product-info"
title=
"服务包信息"
expandSwicth
style=
"margin-top: 15px"
:isExpand=
"expandServiceInfo"
@
expand=
"(v) => (expandServiceInfo = v)"
description=
""
class=
"mb16"
>
<ContentWrap
v-if=
"baseInfoFormRef?.formInline?.damType == '2'"
id=
"product-info"
title=
"服务包信息"
expandSwicth
style=
"margin-top: 15px"
:isExpand=
"expandServiceInfo"
@
expand=
"(v) => (expandServiceInfo = v)"
description=
""
class=
"mb16"
>
<Table
ref=
"productTableRef"
:tableInfo=
"productTableInfo"
class=
"fiveRow-table"
@
table-select-change=
"hanldeTableSelectChange"
/>
<div
class=
"row-add-btn"
>
<el-button
:disabled=
"productData.length >= apiList.length"
link
@
click=
"addProduct"
:icon=
"CirclePlus"
v-preReClick
>
添加服务
</el-button>
<el-button
link
@
click=
"addProduct"
:icon=
"CirclePlus"
v-preReClick
>
添加服务
</el-button>
</div>
</ContentWrap>
<ContentWrap
v-if=
"baseInfoFormRef?.formInline?.damType != '2'"
id=
"id-tableInfo"
title=
"资源表"
description=
""
:expand-swicth=
"true"
:isExpand=
"assetTableInfoExpand"
@
expand=
"(v) => assetTableInfoExpand = v"
>
<ContentWrap
v-if=
"baseInfoFormRef?.formInline?.damType != '2'"
id=
"id-tableInfo"
title=
"资源表"
description=
""
:expand-swicth=
"true"
:isExpand=
"assetTableInfoExpand"
@
expand=
"(v) => assetTableInfoExpand = v"
>
<div
v-show=
"assetDataTableInfo.data.length"
class=
"tools_btns"
>
<el-button
type=
"primary"
@
click=
"handleCreateTable"
v-preReClick
>
添加
</el-button>
</div>
...
...
@@ -1330,4 +1316,5 @@ const handleImportSave = (val) => {
}
}
}
</
style
>
...
...
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