Search results

CrudAction

Configures the data source that is to be bound with diagram

<div id='diagram'></div>
let data: object[] = [
{ Name: "Elizabeth", Role: "Director" },
{ Name: "Christina", ReportingPerson: "Elizabeth", Role: "Manager" },
{ Name: "Yoshi", ReportingPerson: "Christina", Role: "Lead" },
{ Name: "Philip", ReportingPerson: "Christina", Role: "Lead" },
{ Name: "Yang", ReportingPerson: "Elizabeth", Role: "Manager" },
{ Name: "Roland", ReportingPerson: "Yang", Role: "Lead" },
{ Name: "Yvonne", ReportingPerson: "Yang", Role: "Lead" }
];
let items: DataManager = new DataManager(data as JSON[]);
let diagram: Diagram = new Diagram({
...
layout: {
            type: 'OrganizationalChart'
},
dataSourceSettings: {
id: 'Name', parentId: 'ReportingPerson', dataManager: items,
}
...
});
diagram.appendTo('#diagram');

Properties

create

string

set an URL to add a data into database

Defaults to

customFields

Object[]

Add custom fields to node

Defaults to undefined

destroy

string

set an URL to remove an data in database

Defaults to

read

string

set an URL to get a data from database

Defaults to

update

string

set an URL to update the existing data in database

Defaults to