psdi.app.contract

Class ContractService

    • Constructor Detail

      • ContractService

        public ContractService()
                        throws java.rmi.RemoteException
        Call the constructor.
        Throws:
        java.rmi.RemoteException
      • ContractService

        public ContractService(MXServer mxServer)
                        throws java.rmi.RemoteException
        Parameters:
        srvEnv - -- the "Server Environment" this Service is being created in.
        Throws:
        java.rmi.RemoteException
    • Method Detail

      • findContracts

        public MboSetRemote findContracts(MboRemote inputMbo,
                                          MboRemote owningMbo)
                                   throws MXException,
                                          java.rmi.RemoteException
        Find valid contracts for a given item number and vendor combination. Used by PO/PR looking for a contract. This method is finding valid contracts from ContractAuth table. 1) A contract is valid if it has been approved and the contract dates are still valid. 2) Attribute PORequried should be yes. PURCHASE, LEASE, SERVICE and Software License type of contracts are required PO. 3) Valid contract lines are approved and contain this item number and vendor combination. 4) If a vendor is not specified, all valid contracts for this item are found.
        Specified by:
        findContracts in interface ContractServiceRemote
        Parameters:
        inputMbo - The calling MBO. Could be POLine/PRLine MBO.
        owningMbo - The owner of inputMbo. Could be PO/PR MBO.
        Returns:
        - A MboSet of valid contracts for this item number and vendor.
        Throws:
        MXException
        java.rmi.RemoteException
        See Also:
        ContractService.findContracts(MboRemote, MboRemote)
      • findValidContracts

        public java.util.Vector findValidContracts(MboRemote mboRemote,
                                                   java.lang.String vendor,
                                                   java.lang.String catalogCode,
                                                   boolean createRel)
                                            throws MXException,
                                                   java.rmi.RemoteException
        Find valid contracts for this item, vendor and catalog. Used by MR and Reroder looking for a contract. This method is finding valid contracts from ContractAuth table. item has to exist, calalog and vendor can be null. If they are null, the corresponding search criteria will not be used in finding the contracts.
        Specified by:
        findValidContracts in interface ContractServiceRemote
        Parameters:
        mboRemote - The calling MBO. Could be Reroder MBO.
        vendor - The vendor of the contract. If it is null, contracts for all vendors will be searched.
        createRel - Blanket or other contracts. True is Blanket contract. False is other contracts.
        Returns:
        A vector of all valid contract MboRemote.
        Throws:
        MXException
        java.rmi.RemoteException
        See Also:
        ContractService.findValidContracts(MboRemote, String, String, boolean)
      • findLeaseContracts

        public java.util.Vector findLeaseContracts(MboRemote mboRemote,
                                                   java.lang.String vendor,
                                                   java.lang.String catalogCode)
                                            throws MXException,
                                                   java.rmi.RemoteException
        Throws:
        MXException
        java.rmi.RemoteException
      • getContractLine

        public MboSetRemote getContractLine(MboRemote mboRemote)
                                     throws MXException,
                                            java.rmi.RemoteException
        Returns a set of ContractLine. 1) Contract line status is APPR. 2) Contract PORequried is true and vendor should be same as PO/PR's vendor 3) Contract should be authorized. Only apply to PO. 1) If PO type is REL, only show all contractlines from the contract reference number. 2) If PO type is other types than REL, show all contractlines that have CREATEREL is false.
        Specified by:
        getContractLine in interface ContractServiceRemote
        Parameters:
        mboRemote - The calling MBO. Could be PO/PR MBO.
        Returns:
        a set of ContractLine.
        Throws:
        MXException
        java.rmi.RemoteException
        See Also:
        ContractService.getContractLine(MboRemote)