Premium support for our pure JavaScript UI components


Post by belms »

Hi Team,

We are facing an issue where filters are not getting applied in the case of revisions.
In the revisions example,

  1. Import filterBar and enable filters
    features: {
          taskCopyPaste: true,
          // EventSegments feature is not yet supported with revisions
          eventSegments: false,
          filterBar: {
            keyStrokeFilterDelay: 100,
          },
        },
  2. Edit a task from the filtered list of tasks
  3. On save of the dialog (second time) observe that filter is not applied

Recreation video
https://www.awesomescreenshot.com/video/39717280?key=f05808fb39dec34da3381027ba99330a


Post by marcio »

Hey belms,

Thanks for reaching out.

In the video, I see you editing the notes fields (last tab of the editor) instead of the name field (present on the first tab). What are the expectations here? If you edit the name field, does it still not filter the task?

Best regards,
Márcio

How to ask for help? Please read our Support Policy


Post by tasnim »

Sounds like you need https://bryntum.com/products/gantt/docs/api/Gantt/data/TaskStore#config-reapplyFilterOnUpdate to be enabled.

project : {
	taskStore : {
		reapplyFilterOnUpdate : true
	}
}

Please let us know if that helps :)

Best regards,
Tasnim

How to ask for help? Please read our Support Policy


Post by belms »

Hi marcio and tasnim,

When i edit name inline (ie without opening the edit modal) the filter is retained after edit
But if i edit by opening the edit task modal , any field be it name or notes we can see that filter is not retained

I have tried by adding reapplyFilterOnUpdate: true, it does not work

This is very specific to opening edit modal and editing.

Please let us know in case any overrides are possible

Attaching file

Attachments
real-time-updates-app.js
(6.43 KiB) Downloaded 6 times

Post by tasnim »

I'm still not able to reproduce the issue. Are you able to reproduce it here https://bryntum.com/products/gantt/examples/basic/?
Could you share a reproduction video based on this demo https://bryntum.com/products/gantt/examples/basic/ ?

Best regards,
Tasnim

How to ask for help? Please read our Support Policy


Post by belms »

Hi Tasnim

we use revisions

could you please replace the app.js i have attached in real time updates example and ten try reproducing this?

Its very easily reproducible

Attachments
revisions.mov
(11.66 MiB) Downloaded 3 times

Post by belms »

There seems to be some issue between sorting and filtering
From what i have tried out if i remove

reapplySortersOnAdd: true,

then itseems to work fine
but we need both sorting and filtering along with revisions to work


Post by belms »

Hi Tasnim,

was able to recreate this in basic example

Code changes -

import { Gantt, StringHelper } from '../../build/gantt.module.js?484833';
import shared from '../_shared/shared.module.js?484833';

new Gantt({
    appendTo          : 'container',
    dependencyIdField : 'sequenceNumber',
    rowHeight         : 45,
    tickSize          : 45,
    barMargin         : 8,
    features:{
        filter:true
    },
    project           : {
        autoLoad           : true,
        loadUrl            : '../_datasets/launch-saas.json',
        autoSetConstraints : true ,// automatically introduce `startnoearlier` constraint if tasks do not use constraints, dependencies, or manuallyScheduled
            taskStore          : {
            expandWhenNewParent: true,
            sorters: [
                {
                    field: 'wbsValue',
                    ascending: true,
                },
            ],
            useOrderedTreeForWbs: true,
            wbsMode: 'auto',
            outdentIgnoringSiblings: true,
            forceWbsOrderForChanges: true,
            reapplySortersOnAdd: true,
            reapplyFilterOnUpdate: true,
            applyChangesetFilterSortTarget: 'changes',
        },
    },

columns : [
    { type : 'name', width : 250 }
],

// Custom task content, display task name on child tasks
taskRenderer({ taskRecord }) {
    if (taskRecord.isLeaf && !taskRecord.isMilestone) {
        return StringHelper.encodeHtml(taskRecord.name);
    }
}
});
Attachments
Basic.mov
(20.09 MiB) Downloaded 5 times

Post by alex.l »

Hi belms,

Thank you for the clear test case, confirmed a bug https://github.com/bryntum/support/issues/11332
You can subscribe on ticket updates to be notified when it's done.

All the best,
Alex Lazarev

How to ask for help? Please read our Support Policy

We do not write the code in bounds of forum support. If you need help with development, contact us via bryntum.com/services


Post Reply