예제 #1
0
 public LotProcessCheckInfo(DataRow LotInfo) : base(LotInfo)
 {
     if (LotInfo == null)
     {
         throw new Exception("Data is Null");
     }
     Process_state        = DBCONVERT.GetByte(LotInfo, "process_state");
     Ticket_id            = DBCONVERT.GetInt32(LotInfo, "device_slip_id");
     Step_no              = DBCONVERT.GetInt32(LotInfo, "step_no");
     Package_id           = DBCONVERT.GetInt32(LotInfo, "package_id");
     Product_family_id    = DBCONVERT.GetInt32(LotInfo, "product_family_id");
     Quality_state        = DBCONVERT.GetByte(LotInfo, "quality_state");
     Wip_state            = DBCONVERT.GetByte(LotInfo, "wip_state");
     Is_special_flow      = DBCONVERT.GetByte(LotInfo, "is_special_flow");
     Location_id          = DBCONVERT.GetInt32(LotInfo, "location_id");
     Pj_id                = DBCONVERT.GetInt32(LotInfo, "process_job_id");
     Qty_in               = DBCONVERT.GetInt32(LotInfo, "qty_in");
     Qty_pass             = DBCONVERT.GetInt32(LotInfo, "qty_pass");
     Qty_fail             = DBCONVERT.GetInt32(LotInfo, "qty_fail");
     c_Package_name       = DBCONVERT.GetString(LotInfo, "name");
     c_Package_IsEnable   = DBCONVERT.GetByte(LotInfo, "is_Enabled");
     c_Package_AutoMotive = DBCONVERT.GetByte(LotInfo, "is_automotive");
     c_MachineId          = DBCONVERT.GetInt32(LotInfo, "machine_id");
     c_MachineName        = DBCONVERT.GetString(LotInfo, "machine_name");
     c_MachineRunState    = DBCONVERT.GetByte(LotInfo, "run_state");
     c_MachineOnlineState = DBCONVERT.GetByte(LotInfo, "online_state");
     c_MachineQCState     = DBCONVERT.GetByte(LotInfo, "qc_state");
     c_Machine_AutoMotive = DBCONVERT.GetByte(LotInfo, "machine_is_automotive");
     Errorflag            = false;
     ErrorMessage         = null;
 }
예제 #2
0
        public SpLotDBInfo(DataRow LotInfo) : base(LotInfo.Field <int>("id"), LotInfo.Field <string>("lot_no"))
        {
            if (LotInfo == null)
            {
                throw new Exception("Data is Null");
            }

            c_Specialflow_id = DBCONVERT.GetInt32(LotInfo, "special_flow_id");
            c_Pocess_state   = DBCONVERT.GetByte(LotInfo, "process_state");
            c_Step_no        = DBCONVERT.GetInt32(LotInfo, "step_no");
            c_Quality_state  = DBCONVERT.GetByte(LotInfo, "quality_state");
            c_Qty_in         = DBCONVERT.GetInt32(LotInfo, "qty_in");
            c_Qty_pass       = DBCONVERT.GetInt32(LotInfo, "qty_pass");
            c_Qty_fail       = DBCONVERT.GetInt32(LotInfo, "qty_fail");
            c_Errorflag      = false;
            c_ErrorMessage   = null;
        }
예제 #3
0
        /// <summary>
        /// Class MachineInfo's constructor with datarow parameter
        /// </summary>
        /// <param name="machineInfo">Data row with specific column name [<int>Id,<string>Name,<int>MachineTypeId,<string>MachineType,<bool>IsAutomotive,<bool>IsDisable]</param>
        /// <param name="jobInfo">Data row with specific column name [<int>Id,<string>Name]</param>
        /// <param name="machineStateInfo">Data row with specific column name [<int>OnlineState,<int>RunState,<int>QcState]</param>
        internal MachineInfo(DataRow machineInfo, DataTable jobInfo, DataRow machineStateInfo) : base(machineInfo)
        {
            c_MachineModels = new MachineModelInfo(DBCONVERT.GetInt32(machineInfo, "MachineModelId"), DBCONVERT.GetString(machineInfo, "MachineModel"));
            c_MachineType   = DBCONVERT.GetString(machineInfo, "MachineType");
            c_IsAutomotive  = Convert.ToBoolean(DBCONVERT.GetByte(machineInfo, "IsAutomotive"));
            c_IsDisable     = Convert.ToBoolean(DBCONVERT.GetByte(machineInfo, "IsDisable"));
            c_Jobs          = new JobInfo[jobInfo.Rows.Count];

            if (jobInfo != null)
            {
                for (int i = 0; i < jobInfo.Rows.Count; i++)
                {
                    JobInfo c_tmps = new JobInfo(jobInfo.Rows[i]);
                    c_Jobs[i] = c_tmps;
                }
            }
            if (machineStateInfo != null)
            {
                c_MachineState = new MachineState(DBCONVERT.GetByte(machineStateInfo, "OnlineState"), DBCONVERT.GetByte(machineStateInfo, "RunState"), DBCONVERT.GetByte(machineStateInfo, "QcState"));
            }
        }
예제 #4
0
        /// <summary>
        /// Class LotInfo's constructor with datarow parameter
        /// </summary>
        /// <param name="lotInfo">Data row with specific column name [<int>Id,<string>Name,<bool>IsAutomotive,<bool>IsSpecialFlow,<int>DeviceId,<string>DeviceName,<int>PackageId,<string>PackageName,<int>QuantityIn,<int>QuantityPass,<int>QuantityFail]</param>
        /// <param name="jobInfo">Data row with specific column name [<int>Id,<string>Name]</param>
        /// <param name="RecipeInfo">Data row with specific column name [<int>Id,<string>Name]</param>
        /// <param name="LotStateInfo">Data row with specific column name [<int>ProcessState,<int>QualityState]</param>
        internal LotInfo(DataRow lotInfo, DataRow jobInfo, DataRow recipeInfo, DataRow lotStateInfo, Boolean Is_Abnormal) : base(lotInfo)
        {
            c_IsAutomotive  = Convert.ToBoolean(DBCONVERT.GetByte(lotInfo, "IsAutomotive"));
            c_IsSpecialFlow = Convert.ToBoolean(DBCONVERT.GetByte(lotInfo, "IsSpecialFlow"));
            c_Device        = new DeviceInfo(DBCONVERT.GetInt32(lotInfo, "DeviceId"), DBCONVERT.GetString(lotInfo, "DeviceName"));
            c_Package       = new PackageInfo(DBCONVERT.GetInt32(lotInfo, "PackageId"), DBCONVERT.GetString(lotInfo, "PackageName"));
            if (jobInfo != null)
            {
                c_Job = new JobInfo(DBCONVERT.GetInt32(jobInfo, "Id"), DBCONVERT.GetString(jobInfo, "Name"));
            }
            if (recipeInfo != null)
            {
                c_DeviceFlows_Recipe = new RecipeInfo(DBCONVERT.GetInt32(jobInfo, "Id"), DBCONVERT.GetString(jobInfo, "Name"));
            }
            if (lotStateInfo != null)
            {
                c_LotState = new LotState(DBCONVERT.GetByte(lotStateInfo, "ProcessState"), DBCONVERT.GetByte(lotStateInfo, "QualityState"));
            }

            c_Quantity   = new Quantity(lotInfo, Is_Abnormal);
            c_PcsParWork = DBCONVERT.GetInt16(lotInfo, "PcsPerWork");
        }
예제 #5
0
 public JigInfo(DataRow JigInfo) : base(JigInfo)
 {
     try
     {
         c_Type_ID           = DBCONVERT.GetInt32(JigInfo, "categorie_id");
         c_Type_Name         = DBCONVERT.GetString(JigInfo, "name");
         c_Count_id          = DBCONVERT.GetInt32(JigInfo, "control_no");
         c_Count_name        = DBCONVERT.GetString(JigInfo, "control_name");
         c_Value             = DBCONVERT.GetString(JigInfo, "value");
         c_Is_ValueExsist    = DBCONVERT.GetInt32(JigInfo, "is_value_null");
         c_CountUnit         = DBCONVERT.GetInt32(JigInfo, "integration_unit");
         c_CountWarning      = DBCONVERT.GetString(JigInfo, "warn_value");
         c_CountLimit        = DBCONVERT.GetString(JigInfo, "alarm_value");
         c_Location          = DBCONVERT.GetInt32(JigInfo, "location_id");
         c_LocationType      = DBCONVERT.GetString(JigInfo, "location_name");
         c_Product_family_id = DBCONVERT.GetInt32(JigInfo, "division_id");
         c_Errorflag         = true;
         c_ErrorMessage      = null;
     }
     catch (Exception e)
     {
         c_Type_ID           = -1;
         c_Type_Name         = null;
         c_Count_id          = -1;
         c_Count_name        = null;
         c_Value             = null;
         c_Is_ValueExsist    = -1;
         c_CountUnit         = -1;
         c_CountWarning      = null;
         c_CountLimit        = null;
         c_Location          = -1;
         c_LocationType      = null;
         c_Product_family_id = -1;
         c_Errorflag         = true;
         c_ErrorMessage      = e.ToString();
     }
 }
예제 #6
0
        internal LotDBInfo(DataRow LotInfo) : base(LotInfo.Field <int>("id"), LotInfo.Field <string>("lot_no"), LotInfo.Field <byte>("is_automotive"), LotInfo.Field <int>("job_id"))
        {
            if (LotInfo == null)
            {
                throw new Exception("Data is Null");
            }
            c_Process_state     = DBCONVERT.GetByte(LotInfo, "process_state");
            c_Ticket_id         = DBCONVERT.GetInt32(LotInfo, "device_slip_id");
            c_Step_no           = DBCONVERT.GetInt32(LotInfo, "step_no");
            c_Package_id        = DBCONVERT.GetInt32(LotInfo, "act_package_id");
            c_Product_family_id = DBCONVERT.GetInt32(LotInfo, "product_family_id");
            c_Quality_state     = DBCONVERT.GetByte(LotInfo, "quality_state");
            c_Is_special_flow   = DBCONVERT.GetByte(LotInfo, "is_special_flow");
            c_Location_id       = DBCONVERT.GetInt32(LotInfo, "location_id");
            c_Pj_id             = DBCONVERT.GetInt32(LotInfo, "process_job_id");
            c_Qty_in            = DBCONVERT.GetInt32(LotInfo, "qty_in");
            c_Qty_pass          = DBCONVERT.GetInt32(LotInfo, "qty_pass");
            c_Qty_fail          = DBCONVERT.GetInt32(LotInfo, "qty_fail");
            c_Wip_state         = DBCONVERT.GetByte(LotInfo, "wip_state");
            c_First_inspection  = DBCONVERT.GetByte(LotInfo, "first_ins_state");
            c_Final_inspection  = DBCONVERT.GetByte(LotInfo, "final_ins_state");

            c_ErrorMessage = null;
        }
예제 #7
0
 /// <summary>
 /// Class Info's constructor with datarow parameter
 /// </summary>
 /// <param name="info">Data row with specific column name [<int>Id,<string>Name]</param>
 internal Info(DataRow info)
 {
     c_DBCONVERT = new DB_GetConverter();
     c_Id        = DBCONVERT.GetInt32(info, "Id");
     c_Name      = DBCONVERT.GetString(info, "Name").Trim();
 }