psdi.app.invoice

Class FldInvoiceInclusive

  • All Implemented Interfaces:
    MboConstants, MboValueListener


    public class FldInvoiceInclusive
    extends MboValueAdapter
    Invoice.inclusive1-5 validation class: Calculates the invoice pre-tax total, total cost and base total cost when the field is toggled. Before calculations we have to check if the syscode is set on pre-tax total or total cost. Syscode can only be set on one of the two fields and we cannot calculate the field it is set on.
    • Constructor Detail

      • FldInvoiceInclusive

        public FldInvoiceInclusive(MboValue mbv)
        Construct and attach to the mbo value
    • Method Detail

      • action

        public void action()
                    throws MXException,
                           java.rmi.RemoteException
        Updates the total cost or the pre-tax total based on the value of this field. Every time the pay to vendor field (INCLUSIVE1-5) is changed the total cost or pre-tax total (based on the syscode) needs to be recalculated. If the total cost is calculated we have to calculate the base total cost also.
        1. Recalculate the total cost only if the syscode on totalCost is not already set.
        2. Recalculate the pretaxtotal if the syscode on pretaxtotal is not already set.
        3. Recalculate the base totalcost only if the syscode on totalcost is not already set.
        4. Recalculate the uninvoiced total cost if this field is changed.
        Specified by:
        action in interface MboValueListener
        Overrides:
        action in class MboValueAdapter
        Throws:
        MXException
        java.rmi.RemoteException