Skip to content

Commit

Permalink
IDocTypeDAO convenient method (without ctx and trxName)
Browse files Browse the repository at this point in the history
  • Loading branch information
teosarca committed Dec 20, 2017
1 parent b32406a commit 6581052
Showing 1 changed file with 7 additions and 0 deletions.
Expand Up @@ -25,9 +25,11 @@
import java.util.List;
import java.util.Properties;

import org.adempiere.ad.trx.api.ITrx;
import org.adempiere.exceptions.DocTypeNotFoundException;
import org.adempiere.util.ISingletonService;
import org.compiere.model.I_C_DocType;
import org.compiere.util.Env;

import lombok.Builder;
import lombok.Builder.Default;
Expand Down Expand Up @@ -62,6 +64,11 @@ public interface IDocTypeDAO extends ISingletonService
* @throws DocTypeNotFoundException if no document type was found
*/
int getDocTypeId(Properties ctx, String docBaseType, int adClientId, int adOrgId, String trxName);

default int getDocTypeId(String docBaseType, int adClientId, int adOrgId)
{
return getDocTypeId(Env.getCtx(), docBaseType, adClientId, adOrgId, ITrx.TRXNAME_None);
}

/**
*
Expand Down

0 comments on commit 6581052

Please sign in to comment.