我有这个表 C_InvoiceTaxDetail,我正在尝试创建一个名为 MInvoiceTaxDetail 的模型类。
现在我已经创建了这个类,把它放在 org.compiere.model 和扩展的 X_C_InvoiceTaxDetail 类中。但是只有当我将它放在 X_C_InvoiceTaxDetail 中并且如果我将它放在 MInvoiceTaxDetail 中时,仍然 aftersave 方法才有效,则会出现以下错误:
===========> GridTable.dataSave: Persistency Issue - C_INVOICETAX_DETAIL: org/compiere/model/MINVOICETAXDETAIL (wrong name: org/compiere/model/MInvoiceTaxDetail) [20]
java.lang.NoClassDefFoundError: org/compiere/model/MINVOICETAXDETAIL (wrong name: org/compiere/model/MInvoiceTaxDetail)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:191)
at org.compiere.model.MTable.getPOclass(MTable.java:360)
at org.compiere.model.MTable.getClass(MTable.java:300)
at org.compiere.model.MTable.getPO(MTable.java:537)
at org.compiere.model.GridTable.dataSavePO(GridTable.java:2049)
at org.compiere.model.GridTable.dataSave(GridTable.java:1467)
at org.compiere.model.GridTab.dataSave(GridTab.java:983)
at org.compiere.apps.APanel.cmd_save(APanel.java:2045)
at org.compiere.apps.APanel.actionPerformed(APanel.java:1708)
at org.compiere.apps.AppsAction.actionPerformed(AppsAction.java:286)