Premium support for our pure JavaScript UI components


Post by damir »

I was able to reproduce this issue in your demo here https://bryntum.com/products/gantt/examples/gantt-schedulerpro/

Use below code which just add autoHeight to true, and then delete all tasks apart one.

import { Splitter, WidgetHelper, Gantt, SchedulerPro, ProjectModel } from '../../build/gantt.module.js?474872';
import shared from '../_shared/shared.module.js?474872';

Array(1).fill().map(p => {
	return new ProjectModel({
		calendar : 'general',
		transport : { load : { url : Math.floor(Math.random() * 11) < 5 ? '../_datasets/launch-saas.json' : '../_datasets/tasks-workedhours.json' }},
		autoLoad : true,
		validateResponse : true
	})
}).forEach(project => {
	const gantt = new Gantt({
		project,
		tbar : [
			{ type : 'widget', html : 'Zoom:' },
			{ ref: 'zoomInButton', icon: 'b-icon-search-plus',  tooltip: 'Zoom in', onAction: () => gantt.zoomIn()},
			{ ref: 'zoomOutButton', icon: 'b-icon-search-minus', tooltip: 'Zoom out', onAction: () => gantt.zoomOut()}
		],
		resourceImageFolderPath : '../_shared/images/users/',
		appendTo                : 'container',
		features                : {
			labels : {
				left : { field  : 'name', editor : {type : 'textfield'}}
			}
		},
		viewPreset  : 'weekAndDayLetter',
		columnLines : true,
		columns : [
			{ type : 'sequence', minWidth : 50, width : 50, text : '', align : 'right', resizable : false },
			{ type : 'name', width : 280 },
			{ type : 'percent', text : '% Completed', field : 'percentDone', showValue : false, width : 160 },
			{ type : 'resourceassignment', text : 'Assigned Resources', showAvatars : true, width : 160 }
		],
		startDate : '2015-01-01',
		endDate: '2030-01-01',    
listeners : { beforeCellEditStart : ({ editorContext }) => editorContext.column.field !== 'percentDone' || editorContext.record.isLeaf }, // Added autoHeight: true, }); });
Screenshot 2024-03-25 045204.png
Screenshot 2024-03-25 045204.png (27.14 KiB) Viewed 47 times

Post by tasnim »

Thanks for the test case. We'll investigate it. Here is the ticket to track progress https://github.com/bryntum/support/issues/8870

Best regards,
Tasnim


Post Reply