Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

节点使用updateCellId更新了id触发了graph.on('cell:removed', ({ cell, index, options }) => {} 事件 然后连接的线没了 #3995

Open
yxj1124 opened this issue Oct 27, 2023 · 2 comments
Labels
resolution: needs demos 需要复现 Issues that need minimal demos to reproduce any problems

Comments

@yxj1124
Copy link

yxj1124 commented Oct 27, 2023

问题描述

节点使用了updateCellId更新了id 触发了graph.on('cell:removed', ({ cell, index, options }) => {} 事件 然后连接的线没了

重现链接

重现步骤

1.使用diagram.updateCellId更新节点ID
diagram.updateCellId(cell, nodeId)
2. 触发了cell:removed事件,
graph.on('cell:removed', ({ cell, index, options }) => {}
3.节点链接的线消失了

预期行为

希望更新节点id时,线不会消失

平台

  • 操作系统: [macOS, Windows, Linux, React Native ...]
  • 网页浏览器: [Google Chrome, Safari, Firefox ...]
  • X6 版本: [2.11.1 ...]

屏幕截图或视频(可选)

No response

补充说明(可选)

根据接口返回的业务id,更新到节点id,跟业务关联

@lloydzhou
Copy link
Contributor

节点id换了,线没了算是正常的行为吧?

@NewByVector
Copy link
Contributor

能否提供一个可以复现的 codesanbox 链接?

@NewByVector NewByVector added the resolution: needs demos 需要复现 Issues that need minimal demos to reproduce any problems label Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
resolution: needs demos 需要复现 Issues that need minimal demos to reproduce any problems
Projects
None yet
Development

No branches or pull requests

3 participants