psdi.app.ticket

Class FldTKAssetnum

    • Constructor Detail

      • FldTKAssetnum

        public FldTKAssetnum(MboValue mbv)
                      throws MXException
        Construct without a criteria.
        Parameters:
        mbv - the MboValue the assetnum field in the ticket object attach to.
        Throws:
        MXException
    • Method Detail

      • validate

        public void validate()
                      throws MXException,
                             java.rmi.RemoteException
        The validate method determines the action if there is a change in the location/asset and gl information.
        Specified by:
        validate in interface MboValueListener
        Overrides:
        validate in class FldAssetnum
        Throws:
        MXException
        java.rmi.RemoteException
      • getList

        public MboSetRemote getList()
                             throws MXException,
                                    java.rmi.RemoteException
        Show only the assets, which are not decommissioned Flag to indicate whether this mbo is zombie or not. A zombie mbo is created for the purpose of QBE and does not really have any data associated with it. The list is always filtered by a value in the Asset Site field. By default, this is the site on the person record of the user specified in the Affected Person field. However, the site might be copied from an originating service request if your administrator has configured the system to behave this way.
        Specified by:
        getList in interface MboValueListener
        Overrides:
        getList in class MAXTableDomain
        Throws:
        MXException
        java.rmi.RemoteException
      • action

        public void action()
                    throws MXException,
                           java.rmi.RemoteException
        Updates the fields affected by changing this field. It creates a new record in the multiassetlocci table with this assetnum and location as the primary asset. Also, it sets the CI with Asset's CI value.
        Specified by:
        action in interface MboValueListener
        Overrides:
        action in class MAXTableDomain
        Throws:
        MXException
        java.rmi.RemoteException
      • getAssetWithoutSiteId

        public static MboRemote getAssetWithoutSiteId(MboRemote ticket,
                                                      MboValue assetMbv,
                                                      Translate xlator)
                                               throws java.rmi.RemoteException,
                                                      MXException
        Because SR is a system level mbo there are states where no site id information can be found.
        So if user uses smart fill for the asset/location field, we must define what is the site id of that asset/location
        Legacy code of TPAE had the logic of iterating over all locations/assets that had the same LOCATION/ASSETNUM value. And if no other info about the siteid is found it uses the 1st Asset/Location found. This also happens in FldTkAssetnum.
        TODO We must confirm this behavior. - rcouto - i'm looking for explanations for it.
        Parameters:
        ticket -
        locaMbv -
        Returns:
        Throws:
        java.rmi.RemoteException
        MXException
      • setCIForAsset

        public void setCIForAsset()
                           throws MXException,
                                  java.rmi.RemoteException
        This method is called by the assetnum attribute to set the Ticket's CINum to the Asset's CI. If the asset has a Valid CI for the ticket and if the CI field is blank, then CI will be copied to the ticket. If the ticket's cinum is not blank, a warning will be given (MXApplicationException, ticket, AssetChangeLoc, parameter of the asset's CI).
        Throws:
        MXException
        java.rmi.RemoteException