Supporting tree on any custom table
Description
Environment
Attachments
blocks
relates to
Activity
Thanks for review. i see, however in ticket was not specified improvement exclude trx tables. but ok. i suggest to add improve/dynamic validation for check table for valid - fulfil same criteria as code.
new ticket:
https://idempiere.atlassian.net/browse/IDEMPIERE-3056
n
@Norbert Bede, I think you found a restriction about tables being used in a tree requires to have Name and Description columns.
I think that's ok in principle.
If you want trees for trx tables maybe would be better to open a new feature request ticket?
Regards,
Carlos Ruiz
version:3.1.0.qualifier
I have made test, and one test case failed(order/trx):
Test case 1. "Sales Order Tree" - TRX
1. Add isSummary field for c_order table
2. add isSummary column to window
3. Enable on window tab c_order has tree, and Tree Display= "BOTH"
4. Add tree entry for custom table = c_order and All Nodes=Y
Test Case 2. Charge - Base Data
repeat 1-4 use charge
Result:
1. Order - window fail tree, fail. attached screen
2. Charge - ≥ tree works, window works
LOGS

I am not able to reproduce error mentioned by Red1.
Please note that IDEMPIERE-2675_1.patch contains all changes, also correction given by Red1 in same patch.

Somehow it works with an external custom tree from Spinsuite
and not for present (Primary Organization)! Clicking on the right line gives an NPL
Jul 20, 2015 1:52:29 PM org.zkoss.zk.ui.impl.UiEngineImpl handleError
SEVERE:
java.lang.NullPointerException
at org.adempiere.webui.apps.form.WTreeMaintenance.onListSelection(WTreeMaintenance.java:352)
at org.adempiere.webui.apps.form.WTreeMaintenance.onEvent(WTreeMaintenance.java:255)
Currently tree maintenance has all hard coded trees into code based on column name.
If we want to add custom table for tree maintenance is hard. So need to improve tree to have type/Area as Table. When this area selected, system should allow to select Table on which tree can be defined.