Index: core-module/pom.xml
===================================================================
diff -u -r51ab1ca162c4491014564da9cb99fcaeaa0f2918 -rf65e10072e504fd3e477c875d38b08ad8176a154
--- core-module/pom.xml (.../pom.xml) (revision 51ab1ca162c4491014564da9cb99fcaeaa0f2918)
+++ core-module/pom.xml (.../pom.xml) (revision f65e10072e504fd3e477c875d38b08ad8176a154)
@@ -7,7 +7,7 @@
313devgrp
java-service-tree-framework-core-library
- 23.02.04
+ 23.02.05
../pom.xml
@@ -31,7 +31,7 @@
313devgrp
lib-module
- 23.02.04
+ 23.02.05
pom
Index: core-module/src/main/java/egovframework/com/ext/jstree/springHibernate/core/service/JsTreeHibernateServiceImpl.java
===================================================================
diff -u -r51ab1ca162c4491014564da9cb99fcaeaa0f2918 -rf65e10072e504fd3e477c875d38b08ad8176a154
--- core-module/src/main/java/egovframework/com/ext/jstree/springHibernate/core/service/JsTreeHibernateServiceImpl.java (.../JsTreeHibernateServiceImpl.java) (revision 51ab1ca162c4491014564da9cb99fcaeaa0f2918)
+++ core-module/src/main/java/egovframework/com/ext/jstree/springHibernate/core/service/JsTreeHibernateServiceImpl.java (.../JsTreeHibernateServiceImpl.java) (revision f65e10072e504fd3e477c875d38b08ad8176a154)
@@ -397,12 +397,25 @@
logger.debug("-----------------------getChildNodeByLeftRight 완료-----------------------");
DetachedCriteria getChildNodeByLeftRightCriteria = DetachedCriteria.forClass(jsTreeHibernateDTO.getClass());
- Criterion whereChildNodeByLeftRight = Restrictions.ge("c_left", nodeById.getC_left());
- getChildNodeByLeftRightCriteria.add(whereChildNodeByLeftRight);
- getChildNodeByLeftRightCriteria.add(Restrictions.and(Restrictions.le("c_right", nodeById.getC_right())));
+
+ Criterion criterion = Restrictions.and(
+ Restrictions.ge("c_left", nodeById.getC_left()),
+ Restrictions.le("c_right", nodeById.getC_right())
+ );
+ getChildNodeByLeftRightCriteria.add(criterion);
getChildNodeByLeftRightCriteria.addOrder(Order.asc("c_left"));
List childNodesFromNodeById = jsTreeHibernateDao.getListWithoutPaging(getChildNodeByLeftRightCriteria);
+ logger.debug("-----------------------position 값이 over될때 방어코드-----------------------");
+ DetachedCriteria getChildNodeByPositionCriteria = DetachedCriteria.forClass(jsTreeHibernateDTO.getClass());
+
+ Criterion postion_criterion = Restrictions.eq("c_parentid", jsTreeHibernateDTO.getRef());
+ getChildNodeByPositionCriteria.add(postion_criterion);
+ int refChildCount = jsTreeHibernateDao.getListWithoutPaging(getChildNodeByPositionCriteria).size();
+ if(jsTreeHibernateDTO.getC_position() > refChildCount){
+ jsTreeHibernateDTO.setC_position(Long.valueOf(refChildCount));
+ }
+
logger.debug("-----------------------nodeByRef 완료-----------------------");
T nodeByRef = (T) jsTreeHibernateDao.getUnique(jsTreeHibernateDTO.getRef());
if(StringUtils.equals(nodeByRef.getC_type(),"default")){
@@ -502,6 +515,7 @@
jsTreeHibernateDTO);
enterMyselfFixLeftRight(comparePoint, targetNodeLevel, c_idsByChildNodeFromNodeById, jsTreeHibernateDTO);
}
+
return t_ComprehensiveTree;
}
Index: lib-module/pom.xml
===================================================================
diff -u -r51ab1ca162c4491014564da9cb99fcaeaa0f2918 -rf65e10072e504fd3e477c875d38b08ad8176a154
--- lib-module/pom.xml (.../pom.xml) (revision 51ab1ca162c4491014564da9cb99fcaeaa0f2918)
+++ lib-module/pom.xml (.../pom.xml) (revision f65e10072e504fd3e477c875d38b08ad8176a154)
@@ -5,7 +5,7 @@
313devgrp
java-service-tree-framework-core-library
- 23.02.04
+ 23.02.05
../pom.xml
Index: pom.xml
===================================================================
diff -u -r51ab1ca162c4491014564da9cb99fcaeaa0f2918 -rf65e10072e504fd3e477c875d38b08ad8176a154
--- pom.xml (.../pom.xml) (revision 51ab1ca162c4491014564da9cb99fcaeaa0f2918)
+++ pom.xml (.../pom.xml) (revision f65e10072e504fd3e477c875d38b08ad8176a154)
@@ -10,7 +10,7 @@
4.0.0
313devgrp
java-service-tree-framework-core-library
- 23.02.04
+ 23.02.05
pom
java-service-tree-framework-core-library