psdi.app.workorder

Class WoPrecaution

  • java.lang.Object
  • All Implemented Interfaces:
    java.rmi.Remote, WoPrecautionRemote, MboConstants, MboRemote, MaxRemoteProxy


    public class WoPrecaution
    extends Mbo
    implements WoPrecautionRemote
    Mbo object to represent WoPrecaution. Precautions are related to hazards via the WoHazardPrec object.

    See Work Order Safety Mbos Overview.

    This is a site level object.

    The key attributes for this object are SiteID, WoNum, PrecautionID, and WoSafetyDataSource.

    The attributes in this object are as follows:

    Attribute NameDescription
    DescriptionFreeform description. Also accommodates a long description.
    OrgIDThe organization for this site, stored on this table for ease of access. This equals the value for OrgID specified on the Site table.
    PrecautionIDMain identifier for this object. May be foreign key to Precaution.
    SiteIDThe site to which this record pertains. Foreign key to Site.
    WoNumForeign key to Workorder.
    WoSafetyDataSourceSee Work Order Safety Mbos Overview.
    • Constructor Detail

      • WoPrecaution

        public WoPrecaution(MboSet ms)
                     throws MXException,
                            java.rmi.RemoteException
        Construct the WoPrecaution object
        Throws:
        MXException
        java.rmi.RemoteException
    • Method Detail

      • init

        public void init()
                  throws MXException
        Owner must be workorder, wohazardprec, or wohazard.
        Overrides:
        init in class Mbo
        Throws:
        MXException
      • add

        public void add()
                 throws MXException,
                        java.rmi.RemoteException
        Add a mbo, defaulting the attributes shown below. The owner can be Workorder, WoHazardPrec, or WoHazard
        Attribute NameAttribute Value
        PrecautionIDIf owner is WoHazardPrec, equals the owner's PrecautionID.
        WoNumOwner's WoNum
        WoSafetyDataSourceIf owner is WoTagLock, equals the owner's WoSafetyDataSource.
        Specified by:
        add in interface MboRemote
        Overrides:
        add in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • appValidate

        public void appValidate()
                         throws MXException,
                                java.rmi.RemoteException
        If adding a woprecaution, add row to WoHazardPrec.
        Overrides:
        appValidate in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • skipCopyField

        protected boolean skipCopyField(MboValueInfo mvi)
                                 throws java.rmi.RemoteException,
                                        MXException
        This method overrides the skipCopyField() in the Mbo.Since this method takes the MboValueInfo as its parameter just check to see if this field needs to be copied or skipped.If this field does not need to be copied return true. The following is a list of fields that are not copied from the source WOPRECAUTION to the target WOPRECAUTION.
        1. WONUM
        Overrides:
        skipCopyField in class Mbo
        Parameters:
        - - The MboValueInfo object of the MboValue that needs to be copied.
        Returns:
        - True,if the field does not need to be copied.In all other cases return false.
        Throws:
        MXException
        java.rmi.RemoteException