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
96c30179
authored
2025-06-24 17:58:35 +0800
by
lxs
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
数据定价更新
1 parent
3330d91f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
31 deletions
src/views/data_pricing/priceConfig.vue
src/views/data_pricing/priceModel.vue
src/views/data_pricing/priceConfig.vue
View file @
96c3017
...
...
@@ -15,6 +15,8 @@ import { getAllFlowData } from '@/api/modules/queryService';
import
{
getConfigureList
,
deleteConfigure
,
getConfigureDetail
,
addCopyConfigure
}
from
'@/api/modules/dataPricing'
;
const
router
=
useRouter
();
...
...
@@ -95,7 +97,7 @@ const tableInfo = ref({
// 过滤
const
filterVal
=
(
val
,
name
)
=>
{
if
(
typeMap
.
value
[
name
])
{
if
(
typeMap
.
value
[
name
])
{
const
data
=
typeMap
.
value
[
name
].
find
(
item
=>
item
.
value
==
val
);
return
data
?.
label
||
'--'
;
}
...
...
@@ -172,17 +174,43 @@ const tableBtnClick = (scope, btn) => {
}
}
);
}
else
if
(
type
==
'copy'
){
//复制
router
.
push
(
{
name
:
'priceModel'
,
query
:
{
guid
:
row
.
guid
,
name
:
`
${
row
.
modelName
}
_副本`
,
type
}
else
if
(
type
==
'copy'
)
{
//复制
ElMessageBox
.
confirm
(
'是否确定复制该模型?'
,
"提示"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
'warning'
,
}).
then
(()
=>
{
getConfigureDetail
({
guid
:
row
.
guid
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
{};
let
params
=
{
...
data
};
delete
params
.
createTime
;
delete
params
.
createUserName
;
delete
params
.
pricingDimensionalityRSVOS
;
const
pricingDimensionalityRSVOS
=
data
.
pricingDimensionalityRSVOS
||
[];
pricingDimensionalityRSVOS
.
map
(
p
=>
{
p
.
pricingTargetRQVOS
=
p
.
pricingTargetRSVOS
||
[];
delete
p
.
pricingTargetRSVOS
;
});
params
.
pricingDimensionalityRQVOS
=
pricingDimensionalityRSVOS
;
addCopyConfigure
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
ElMessage
({
type
:
"success"
,
message
:
"复制定价配置成功"
,
});
getTableData
();
}
else
{
proxy
.
$ElMessage
.
error
(
res
.
msg
);
}
}).
catch
(()
=>
{
});
}
);
}).
catch
(()
=>
{
})
});
}
else
if
(
type
===
'del'
)
{
// 删除
open
(
'确定要删除该条数据吗?'
,
'warning'
);
}
...
...
src/views/data_pricing/priceModel.vue
View file @
96c3017
...
...
@@ -15,8 +15,7 @@ import {
getDemandTreeList
,
getConfigureDetail
,
saveConfigure
,
updateConfigure
,
addCopyConfigure
updateConfigure
}
from
'@/api/modules/dataPricing'
;
const
{
proxy
}
=
getCurrentInstance
()
as
any
;
...
...
@@ -28,7 +27,6 @@ const fullPath = route.fullPath;
const
userData
=
JSON
.
parse
(
localStorage
.
userData
);
const
guid
=
route
.
query
.
guid
;
const
modelName
=
route
.
query
.
name
;
const
detailType
=
route
.
query
.
type
;
const
loading
=
ref
(
false
);
const
flowDetail
:
any
=
ref
({});
...
...
@@ -794,7 +792,6 @@ const getModelDetail = () => {
getConfigureDetail
({
guid
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
{};
detailType
==
'copy'
&&
(
data
.
modelName
=
`
${
data
.
modelName
}
_副本`
);
flowDetail
.
value
=
data
;
getDataTypeList
()
}
...
...
@@ -993,22 +990,6 @@ const btnClick = async (btn, row: any = null) => {
};
if
(
guid
)
{
params
.
guid
=
guid
if
(
detailType
==
'copy'
)
{
addCopyConfigure
(
params
).
then
((
res
:
any
)
=>
{
loading
.
value
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
ElMessage
({
type
:
"success"
,
message
:
"复制定价配置成功"
,
});
toPath
()
}
else
{
proxy
.
$ElMessage
.
error
(
res
.
msg
);
}
}).
catch
(()
=>
{
loading
.
value
=
false
;
});
}
else
{
updateConfigure
(
params
).
then
((
res
:
any
)
=>
{
loading
.
value
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
...
...
@@ -1023,7 +1004,6 @@ const btnClick = async (btn, row: any = null) => {
}).
catch
(()
=>
{
loading
.
value
=
false
;
});
}
}
else
{
saveConfigure
(
params
).
then
((
res
:
any
)
=>
{
loading
.
value
=
false
;
...
...
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