[treeimpr] Added 'Node Deletion Policy' combo to 'Tree Table Category' tab
authorDavid Baz Fayos <david.baz@openbravo.com>
Wed, 30 Apr 2014 16:10:23 +0200
changeset 23063 08ecbbe06eca
parent 23062 695cedf436b3
child 23064 4f1590259dcc
[treeimpr] Added 'Node Deletion Policy' combo to 'Tree Table Category' tab
modules/org.openbravo.client.application/src/org/openbravo/client/application/event/TableTreeEventHandler.java
modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/ADTreeDatasourceService.java
modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/LinkToParentTreeDatasourceService.java
modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/TreeDatasourceService.java
src-db/database/model/tables/AD_TAB.xml
src-db/database/model/tables/AD_TABLE_TREE.xml
src-db/database/sourcedata/AD_COLUMN.xml
src-db/database/sourcedata/AD_ELEMENT.xml
src-db/database/sourcedata/AD_FIELD.xml
src-db/database/sourcedata/AD_MESSAGE.xml
src-db/database/sourcedata/AD_REFERENCE.xml
src-db/database/sourcedata/AD_REF_LIST.xml
src-db/database/sourcedata/AD_TABLE_TREE.xml
--- a/modules/org.openbravo.client.application/src/org/openbravo/client/application/event/TableTreeEventHandler.java	Tue Apr 29 09:25:17 2014 +0200
+++ b/modules/org.openbravo.client.application/src/org/openbravo/client/application/event/TableTreeEventHandler.java	Wed Apr 30 16:10:23 2014 +0200
@@ -86,7 +86,7 @@
       OBCriteria<TableTree> obq = OBDal.getInstance().createCriteria(TableTree.class);
       obq.add(Restrictions.eq(TableTree.PROPERTY_TABLE, table));
       obq.add(Restrictions.eq(TableTree.PROPERTY_TREESTRUCTURE, treeStructure));
-      if (obq.count() > 0) {
+      if (obq.count() > 1) {
         String language = OBContext.getOBContext().getLanguage().getLanguage();
         ConnectionProvider conn = new DalConnectionProvider(false);
         throw new OBException(Utility.messageBD(conn, "OBUIAPP_OneADTreePerTable", language));
--- a/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/ADTreeDatasourceService.java	Tue Apr 29 09:25:17 2014 +0200
+++ b/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/ADTreeDatasourceService.java	Wed Apr 30 16:10:23 2014 +0200
@@ -337,6 +337,7 @@
     return parentRecordId;
   }
 
+  @Override
   /**
    * Check if a node has children
    * 
@@ -348,7 +349,7 @@
    *          the where clause to be applied to the children
    * @return
    */
-  private boolean nodeHasChildren(Entity entity, String nodeId, String hqlWhereClause) {
+  protected boolean nodeHasChildren(Entity entity, String nodeId, String hqlWhereClause) {
     StringBuilder joinClause = new StringBuilder();
     joinClause.append(" as tn ");
     joinClause.append(" , " + entity.getName() + " as e ");
--- a/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/LinkToParentTreeDatasourceService.java	Tue Apr 29 09:25:17 2014 +0200
+++ b/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/LinkToParentTreeDatasourceService.java	Wed Apr 30 16:10:23 2014 +0200
@@ -320,6 +320,36 @@
     return responseData;
   }
 
+  @Override
+  /**
+   * Check if a node has children
+   * 
+   * @param entity
+   *          the entity the node belongs to
+   * @param nodeId
+   *          the id (database record id) of the node to be checked
+   * @param hqlWhereClause
+   *          the where clause to be applied to the children
+   * @return
+   */
+  protected boolean nodeHasChildren(Entity entity, String nodeId, String hqlWhereClause) {
+    BaseOBObject bob = OBDal.getInstance().get(entity.getName(), nodeId);
+
+    Table table = OBDal.getInstance().get(Table.class, entity.getTableId());
+    List<TableTree> tableTreeList = table.getADTableTreeList();
+    if (tableTreeList.size() == 0) {
+      throw new OBException("Error while determining if the node has children");
+    }
+    TableTree tableTree = tableTreeList.get(0);
+    Property linkToParentProperty = getLinkToParentProperty(tableTree);
+    Property nodeIdProperty = getNodeIdProperty(tableTree);
+
+    boolean nodeHasChilden = nodeHasChildren(entity, linkToParentProperty, nodeIdProperty, bob,
+        hqlWhereClause);
+
+    return nodeHasChilden;
+  }
+
   /**
    * Check if a node has children that should be shown in the target treegrid
    * 
--- a/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/TreeDatasourceService.java	Tue Apr 29 09:25:17 2014 +0200
+++ b/modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/TreeDatasourceService.java	Wed Apr 30 16:10:23 2014 +0200
@@ -122,6 +122,14 @@
       // We can't get the bob from DAL, it has not been saved yet
       JSONObject bobProperties = new JSONObject(parameters.get("jsonBob"));
       Entity theEntity = getEntity();
+      String bobId = bobProperties.getString("id");
+      String entityName = bobProperties.getString("_entity");
+      Entity entity = ModelProvider.getInstance().getEntity(entityName);
+      String nodeDeletionPolicy = this.getNodeDeletionPolicy(entity);
+      if ("DNAIHC".equals(nodeDeletionPolicy) && this.nodeHasChildren(entity, bobId, null)) {
+        // Handle the deletion policy "Do Not Allow If Has Children" if it applies to this entity
+        throw new OBException(OBMessageUtils.messageBD("CannotDeleteNodeBecauseChildren"));
+      }
       if (!hasAccess(theEntity, null, false)) {
         throw new OBException(OBMessageUtils.messageBD("AccessTableNoView"));
       }
@@ -143,6 +151,12 @@
   protected abstract void deleteNode(JSONObject bobProperties);
 
   /**
+   * Classes that extend TreeDatasourceService this method must implement this method to handle the
+   * check if a node has children in a tree table
+   */
+  protected abstract boolean nodeHasChildren(Entity entity, String nodeId, String hqlWhereClause);
+
+  /**
    * Fetches some tree nodes Two operation modes:
    * 
    * - If a criteria is included in the parameters, this method will return the nodes that conform
@@ -420,6 +434,32 @@
   }
 
   /**
+   * Obtains the value of the node deletion policy for a particular tree based on the entity
+   * 
+   * @param entity
+   *          Entity whose accessibility is to be determined
+   * @return the value of the node deletion policy
+   */
+  private String getNodeDeletionPolicy(Entity entity) {
+    try {
+      String tableTreeNodeDeletionPolicy = "";
+
+      Table table = OBDal.getInstance().get(Table.class, entity.getTableId());
+      List<TableTree> tableTreeList = table.getADTableTreeList();
+      if (tableTreeList.size() == 0) {
+        throw new OBException("Error while determining the node deletion policy");
+      }
+
+      TableTree tableTree = tableTreeList.get(0);
+      tableTreeNodeDeletionPolicy = tableTree.getNodeDeletionPolicy();
+
+      return tableTreeNodeDeletionPolicy;
+    } catch (Exception e) {
+      throw new OBException("Error while determining the node deletion policy");
+    }
+  }
+
+  /**
    * Given a criteria, return the list of nodes that conforms to the criteria If the number of
    * returned nodes is too high, throws the TooManyTreeNodesException exception
    * 
--- a/src-db/database/model/tables/AD_TAB.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/model/tables/AD_TAB.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -246,6 +246,8 @@
       <check name="AD_TAB_ISACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="AD_TAB_ISINFOTAB_CHK"><![CDATA[ISINFOTAB IN ('Y', 'N')]]></check>
       <check name="AD_TAB_ISREADONLY_CHK"><![CDATA[ISREADONLY IN ('Y', 'N')]]></check>
+      <check name="AD_TAB_ISREADONLYTREE_CHK"><![CDATA[ISREADONLYTREE IN ('Y', 'N')]]></check>
+      <check name="AD_TAB_ISSHOWTREENODEICONS_CHK"><![CDATA[ISSHOWTREENODEICONS IN ('Y', 'N')]]></check>
       <check name="AD_TAB_ISSINGLEROW_CHK"><![CDATA[ISSINGLEROW IN ('Y', 'N')]]></check>
       <check name="AD_TAB_ISTRANSLATIONTAB_CHK"><![CDATA[ISTRANSLATIONTAB IN ('Y', 'N')]]></check>
       <check name="AD_TAB_NAME_CHK"><![CDATA[INSTR(NAME, TO_CHAR('_')) = 0]]></check>
--- a/src-db/database/model/tables/AD_TABLE_TREE.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/model/tables/AD_TABLE_TREE.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -85,6 +85,10 @@
         <default><![CDATA[Y]]></default>
         <onCreateDefault><![CDATA['Y']]></onCreateDefault>
       </column>
+      <column name="NODEDELETIONPOLICY" primaryKey="false" required="true" type="VARCHAR" size="60" autoIncrement="false">
+        <default><![CDATA[RCN]]></default>
+        <onCreateDefault><![CDATA['RCN']]></onCreateDefault>
+      </column>
       <foreign-key foreignTable="AD_CLIENT" name="AD_TABLETREE_AD_CLIENT">
         <reference local="AD_CLIENT_ID" foreign="AD_CLIENT_ID"/>
       </foreign-key>
--- a/src-db/database/sourcedata/AD_COLUMN.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/sourcedata/AD_COLUMN.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -222925,7 +222925,7 @@
 <!--0FA23D0D90E34E8790627C9928566EE3-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--0FA23D0D90E34E8790627C9928566EE3-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--0FA23D0D90E34E8790627C9928566EE3-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--0FA23D0D90E34E8790627C9928566EE3-->  <POSITION><![CDATA[11]]></POSITION>
+<!--0FA23D0D90E34E8790627C9928566EE3-->  <POSITION><![CDATA[10]]></POSITION>
 <!--0FA23D0D90E34E8790627C9928566EE3-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--0FA23D0D90E34E8790627C9928566EE3-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--0FA23D0D90E34E8790627C9928566EE3-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -229375,7 +229375,7 @@
 <!--2BF196792D1E4585857593DA16E0FEDD-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--2BF196792D1E4585857593DA16E0FEDD-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--2BF196792D1E4585857593DA16E0FEDD-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--2BF196792D1E4585857593DA16E0FEDD-->  <POSITION><![CDATA[20]]></POSITION>
+<!--2BF196792D1E4585857593DA16E0FEDD-->  <POSITION><![CDATA[18]]></POSITION>
 <!--2BF196792D1E4585857593DA16E0FEDD-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--2BF196792D1E4585857593DA16E0FEDD-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--2BF196792D1E4585857593DA16E0FEDD-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -233868,7 +233868,7 @@
 <!--4244EF30C51A4F94A7169E489E39D427-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--4244EF30C51A4F94A7169E489E39D427-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--4244EF30C51A4F94A7169E489E39D427-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--4244EF30C51A4F94A7169E489E39D427-->  <POSITION><![CDATA[21]]></POSITION>
+<!--4244EF30C51A4F94A7169E489E39D427-->  <POSITION><![CDATA[19]]></POSITION>
 <!--4244EF30C51A4F94A7169E489E39D427-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--4244EF30C51A4F94A7169E489E39D427-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--4244EF30C51A4F94A7169E489E39D427-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -236217,7 +236217,7 @@
 <!--4E3DA815197C400C9CA1FC8837701ACC-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--4E3DA815197C400C9CA1FC8837701ACC-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--4E3DA815197C400C9CA1FC8837701ACC-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--4E3DA815197C400C9CA1FC8837701ACC-->  <POSITION><![CDATA[15]]></POSITION>
+<!--4E3DA815197C400C9CA1FC8837701ACC-->  <POSITION><![CDATA[13]]></POSITION>
 <!--4E3DA815197C400C9CA1FC8837701ACC-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--4E3DA815197C400C9CA1FC8837701ACC-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--4E3DA815197C400C9CA1FC8837701ACC-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -256294,7 +256294,7 @@
 <!--6758510A59BE44D993496328046F05F8-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--6758510A59BE44D993496328046F05F8-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--6758510A59BE44D993496328046F05F8-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--6758510A59BE44D993496328046F05F8-->  <POSITION><![CDATA[19]]></POSITION>
+<!--6758510A59BE44D993496328046F05F8-->  <POSITION><![CDATA[17]]></POSITION>
 <!--6758510A59BE44D993496328046F05F8-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--6758510A59BE44D993496328046F05F8-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--6758510A59BE44D993496328046F05F8-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -267164,7 +267164,7 @@
 <!--789C71A9ABAB40228548F7CECB40531E-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--789C71A9ABAB40228548F7CECB40531E-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--789C71A9ABAB40228548F7CECB40531E-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--789C71A9ABAB40228548F7CECB40531E-->  <POSITION><![CDATA[13]]></POSITION>
+<!--789C71A9ABAB40228548F7CECB40531E-->  <POSITION><![CDATA[11]]></POSITION>
 <!--789C71A9ABAB40228548F7CECB40531E-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--789C71A9ABAB40228548F7CECB40531E-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--789C71A9ABAB40228548F7CECB40531E-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -286355,7 +286355,7 @@
 <!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <POSITION><![CDATA[17]]></POSITION>
+<!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <POSITION><![CDATA[15]]></POSITION>
 <!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--8D00A9AA33E0408FB41D4A57F3AFE0C6-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -308942,6 +308942,42 @@
 <!--C60DD944BD9F459999D0EAB9062E7AA0-->  <ISUSEDSEQUENCE><![CDATA[N]]></ISUSEDSEQUENCE>
 <!--C60DD944BD9F459999D0EAB9062E7AA0--></AD_COLUMN>
 
+<!--C61E9BF7DE874FC5A2022F10DC51E619--><AD_COLUMN>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_COLUMN_ID><![CDATA[C61E9BF7DE874FC5A2022F10DC51E619]]></AD_COLUMN_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <NAME><![CDATA[Node Deletion Policy]]></NAME>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <DESCRIPTION><![CDATA[It defines the behavior when a node item is deleted]]></DESCRIPTION>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <HELP><![CDATA[It defines the behavior when a node item is deleted]]></HELP>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <COLUMNNAME><![CDATA[NodeDeletionPolicy]]></COLUMNNAME>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_TABLE_ID><![CDATA[48F5363A7C0C44DE8114627C64DB4BDA]]></AD_TABLE_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_REFERENCE_ID><![CDATA[17]]></AD_REFERENCE_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_REFERENCE_VALUE_ID><![CDATA[025E4CBD3FC94036B669F5DAE4D0F193]]></AD_REFERENCE_VALUE_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <FIELDLENGTH><![CDATA[60]]></FIELDLENGTH>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISKEY><![CDATA[N]]></ISKEY>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISPARENT><![CDATA[N]]></ISPARENT>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISMANDATORY><![CDATA[Y]]></ISMANDATORY>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <SEQNO><![CDATA[240]]></SEQNO>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISTRANSLATED><![CDATA[N]]></ISTRANSLATED>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISSELECTIONCOLUMN><![CDATA[N]]></ISSELECTIONCOLUMN>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_ELEMENT_ID><![CDATA[E30B696E45E74546AA647D26BE75D628]]></AD_ELEMENT_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <POSITION><![CDATA[22]]></POSITION>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <IMAGESIZEVALUESACTION><![CDATA[N]]></IMAGESIZEVALUESACTION>
+<!--C61E9BF7DE874FC5A2022F10DC51E619-->  <ISUSEDSEQUENCE><![CDATA[N]]></ISUSEDSEQUENCE>
+<!--C61E9BF7DE874FC5A2022F10DC51E619--></AD_COLUMN>
+
 <!--C621D181EEAECF2BE040007F010027AD--><AD_COLUMN>
 <!--C621D181EEAECF2BE040007F010027AD-->  <AD_COLUMN_ID><![CDATA[C621D181EEAECF2BE040007F010027AD]]></AD_COLUMN_ID>
 <!--C621D181EEAECF2BE040007F010027AD-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -314981,7 +315017,7 @@
 <!--CFEC357F0AB44C9391E11AD519875C46-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--CFEC357F0AB44C9391E11AD519875C46-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--CFEC357F0AB44C9391E11AD519875C46-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--CFEC357F0AB44C9391E11AD519875C46-->  <POSITION><![CDATA[16]]></POSITION>
+<!--CFEC357F0AB44C9391E11AD519875C46-->  <POSITION><![CDATA[14]]></POSITION>
 <!--CFEC357F0AB44C9391E11AD519875C46-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--CFEC357F0AB44C9391E11AD519875C46-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--CFEC357F0AB44C9391E11AD519875C46-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -315373,7 +315409,7 @@
 <!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <POSITION><![CDATA[18]]></POSITION>
+<!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <POSITION><![CDATA[16]]></POSITION>
 <!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--D1FA35E7BC7442A5BF3E44E8C3170F70-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -320759,7 +320795,7 @@
 <!--DB40E6B8151348BD81EBA209E43C712D-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--DB40E6B8151348BD81EBA209E43C712D-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--DB40E6B8151348BD81EBA209E43C712D-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--DB40E6B8151348BD81EBA209E43C712D-->  <POSITION><![CDATA[23]]></POSITION>
+<!--DB40E6B8151348BD81EBA209E43C712D-->  <POSITION><![CDATA[21]]></POSITION>
 <!--DB40E6B8151348BD81EBA209E43C712D-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--DB40E6B8151348BD81EBA209E43C712D-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--DB40E6B8151348BD81EBA209E43C712D-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -324012,7 +324048,7 @@
 <!--E8DDE75253DDD184E040007F0100406D-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--E8DDE75253DDD184E040007F0100406D-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--E8DDE75253DDD184E040007F0100406D-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--E8DDE75253DDD184E040007F0100406D-->  <POSITION><![CDATA[14]]></POSITION>
+<!--E8DDE75253DDD184E040007F0100406D-->  <POSITION><![CDATA[12]]></POSITION>
 <!--E8DDE75253DDD184E040007F0100406D-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--E8DDE75253DDD184E040007F0100406D-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--E8DDE75253DDD184E040007F0100406D-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
@@ -324762,7 +324798,7 @@
 <!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
-<!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <POSITION><![CDATA[22]]></POSITION>
+<!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <POSITION><![CDATA[20]]></POSITION>
 <!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--EBA50C5405F44DC6887DFE6A1B15DFEA-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
--- a/src-db/database/sourcedata/AD_ELEMENT.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/sourcedata/AD_ELEMENT.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -31898,6 +31898,20 @@
 <!--E189C54FFCD19351E040007F01004C07-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--E189C54FFCD19351E040007F01004C07--></AD_ELEMENT>
 
+<!--E30B696E45E74546AA647D26BE75D628--><AD_ELEMENT>
+<!--E30B696E45E74546AA647D26BE75D628-->  <AD_ELEMENT_ID><![CDATA[E30B696E45E74546AA647D26BE75D628]]></AD_ELEMENT_ID>
+<!--E30B696E45E74546AA647D26BE75D628-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--E30B696E45E74546AA647D26BE75D628-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--E30B696E45E74546AA647D26BE75D628-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--E30B696E45E74546AA647D26BE75D628-->  <COLUMNNAME><![CDATA[NodeDeletionPolicy]]></COLUMNNAME>
+<!--E30B696E45E74546AA647D26BE75D628-->  <NAME><![CDATA[Node Deletion Policy]]></NAME>
+<!--E30B696E45E74546AA647D26BE75D628-->  <PRINTNAME><![CDATA[Node Deletion Policy]]></PRINTNAME>
+<!--E30B696E45E74546AA647D26BE75D628-->  <DESCRIPTION><![CDATA[It defines the behavior when a node item is deleted]]></DESCRIPTION>
+<!--E30B696E45E74546AA647D26BE75D628-->  <HELP><![CDATA[It defines the behavior when a node item is deleted]]></HELP>
+<!--E30B696E45E74546AA647D26BE75D628-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--E30B696E45E74546AA647D26BE75D628-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--E30B696E45E74546AA647D26BE75D628--></AD_ELEMENT>
+
 <!--E38B247A2EEF426C9908594598D1559B--><AD_ELEMENT>
 <!--E38B247A2EEF426C9908594598D1559B-->  <AD_ELEMENT_ID><![CDATA[E38B247A2EEF426C9908594598D1559B]]></AD_ELEMENT_ID>
 <!--E38B247A2EEF426C9908594598D1559B-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/src-db/database/sourcedata/AD_FIELD.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/sourcedata/AD_FIELD.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -197870,7 +197870,7 @@
 <!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <DISPLAYLOGIC><![CDATA[@Treestructure@='Custom']]></DISPLAYLOGIC>
 <!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <DISPLAYLENGTH><![CDATA[32]]></DISPLAYLENGTH>
 <!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
-<!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <SEQNO><![CDATA[110]]></SEQNO>
+<!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <SEQNO><![CDATA[120]]></SEQNO>
 <!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
 <!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
 <!--4E277C7DCF1A4440B81AB9D7D12FCE53-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
@@ -226183,7 +226183,7 @@
 <!--7FBD12C6C55D46BDAF73119282933F98-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
 <!--7FBD12C6C55D46BDAF73119282933F98-->  <DISPLAYLENGTH><![CDATA[1]]></DISPLAYLENGTH>
 <!--7FBD12C6C55D46BDAF73119282933F98-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
-<!--7FBD12C6C55D46BDAF73119282933F98-->  <SEQNO><![CDATA[75]]></SEQNO>
+<!--7FBD12C6C55D46BDAF73119282933F98-->  <SEQNO><![CDATA[115]]></SEQNO>
 <!--7FBD12C6C55D46BDAF73119282933F98-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
 <!--7FBD12C6C55D46BDAF73119282933F98-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
 <!--7FBD12C6C55D46BDAF73119282933F98-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
@@ -262326,6 +262326,34 @@
 <!--C4EED3241F928D5FE040007F010017B9-->  <EM_OBUIAPP_SHOWSUMMARY><![CDATA[N]]></EM_OBUIAPP_SHOWSUMMARY>
 <!--C4EED3241F928D5FE040007F010017B9--></AD_FIELD>
 
+<!--C4F2E4B1B0724B12B32FF56237923191--><AD_FIELD>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <AD_FIELD_ID><![CDATA[C4F2E4B1B0724B12B32FF56237923191]]></AD_FIELD_ID>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <NAME><![CDATA[Node Deletion Policy]]></NAME>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <DESCRIPTION><![CDATA[It defines the behavior when a node item is deleted]]></DESCRIPTION>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <HELP><![CDATA[It defines the behavior when a node item is deleted]]></HELP>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <AD_TAB_ID><![CDATA[708B2569E609493E818B5F6E1563A9A0]]></AD_TAB_ID>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <AD_COLUMN_ID><![CDATA[C61E9BF7DE874FC5A2022F10DC51E619]]></AD_COLUMN_ID>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <IGNOREINWAD><![CDATA[N]]></IGNOREINWAD>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <DISPLAYLENGTH><![CDATA[60]]></DISPLAYLENGTH>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <SEQNO><![CDATA[110]]></SEQNO>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <SHOWINRELATION><![CDATA[N]]></SHOWINRELATION>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISFIRSTFOCUSEDFIELD><![CDATA[N]]></ISFIRSTFOCUSEDFIELD>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <STARTINODDCOLUMN><![CDATA[N]]></STARTINODDCOLUMN>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <STARTNEWLINE><![CDATA[N]]></STARTNEWLINE>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <ISSHOWNINSTATUSBAR><![CDATA[N]]></ISSHOWNINSTATUSBAR>
+<!--C4F2E4B1B0724B12B32FF56237923191-->  <EM_OBUIAPP_SHOWSUMMARY><![CDATA[N]]></EM_OBUIAPP_SHOWSUMMARY>
+<!--C4F2E4B1B0724B12B32FF56237923191--></AD_FIELD>
+
 <!--C5038F12762C44079749F3E117F14A44--><AD_FIELD>
 <!--C5038F12762C44079749F3E117F14A44-->  <AD_FIELD_ID><![CDATA[C5038F12762C44079749F3E117F14A44]]></AD_FIELD_ID>
 <!--C5038F12762C44079749F3E117F14A44-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/src-db/database/sourcedata/AD_MESSAGE.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/sourcedata/AD_MESSAGE.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -20182,6 +20182,18 @@
 <!--7483DF96F3C34BB38C67B66BFAC79404-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--7483DF96F3C34BB38C67B66BFAC79404--></AD_MESSAGE>
 
+<!--749D4E033928426B90CF4E007CA1B5FE--><AD_MESSAGE>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <AD_MESSAGE_ID><![CDATA[749D4E033928426B90CF4E007CA1B5FE]]></AD_MESSAGE_ID>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <VALUE><![CDATA[CannotDeleteNodeBecauseChildren]]></VALUE>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <MSGTEXT><![CDATA[You cannot delete this node because it has children nodes associated]]></MSGTEXT>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <MSGTYPE><![CDATA[E]]></MSGTYPE>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--749D4E033928426B90CF4E007CA1B5FE-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
+<!--749D4E033928426B90CF4E007CA1B5FE--></AD_MESSAGE>
+
 <!--750BD7EF580544768D8DEC762753A24D--><AD_MESSAGE>
 <!--750BD7EF580544768D8DEC762753A24D-->  <AD_MESSAGE_ID><![CDATA[750BD7EF580544768D8DEC762753A24D]]></AD_MESSAGE_ID>
 <!--750BD7EF580544768D8DEC762753A24D-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/src-db/database/sourcedata/AD_REFERENCE.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/sourcedata/AD_REFERENCE.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -4187,6 +4187,18 @@
 <!--01F377BC3C0743E7868F81C20D062AA8-->  <ISVALUEDISPLAYED><![CDATA[N]]></ISVALUEDISPLAYED>
 <!--01F377BC3C0743E7868F81C20D062AA8--></AD_REFERENCE>
 
+<!--025E4CBD3FC94036B669F5DAE4D0F193--><AD_REFERENCE>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <AD_REFERENCE_ID><![CDATA[025E4CBD3FC94036B669F5DAE4D0F193]]></AD_REFERENCE_ID>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <NAME><![CDATA[Node Deletion Policy]]></NAME>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <ISBASEREFERENCE><![CDATA[N]]></ISBASEREFERENCE>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <PARENTREFERENCE_ID><![CDATA[17]]></PARENTREFERENCE_ID>
+<!--025E4CBD3FC94036B669F5DAE4D0F193-->  <ISVALUEDISPLAYED><![CDATA[N]]></ISVALUEDISPLAYED>
+<!--025E4CBD3FC94036B669F5DAE4D0F193--></AD_REFERENCE>
+
 <!--0537E1156A064FDE8EF0CFBC97577E5F--><AD_REFERENCE>
 <!--0537E1156A064FDE8EF0CFBC97577E5F-->  <AD_REFERENCE_ID><![CDATA[0537E1156A064FDE8EF0CFBC97577E5F]]></AD_REFERENCE_ID>
 <!--0537E1156A064FDE8EF0CFBC97577E5F-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/src-db/database/sourcedata/AD_REF_LIST.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/sourcedata/AD_REF_LIST.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -9430,6 +9430,17 @@
 <!--58C82EFABC4743808AD3F7AAD6CCE6A2-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--58C82EFABC4743808AD3F7AAD6CCE6A2--></AD_REF_LIST>
 
+<!--5AB94A06CE0B44E786ECBC5969AA83BB--><AD_REF_LIST>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <AD_REF_LIST_ID><![CDATA[5AB94A06CE0B44E786ECBC5969AA83BB]]></AD_REF_LIST_ID>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <VALUE><![CDATA[RCN]]></VALUE>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <NAME><![CDATA[Reparent Child Nodes]]></NAME>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <AD_REFERENCE_ID><![CDATA[025E4CBD3FC94036B669F5DAE4D0F193]]></AD_REFERENCE_ID>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--5AB94A06CE0B44E786ECBC5969AA83BB--></AD_REF_LIST>
+
 <!--5BBABB0BC5E74B919FAE36EC25F2951D--><AD_REF_LIST>
 <!--5BBABB0BC5E74B919FAE36EC25F2951D-->  <AD_REF_LIST_ID><![CDATA[5BBABB0BC5E74B919FAE36EC25F2951D]]></AD_REF_LIST_ID>
 <!--5BBABB0BC5E74B919FAE36EC25F2951D-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -9724,6 +9735,17 @@
 <!--748DF1663F76484993DE25043E4D0F04-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--748DF1663F76484993DE25043E4D0F04--></AD_REF_LIST>
 
+<!--748E9CB9CF5A473DA33AC447F3EA3698--><AD_REF_LIST>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <AD_REF_LIST_ID><![CDATA[748E9CB9CF5A473DA33AC447F3EA3698]]></AD_REF_LIST_ID>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <VALUE><![CDATA[DNAIHC]]></VALUE>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <NAME><![CDATA[Do Not Allow If Has Children]]></NAME>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <AD_REFERENCE_ID><![CDATA[025E4CBD3FC94036B669F5DAE4D0F193]]></AD_REFERENCE_ID>
+<!--748E9CB9CF5A473DA33AC447F3EA3698-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--748E9CB9CF5A473DA33AC447F3EA3698--></AD_REF_LIST>
+
 <!--74E2E8E4959342CAB71C5C59C3AEC4AC--><AD_REF_LIST>
 <!--74E2E8E4959342CAB71C5C59C3AEC4AC-->  <AD_REF_LIST_ID><![CDATA[74E2E8E4959342CAB71C5C59C3AEC4AC]]></AD_REF_LIST_ID>
 <!--74E2E8E4959342CAB71C5C59C3AEC4AC-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/src-db/database/sourcedata/AD_TABLE_TREE.xml	Tue Apr 29 09:25:17 2014 +0200
+++ b/src-db/database/sourcedata/AD_TABLE_TREE.xml	Wed Apr 30 16:10:23 2014 +0200
@@ -16,6 +16,7 @@
 <!--21E9F7EED1F24E95B0F4F21CF87AF995-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--21E9F7EED1F24E95B0F4F21CF87AF995-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--21E9F7EED1F24E95B0F4F21CF87AF995-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--21E9F7EED1F24E95B0F4F21CF87AF995-->  <NODEDELETIONPOLICY><![CDATA[DNAIHC]]></NODEDELETIONPOLICY>
 <!--21E9F7EED1F24E95B0F4F21CF87AF995--></AD_TABLE_TREE>
 
 <!--50741E7509994C5C8F764A18FA77CCE3--><AD_TABLE_TREE>
@@ -34,6 +35,7 @@
 <!--50741E7509994C5C8F764A18FA77CCE3-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--50741E7509994C5C8F764A18FA77CCE3-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--50741E7509994C5C8F764A18FA77CCE3-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--50741E7509994C5C8F764A18FA77CCE3-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--50741E7509994C5C8F764A18FA77CCE3--></AD_TABLE_TREE>
 
 <!--67D3E44B84D74A00946E4A7EBB3235E5--><AD_TABLE_TREE>
@@ -52,6 +54,7 @@
 <!--67D3E44B84D74A00946E4A7EBB3235E5-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--67D3E44B84D74A00946E4A7EBB3235E5-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--67D3E44B84D74A00946E4A7EBB3235E5-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--67D3E44B84D74A00946E4A7EBB3235E5-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--67D3E44B84D74A00946E4A7EBB3235E5--></AD_TABLE_TREE>
 
 <!--67F1DBEBB6B942C5A97C89A709E68CE8--><AD_TABLE_TREE>
@@ -70,6 +73,7 @@
 <!--67F1DBEBB6B942C5A97C89A709E68CE8-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--67F1DBEBB6B942C5A97C89A709E68CE8-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--67F1DBEBB6B942C5A97C89A709E68CE8-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--67F1DBEBB6B942C5A97C89A709E68CE8-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--67F1DBEBB6B942C5A97C89A709E68CE8--></AD_TABLE_TREE>
 
 <!--8CA3833994EA4CF0B535A56307C5A11A--><AD_TABLE_TREE>
@@ -88,6 +92,7 @@
 <!--8CA3833994EA4CF0B535A56307C5A11A-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--8CA3833994EA4CF0B535A56307C5A11A-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--8CA3833994EA4CF0B535A56307C5A11A-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--8CA3833994EA4CF0B535A56307C5A11A-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--8CA3833994EA4CF0B535A56307C5A11A--></AD_TABLE_TREE>
 
 <!--8E70E92119184AB69AE031A72BF6BF9E--><AD_TABLE_TREE>
@@ -106,6 +111,7 @@
 <!--8E70E92119184AB69AE031A72BF6BF9E-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--8E70E92119184AB69AE031A72BF6BF9E-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--8E70E92119184AB69AE031A72BF6BF9E-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--8E70E92119184AB69AE031A72BF6BF9E-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--8E70E92119184AB69AE031A72BF6BF9E--></AD_TABLE_TREE>
 
 <!--931BCF770A0A44FAB32794733C69C19D--><AD_TABLE_TREE>
@@ -124,6 +130,7 @@
 <!--931BCF770A0A44FAB32794733C69C19D-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--931BCF770A0A44FAB32794733C69C19D-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--931BCF770A0A44FAB32794733C69C19D-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--931BCF770A0A44FAB32794733C69C19D-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--931BCF770A0A44FAB32794733C69C19D--></AD_TABLE_TREE>
 
 <!--9C0304E9DC464C7495AAAC88958E1297--><AD_TABLE_TREE>
@@ -142,6 +149,7 @@
 <!--9C0304E9DC464C7495AAAC88958E1297-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--9C0304E9DC464C7495AAAC88958E1297-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--9C0304E9DC464C7495AAAC88958E1297-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--9C0304E9DC464C7495AAAC88958E1297-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--9C0304E9DC464C7495AAAC88958E1297--></AD_TABLE_TREE>
 
 <!--9F30DDEA05FC45C9B7CDA2A128ADE374--><AD_TABLE_TREE>
@@ -160,6 +168,7 @@
 <!--9F30DDEA05FC45C9B7CDA2A128ADE374-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--9F30DDEA05FC45C9B7CDA2A128ADE374-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--9F30DDEA05FC45C9B7CDA2A128ADE374-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--9F30DDEA05FC45C9B7CDA2A128ADE374-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--9F30DDEA05FC45C9B7CDA2A128ADE374--></AD_TABLE_TREE>
 
 <!--A141E11D8361424CB1E866DC8A301DCC--><AD_TABLE_TREE>
@@ -178,6 +187,7 @@
 <!--A141E11D8361424CB1E866DC8A301DCC-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--A141E11D8361424CB1E866DC8A301DCC-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--A141E11D8361424CB1E866DC8A301DCC-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--A141E11D8361424CB1E866DC8A301DCC-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--A141E11D8361424CB1E866DC8A301DCC--></AD_TABLE_TREE>
 
 <!--A9D065378E2E4487B842A6D02BFEAA9B--><AD_TABLE_TREE>
@@ -196,6 +206,7 @@
 <!--A9D065378E2E4487B842A6D02BFEAA9B-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--A9D065378E2E4487B842A6D02BFEAA9B-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--A9D065378E2E4487B842A6D02BFEAA9B-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--A9D065378E2E4487B842A6D02BFEAA9B-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--A9D065378E2E4487B842A6D02BFEAA9B--></AD_TABLE_TREE>
 
 <!--B6C7204712CC4EDEB5705C93F706DF05--><AD_TABLE_TREE>
@@ -214,6 +225,7 @@
 <!--B6C7204712CC4EDEB5705C93F706DF05-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--B6C7204712CC4EDEB5705C93F706DF05-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--B6C7204712CC4EDEB5705C93F706DF05-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--B6C7204712CC4EDEB5705C93F706DF05-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--B6C7204712CC4EDEB5705C93F706DF05--></AD_TABLE_TREE>
 
 <!--C5A8FBD40E6148C0A475C2D83FDAFD32--><AD_TABLE_TREE>
@@ -232,6 +244,7 @@
 <!--C5A8FBD40E6148C0A475C2D83FDAFD32-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--C5A8FBD40E6148C0A475C2D83FDAFD32-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--C5A8FBD40E6148C0A475C2D83FDAFD32-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--C5A8FBD40E6148C0A475C2D83FDAFD32-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--C5A8FBD40E6148C0A475C2D83FDAFD32--></AD_TABLE_TREE>
 
 <!--CF09E04DEAB34316BC6022C1B3CBBDD9--><AD_TABLE_TREE>
@@ -250,6 +263,7 @@
 <!--CF09E04DEAB34316BC6022C1B3CBBDD9-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--CF09E04DEAB34316BC6022C1B3CBBDD9-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--CF09E04DEAB34316BC6022C1B3CBBDD9-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--CF09E04DEAB34316BC6022C1B3CBBDD9-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--CF09E04DEAB34316BC6022C1B3CBBDD9--></AD_TABLE_TREE>
 
 <!--D298DD9EB4514BF8ABBDA4D88A591AFF--><AD_TABLE_TREE>
@@ -268,6 +282,7 @@
 <!--D298DD9EB4514BF8ABBDA4D88A591AFF-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--D298DD9EB4514BF8ABBDA4D88A591AFF-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--D298DD9EB4514BF8ABBDA4D88A591AFF-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--D298DD9EB4514BF8ABBDA4D88A591AFF-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--D298DD9EB4514BF8ABBDA4D88A591AFF--></AD_TABLE_TREE>
 
 <!--D45388802D4F41719DEACD336FA2B88F--><AD_TABLE_TREE>
@@ -286,6 +301,7 @@
 <!--D45388802D4F41719DEACD336FA2B88F-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--D45388802D4F41719DEACD336FA2B88F-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--D45388802D4F41719DEACD336FA2B88F-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--D45388802D4F41719DEACD336FA2B88F-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--D45388802D4F41719DEACD336FA2B88F--></AD_TABLE_TREE>
 
 <!--E52D2F7D418F41CCAE199ABE56CE282F--><AD_TABLE_TREE>
@@ -304,6 +320,7 @@
 <!--E52D2F7D418F41CCAE199ABE56CE282F-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--E52D2F7D418F41CCAE199ABE56CE282F-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--E52D2F7D418F41CCAE199ABE56CE282F-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--E52D2F7D418F41CCAE199ABE56CE282F-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--E52D2F7D418F41CCAE199ABE56CE282F--></AD_TABLE_TREE>
 
 <!--EE2CF4DC126041EDB103687280BD6D15--><AD_TABLE_TREE>
@@ -322,6 +339,7 @@
 <!--EE2CF4DC126041EDB103687280BD6D15-->  <TREESTRUCTURE><![CDATA[ADTree]]></TREESTRUCTURE>
 <!--EE2CF4DC126041EDB103687280BD6D15-->  <ISHANDLENODESMANUALLY><![CDATA[Y]]></ISHANDLENODESMANUALLY>
 <!--EE2CF4DC126041EDB103687280BD6D15-->  <ISMAINTREE><![CDATA[Y]]></ISMAINTREE>
+<!--EE2CF4DC126041EDB103687280BD6D15-->  <NODEDELETIONPOLICY><![CDATA[RCN]]></NODEDELETIONPOLICY>
 <!--EE2CF4DC126041EDB103687280BD6D15--></AD_TABLE_TREE>
 
 </data>