맨위로가기
 

SBCHART

닫기

Gantt Options

#latest  #options

Gantt 차트 고유 옵션입니다.

Options

  • extend.ontology.xTickInterval

  • extend.gantt.yTickInterval

  • extend.gantt.planHeight

  • extend.gantt.planRadius

Example

Code

const chart = new sb.chart("#chartWrap", {
    data: {
        type: "tree",
        json: [
            {
                name: "Company",
                children: [
                    {
                        name: "Sales",
                        children: [
                            {
                                name: "Domestic Sales",
                                children: [
                                    { name: "Team A" },
                                    { name: "Team B" },
                                    { name: "Team C" }
                                ]
                            },
                            {
                                name: "International Sales",
                                children: [
                                    { name: "Team D" },
                                    { name: "Team E" }
                                ]
                            }
                        ]
                    },
                    {
                        name: "Engineering",
                        children: [
                            {
                                name: "Software",
                                children: [
                                    { name: "Frontend Team" },
                                    { name: "Backend Team" },
                                    { name: "QA Team" }
                                ]
                            },
                            {
                                name: "Hardware",
                                children: [
                                    { name: "Design Team" },
                                    { name: "Manufacturing Team" }
                                ]
                            }
                        ]
                    },
                    {
                        name: "HR",
                        children: [
                            { name: "Recruiting" },
                            { name: "Benefits" },
                            { name: "Training" }
                        ]
                    },
                    {
                        name: "Marketing",       
                        children: [
                            { name: "Product Marketing" },
                            { name: "Content Team" },
                            { name: "Social Media Team" },
                            { name: "Events Team" }
                        ]
                    },
                    {
                        name: "Finance",
                        children: [
                            { name: "Accounting" },
                            { name: "Treasury" },
                            { name: "Internal Audit" }
                        ]
                    }
                ]
            }
        ]
    },
    extend: {
        gantt: {
            xTickInterval: 30,
            yTickInterval: 40,
            planHeight: 10,
            planRadius: 10,
        }
    }
});