Package org.compiere.apps.form
Class Charge
java.lang.Object
org.compiere.apps.form.Charge
- Direct Known Subclasses:
WCharge
Create Charge from Accounts
- Version:
- $Id: Charge.java,v 1.3 2006/07/30 00:51:28 jjanke Exp $
- Author:
- Jorg Janke
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumEnumeration of column names and indices. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected StringBufferprotected StringBufferprotected static final CLoggerLoggerprotected intAccount Elementprotected intWindow No -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateAccount(IMiniTable dataTable) Create charge from selected account elementsintcreateCharge(String name, int elementValueId) Create Charge and account element for primary Account Schema.intcreateElementValue(String value, String name, boolean isExpenseType) Create ElementValue (C_ElementValue) for primary AcctSchemaprotected voidFinds C_Element_ID of primary accounting schemaprotected voidFinds default tax category for the client.Get column names forgetData()Get account element names for charge createdgetData()Get revenue and expense account elementsGet account element names for charge create failurevoidsetColumnClass(IMiniTable dataTable) Set class type of columnsvoidsetTrxName(String trxName) Set optional trx name
-
Field Details
-
m_WindowNo
protected int m_WindowNoWindow No -
m_C_Element_ID
protected int m_C_Element_IDAccount Element -
log
Logger -
listCreated
-
listRejected
-
-
Constructor Details
-
Charge
public Charge()default constructor
-
-
Method Details
-
setTrxName
Set optional trx name- Parameters:
trxName-
-
getData
Get revenue and expense account elements- Returns:
- list of account element(Boolean[Select],KeyNamePair[C_ElementValue_ID,Value],Name,Boolean[IsExpense]) records
-
findChargeElementID
protected void findChargeElementID()Finds C_Element_ID of primary accounting schema -
getColumnNames
Get column names forgetData()- Returns:
- column names
-
setColumnClass
Set class type of columns- Parameters:
dataTable-- See Also:
-
findTaxCategoryID
protected void findTaxCategoryID()Finds default tax category for the client. -
createElementValue
Create ElementValue (C_ElementValue) for primary AcctSchema- Parameters:
value- valuename- nameisExpenseType- is expense- Returns:
- C_ElementValue_ID or 0 if create fail
-
createCharge
Create Charge and account element for primary Account Schema.- Parameters:
name- charge nameelementValueId- element value identifier- Returns:
- charge identifier, or 0 if create fail
-
createAccount
Create charge from selected account elements- Parameters:
dataTable-
-
getCreatedAccountNames
Get account element names for charge created- Returns:
- comma separated list of account element names (where charge create success)
-
getRejectedAccountNames
Get account element names for charge create failure- Returns:
- comma separated list of account element names (where charge create fail)
-