Example of Context Menu in React Gantt Component

/
/
ContextMenuItem

This sample demonstrates the various phases involved in constructing a residential house, from testing the soil to handing over the fully constructed property to the owner. This also demonstrates the usage of default and custom context menu in Gantt component.

More Details...

1
Project initiation
Apr 02, 20244 days0
2
Identify site location
Apr 02, 20240 days30
3
Perform Soil test
Apr 02, 20244 days02FS
4
Soil test approval
Apr 05, 20240 days303FS
5
Project estimation
Apr 08, 20246 days15
6
Develop floor plan for estimation
Apr 08, 20243 days304FS
7
List materials
Apr 11, 20243 days06FS
8
Estimation approval
Apr 15, 20240 days07FS
9
Sign contract
Apr 16, 20241 day308FS
10
Project approval and kick off
Apr 16, 20240 days09FS
11
Site work
Apr 17, 20244 days15
12
Clear the building site
Apr 17, 20242 days309FS
13
Install temporary power service
Apr 19, 20242 days012FS
14
Foundation
Apr 23, 202412 days23
15
Excavate for foundations
Apr 23, 20243 days3013FS
16
Dig footer
Apr 24, 20242 days015FF
17
Install plumbing grounds
Apr 26, 20244 days3015FS
18
Pour a foundation and footer with concrete
May 02, 20241 day017FS
19
Cure basement walls
May 03, 20244 days3018FS
20
Framing
May 09, 202412 days20
21
Add load-bearing structure
May 09, 20243 days3019FS
22
Install floor joists
May 14, 20243 days021FS
23
Add ceiling joists
May 14, 20243 days3022SS
24
Install subfloor panels
May 17, 20243 days023FS
25
Frame floor walls
May 22, 20243 days3024FS
26
Frame floor decking
May 22, 20243 days3025SS
27
Exterior finishing
May 27, 20249 days15
28
Cover outer walls and roof in OSB
May 27, 20243 days3026FS
29
Add water resistive barrier
May 30, 20243 days028FS
30
Install roof shingles
Jun 04, 20243 days3029FS
31
Install windows
Jun 04, 20243 days029FS
32
Utilities
May 27, 202412 days18
33
Install internal plumbing
May 27, 20243 days3026FS
34
Install HVAC
May 30, 20243 days033FS
35
Electrical utilities
Jun 04, 20243 days3034FS
36
Natural gas utilities
Jun 07, 20243 days035FS
37
Install bathroom fixtures
Jun 07, 20243 days3035FS
38
Interior finsihing
Jun 12, 202418 days20
39
Install insulation
Jun 12, 20243 days3037FS
40
Install drywall panels
Jun 17, 20243 days039FS
41
Spackle
Jun 20, 20243 days3040FS
42
Apply primer
Jun 25, 20243 days041FS
43
Paint wall and ceilings
Jun 28, 20243 days3042FS
44
Install modular kitchen
Jul 03, 20243 days3043FS
45
Flooring
Jul 08, 20243 days15
46
Tile kitchen, bathroom and entry walls
Jul 08, 20243 days3044FS
47
Tile floor
Jul 08, 20243 days046SS
48
Final Acceptance
Jul 11, 20244 days15
49
Final inspection
Jul 11, 20242 days3047FS
50
Cleanup for occupancy
Jul 15, 20242 days049FS
51
Property handover
Jul 16, 20240 days050FS
Project initiation
Identify site location
Martin Tamer
Perform Soil test
Rose Fuller , Margaret Buchanan , Davolio Fuller
Soil test approval
Project estimation
Develop floor plan for estimation
List materials
Fuller King , Jack Davolio
Estimation approval
Construction Supervisor , Davolio Fuller
Sign contract
Construction Supervisor
Project approval and kick off
Site work
Clear the building site
Van Jack , Fuller Buchanan
Install temporary power service
Van Jack , Fuller Buchanan
Foundation
Excavate for foundations
Rose Fuller , Jack Davolio
Dig footer
Jack Davolio
Install plumbing grounds
Tamer Vinet
Pour a foundation and footer with concrete
Jack Davolio , Tamer Vinet , Vinet Fuller
Cure basement walls
Vinet Fuller
Framing
Add load-bearing structure
Fuller King , Davolio Fuller
Install floor joists
Rose Fuller , Margaret Buchanan
Add ceiling joists
Davolio Fuller
Install subfloor panels
Jack Davolio , Tamer Vinet
Frame floor walls
Vinet Fuller
Frame floor decking
Fuller King , Jack Davolio
Exterior finishing
Cover outer walls and roof in OSB
Rose Fuller , Jack Davolio
Add water resistive barrier
Martin Tamer , Vinet Fuller
Install roof shingles
Jack Davolio , Tamer Vinet
Install windows
Utilities
Install internal plumbing
Martin Tamer , Vinet Fuller
Install HVAC
Fuller King , Tamer Vinet
Electrical utilities
Natural gas utilities
Install bathroom fixtures
Margaret Buchanan , Fuller Buchanan
Interior finsihing
Install insulation
Martin Tamer , Jack Davolio
Install drywall panels
Spackle
Apply primer
Vinet Fuller , Bergs Anton
Paint wall and ceilings
Rose Fuller , Tamer Vinet
Install modular kitchen
Davolio Fuller , Fuller Buchanan
Flooring
Tile kitchen, bathroom and entry walls
Fuller King , Tamer Vinet , Margaret Buchanan
Tile floor
Rose Fuller , Jack Davolio
Final Acceptance
Final inspection
Cleanup for occupancy
Martin Tamer , Davolio Fuller
Property handover
Project approval and kick-off
Foundation inspection
Site manager inspection
Property handover and sign-off
Description

Gantt has an option to show the context menu while performing right click on it. You can configure the default and custom menu items in the context menu using the contextMenuItems property. Each menu item will be displayed contextually based on its target. In this demo we have rendered following default and custom menu items

Default items:

  • AutoFitAll - Auto fit all columns.
  • AutoFit - Auto fit the current column.
  • TaskInformation - Edit the current record.
  • Indent - Indent the selected record to one level
  • Outdent - Outdent the selected record to one level
  • DeleteTask - Delete the current record.
  • Save - Save the edited record.
  • Cancel - Cancel the edited state.
  • SortAscending - Sort the current column in ascending order.
  • SortDescending - Sort the current column in descending order.
  • DeleteDependency - Delete the dependency of the current record.
  • Convert - Convert the normal task in to milestone task and vice versa.
  • Add
    • Above - Add a new row above the selected row
    • Below - Add a new row below the selected row
    • Child - Add a new row as child to the selected row
    • Milestone - Add a milestone task below to selected row

Custom items:

In this demo, custom menu items have been enabled in the context menu to perform expanding and collapsing the parent rows,

  • Expand the Row - Used to expand the parent row and it will render where the row is in a collapsed state.
  • Collapse the Row - Used to collapse the parent row and it will render where the row is in a expanded state.
  • To use context menu feature, we need to inject ContextMenu module into the services.