How to Filter Task that has ShowInTimeLine set to true
- VinceBlood
- Posts: 7
- Joined: Tue May 03, 2016 8:20 pm
How to Filter Task that has ShowInTimeLine set to true
I'm using the Advanced Gantt Example.
I don't understand how make a filter on the ShowInTimeLine column
app/view/MainViewportController.js
This code works correctly :
This code doesn't work properly :
It seems that the TaskStore doesn't accept bolean value as entry but only text value.
A second question is how to make a FilterColumn like the example "app\filed\Filter.js". I would like to display a list of possible value "True or False".
I don't understand how make a filter on the ShowInTimeLine column
app/view/MainViewportController.js
This code works correctly :
Code: Select all
onFilterTasks : function () {
this.getGantt().taskStore.filterTreeBy(function (task) {
return task.getDuration() >= 10;
});
},
Code: Select all
onFilterTasks : function () {
this.getGantt().taskStore.filterTreeBy(function (task) {
return task.getShowInTimeline();
});
},
A second question is how to make a FilterColumn like the example "app\filed\Filter.js". I would like to display a list of possible value "True or False".
Re: How to Filter Task that has ShowInTimeLine set to true
It works fine for me in advanced demo:
As for 2nd question, please provide more details.
Code: Select all
Ext.first('ganttpanel').taskStore.filterTreeBy(function (task) {
return task.getShowInTimeline();
});
Tired of debugging javascript errors in web applications? Try our new error logging service RootCause, or read more on the Sencha blog
@bryntum
Facebook
API documentation
@bryntum
API documentation
- VinceBlood
- Posts: 7
- Joined: Tue May 03, 2016 8:20 pm
Re: How to Filter Task that has ShowInTimeLine set to true
I'm using Gantt 4.1.3, maybe there is an issue on this version ?
For the 2nd question :
I would like to change the "input field" by several option :
- a special Date filter like EXCEL to manage Date column (startdate, enddate, contraintdate). On excel when you have a date column you can apply a filter that allow you to click/unclick by year/month/day
- a list with yes/no to manage checkbox column (showtimeline)
For the 2nd question :
I would like to change the "input field" by several option :
- a special Date filter like EXCEL to manage Date column (startdate, enddate, contraintdate). On excel when you have a date column you can apply a filter that allow you to click/unclick by year/month/day
- a list with yes/no to manage checkbox column (showtimeline)
Re: How to Filter Task that has ShowInTimeLine set to true
Possibly, try upgrading to latest?
#2. Sounds like you just have to build a custom UI using the standard Ext JS classes. Look at TextField, Combo, Panel, Picker etc and you'll find all the pieces you need.
#2. Sounds like you just have to build a custom UI using the standard Ext JS classes. Look at TextField, Combo, Panel, Picker etc and you'll find all the pieces you need.
Tired of debugging javascript errors in web applications? Try our new error logging service RootCause, or read more on the Sencha blog
@bryntum
Facebook
API documentation
@bryntum
API documentation
- VinceBlood
- Posts: 7
- Joined: Tue May 03, 2016 8:20 pm
Re: How to Filter Task that has ShowInTimeLine set to true
I don't know why but now the function works !
filters columns.
I have however a two missing tasks that should appears :
The complete list : Filter by ShowInTimeLine, the Task "Commande matériel" is missing I joined the json data.
Code: Select all
return task.getShowInTimeline();
I have however a two missing tasks that should appears :
The complete list : Filter by ShowInTimeLine, the Task "Commande matériel" is missing I joined the json data.
- Attachments
-
- json_data.txt
- (74.45 KiB) Downloaded 104 times
- pmiklashevich
- Core Developer
- Posts: 3449
- Joined: Fri Apr 01, 2016 11:08 am
Re: How to Filter Task that has ShowInTimeLine set to true
Code: Select all
Ext.first('ganttpanel').taskStore.filterTreeBy({
filter : function (task) {
return task.getShowInTimeline();
},
checkParents : true
});
Pavel Miklashevich - Core Developer
- VinceBlood
- Posts: 7
- Joined: Tue May 03, 2016 8:20 pm
Re: How to Filter Task that has ShowInTimeLine set to true
Thank you very much, it works perfectly!