예제 #1
0
        private void LoadVals(string strXml)
        {
            XmlSerializer s;
            StringReader  sr;

            s  = new XmlSerializer(typeof(COPCIInfo));
            sr = new System.IO.StringReader(strXml);

            oVar = new COPCIInfo();
            oVar = (COPCIInfo)s.Deserialize(sr);

            sr.Close();
            sr = null;
            s  = null;
        }
예제 #2
0
        public void LoadVals(string strXml)
        {
            XmlSerializer s;
            StringReader  sr;
            COPCIInfo     o;

            s  = new XmlSerializer(typeof(COPCIInfo));
            sr = new System.IO.StringReader(strXml);

            o = new COPCIInfo();
            o = (COPCIInfo)s.Deserialize(sr);

            base.LoadFromObj(o);

            o = null;
            sr.Close();
            sr = null;
            s  = null;
        }
예제 #3
0
 public void LoadFromObj(COPCIInfo oOrg)
 {
     miID                    = oOrg.ID;
     miDepartmentID          = oOrg.DepartmentID;
     miProjectID             = oOrg.ProjectID;
     miInitiatedByID         = oOrg.InitiatedByID;
     msPCINumber             = oOrg.PCINumber;
     msPCITitle              = oOrg.PCITitle;
     mdtDateInitiated        = oOrg.DateInitiated;
     msRequestedBy           = oOrg.RequestedBy;
     mdtDateRequested        = oOrg.DateRequested;
     msDescOfChange          = oOrg.DescOfChange;
     mbReasonDesignError     = oOrg.ReasonDesignError;
     mbReasonVendorError     = oOrg.ReasonVendorError;
     mbReasonEstimatingError = oOrg.ReasonEstimatingError;
     mbReasonContractorError = oOrg.ReasonContractorError;
     mbReasonSchedule        = oOrg.ReasonSchedule;
     mbReasonScopeAdd        = oOrg.ReasonScopeAdd;
     mbReasonScopeDel        = oOrg.ReasonScopeDel;
     mbReasonDesignChange    = oOrg.ReasonDesignChange;
     mbReasonOther           = oOrg.ReasonOther;
     msOtherReasonDesc       = oOrg.OtherReasonDesc;
     mbAffectedMechPipe      = oOrg.AffectedMechPipe;
     mbAffectedCSA           = oOrg.AffectedCSA;
     mbAffectedProjAdmin     = oOrg.AffectedProjAdmin;
     mbAffectedProcess       = oOrg.AffectedProcess;
     mbAffectedEandI         = oOrg.AffectedEandI;
     miEstimatedEngrHrs      = oOrg.EstimatedEngrHrs;
     mdEstimatedEngrDlrs     = oOrg.EstimatedEngrDlrs;
     mdEstimatedEngrTIC      = oOrg.EstimatedEngrTIC;
     msEstimatedAccuracy     = oOrg.EstimatedAccuracy;
     msScheduleImpact        = oOrg.ScheduleImpact;
     mbApprovedProceed       = oOrg.ApprovedProceed;
     mbApprovedTrack         = oOrg.ApprovedTrack;
     mbApprovedNot           = oOrg.ApprovedNot;
     miProjectManagerID      = oOrg.ProjectManagerID;
     mdtDateApproved         = oOrg.DateApproved;
     mbIsLocked              = oOrg.IsLocked;
     msComments              = oOrg.Comments;
 }
예제 #4
0
 public void Copy(COPCIInfo oNew)
 {
     oNew.ID                    = miID;
     oNew.DepartmentID          = miDepartmentID;
     oNew.ProjectID             = miProjectID;
     oNew.InitiatedByID         = miInitiatedByID;
     oNew.PCINumber             = msPCINumber;
     oNew.PCITitle              = msPCITitle;
     oNew.DateInitiated         = mdtDateInitiated;
     oNew.RequestedBy           = msRequestedBy;
     oNew.DateRequested         = mdtDateRequested;
     oNew.DescOfChange          = msDescOfChange;
     oNew.ReasonDesignError     = mbReasonDesignError;
     oNew.ReasonVendorError     = mbReasonVendorError;
     oNew.ReasonEstimatingError = mbReasonEstimatingError;
     oNew.ReasonContractorError = mbReasonContractorError;
     oNew.ReasonSchedule        = mbReasonSchedule;
     oNew.ReasonScopeAdd        = mbReasonScopeAdd;
     oNew.ReasonScopeDel        = mbReasonScopeDel;
     oNew.ReasonDesignChange    = mbReasonDesignChange;
     oNew.ReasonOther           = mbReasonOther;
     oNew.OtherReasonDesc       = msOtherReasonDesc;
     oNew.AffectedMechPipe      = mbAffectedMechPipe;
     oNew.AffectedCSA           = mbAffectedCSA;
     oNew.AffectedProjAdmin     = mbAffectedProjAdmin;
     oNew.AffectedProcess       = mbAffectedProcess;
     oNew.AffectedEandI         = mbAffectedEandI;
     oNew.EstimatedEngrHrs      = miEstimatedEngrHrs;
     oNew.EstimatedEngrDlrs     = mdEstimatedEngrDlrs;
     oNew.EstimatedEngrTIC      = mdEstimatedEngrTIC;
     oNew.EstimatedAccuracy     = msEstimatedAccuracy;
     oNew.ScheduleImpact        = msScheduleImpact;
     oNew.ApprovedProceed       = mbApprovedProceed;
     oNew.ApprovedTrack         = mbApprovedTrack;
     oNew.ApprovedNot           = mbApprovedNot;
     oNew.ProjectManagerID      = miProjectManagerID;
     oNew.DateApproved          = mdtDateApproved;
     oNew.IsLocked              = mbIsLocked;
     oNew.Comments              = msComments;
 }
