Hi there,
I'm currently testing SmartClient_v100p_2015-04-27_Pro, and I found a visual bug using paged TreeGrids.
Sorry for reporting another paged-treegrid related issue.
I'm trying to use all features of the treegrid, so now in order to reduce the count of the datasource-requests the datasource can also return open nodes and the children of the nodes simultaneously. The code example below and the used datasource are only for reproducibility. It isn't our real backend, but it does the job to report the issues, which I have detected using the paged-datasource in our application.
To not interfere with the bugfixing of the other thread i have copied the datasource, to enable the "canReturnOpenSubfolder"-feature combined with the childCount.
What the example does:
It returns for the root-node all childNodes with all their childNodes.
Using a paged TeeGrid also the childCount-property is set for each node.
In the initial-server-respone there are all "root-x" and their child-nodes "root-x-y" returned. The nodes "root-x-y" have the childCount-Property set, so the tree does already know how many childnodes will be gathered by the datasource, if the user tries to open "root-x-y".
The problem like shown below in the gif is, that opening a "root-x-y" nodes results in hiding all nodes, which are below that node. After the loading is finished and the childnodes of "root-x-y" are displayed all childnodes are displayed again.
This is not really visible if you are testing on localhost. In the example a delay in line 86 is mandatory! Increasing the delay makes the effect more visible. Because the paged TreeGrid is only used if you have a large tree, a delay while requesting the child-nodes is natural.
Because I have already set the childCount, the tree should not hide the nodes below.
It's reproducable with the latest nightly build SmartClient_v100p_2015-04-27_Pro and all current browsers (IE, Chrome, Firefox).
This is the code to reproduce:
Best Regards
I'm currently testing SmartClient_v100p_2015-04-27_Pro, and I found a visual bug using paged TreeGrids.
Sorry for reporting another paged-treegrid related issue.
I'm trying to use all features of the treegrid, so now in order to reduce the count of the datasource-requests the datasource can also return open nodes and the children of the nodes simultaneously. The code example below and the used datasource are only for reproducibility. It isn't our real backend, but it does the job to report the issues, which I have detected using the paged-datasource in our application.
To not interfere with the bugfixing of the other thread i have copied the datasource, to enable the "canReturnOpenSubfolder"-feature combined with the childCount.
What the example does:
It returns for the root-node all childNodes with all their childNodes.
Using a paged TeeGrid also the childCount-property is set for each node.
In the initial-server-respone there are all "root-x" and their child-nodes "root-x-y" returned. The nodes "root-x-y" have the childCount-Property set, so the tree does already know how many childnodes will be gathered by the datasource, if the user tries to open "root-x-y".
The problem like shown below in the gif is, that opening a "root-x-y" nodes results in hiding all nodes, which are below that node. After the loading is finished and the childnodes of "root-x-y" are displayed all childnodes are displayed again.
This is not really visible if you are testing on localhost. In the example a delay in line 86 is mandatory! Increasing the delay makes the effect more visible. Because the paged TreeGrid is only used if you have a large tree, a delay while requesting the child-nodes is natural.
Because I have already set the childCount, the tree should not hide the nodes below.
It's reproducable with the latest nightly build SmartClient_v100p_2015-04-27_Pro and all current browsers (IE, Chrome, Firefox).
This is the code to reproduce:
Code:
isc.VLayout.create({ "ID" : "rootLayout_5", "width" : "100%", "height" : "100%", "autoDraw" : true, "hideUsingDisplayNone" : false, "leaveScrollbarGap" : false, "members" : [ isc.TreeGrid.create({ "ID" : "theTreeGrid", "width" : "100%", "height" : "100%", "selectionType" : "multiple", "canEdit" : false, "showFilterEditor" : false, dataSource : isc.DataSource.create({ "fields" : [{ "name" : "treeGridGeneratedIndex", "primaryKey" : true, "hidden" : true, "canView" : false }, { "name" : "nameField", "title" : "Reason", "type" : "text" }, { "name" : "parentId", "rootValue" : "root", "foreignKey" : "treeGridGeneratedIndex", "hidden" : true } ], "dataFormat" : "json", "dataURL" : "http://devset.de/treegrid2.php", "transformRequest" : requestTransformer, "transformResponse" : responseTransformer, "recordXPath" : "\/resultData", useHttpProxy : false }), dataProperties : { openProperty : "isOpen", childrenProperty : "children", canReturnOpenFolders: true, progressiveLoading : false }, "autoFetchData" : true, "dataPageSize" : 50, "dataFetchMode" : "paged", "selectionProperty" : "isSelected", "fields" : [{ "name" : "nameField", "title" : "Reason", "type" : "text", "canEdit" : true, "canSort" : true }, { "name" : "lastField", "title" : "Name", "type" : "text", "canEdit" : true, "canSort" : true }, { "name" : "randomField", "title" : "random", "type" : "text", "canEdit" : true, "canSort" : true } ], "selectionProperty" : "isSelected", "members" : [] }) ] }); function requestTransformer(dataSourceRequest) { var operationType = { operationType : dataSourceRequest.operationType }; if (dataSourceRequest.operationType == "fetch") { var params = { delay: 300, sortBy : dataSourceRequest.sortBy, start : dataSourceRequest.startRow, end : dataSourceRequest.endRow }; } return isc.addProperties({}, operationType, dataSourceRequest.data, params); } function responseTransformer(dataSourceResponse, dataSourceRequest, jsonData) { if (dataSourceRequest.operationType == "fetch") { dataSourceResponse.totalRows = jsonData.totalRows; dataSourceResponse.endRow = jsonData.endRow; dataSourceResponse.startRow = jsonData.startRow; }; }
Comment