v7.3.0
SupportExamplesFree Trial

Dependencies
Feature

Extends the Scheduler's Dependencies feature to integrate with the Scheduler Pro scheduling engine. It renders dependency lines between events and supports interactive creation of new dependencies by dragging from one event's dependency terminal to another. All dependency creation and modification operations are wrapped in project transactions, ensuring that the scheduling engine processes the changes atomically and can revert them if needed.

This feature is enabled by default.

const schedulerPro = new SchedulerPro({
    features : {
        dependencies : {
            radius                            : 5,
            highlightDependenciesOnEventHover : true
        }
    }
});

See also

No results

Configs

Configs are options you supply in a configuration object when creating an instance of this class
  • baseCls : Stringb-sch-dependency
    private
    Dependencies

    The CSS class applied to dependency lines

  • The clickable/touchable width of the dependency line in pixels. Draws an invisible but wider line along the same path as each dependency, making lines much easier to click and tap on touch devices. The tradeoff is that twice as many SVG lines will be drawn, which can affect performance with many visible dependencies. Set to null to disable the wider hit area and only use the visible line width.

    Has a corresponding runtime clickWidth property.

  • Specify false to prevent dependencies from being redrawn during event interaction, such as dragging, resizing or rescheduling through other means, including when events animate into place. This makes interaction smoother, but dependency lines will not be updated until the interaction is finished.

    Has a corresponding runtime drawOnEventInteraction property.

  • Specify false to prevent dependencies from being drawn during scroll, for smoother scrolling in schedules with lots of dependencies. Dependencies will be drawn when scrolling stops instead.

    Has a corresponding runtime drawOnScroll property.

  • Specify false to not enable simple deletion of dependencies by clicking on them.

    Has a corresponding runtime enableDelete property.

  • Specify true to highlight incoming and outgoing dependencies when hovering an event.

    Has a corresponding runtime highlightDependenciesOnEventHover property.

  • noMarkerCls : Stringb-sch-dependency-markerless
    private
    Dependencies

    The CSS class applied to a too narrow dependency line (to hide markers)

  • overCls : Stringb-sch-dependency-over
    private
    Dependencies

    The CSS class to add to a dependency line when hovering over it

  • removeIconCls : Stringb-icon b-icon-remove-circle
    Dependencies

    The CSS class representing a delete icon shown when clicking a dependency line

  • Set to false to not allow creating dependencies

  • Set it to true to allow dependency creation only for parent events (only applies to Scheduler Pro using the NestedEvents feature). Normally the nested event container inside parent events cannot be scrolled when using dependencies, but by enabling this setting and limiting to where dependencies can be drawn scrolling will be enabled.

  • false to require a drop on a target event bar side circle to define the dependency type. If dropped on the event bar, the defaultValue of the DependencyModel type field will be used to determine the target task side.

    Has a corresponding runtime allowDropOnEventBar property.

  • A tooltip config object that will be applied to the dependency creation Tooltip

  • false to not show a tooltip while creating a dependency

  • CSS class used for terminals

  • Where (on event bar edges) to display terminals. The sides are 'start', 'top', 'end' and 'bottom'

  • Set to true to show a tooltip when hovering a dependency line

    Has a corresponding runtime showTooltip property.

  • A tooltip config object that will be applied to the dependency hover tooltip. Can be used to for example customize delay

  • Set to true to show the lag in the tooltip

  • Internal listeners, that cannot be removed by the user.

  • The widget which this plugin is to attach to.

    Has a corresponding runtime client property.

  • Set to false to disable localization of this object.

Properties

