View Issue Details

IDProjectCategoryView StatusLast Update
0004064JEDI VCL00 JVCL Componentspublic2007-06-19 07:42
ReportermartinalexAssigned Toobones 
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product VersionDaily / GIT 
Target VersionFixed in Version3.34 
Summary0004064: JvDBTreeView, 4 bugs; Add Node IconField; unique MasterField; delete childs; drag&drop
DescriptionI use JvDBTreeView for a Delphi project. While using it I have found and fixed 4 bugs. See attached source.

1) Add Node, IconField, value set, same value as parent
IconField was not populated during node creation, resulting in a node without icon

2) Add Node, MasterField, unique value ensured
Current routine counts the records and adds 1 for the next node MasterField. This does not work when nodes in between have been deleted. Unique key violation.
The record count is used as a start value for a loop to find the first unused MasterField value.

3) Delete node, delete records for all childs
Only the selected record was deleted on the database, but not records from child nodes. The child nodes were not visible since the MasterField – DetailField connection was lost, but the child records were still on the database. Rekursive child deletion added.

4) Drag&drop, move node only for node drop, not for drop of other objects
Drop to the tree and within the tree have to be handled separately. Otherwise drop distorts tree.


 
Additional InformationI have added 3 additional properties with I need for my project (www.bookpiles.org). I can make the source avalable, if wanted, but it's not included in this fix. The additional properties are:
- InfoField,
  Additional text for tree nodes, stored in additional db column, can be used to show counters for each node like in Outlook
- UseInfo, switch to use InfoField
- ResevedNodes, I need a reserved number range for node id's. So that I can add nodes with given id's later

TagsNo tags attached.

Activities

2007-02-13 15:02

 

JvDBTreeView-fix4.pas (44,671 bytes)

obones

2007-06-19 07:42

administrator   ~0013446

Your changes are now in SVN. For the rest of your proposition, I'm afraid this is too specific to your use case and might have bad consequences for regular users.

Issue History

Date Modified Username Field Change
2007-02-13 15:02 martinalex New Issue
2007-02-13 15:02 martinalex File Added: JvDBTreeView-fix4.pas
2007-06-19 07:42 obones Status new => resolved
2007-06-19 07:42 obones Fixed in Version => Daily / SVN
2007-06-19 07:42 obones Resolution open => fixed
2007-06-19 07:42 obones Assigned To => obones
2007-06-19 07:42 obones Note Added: 0013446