예제 #5
0
        public string GetDataString()
        {
            string        tmpStr;
            COPCIInfo     o;
            XmlSerializer s;
            StringWriter  sw;

            o  = new COPCIInfo();
            s  = new XmlSerializer(typeof(COPCIInfo));
            sw = new StringWriter();

            base.Copy(o);
            s.Serialize(sw, o);

            tmpStr = sw.ToString();

            o  = null;
            s  = null;
            sw = null;

            return(tmpStr);
        }
예제 #6
0
        public string GetByID(int iID)
        {
            SqlDataReader dr;

            RSLib.CDbConnection cnn;
            SqlCommand          cmd;
            SqlParameter        prm;
            string tmpStr = "";

            cnn             = new RSLib.CDbConnection();
            cmd             = new SqlCommand("spPCIInfo_ByID", cnn.GetConnection());
            cmd.CommandType = CommandType.StoredProcedure;

            prm       = cmd.Parameters.Add("@ID", SqlDbType.Int);
            prm.Value = iID;

            dr = cmd.ExecuteReader(CommandBehavior.CloseConnection);

            while (dr.Read())
            {
                oVar                       = new COPCIInfo();
                oVar.ID                    = Convert.ToInt32(dr["ID"]);
                oVar.DepartmentID          = Convert.ToInt32(dr["DepartmentID"]);
                oVar.ProjectID             = Convert.ToInt32(dr["ProjectID"]);
                oVar.InitiatedByID         = Convert.ToInt32(dr["InitiatedByID"]);
                oVar.PCINumber             = dr["PCINumber"].ToString();
                oVar.PCITitle              = dr["PCITitle"].ToString();
                oVar.DateInitiated         = Convert.ToDateTime(dr["DateInitiated"]);
                oVar.RequestedBy           = dr["RequestedBy"].ToString();
                oVar.DateRequested         = Convert.ToDateTime(dr["DateRequested"]);
                oVar.DescOfChange          = dr["DescOfChange"].ToString();
                oVar.ReasonDesignError     = Convert.ToBoolean(dr["ReasonDesignError"]);
                oVar.ReasonVendorError     = Convert.ToBoolean(dr["ReasonVendorError"]);
                oVar.ReasonEstimatingError = Convert.ToBoolean(dr["ReasonEstimatingError"]);
                oVar.ReasonContractorError = Convert.ToBoolean(dr["ReasonContractorError"]);
                oVar.ReasonSchedule        = Convert.ToBoolean(dr["ReasonSchedule"]);
                oVar.ReasonScopeAdd        = Convert.ToBoolean(dr["ReasonScopeAdd"]);
                oVar.ReasonScopeDel        = Convert.ToBoolean(dr["ReasonScopeDel"]);
                oVar.ReasonDesignChange    = Convert.ToBoolean(dr["ReasonDesignChange"]);
                oVar.ReasonOther           = Convert.ToBoolean(dr["ReasonOther"]);
                oVar.OtherReasonDesc       = dr["OtherReasonDesc"].ToString();
                oVar.AffectedMechPipe      = Convert.ToBoolean(dr["AffectedMechPipe"]);
                oVar.AffectedCSA           = Convert.ToBoolean(dr["AffectedCSA"]);
                oVar.AffectedProjAdmin     = Convert.ToBoolean(dr["AffectedProjAdmin"]);
                oVar.AffectedProcess       = Convert.ToBoolean(dr["AffectedProcess"]);
                oVar.AffectedEandI         = Convert.ToBoolean(dr["AffectedEandI"]);
                oVar.EstimatedEngrHrs      = Convert.ToInt32(dr["EstimatedEngrHrs"]);
                oVar.EstimatedEngrDlrs     = Convert.ToDecimal(dr["EstimatedEngrDlrs"]);
                oVar.EstimatedEngrTIC      = Convert.ToDecimal(dr["EstimatedEngrTIC"]);
                oVar.EstimatedAccuracy     = dr["EstimatedAccuracy"].ToString();
                oVar.ScheduleImpact        = dr["ScheduleImpact"].ToString();
                oVar.ApprovedProceed       = Convert.ToBoolean(dr["ApprovedProceed"]);
                oVar.ApprovedTrack         = Convert.ToBoolean(dr["ApprovedTrack"]);
                oVar.ApprovedNot           = Convert.ToBoolean(dr["ApprovedNot"]);
                oVar.ProjectManagerID      = Convert.ToInt32(dr["ProjectManagerID"]);
                oVar.DateApproved          = Convert.ToDateTime(dr["DateApproved"]);
                oVar.IsLocked              = Convert.ToBoolean(dr["IsLocked"]);
                oVar.Comments              = dr["Comments"].ToString();

                tmpStr = GetDataString();
            }
            dr.Close();
            dr  = null;
            prm = null;
            cmd = null;
            cnn.CloseConnection();
            cnn = null;

            return(tmpStr);
        }