psdi.app.invoice

Class FldInvoiceTotalCost

  • All Implemented Interfaces:
    MboConstants, MboValueListener
    Direct Known Subclasses:
    FldInvoiceTotalCostForUI


    public class FldInvoiceTotalCost
    extends FldPurTotalCost
    Invoice.totalcost validation class: This class recalculates and set the invoice pretaxtotal based on the syscode. If the totalcost changes the basetotalcost is calculated which is taken care of by the base class FldPurTotalCost. On clearing this field it is set equal to the the sum of the invoice pretaxtotal and invoice total taxes. Also syscode is cleared and set depending on from where the field is set i.e. whether it is set internally or directly by the user.
    See Also:
    FldPurTotalCost
    • Constructor Detail

      • FldInvoiceTotalCost

        public FldInvoiceTotalCost(MboValue mbv)
                            throws MXException,
                                   java.rmi.RemoteException
        Construct and attach to the mbo value.
        Throws:
        MXException
        java.rmi.RemoteException
    • Method Detail

      • action

        public void action()
                    throws MXException,
                           java.rmi.RemoteException
        Recalculate the invoice pretaxtotal based on the syscode. Also if the totalcost changes we have to recalculate the basetotalcost. Also set and clear the syscode depending on from where this field is set. A message is posted on the bulletin board when the field is set internally and in that case we don't set or clear the syscode. If the field is cleared it is set equal to the sum of pretaxtotal and the total taxes.



        Conditions:
        If the totalcost is made null by the user then clear the syscode on the totalcost and set totalcost=pretaxtotal + total of the taxes(Include the taxes based on the inclusive1..5).
        1. Update the pretaxtotal only if the syscode on the pretaxtotal is not already set If the totalcost is made null by the user then clear the syscode on the totalcost
          Specified by:
          action in interface MboValueListener
          Overrides:
          action in class FldPurTotalCost
          Throws:
          MXException
          java.rmi.RemoteException
          See Also:
          BulletinBoardService