Properties are getters/setters or publicly accessible variables on this class
  • isDelayable : Booleantrue
    READONLY
    static
    ADVANCED
    Delayable
    Identifies an object as an instance of Delayable class, or subclass thereof.
  • isDependencies : Booleantrue
    READONLY
    static
    ADVANCED
    Identifies an object as an instance of Dependencies class, or subclass thereof.
  • isDependencyCreation : Booleantrue
    READONLY
    static
    ADVANCED
    DependencyCreation
    Identifies an object as an instance of DependencyCreation class, or subclass thereof.
  • isDependencyTooltip : Booleantrue
    READONLY
    static
    ADVANCED
    DependencyTooltip
    Identifies an object as an instance of DependencyTooltip class, or subclass thereof.
  • isEvents : Booleantrue
    READONLY
    static
    ADVANCED
    Events
    Identifies an object as an instance of Events class, or subclass thereof.
  • isLocalizable : Booleantrue
    READONLY
    static
    ADVANCED
    Localizable
    Identifies an object as an instance of Localizable class, or subclass thereof.
  • properties : Object
    internal
    static
    Dependencies

    A class property getter for the default values of internal properties for this class.

  • emptyArray : Array
    internal
    READONLY
    Dependencies

    An empty array that can be used as a default value.

  • emptyObject : Object
    internal
    READONLY
    Dependencies

    An empty object that can be used as a default value.

  • isDependencies : Booleantrue
    READONLY
    ADVANCED
    Identifies an object as an instance of Dependencies class, or subclass thereof.
  • isInstancePlugin : Booleantrue
    READONLY
    ADVANCED
    Dependencies
    Identifies an object as an instance of InstancePlugin class, or subclass thereof.
  • The clickable/touchable width of the dependency line in pixels. Draws an invisible but wider line along the same path as each dependency, making lines much easier to click and tap on touch devices. The tradeoff is that twice as many SVG lines will be drawn, which can affect performance with many visible dependencies. Set to null to disable the wider hit area and only use the visible line width.

    Has a corresponding clickWidth config.

  • Specify false to prevent dependencies from being redrawn during event interaction, such as dragging, resizing or rescheduling through other means, including when events animate into place. This makes interaction smoother, but dependency lines will not be updated until the interaction is finished.

    Has a corresponding drawOnEventInteraction config.

  • Specify false to prevent dependencies from being drawn during scroll, for smoother scrolling in schedules with lots of dependencies. Dependencies will be drawn when scrolling stops instead.

    Has a corresponding drawOnScroll config.

  • Specify false to not enable simple deletion of dependencies by clicking on them.

    Has a corresponding enableDelete config.

  • Specify true to highlight incoming and outgoing dependencies when hovering an event.

    Has a corresponding highlightDependenciesOnEventHover config.

  • false to require a drop on a target event bar side circle to define the dependency type. If dropped on the event bar, the defaultValue of the DependencyModel type field will be used to determine the target task side.

    Has a corresponding allowDropOnEventBar config.

  • A template function that will be called to generate the HTML contents of the dependency creation tooltip. You can return either an HTML string or a DomConfig object.

    Has a corresponding creationTooltipTemplate config.

  • Set to true to show a tooltip when hovering a dependency line

    Has a corresponding showTooltip config.

  • A template function allowing you to configure the contents of the tooltip shown when hovering a dependency line. You can return either an HTML string or a DomConfig object.

    Has a corresponding tooltipTemplate config.

  • config : Object
    READONLY
    ADVANCED
    Dependencies

    Returns a copy of the full configuration which was used to configure this object.

  • isConstructing : Boolean
    READONLY
    ADVANCED
    Dependencies

    This property is set to true before the constructor returns.

  • isDestroying : Boolean
    READONLY
    ADVANCED
    Dependencies

    This property is set to true on entry to the destroy method. It remains on the objects after returning from destroy(). If isDestroyed is true, this property will also be true, so there is no need to test for both (for example, comp.isDestroying || comp.isDestroyed).

  • client : Widget
    READONLY
    ADVANCED
    Dependencies

    The Widget which was passed into the constructor, which is the Widget we are providing extra services for.

    Has a corresponding client config.

  • Get the global LocaleHelper

  • Get the global LocaleManager

Functions

Functions are methods available for calling on the class
  • onClassMixedIn( )
    internal
    static
    Dependencies

    This optional class method is called when a class is mixed in using the mixin() method.

  • initClass( )
    static
    ADVANCED
    Dependencies

    Registers this class type with its Factory

  • Deselects the dependency record

  • Redraws dependencies on the next animation frame

  • Aborts dependency creation, removes proxy and cleans up listeners

  • Creates a connector line that visualizes dependency source & target

  • Create a new dependency from source terminal to target terminal

  • Update connector line showing dependency between source and target when mouse moves. Also check if mouse is over a valid target terminal

  • Create a new dependency if mouse release over valid terminal. Hides connector

  • Remove hover styling when mouse leaves terminal. Also hides terminals when mouse leaves one it and not creating a dependency.

  • Start creating a dependency when mouse is pressed over terminal

  • Show terminals when mouse enters event/task element

  • Hide terminals when mouse leaves event/task element

  • Update dependency creation tooltip

  • Remove connector

  • Internal function used to hook destroy() calls when using thisObj

  • Internal function used restore hooked destroy() calls when using thisObj

  • doDestroy( )
    internal
    Events

    Auto detaches listeners registered from start, if set as detachable

  • once( )
    private
    Events

    Internal function used to run a callback function after an event is triggered

  • Removes all listeners registered to this object by the application.

  • This will merge a feature's (subclass of InstancePlugin) keyMap with it's client's keyMap.

Events

Events are triggered for certain actions in this class and can be listened for to react to those actions in your code
  • Fired when dependencies are rendered

    Note that this event is triggered on the owning widget:

Event handlers

Event handlers are callbacks called as a result of certain actions in this class

CSS variables

CSS variables that can be set to adjust appearance
Name Description
--b-inactive-dependency-stroke-array Inactive dependency stroke array (SVG)
id: dependencies

Source path

SchedulerPro/feature/Dependencies.js

Contents