auto_scheduling

启用自动排程

boolean | AutoSchedulingConfig auto_scheduling;

Available only in PRO Edition

Example

gantt.config.auto_scheduling = true;
 
gantt.init("gantt_here");


Default value:

false

Related samples

Details

此功能仅在 PRO 版本中提供。

此设置属于 auto_scheduling 扩展的一部分,因此请确保启用 auto_scheduling 插件。更多详情请参见 自动调度 文章。

auto_scheduling 选项可以是布尔值,也可以是对象,后者提供了更详细的自动排程控制。当使用对象时,可以配置以下内容:

  • enabled - (boolean) - 用于开启或关闭自动排程,功能等同于直接设置布尔值。
  • show_constraints? - (boolean) - 控制是否在甘特图中显示任务约束。 设置为 true 显示约束,设置为 false 则隐藏。

例如,开启自动排程但保持任务约束隐藏:

gantt.config.auto_scheduling = {
  enabled: true,
  show_constraints: false
};
gantt.init("gantt_here");
See also
Change log

自版本 9.0 起,此配置支持定义为对象

Back to top