I follow this Tutorials ” https://tutorials.autodesk.io/tutorials/dashboard/grid ”
I have done all of activities and I tried it out.
The “Data Grid” shows all of models data.
But I want to show only “isolation has changed items dbids” (by clicking or filtering).
of course, incase without selection, I do not want to show only selection but all.
I think update method should be changed on “DataGridPanel.js”.
But I am not sure. please help me
Regards,
/DataGridPanel.js
pdate(model, dbids) {
model.getBulkProperties(dbids, { propFilter: DATAGRID_CONFIG.requiredProps }, (results) => {
this.table.replaceData(results.map((result) => DATAGRID_CONFIG.createRow(result.dbId, result.name, result.properties)));
}, (err) => {
console.error(err);
});
}
/DataGridExtension.js
onModelLoaded(model) {
super.onModelLoaded(model);
if (this._panel && this._panel.isVisible()) {
this.update();
}
}
async update() {
const dbids = await this.findLeafNodes(this.viewer.model);
this._panel.update(this.viewer.model, dbids);
}