修正主子表示例,删除的时候子表数据未删除问题
This commit is contained in:
@@ -162,7 +162,7 @@ public class ${ClassName}Service extends ${table.isTreeEntity?'Tree':'Crud'}Serv
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
%>
|
%>
|
||||||
${@StringUtils.uncap(child.className)}Dao.delete(${@StringUtils.uncap(child.className)});
|
${@StringUtils.uncap(child.className)}Dao.deleteByEntity(${@StringUtils.uncap(child.className)});
|
||||||
<% } %>
|
<% } %>
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -115,7 +115,7 @@ public class TestDataService extends CrudService<TestDataDao, TestData> {
|
|||||||
super.delete(testData);
|
super.delete(testData);
|
||||||
TestDataChild testDataChild = new TestDataChild();
|
TestDataChild testDataChild = new TestDataChild();
|
||||||
testDataChild.setTestData(testData);
|
testDataChild.setTestData(testData);
|
||||||
testDataChildDao.delete(testDataChild);
|
testDataChildDao.deleteByEntity(testDataChild);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user