0

我尝试了很多,但无法找到解决方案。请帮助我,因为我对这个问题感到震惊超过 1 天。任何帮助将非常感激。

我有一个Syncfusion使用.AngularVuejsejsdiagram methods

Angular我使用以下代码和相应的方法:

<ej-diagram id="diagram" e-height="80vh" e-width="100%" e-nodeCollectionChange="nodeCollectionChange" e-connectorCollectionChange="connectorCollectionChange" e-connectorTargetChange="connectorTargetChange" e-connectorSourceChange="connectorSourceChange" e-textChange="textChange"></ej-diagram>

现在我正在使用这样的东西Vuejs


<div id="app">
            <ejs-diagram
              id="diagram"
              ref="diagramObj"
              :width="width"
              :height="height"
              :collection-change="collectionChange"
              :e-connector-collection-change="connectorCollectionChange"
            />
          div>

我想知道 , 等的Vuejs等效功能e-connectorCollectionChangee-connectorTargetChange我搜索了很多但找不到任何文档,或者我错过了一些东西。有人可以指导我完成这个吗?

基本上,我想在我的Vuejs+Syncfusion应用程序中有这样的东西。我有它Angular+Syncfusion

在此处输入图像描述

4

1 回答 1

1

我们添加了示例链接来演示如何在图中添加连接器集合更改和连接器目标更改。我们可以使用集合更改事件,而不是使用连接器集合更改,该事件将在新节点或连接器添加到图表时触发。使用集合更改事件参数中的元素参数,我们可以找到连接器或节点是否被添加到图表中。有关更多信息,请参阅以下文档和下面的代码片段。

<ejs-diagram style='display:block' 
  ref="diagramObject"
  id="diagram"
  :width='width'
  :height='height'
  :nodes='nodes'
  :connectors='connectors'
  :getNodeDefaults='getNodeDefaults' 
  :getConnectorDefaults='getConnectorDefaults' 
  :collectionChange="collectionChange" 
  :sourcePointChange="sourcePointChange" 
  :targetPointChange="targetPointChange"
  :textEdit="textEdit">
</ejs-diagram>

示例链接:https ://www.syncfusion.com/downloads/support/directtrac/general/ze/Events16960811600180

文档链接:https ://ej2.syncfusion.com/vue/documentation/diagram/getting-started/

示例浏览器链接:https ://ej2.syncfusion.com/vue/demos/#/bootstrap5/diagram/diagram-events.html

于 2021-10-15T14:04:50.033 回答