Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Can i create Custom JSON and render in BPMN Diagram? (Read 207 times)
Avinash
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 12
Joined: Nov 12th, 2024
Can i create Custom JSON and render in BPMN Diagram?
Nov 13th, 2024 at 8:42am
Print Post  
When i create a simple Diagram and generate JSON of it, It seems pretty large. Which i cannot create that kind of JSON to render it back.

I have some data with links between them, From that data i want to create a simple JSON and render in BPMN Diagram.

Thanks in advance.

  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Online


tech.support

Posts: 3323
Joined: Oct 19th, 2005
Re: Can i create Custom JSON and render in BPMN Diagram?
Reply #1 - Nov 13th, 2024 at 10:08am
Print Post  
The diagram has toJson and fromJson methods you could call. If you mean their result is too large, you could devise a simple format and load from it as shown in tutorial:

https://www.mindfusion.eu/onlinehelp/jsdiagram/CC_Tutorial_1__Loading_Graph_Data...

Saving could be done by looping over the diagram's nodes and links, creating corresponding node or link objects in same format, and calling JSON.stringify. Let me know if you need sample code for that.

Regards,
Slavcho
Mindfusion
  
Back to top
 
IP Logged
 
Avinash
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 12
Joined: Nov 12th, 2024
Re: Can i create Custom JSON and render in BPMN Diagram?
Reply #2 - Nov 13th, 2024 at 10:34am
Print Post  
Thank You Slavcho,

I'll go through

Regards,
Avinash
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint