Merge pull request #13457 from dataease/pr@dev-v2@fix_jump
fix(仪表板、数据大屏): 修改跳转配置界面单个条件删除会串行问题
This commit is contained in:
commit
d9570036be
@ -43,6 +43,7 @@
|
||||
<result column="publicJumpId" jdbcType="VARCHAR" property="publicJumpId"/>
|
||||
<collection property="targetViewInfoList"
|
||||
ofType="io.dataease.api.visualization.vo.VisualizationLinkJumpTargetViewInfoVO">
|
||||
<result column="target_id" jdbcType="BIGINT" property="targetId"/>
|
||||
<result column="target_view_id" jdbcType="BIGINT" property="targetViewId"/>
|
||||
<result column="target_field_id" jdbcType="BIGINT" property="targetFieldId"/>
|
||||
<result column="source_field_active_id" jdbcType="VARCHAR" property="sourceFieldActiveId"/>
|
||||
@ -87,6 +88,7 @@
|
||||
xpack_share.uuid AS publicJumpId,
|
||||
ifnull( visualization_link_jump_info.checked, 0 ) AS checked,
|
||||
ifnull( visualization_link_jump_info.attach_params, 0 ) AS attach_params,
|
||||
visualization_link_jump_target_view_info.target_id,
|
||||
visualization_link_jump_target_view_info.target_view_id,
|
||||
visualization_link_jump_target_view_info.target_field_id,
|
||||
visualization_link_jump_target_view_info.target_type,
|
||||
|
||||
@ -324,7 +324,7 @@
|
||||
<el-button
|
||||
class="m-del-icon-btn"
|
||||
text
|
||||
@click="deleteLinkJumpField(index)"
|
||||
@click="deleteLinkJumpFieldById(targetViewInfo.targetId)"
|
||||
>
|
||||
<el-icon size="20px">
|
||||
<Icon name="icon_delete-trash_outlined"
|
||||
@ -442,7 +442,7 @@
|
||||
<el-button
|
||||
class="m-del-icon-btn"
|
||||
text
|
||||
@click="deleteLinkJumpField(index)"
|
||||
@click="deleteLinkJumpFieldById(targetViewInfo.targetId)"
|
||||
>
|
||||
<el-icon size="20px">
|
||||
<Icon name="icon_delete-trash_outlined"
|
||||
@ -601,6 +601,7 @@ import { useAppStoreWithOut } from '@/store/modules/app'
|
||||
import { XpackComponent } from '@/components/plugin'
|
||||
import { useCache } from '@/hooks/web/useCache'
|
||||
import { useEmbedded } from '@/store/modules/embedded'
|
||||
import { guid } from '@/views/visualized/data/dataset/form/util'
|
||||
const dvMainStore = dvMainStoreWithOut()
|
||||
const { dvInfo, canvasViewInfo, componentData } = storeToRefs(dvMainStore)
|
||||
const linkJumpInfoTree = ref(null)
|
||||
@ -909,14 +910,25 @@ const dvNodeClick = data => {
|
||||
}
|
||||
const addLinkJumpField = (type = 'view') => {
|
||||
state.linkJumpInfo.targetViewInfoList.push({
|
||||
targetId: guid(),
|
||||
targetViewId: '',
|
||||
targetType: type,
|
||||
targetFieldId: ''
|
||||
})
|
||||
}
|
||||
|
||||
const deleteLinkJumpFieldById = index => {
|
||||
state.linkJumpInfo.targetViewInfoList.splice(index, 1)
|
||||
const deleteLinkJumpFieldById = targetId => {
|
||||
if (targetId) {
|
||||
let indexResult
|
||||
state.linkJumpInfo.targetViewInfoList.forEach((item, index) => {
|
||||
if (targetId === item.targetId) {
|
||||
indexResult = index
|
||||
}
|
||||
})
|
||||
if (indexResult !== undefined) {
|
||||
state.linkJumpInfo.targetViewInfoList.splice(indexResult, 1)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const deleteLinkJumpField = index => {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user