0

I have this table C_InvoiceTaxDetail and I am trying to create a model class with the name of MInvoiceTaxDetail.

Now i have created the class , placed it in org.compiere.model and extended X_C_InvoiceTaxDetail class also. But Still aftersave method works only if i place it in X_C_InvoiceTaxDetail and if i place it in MInvoiceTaxDetail gives the following error:

===========> 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)
JavaDragon
  • 431
  • 1
  • 6
  • 17

1 Answers1

-1

Make sure you run the Generate Model utility after adding the new Class. You can find full details in the link to the Adempiere wiki.

Colin Rooney
  • 439
  • 7
  • 15