Class MReportColumn

    • Constructor Detail

      • MReportColumn

        public MReportColumn​(Properties ctx,
                             int PA_ReportColumn_ID,
                             String trxName)
        Constructor
        Parameters:
        ctx - context
        PA_ReportColumn_ID - id
        trxName - transaction
      • MReportColumn

        public MReportColumn​(Properties ctx,
                             ResultSet rs,
                             String trxName)
        Constructor
        Parameters:
        ctx - context
        rs - ResultSet to load from
        trxName - transaction
    • Method Detail

      • getSelectClause

        public String getSelectClause​(boolean withSum)
        Get Column SQL Select Clause.
        Parameters:
        withSum - with SUM() function
        Returns:
        select clause - AmtAcctCR+AmtAcctDR/etc or "null" if not defined
      • isPeriod

        public boolean isPeriod()
        Is it Period Info ?
        Returns:
        true if Period Amount Type
      • isYear

        public boolean isYear()
        Is it Year Info ?
        Returns:
        true if Year Amount Type
      • isTotal

        public boolean isTotal()
        Is it Total Info ?
        Returns:
        true if Year Amount Type
      • isNatural

        public boolean isNatural()
        Is it natural balance ? Natural balance means year balance for profit and loss a/c, total balance for balance sheet account
        Returns:
        true if Natural Balance Amount Type
      • getWhereClause

        public String getWhereClause​(int PA_Hierarchy_ID)
        Get Segment Value Where Clause
        Parameters:
        PA_Hierarchy_ID - hierarchy
        Returns:
        where clause
      • isCalculationTypeRange

        public boolean isCalculationTypeRange()
        Calculation Type Range
        Returns:
        true if range
      • isCalculationTypeAdd

        public boolean isCalculationTypeAdd()
        Calculation Type Add
        Returns:
        true id add
      • isCalculationTypeSubtract

        public boolean isCalculationTypeSubtract()
        Calculation Type Subtract
        Returns:
        true if subtract
      • isCalculationTypePercent

        public boolean isCalculationTypePercent()
        Calculation Type Percent
        Returns:
        true if percent
      • isColumnTypeCalculation

        public boolean isColumnTypeCalculation()
        Column Type Calculation
        Returns:
        true if calculation
      • isColumnTypeRelativePeriod

        public boolean isColumnTypeRelativePeriod()
        Column Type Relative Period
        Returns:
        true if relative period
      • isColumnTypeSegmentValue

        public boolean isColumnTypeSegmentValue()
        Column Type Segment Value
        Returns:
        true if segment value
      • getRelativePeriodAsInt

        public int getRelativePeriodAsInt()
        Get Relative Period As Int
        Returns:
        relative period
      • beforeSave

        protected boolean beforeSave​(boolean newRecord)
        Before Save
        Overrides:
        beforeSave in class PO
        Parameters:
        newRecord - new
        Returns:
        true
      • copy

        public static MReportColumn copy​(Properties ctx,
                                         int AD_Client_ID,
                                         int AD_Org_ID,
                                         int PA_ReportColumnSet_ID,
                                         MReportColumn source,
                                         String trxName)
        /** Copy
        Parameters:
        ctx - context
        AD_Client_ID - parent
        AD_Org_ID - parent
        PA_ReportColumnSet_ID - parent
        source - copy source
        trxName - transaction
        Returns:
        Report Column