fix: 反引号+data架构同步+因果链推荐
This commit is contained in:
@@ -988,7 +988,7 @@ async function showCausalityRecommendations() {
|
|||||||
|
|
||||||
async function applyCausality(rec: any) {
|
async function applyCausality(rec: any) {
|
||||||
try {
|
try {
|
||||||
await api.post(\\`/maps/\\${currentMap.value?.id}/connections\\`, { from: rec.source_kpi_code, to: rec.target_kpi_code })
|
await api.post(`/maps/${currentMap.value?.id}/connections`, { from: rec.source_kpi_code, to: rec.target_kpi_code })
|
||||||
ElMessage.success('连线已添加')
|
ElMessage.success('连线已添加')
|
||||||
showCausalityDialog.value = false
|
showCausalityDialog.value = false
|
||||||
loadMap()
|
loadMap()
|
||||||
@@ -999,11 +999,11 @@ async function applyAllCausality() {
|
|||||||
let added = 0
|
let added = 0
|
||||||
for (const rec of causalityRecommendations.value) {
|
for (const rec of causalityRecommendations.value) {
|
||||||
try {
|
try {
|
||||||
await api.post(\\`/maps/\\${currentMap.value?.id}/connections\\`, { from: rec.source_kpi_code, to: rec.target_kpi_code })
|
await api.post(`/maps/${currentMap.value?.id}/connections`, { from: rec.source_kpi_code, to: rec.target_kpi_code })
|
||||||
added++
|
added++
|
||||||
} catch {}
|
} catch {}
|
||||||
}
|
}
|
||||||
ElMessage.success(\\`已添加 \\${added}/\\${causalityRecommendations.value.length} 条因果链\\`)
|
ElMessage.success(`已添加 ${added}/${causalityRecommendations.value.length} 条因果链`)
|
||||||
showCausalityDialog.value = false
|
showCausalityDialog.value = false
|
||||||
loadMap()
|
loadMap()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user