using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
using DBUtility;
namespace BLL
{
///
/// ·µ»Ø»ù´¡×ÊÁÏÐÅÏ¢Àà
///
public class ClsBaseSelect
{
#region ÉèÖÃÎı¾¿ò
//ÎïÁÏ·ÖÀà
///
/// ÎïÁÏ·ÖÀà
///
///
public static void SetTextByMaterType(TextBox txt)
{
DAL.ClsGy_UnitGroup_View oUnitGroup = new DAL.ClsGy_UnitGroup_View();
if (oUnitGroup.RefreshView())
{
txt.Text = oUnitGroup.oModel.HName;
txt.Tag = oUnitGroup.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡ÔñÖ°Ô±-°´°à×é
///
/// Ñ¡ÔñÖ°Ô±-°´°à×é
///
///
public static void SetTextByEmp_Group(TextBox txt, long HGroupID)
{
DAL.ClsGy_Employee_View oEmp = new DAL.ClsGy_Employee_View();
if (oEmp.RefreshView("and HGroupID=" + HGroupID))
{
txt.Text = oEmp.oModel.HName;
txt.Tag = oEmp.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ðé²Ö²Ö¿â
///
/// ²Ö¿â
///
///
public static void SetTextByVirtualWarehouse(TextBox txt)
{
DAL.ClsGy_VirtualWarehouse_View oWare = new DAL.ClsGy_VirtualWarehouse_View();
if (oWare.RefreshView())
{
txt.Text = oWare.oModel.HName;
txt.Tag = oWare.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡ÔñÐé²Ö³öÈëÀàÐÍ
///
/// Ñ¡ÔñÐé²Ö³öÈëÀàÐÍ
///
///
public static void SetTextByVirtualStockClass(TextBox txt)
{
DAL.ClsGy_VirtualStockClass_View oVSC = new DAL.ClsGy_VirtualStockClass_View();
if (oVSC.RefreshView())
{
txt.Text = oVSC.oModel.HName;
txt.Tag = oVSC.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¼ì¾ß
///
/// ¼ì¾ß
///
///
public static void SetTextByCheckTools(TextBox txt)
{
DAL.ClsGy_CheckToolsFileMain_View oCheck = new DAL.ClsGy_CheckToolsFileMain_View();
if (oCheck.RefreshView())
{
txt.Text = oCheck.oModel.HName;
txt.Tag = oCheck.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡Ôñ»õÔ˹«Ë¾
///
/// Ñ¡Ôñ»õÔ˹«Ë¾
///
///
public static void SetTextByConveyComp(TextBox txt)
{
DAL.ClsGy_ConveyComp_View oConveyComp = new DAL.ClsGy_ConveyComp_View();
if (oConveyComp.RefreshView())
{
txt.Text = oConveyComp.oModel.HName;
txt.Tag = oConveyComp.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡Ôñµµ°¸¹ñ
///
/// Ñ¡Ôñµµ°¸¹ñ
///
///
public static void SetTextByArchivesArk(TextBox txt)
{
DAL.ClsGy_ArchivesArk_View oArchivesArk = new DAL.ClsGy_ArchivesArk_View();
if (oArchivesArk.RefreshView())
{
txt.Text = oArchivesArk.oModel.HName;
txt.Tag = oArchivesArk.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡Ôñµµ°¸²ã
///
/// Ñ¡Ôñµµ°¸²ã
///
///
public static void SetTextByArchivesFloor(TextBox txt)
{
DAL.ClsGy_ArchivesFloor_View oArchivesFloor = new DAL.ClsGy_ArchivesFloor_View();
if (oArchivesFloor.RefreshView())
{
txt.Text = oArchivesFloor.oModel.HName;
txt.Tag = oArchivesFloor.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡ÔñµØÇø
///
/// Ñ¡ÔñµØÇø
///
///
public static void SetTextByAreaSet(TextBox txt)
{
DAL.ClsGy_AreaSet_View oAreaSet = new DAL.ClsGy_AreaSet_View();
if (oAreaSet.RefreshView())
{
txt.Text = oAreaSet.omodel.HName;
txt.Tag = oAreaSet.omodel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²»Á¼ÔÒò
///
/// ²»Á¼ÔÒò
///
///
public static void SetTextByBadReason(TextBox txt)
{
DAL.ClsGy_BadReason_View oBadReason = new DAL.ClsGy_BadReason_View();
if (oBadReason.RefreshView())
{
txt.Text = oBadReason.oModel.HName;
txt.Tag = oBadReason.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ÒøÐÐ
///
/// ÒøÐÐ
///
///
public static void SetTextByBank(TextBox txt)
{
DAL.ClsGy_Bank_View oBank = new DAL.ClsGy_Bank_View();
if (oBank.RefreshView())
{
txt.Text = oBank.oModel.HName;
txt.Tag = oBank.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//³µÁ¾
///
/// ³µÁ¾
///
///
public static void SetTextByCar(TextBox txt)
{
DAL.ClsGy_Car_View oCar = new DAL.ClsGy_Car_View();
if (oCar.RefreshView())
{
txt.Text = oCar.oModel.HName;
txt.Tag = oCar.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¼¯Ì弯¼þ·½°¸
///
/// ¼¯Ì弯¼þ·½°¸
///
///
public static void SetTextByClassTimePrjGroup(TextBox txt)
{
DAL.ClsGy_ClassTimePrjGroup_View oCTPG = new DAL.ClsGy_ClassTimePrjGroup_View();
if (oCTPG.RefreshView())
{
txt.Text = oCTPG.oModel.HName;
txt.Tag = oCTPG.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹«Ë¾ÐÔÖÊ
///
/// ¹«Ë¾ÐÔÖÊ
///
///
public static void SetTextByComKind(TextBox txt)
{
DAL.ClsGy_ComKind_View oComKind = new DAL.ClsGy_ComKind_View();
if (oComKind.RefreshView())
{
txt.Text = oComKind.oModel.HName;
txt.Tag = oComKind.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹«Ë¾¹æÄ£
///
/// ¹«Ë¾¹æÄ£
///
///
public static void SetTextByComScope(TextBox txt)
{
DAL.ClsGy_ComScope_View oComScope = new DAL.ClsGy_ComScope_View();
if (oComScope.RefreshView())
{
txt.Text = oComScope.oModel.HName;
txt.Tag = oComScope.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹«Ë¾Àà±ð
///
/// ¹«Ë¾Àà±ð
///
///
public static void SetTextByComSort(TextBox txt)
{
DAL.ClsGy_ComSort_View oComSort = new DAL.ClsGy_ComSort_View();
if (oComSort.RefreshView())
{
txt.Text = oComSort.oModel.HName;
txt.Tag = oComSort.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹«Ë¾ÀàÐÍ/
///
/// ¹«Ë¾ÀàÐÍ
///
///
public static void SetTextByComType(TextBox txt)
{
DAL.ClsGy_ComType_View oComType = new DAL.ClsGy_ComType_View();
if (oComType.RefreshView())
{
txt.Text = oComType.oModel.HName;
txt.Tag = oComType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹ÊÕÏÔÒò
///
/// ¹ÊÕÏÔÒò
///
///
public static void SetTextByConkReason(TextBox txt)
{
DAL.ClsGy_ConkReason_View oConkReason = new DAL.ClsGy_ConkReason_View();
if (oConkReason.RefreshView())
{
txt.Text = oConkReason.oModel.HName;
txt.Tag = oConkReason.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹ÊÕÏÀà±ð
///
/// ¹ÊÕÏÀà±ð
///
///
public static void SetTextByConkType(TextBox txt)
{
DAL.ClsGy_ConkType_View oConkType = new DAL.ClsGy_ConkType_View();
if (oConkType.RefreshView())
{
txt.Text = oConkType.oModel.HName;
txt.Tag = oConkType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//³É±¾ÖÐÐÄ
///
/// ³É±¾ÖÐÐÄ
///
///
public static void SetTextByCostCenter(TextBox txt)
{
DAL.ClsGy_CostCenter_View oCostCenter = new DAL.ClsGy_CostCenter_View();
if (oCostCenter.RefreshView())
{
txt.Text = oCostCenter.oModel.HName;
txt.Tag = oCostCenter.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//±Ò±ð
///
/// ±Ò±ð
///
///
///
public static void SetTextByCur(TextBox txt, TextBox txtHRate)
{
DAL.ClsGy_Currency_View oCur = new DAL.ClsGy_Currency_View();
if (oCur.RefreshView())
{
if (oCur.GetInfoByID(oCur.oModel.HItemID))
{
txt.Text = oCur.omodel.HName;
txt.Tag = oCur.omodel.HItemID.ToString();
txtHRate.Text = oCur.omodel.HExchangeRate.ToString();
}
}
else
{
txt.Text = "";
txtHRate.Text = "1";
}
}
//±Ò±ð
///
/// ±Ò±ð ·µ»Ø´úÂë
///
///
///
public static void SetTextByCur(TextBox txt,bool backNumber)
{
DAL.ClsGy_Currency_View oCur = new DAL.ClsGy_Currency_View();
if (oCur.RefreshView())
{
if (oCur.GetInfoByID(oCur.oModel.HItemID))
{
txt.Text = oCur.omodel.HNumber;
txt.Tag = oCur.omodel.HItemID.ToString();
}
}
else
{
txt.Text = "";
}
}
//¿Í»§
///
/// ¿Í»§
///
///
public static void SetTextByCus(TextBox txt)
{
DAL.ClsGy_Customer_View oCus = new DAL.ClsGy_Customer_View();
if (oCus.RefreshView())
{
txt.Text = oCus.oModel.HName;
txt.Tag = oCus.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¿Í»§·ÖÀà
///
/// ¿Í»§·ÖÀà
///
///
public static void SetTextByCusType(TextBox txt)
{
DAL.ClsGy_CusType_View oCusType = new DAL.ClsGy_CusType_View();
if (oCusType.RefreshView())
{
txt.Text = oCusType.oModel.HName;
txt.Tag = oCusType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²¿ÃÅ
///
/// ²¿ÃÅ
///
///
public static void SetTextByDept(TextBox txt)
{
DAL.ClsGy_Department_View oDept = new DAL.ClsGy_Department_View();
if (oDept.RefreshView())
{
txt.Text = oDept.oModel.HName;
txt.Tag = oDept.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
////²¿ÃŽӿÚ
/////
///// ²¿ÃŽӿÚ
/////
/////
//public static void SetTextByDept_IF(TextBox txt)
//{
// DAL.ClsIF_Department_View oDept = new DAL.ClsIF_Department_View();
// if (oDept.RefreshView())
// {
// txt.Text = oDept.oModel.HName;
// txt.Tag = oDept.oModel.HItemID.ToString();
// }
// else
// {
// txt.Text = "";
// }
//}
//²¿ÃÅ
///
/// ²¿ÃÅ ·µ»Ø´úÂë
///
///
public static void SetTextByDept(TextBox txt,bool backNumber)
{
DAL.ClsGy_Department_View oDept = new DAL.ClsGy_Department_View();
if (oDept.RefreshView())
{
txt.Text = oDept.oModel.HNumber;
txt.Tag = oDept.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ËÞÉá
///
/// ËÞÉá
///
///
public static void SetTextByDorm(TextBox txt)
{
DAL.ClsGy_Dorm_View oDorm = new DAL.ClsGy_Dorm_View();
if (oDorm.RefreshView())
{
txt.Text = oDorm.oModel.HName;
txt.Tag = oDorm.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¿Û²¹×ÊÁÏ
///
/// ¿Û²¹×ÊÁÏ
///
///
public static void SetTextByDuSubsidyItem(TextBox txt)
{
DAL.ClsGy_DuSubsidyItem_View oDuSubsidyItem = new DAL.ClsGy_DuSubsidyItem_View();
if (oDuSubsidyItem.RefreshView())
{
txt.Text = oDuSubsidyItem.oModel.HName;
txt.Tag = oDuSubsidyItem.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ö°Îñ
///
/// Ö°Îñ
///
///
public static void SetTextByDuty(TextBox txt)
{
DAL.ClsGy_Duty_View oDuty = new DAL.ClsGy_Duty_View();
if (oDuty.RefreshView())
{
txt.Text = oDuty.oModel.HName;
txt.Tag = oDuty.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡ÔñÖ°Ô±
///
/// Ñ¡ÔñÖ°Ô±
///
///
public static void SetTextByEmp(TextBox txt)
{
DAL.ClsGy_Employee_View oEmp = new DAL.ClsGy_Employee_View();
if (oEmp.RefreshView())
{
txt.Text = oEmp.oModel.HName;
txt.Tag = oEmp.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ñ¡ÔñÖ°Ô±
///
/// Ñ¡ÔñÖ°Ô±
///
///
public static void SetTextByEmp(TextBox txt,TextBox txtName)
{
DAL.ClsGy_Employee_View oEmp = new DAL.ClsGy_Employee_View();
if (oEmp.RefreshView())
{
txt.Text = oEmp.oModel.HNumber;
txt.Tag = oEmp.oModel.HItemID.ToString();
txtName.Text = oEmp.oModel.HName;
}
else
{
txt.Text = "";
txtName.Text = "";
}
}
//ÄÜÔ´ÏîÄ¿
///
/// ÄÜÔ´ÏîÄ¿
///
///
public static void SetTextByEnergy(TextBox txt)
{
DAL.ClsGy_Energy_View oEnergy = new DAL.ClsGy_Energy_View();
if (oEnergy.RefreshView())
{
txt.Text = oEnergy.oModel.HName;
txt.Tag = oEnergy.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//É豸
///
/// É豸
///
///
public static void SetTextByEquipMent(TextBox txt)
{
DAL.ClsGy_EquipMent_View oEquipMent = new DAL.ClsGy_EquipMent_View();
if (oEquipMent.RefreshView())
{
txt.Text = oEquipMent.oModel.HName;
txt.Tag = oEquipMent.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Òì³£ÀàÐÍ
///
/// Òì³£ÀàÐÍ
///
///
public static void SetTextByErrType(TextBox txt)
{
DAL.ClsGy_ErrType_View oErrType = new DAL.ClsGy_ErrType_View();
if (oErrType.RefreshView())
{
txt.Text = oErrType.oModel.HName;
txt.Tag = oErrType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ÆÀ¼ÛÇé¿ö
///
/// ÆÀ¼ÛÇé¿ö
///
///
public static void SetTextByEvaluateStatus(TextBox txt)
{
DAL.ClsGy_EvaluateStatus_View oEvaluateStatus = new DAL.ClsGy_EvaluateStatus_View();
if (oEvaluateStatus.RefreshView())
{
txt.Text = oEvaluateStatus.oModel.HName;
txt.Tag = oEvaluateStatus.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//·ÑÓÃÇé¿ö
///
/// ·ÑÓÃÇé¿ö
///
///
public static void SetTextByExpenseStatus(TextBox txt)
{
DAL.ClsGy_ExpenseStatus_View oExpenseStatus = new DAL.ClsGy_ExpenseStatus_View();
if (oExpenseStatus.RefreshView())
{
txt.Text = oExpenseStatus.oModel.HName;
txt.Tag = oExpenseStatus.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//³§¼Ò
///
/// ³§¼Ò
///
///
public static void SetTextByFactory(TextBox txt)
{
DAL.ClsGy_Factory_View oFactory = new DAL.ClsGy_Factory_View();
if (oFactory.RefreshView())
{
txt.Text = oFactory.oModel.HName;
txt.Tag = oFactory.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//°à×é
///
/// °à×é
///
///
public static void SetTextByGroup(TextBox txt)
{
DAL.ClsGy_Group_View oGroup = new DAL.ClsGy_Group_View();
if (oGroup.RefreshView())
{
txt.Text = oGroup.oModel.HName;
txt.Tag = oGroup.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//°à×é
///
/// °à×é
///
///
public static void SetTextByGroup(TextBox txt,TextBox txtName)
{
DAL.ClsGy_Group_View oGroup = new DAL.ClsGy_Group_View();
if (oGroup.RefreshView())
{
txt.Text = oGroup.oModel.HNumber;
txt.Tag = oGroup.oModel.HItemID.ToString();
txtName.Text = oGroup.oModel.HName;
}
else
{
txt.Text = "";
txtName.Text = "";
}
}
//½Ú¼ÙÈÕ
///
/// ½Ú¼ÙÈÕ
///
///
public static void SetTextByHoliday(TextBox txt)
{
DAL.ClsGy_Holiday_View oHoliday = new DAL.ClsGy_Holiday_View();
if (oHoliday.RefreshView())
{
txt.Text = oHoliday.oModel.HName;
txt.Tag = oHoliday.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//±£ÑøÏîÄ¿
///
/// ±£ÑøÏîÄ¿
///
///
public static void SetTextByMaintain(TextBox txt)
{
DAL.ClsGy_Maintain_View oMaintain = new DAL.ClsGy_Maintain_View();
if (oMaintain.RefreshView())
{
txt.Text = oMaintain.oModel.HName;
txt.Tag = oMaintain.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¿Í»§¶ÔÓ¦ÎïÁÏ
///
/// ¿Í»§¶ÔÓ¦ÎïÁÏ
///
///
public static void SetTextByMateNumRelation(TextBox txt)
{
DAL.ClsGy_MateNumRelation_View oMateNumRelation = new DAL.ClsGy_MateNumRelation_View();
if (oMateNumRelation.RefreshView())
{
txt.Text = oMateNumRelation.oModel.HName;
txt.Tag = oMateNumRelation.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ÎïÁÏ
///
/// ÎïÁÏ
///
/// ´úÂëÎı¾¿ò
/// Ãû³ÆÎı¾¿ò
/// ¹æ¸ñÎı¾¿ò
/// µ¥Î»Îı¾¿ò
public static void SetTextByMaterial(TextBox txtNumber, TextBox txtName, TextBox txtModel, TextBox txtUnit)
{
DAL.ClsGy_Material_View oMaterial = new DAL.ClsGy_Material_View();
DAL.ClsGy_Unit_View oUnit = new DAL.ClsGy_Unit_View();
if (oMaterial.RefreshView())
{
if (oMaterial.GetInfoByID(oMaterial.oModel.HItemID))
{
txtNumber.Text = oMaterial.omodel.HNumber;
txtNumber.Tag = oMaterial.omodel.HItemID.ToString();
txtName.Text = oMaterial.omodel.HName;
txtModel.Text = oMaterial.omodel.HModel;
if (oUnit.GetInfoByID(oMaterial.omodel.HUnitID))
{
txtUnit.Text = oUnit.omodel.HName;
txtUnit.Tag = oUnit.omodel.HItemID.ToString();
}
else
{
txtUnit.Text = "";
txtUnit.Tag = "0";
}
}
else
{
txtNumber.Text = "";
txtNumber.Tag = "0";
txtName.Text = "";
txtModel.Text = "";
txtUnit.Text = "";
txtUnit.Tag = "0";
}
}
else
{
txtNumber.Text = "";
txtNumber.Tag = "0";
txtName.Text = "";
txtModel.Text = "";
txtUnit.Text = "";
txtUnit.Tag = "0";
}
}
//ÎïÁÏ
///
/// ÎïÁÏ Ö»·µ»Ø´úÂë
///
/// ´úÂëÎı¾¿ò
public static void SetTextByMaterial(TextBox txtNumber)
{
DAL.ClsGy_Material_View oMaterial = new DAL.ClsGy_Material_View();
if (oMaterial.RefreshView())
{
if (oMaterial.GetInfoByID(oMaterial.oModel.HItemID))
{
txtNumber.Text = oMaterial.omodel.HNumber;
txtNumber.Tag = oMaterial.omodel.HItemID.ToString();
}
else
{
txtNumber.Text = "";
txtNumber.Tag = "0";
}
}
else
{
txtNumber.Text = "";
txtNumber.Tag = "0";
}
}
//ÎïÁÏÌØÐÔ
///
/// ÎïÁÏÌØÐÔ
///
///
public static void SetTextByMaterTrait(TextBox txt)
{
DAL.ClsGy_MaterTrait_View oMaterTrait = new DAL.ClsGy_MaterTrait_View();
if (oMaterTrait.RefreshView())
{
txt.Text = oMaterTrait.oModel.HName;
txt.Tag = oMaterTrait.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹æ¸ñÐͺÅ
///
/// ¹æ¸ñÐͺÅ
///
///
public static void SetTextByModel(TextBox txt)
{
DAL.ClsGy_Model_View oModel = new DAL.ClsGy_Model_View();
if (oModel.RefreshView())
{
txt.Text = oModel.oModel.HName;
txt.Tag = oModel.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¶©µ¥µÈ¼¶
///
/// ¶©µ¥µÈ¼¶
///
///
public static void SetTextByOrderLev(TextBox txt)
{
DAL.ClsGy_OrderLev_View oOrderLev = new DAL.ClsGy_OrderLev_View();
if (oOrderLev.RefreshView())
{
txt.Text = oOrderLev.oModel.HName;
txt.Tag = oOrderLev.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Ö¤¼þÀà±ð
///
/// Ö¤¼þÀà±ð
///
///
public static void SetTextByPaperSort(TextBox txt)
{
DAL.ClsGy_PaperSort_View oPaperSort = new DAL.ClsGy_PaperSort_View();
if (oPaperSort.RefreshView())
{
txt.Text = oPaperSort.oModel.HName;
txt.Tag = oPaperSort.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//×ÊÔ´ÄÜÁ¦
///
/// ×ÊÔ´ÄÜÁ¦
///
///
public static void SetTextByPlanShifts(TextBox txt)
{
//DAL.ClsGy_PlanShifts_View oPlanShifts = new DAL.ClsGy_PlanShifts_View();
//if (oPlanShifts.RefreshView())
//{
// txt.Text = oPlanShifts.oModel.HName;
// txt.Tag = oPlanShifts.oModel.HItemID.ToString();
//}
//else
//{
// txt.Text = "";
//}
}
//¸Û¿Ú
///
/// ¸Û¿Ú
///
///
public static void SetTextByPort(TextBox txt)
{
DAL.ClsGy_Port_View oPort = new DAL.ClsGy_Port_View();
if (oPort.RefreshView())
{
txt.Text = oPort.oModel.HName;
txt.Tag = oPort.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¸Úλ
///
/// ¸Úλ
///
///
public static void SetTextByPost(TextBox txt)
{
DAL.ClsGy_Post_View oPost = new DAL.ClsGy_Post_View();
if (oPost.RefreshView())
{
txt.Text = oPost.oModel.HName;
txt.Tag = oPost.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²É¹º·½Ê½
///
/// ²É¹º·½Ê½
///
///
public static void SetTextByPoStockStyle(TextBox txt)
{
DAL.ClsGy_PoStockStyle_View oPoStockStyle = new DAL.ClsGy_PoStockStyle_View();
if (oPoStockStyle.RefreshView())
{
txt.Text = oPoStockStyle.oModel.HName;
txt.Tag = oPoStockStyle.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ίÍ⹤Ðò
///
/// ίÍ⹤Ðò
///
///
public static void SetTextByProcComm(TextBox txt)
{
DAL.ClsGy_ProcComm_View oProcComm = new DAL.ClsGy_ProcComm_View();
if (oProcComm.RefreshView())
{
txt.Text = oProcComm.oModel.HName;
txt.Tag = oProcComm.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹¤Ðò
///
/// ¹¤Ðò
///
///
public static void SetTextByProcess(TextBox txt)
{
DAL.ClsGy_Process_View oProcess = new DAL.ClsGy_Process_View();
if (oProcess.RefreshView())
{
txt.Text = oProcess.oModel.HName;
txt.Tag = oProcess.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹¤¶Î
///
/// ¹¤¶Î
///
///
public static void SetTextByProcMul(TextBox txt)
{
DAL.ClsGy_ProcMul_View oProcMul = new DAL.ClsGy_ProcMul_View();
if (oProcMul.RefreshView())
{
txt.Text = oProcMul.oModel.HName;
txt.Tag = oProcMul.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¶¨¶î¹é¼¯
///
/// ¶¨¶î¹é¼¯
///
///
public static void SetTextByProcPriceRela(TextBox txt)
{
DAL.ClsGy_ProcPriceRela_View oProcPriceRela = new DAL.ClsGy_ProcPriceRela_View();
if (oProcPriceRela.RefreshView())
{
txt.Text = oProcPriceRela.oModel.HName;
txt.Tag = oProcPriceRela.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¶¨¶î¹é¼¯×é
///
/// ¶¨¶î¹é¼¯×é
///
///
public static void SetTextByProcPriceRelaGroup(TextBox txt)
{
DAL.ClsGy_ProcPriceRelaGroup_View oPriceRelaGroup = new DAL.ClsGy_ProcPriceRelaGroup_View();
if (oPriceRelaGroup.RefreshView())
{
txt.Text = oPriceRelaGroup.oModel.HName;
txt.Tag = oPriceRelaGroup.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Éú²úÀàÐÍ
///
/// Éú²úÀàÐÍ
///
///
public static void SetTextByProdType(TextBox txt)
{
DAL.ClsGy_ProdType_View oProdType = new DAL.ClsGy_ProdType_View();
if (oProdType.RefreshView())
{
txt.Text = oProdType.oModel.HName;
txt.Tag = oProdType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²úÆ·ÌØÐÔ
///
/// ²úÆ·ÌØÐÔ
///
///
public static void SetTextByProductSpec(TextBox txt)
{
DAL.ClsGy_ProductSpec_View oProductSpec = new DAL.ClsGy_ProductSpec_View();
if (oProductSpec.RefreshView())
{
txt.Text = oProductSpec.oModel.HName;
txt.Tag = oProductSpec.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ÏîÄ¿¹¤³Ì
///
/// ÏîÄ¿¹¤³Ì
///
///
public static void SetTextByProject(TextBox txt)
{
DAL.ClsGy_Project_View oProject = new DAL.ClsGy_Project_View();
if (oProject.RefreshView())
{
txt.Text = oProject.oModel.HName;
txt.Tag = oProject.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¸¨ÖúÊôÐÔ
///
/// ¸¨ÖúÊôÐÔ
///
///
public static void SetTextByProperty(TextBox txt)
{
DAL.ClsGy_Property_View oProperty = new DAL.ClsGy_Property_View();
if (oProperty.RefreshView())
{
txt.Text = oProperty.oModel.HName;
txt.Tag = oProperty.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¸¨ÖúÊôÐÔÀà±ð
///
/// ¸¨ÖúÊôÐÔÀà±ð
///
///
public static void SetTextByPropertyType(TextBox txt)
{
DAL.ClsGy_PropertyType_View oPropertyType = new DAL.ClsGy_PropertyType_View();
if (oPropertyType.RefreshView())
{
txt.Text = oPropertyType.oModel.HName;
txt.Tag = oPropertyType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//άÐÞÏîÄ¿
///
/// άÐÞÏîÄ¿
///
///
public static void SetTextByRepair(TextBox txt)
{
DAL.ClsGy_Repair_View oRepair = new DAL.ClsGy_Repair_View();
if (oRepair.RefreshView())
{
txt.Text = oRepair.oModel.HName;
txt.Tag = oRepair.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//άÐÞÑéÊÕÏîÄ¿
///
/// άÐÞÑéÊÕÏîÄ¿
///
///
public static void SetTextByRepairCheck(TextBox txt)
{
DAL.ClsGy_RepairCheck_View oRepairCheck = new DAL.ClsGy_RepairCheck_View();
if (oRepairCheck.RefreshView())
{
txt.Text = oRepairCheck.oModel.HName;
txt.Tag = oRepairCheck.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//άÐÞ·½Ê½
///
/// άÐÞ·½Ê½
///
///
public static void SetTextByRepairType(TextBox txt)
{
DAL.ClsGy_RepairType_View oRepairType = new DAL.ClsGy_RepairType_View();
if (oRepairType.RefreshView())
{
txt.Text = oRepairType.oModel.HName;
txt.Tag = oRepairType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹¤ÒÕ·Ïß´óÀà
///
/// ¹¤ÒÕ·Ïß´óÀà
///
///
public static void SetTextByRoutingGroup(TextBox txt)
{
DAL.ClsGy_RoutingGroup_View oRoutingGroup = new DAL.ClsGy_RoutingGroup_View();
if (oRoutingGroup.RefreshView())
{
txt.Text = oRoutingGroup.oModel.HName;
txt.Tag = oRoutingGroup.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//°²È«ÏîÄ¿
///
/// °²È«ÏîÄ¿
///
///
public static void SetTextBySafety(TextBox txt)
{
DAL.ClsGy_Safety_View oSafety = new DAL.ClsGy_Safety_View();
if (oSafety.RefreshView())
{
txt.Text = oSafety.oModel.HName;
txt.Tag = oSafety.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//±¨·ÏÔÒò
///
/// ±¨·ÏÔÒò
///
///
public static void SetTextByScrapReason(TextBox txt)
{
DAL.ClsGy_ScrapReason_View oScrapReason = new DAL.ClsGy_ScrapReason_View();
if (oScrapReason.RefreshView())
{
txt.Text = oScrapReason.oModel.HName;
txt.Tag = oScrapReason.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//·þÎñÀàÐÍ
///
/// ·þÎñÀàÐÍ
///
///
public static void SetTextBySecType(TextBox txt)
{
DAL.ClsGy_SecType_View oSecType = new DAL.ClsGy_SecType_View();
if (oSecType.RefreshView())
{
txt.Text = oSecType.oModel.HName;
txt.Tag = oSecType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ÏúÊÛ·½Ê½
///
/// ÏúÊÛ·½Ê½
///
///
public static void SetTextBySellStyle(TextBox txt)
{
DAL.ClsGy_SellStyle_View oSellStyle = new DAL.ClsGy_SellStyle_View();
if (oSellStyle.RefreshView())
{
txt.Text = oSellStyle.oModel.HName;
txt.Tag = oSellStyle.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//½áË㷽ʽ
///
/// ½áË㷽ʽ
///
///
public static void SetTextBySettleStyle(TextBox txt)
{
DAL.ClsGy_SettleStyle_View oSettleStyle = new DAL.ClsGy_SettleStyle_View();
if (oSettleStyle.RefreshView())
{
txt.Text = oSettleStyle.oModel.HName;
txt.Tag = oSettleStyle.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//°à´Î
///
/// °à´Î
///
///
public static void SetTextByShifts(TextBox txt)
{
DAL.ClsGy_Shifts_View oShifts = new DAL.ClsGy_Shifts_View();
if (oShifts.RefreshView())
{
txt.Text = oShifts.oModel.HName;
txt.Tag = oShifts.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Éú²ú×ÊÔ´
///
/// Éú²ú×ÊÔ´
///
///
public static void SetTextBySource(TextBox txt)
{
DAL.ClsGy_Source_View oSource = new DAL.ClsGy_Source_View();
if (oSource.RefreshView())
{
txt.Text = oSource.oModel.HName;
txt.Tag = oSource.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Èë¿âÀàÐÍ
///
/// Èë¿âÀàÐÍ
///
///
public static void SetTextByStockInStyle(TextBox txt)
{
DAL.ClsGy_StockInStyle_View oStockInStyle = new DAL.ClsGy_StockInStyle_View();
if (oStockInStyle.RefreshView())
{
txt.Text = oStockInStyle.oModel.HName;
txt.Tag = oStockInStyle.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//³ö¿âÀàÐÍ
///
/// ³ö¿âÀàÐÍ
///
///
public static void SetTextByStockOutStyle(TextBox txt)
{
DAL.ClsGy_StockOutStyle_View oStockOutStyle = new DAL.ClsGy_StockOutStyle_View();
if (oStockOutStyle.RefreshView())
{
txt.Text = oStockOutStyle.oModel.HName;
txt.Tag = oStockOutStyle.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²Öλ
///
/// ²Öλ
///
///
public static void SetTextByStockPlace(TextBox txt)
{
DAL.ClsGy_StockPlace_View oStockPlace = new DAL.ClsGy_StockPlace_View();
if (oStockPlace.RefreshView())
{
txt.Text = oStockPlace.oModel.HName;
txt.Tag = oStockPlace.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²Öλ×é
///
/// ²Öλ×é
///
///
public static void SetTextByStockPlaceGroup(TextBox txt)
{
DAL.ClsGy_StockPlaceGroup_View oStockPlaceGroup = new DAL.ClsGy_StockPlaceGroup_View();
if (oStockPlaceGroup.RefreshView())
{
txt.Text = oStockPlaceGroup.oModel.HName;
txt.Tag = oStockPlaceGroup.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹©Ó¦ÉÌ
///
/// ¹©Ó¦ÉÌ
///
///
public static void SetTextBySupplier(TextBox txt)
{
DAL.ClsGy_Supplier_View oSupplier = new DAL.ClsGy_Supplier_View();
if (oSupplier.RefreshView())
{
txt.Text = oSupplier.oModel.HName;
txt.Tag = oSupplier.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹©Ó¦ÉÌ
///
/// ¹©Ó¦ÉÌ ·µ»Ø´úÂë
///
///
public static void SetTextBySupplier(TextBox txt,bool backNumber)
{
DAL.ClsGy_Supplier_View oSupplier = new DAL.ClsGy_Supplier_View();
if (oSupplier.RefreshView())
{
txt.Text = oSupplier.oModel.HNumber;
txt.Tag = oSupplier.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹©Ó¦Àà±ð
///
/// ¹©Ó¦Àà±ð
///
///
public static void SetTextBySupSort(TextBox txt)
{
DAL.ClsGy_SupSort_View oSupSort = new DAL.ClsGy_SupSort_View();
if (oSupSort.RefreshView())
{
txt.Text = oSupSort.oModel.HName;
txt.Tag = oSupSort.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹©Ó¦É̵ȼ¶
///
/// ¹©Ó¦É̵ȼ¶
///
///
public static void SetTextBySupStatus(TextBox txt)
{
DAL.ClsGy_SupStatus_View oSupStatus = new DAL.ClsGy_SupStatus_View();
if (oSupStatus.RefreshView())
{
txt.Text = oSupStatus.oModel.HName;
txt.Tag = oSupStatus.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹©Ó¦ÉÌÖ¸±ê
///
/// ¹©Ó¦ÉÌÖ¸±ê
///
///
public static void SetTextBySupTarget(TextBox txt)
{
DAL.ClsGy_SupTarget_View oSupTarget = new DAL.ClsGy_SupTarget_View();
if (oSupTarget.RefreshView())
{
txt.Text = oSupTarget.oModel.HName;
txt.Tag = oSupTarget.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹©Ó¦ÉÌ·ÖÀà
///
/// ¹©Ó¦ÉÌ·ÖÀà
///
///
public static void SetTextBySupType(TextBox txt)
{
DAL.ClsGy_SupType_View oSupType = new DAL.ClsGy_SupType_View();
if (oSupType.RefreshView())
{
txt.Text = oSupType.oModel.HName;
txt.Tag = oSupType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//ËùÊôÐÐÒµ
///
/// ËùÊôÐÐÒµ
///
///
public static void SetTextByTrade(TextBox txt)
{
DAL.ClsGy_Trade_View oTrade = new DAL.ClsGy_Trade_View();
if (oTrade.RefreshView())
{
txt.Text = oTrade.oModel.HName;
txt.Tag = oTrade.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¼ÆÁ¿µ¥Î»
///
/// ¼ÆÁ¿µ¥Î»
///
///
public static void SetTextByUnit(TextBox txt)
{
DAL.ClsGy_Unit_View oUnit = new DAL.ClsGy_Unit_View();
if (oUnit.RefreshView())
{
txt.Text = oUnit.oModel.HName;
txt.Tag = oUnit.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¼ÆÁ¿µ¥Î»
///
/// ¼ÆÁ¿µ¥Î»
///
///
public static void SetTextByUnit(TextBox txt,string sWhere)
{
DAL.ClsGy_Unit_View oUnit = new DAL.ClsGy_Unit_View();
if (oUnit.RefreshView(sWhere))
{
txt.Text = oUnit.oModel.HName;
txt.Tag = oUnit.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¼ÆÁ¿µ¥Î»×é
///
/// ¼ÆÁ¿µ¥Î»×é
///
///
public static void SetTextByUnitGroup(TextBox txt)
{
DAL.ClsGy_UnitGroup_View oUnitGroup = new DAL.ClsGy_UnitGroup_View();
if (oUnitGroup.RefreshView())
{
txt.Text = oUnitGroup.oModel.HName;
txt.Tag = oUnitGroup.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²Ö¿â
///
/// ²Ö¿â
///
///
public static void SetTextByWarehouse(TextBox txt)
{
DAL.ClsGy_Warehouse_View oWarehouse = new DAL.ClsGy_Warehouse_View();
if (oWarehouse.RefreshView())
{
txt.Text = oWarehouse.oModel.HName;
txt.Tag = oWarehouse.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²Ö¿â
///
/// ²Ö¿â Ö»·µ»Ø´úÂë
///
///
public static void SetTextByWarehouse(TextBox txt,bool backNumber)
{
DAL.ClsGy_Warehouse_View oWarehouse = new DAL.ClsGy_Warehouse_View();
if (oWarehouse.RefreshView())
{
txt.Text = oWarehouse.oModel.HNumber;
txt.Tag = oWarehouse.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹¤×÷ÖÐÐÄ
///
/// ¹¤×÷ÖÐÐÄ
///
///
public static void SetTextByWorkCenter(TextBox txt)
{
DAL.ClsGy_WorkCenter_View oWorkCenter = new DAL.ClsGy_WorkCenter_View();
if (oWorkCenter.RefreshView())
{
txt.Text = oWorkCenter.oModel.HName;
txt.Tag = oWorkCenter.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹¤×ÊÀàÐÍ
///
/// ¹¤×ÊÀàÐÍ
///
///
public static void SetTextByWorkPayType(TextBox txt)
{
DAL.ClsGy_WorkPayType_View oWorkPayType = new DAL.ClsGy_WorkPayType_View();
if (oWorkPayType.RefreshView())
{
txt.Text = oWorkPayType.oModel.HName;
txt.Tag = oWorkPayType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//¹¤ÖÖ
///
/// ¹¤ÖÖ
///
///
public static void SetTextByWorkType(TextBox txt)
{
DAL.ClsGy_WorkType_View oWorkType = new DAL.ClsGy_WorkType_View();
if (oWorkType.RefreshView())
{
txt.Text = oWorkType.oModel.HName;
txt.Tag = oWorkType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Òì³£¹¤¼Û
///
/// Òì³£¹¤¼Û
///
///
public static void SetTextByErrWorkPirce(TextBox txt)
{
DAL.ClsGy_ErrWorkPrice_View oWorkPrice = new DAL.ClsGy_ErrWorkPrice_View();
if (oWorkPrice.RefreshView())
{
txt.Text = oWorkPrice.oModel.HName;
txt.Tag = oWorkPrice.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//²É¼¯Æ÷
///
/// ²É¼¯Æ÷
///
///
public static void SetTextByCollect(TextBox txt)
{
DAL.ClsGy_Collect_View oCollect = new DAL.ClsGy_Collect_View();
if (oCollect.RefreshView())
{
txt.Text = oCollect.oModel.HName;
txt.Tag = oCollect.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Òµ»§
///
/// Òµ»§
///
///
public static void SetTextByRoom(TextBox txt)
{
DAL.ClsGy_Room_View oRoom = new DAL.ClsGy_Room_View();
if (oRoom.RefreshView())
{
txt.Text = oRoom.oModel.HName;
txt.Tag = oRoom.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//Â¥ºÅ
///
/// Â¥ºÅ
///
///
public static void SetTextByBuilding(TextBox txt)
{
DAL.ClsGy_Building_View oBuilding = new DAL.ClsGy_Building_View();
if (oBuilding.RefreshView())
{
txt.Text = oBuilding.oModel.HName;
txt.Tag = oBuilding.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
//»§ÐÍ
///
/// »§ÐÍ
///
///
public static void SetTextByHouseType(TextBox txt)
{
DAL.ClsGy_HouseType_View oHouseType = new DAL.ClsGy_HouseType_View();
if (oHouseType.RefreshView())
{
txt.Text = oHouseType.oModel.HName;
txt.Tag = oHouseType.oModel.HItemID.ToString();
}
else
{
txt.Text = "";
}
}
#endregion
#region ÉèÖÃÍø¸ñ
//²Öλ-Íø¸ñ ¸ù¾Ý²Ö¿â
///
/// ²Öλ-Íø¸ñ ¸ù¾Ý²Ö¿â
///
///
///
///
///
///
public static void SetGridByStockPlaceByWh(DataGridView grdMain, int i, int HWhIDCol, int HStockPlaceIDCol, int HStockPlaceNumberCol, int HStockPlaceNameCol)
{
DAL.ClsGy_StockPlace_View oStockPlace = new DAL.ClsGy_StockPlace_View();
if (oStockPlace.RefreshView())
{
if (oStockPlace.GetInfoByID(oStockPlace.oModel.HItemID))
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = oStockPlace.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = oStockPlace.omodel.HNumber;
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = oStockPlace.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = "";
}
}
//²Öλ-Íø¸ñ ¸ù¾Ý²Ö¿â
///
/// ²Öλ-Íø¸ñ ¸ù¾Ý²Ö¿â
///
///
///
///
///
///
public static void SetGridByStockPlaceByWh(DataGridView grdMain, int i, int HWhIDCol, int HStockPlaceIDCol, int HStockPlaceNumberCol, int HStockPlaceNameCol, int HSPGroupIDCol, int HSPGroupNameCol, ref string sBackStr)
{
DAL.ClsGy_StockPlace_View oSP = new DAL.ClsGy_StockPlace_View();
DAL.ClsGy_StockPlaceGroup_View oSPGroup = new DAL.ClsGy_StockPlaceGroup_View();
if (DBUtility.ClsPub.isLong(grdMain.Rows[i].Cells[HWhIDCol].Value) == 0)
{
sBackStr = "ûÓÐÑ¡Ôñ²Ö¿â£¡";
return;
}
if (oSP.RefreshViewByWh(DBUtility.ClsPub.isLong(grdMain.Rows[i].Cells[HWhIDCol].Value)))
{
if (oSP.GetInfoByID(oSP.oModel.HItemID))
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = oSP.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = oSP.omodel.HNumber;
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = oSP.omodel.HName;
if (oSPGroup.GetInfoByID(oSP.omodel.HSPGroupID))
{
grdMain.Rows[i].Cells[HSPGroupIDCol].Value = oSPGroup.omodel.HItemID;
grdMain.Rows[i].Cells[HSPGroupNameCol].Value = oSPGroup.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSPGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HSPGroupNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = "";
grdMain.Rows[i].Cells[HSPGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HSPGroupNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = "";
grdMain.Rows[i].Cells[HSPGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HSPGroupNameCol].Value = "";
}
}
//ÎïÁÏ-Íø¸ñ
///
/// ÎïÁÏ-Íø¸ñ
///
///
///
///
///
///
///
///
///
///
public static void SetGridByMater(DataGridView grdMain, int i, int HMaterIDCol, int HMaterNumberCol, int HMaterNameCol, int HMaterModelCol, int HUnitIDCol, int HUnitNumberCol, int HUnitNameCol)
{
DAL.ClsGy_Material_View oMater = new DAL.ClsGy_Material_View();
DAL.ClsGy_Unit_View oUnit = new DAL.ClsGy_Unit_View();
if (oMater.RefreshView())
{
if (oMater.GetInfoByID(oMater.oModel.HItemID))
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = oMater.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HMaterNumberCol].Value = oMater.omodel.HNumber;
grdMain.Rows[i].Cells[HMaterNameCol].Value = oMater.omodel.HName;
grdMain.Rows[i].Cells[HMaterModelCol].Value = oMater.omodel.HModel;
if (oUnit.GetInfoByID(oMater.omodel.HUnitID))
{
grdMain.Rows[i].Cells[HUnitNumberCol].Value = oUnit.omodel.HNumber;
grdMain.Rows[i].Cells[HUnitNameCol].Value = oUnit.omodel.HName;
grdMain.Rows[i].Cells[HUnitIDCol].Value = oUnit.omodel.HItemID.ToString();
}
else
{
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
}
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
grdMain.Rows[i].Cells[HMaterModelCol].Value = "";
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
}
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
grdMain.Rows[i].Cells[HMaterModelCol].Value = "";
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
}
}
///
/// ÎïÁÏ-Íø¸ñ ¸½¼ÓÊôÐÔ£¬ÑÕÉ«
///
///
///
///
///
///
///
///
///
///
public static void SetGridByMater(DataGridView grdMain, int i, int HMaterIDCol, int HMaterNumberCol, int HMaterNameCol, int HMaterModelCol, int HUnitIDCol, int HUnitNumberCol, int HUnitNameCol, int HSubjoinCol, int HColorCol)
{
DAL.ClsGy_Material_View oMater = new DAL.ClsGy_Material_View();
DAL.ClsGy_Unit_View oUnit = new DAL.ClsGy_Unit_View();
if (oMater.RefreshView())
{
if (oMater.GetInfoByID(oMater.oModel.HItemID))
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = oMater.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HMaterNumberCol].Value = oMater.omodel.HNumber;
grdMain.Rows[i].Cells[HMaterNameCol].Value = oMater.omodel.HName;
grdMain.Rows[i].Cells[HMaterModelCol].Value = oMater.omodel.HModel;
grdMain.Rows[i].Cells[HSubjoinCol].Value = oMater.omodel.HSubjoin;
grdMain.Rows[i].Cells[HColorCol].Value = oMater.omodel.HColor;
if (oUnit.GetInfoByID(oMater.omodel.HUnitID))
{
grdMain.Rows[i].Cells[HUnitNumberCol].Value = oUnit.omodel.HNumber;
grdMain.Rows[i].Cells[HUnitNameCol].Value = oUnit.omodel.HName;
grdMain.Rows[i].Cells[HUnitIDCol].Value = oUnit.omodel.HItemID.ToString();
}
else
{
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
}
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
grdMain.Rows[i].Cells[HMaterModelCol].Value = "";
grdMain.Rows[i].Cells[HSubjoinCol].Value = "";
grdMain.Rows[i].Cells[HColorCol].Value = "";
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
}
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
grdMain.Rows[i].Cells[HMaterModelCol].Value = "";
grdMain.Rows[i].Cells[HSubjoinCol].Value = "";
grdMain.Rows[i].Cells[HColorCol].Value = "";
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
}
}
//²Ö¿â-Íø¸ñ
///
/// ²Ö¿â-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByWareHouse(DataGridView grdMain, int i, int HWhIDCol, int HWhNumberCol, int HWhNameCol)
{
DAL.ClsGy_Warehouse_View oWh = new DAL.ClsGy_Warehouse_View();
if (oWh.RefreshView())
{
if (oWh.GetInfoByID(oWh.oModel.HItemID))
{
grdMain.Rows[i].Cells[HWhIDCol].Value = oWh.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HWhNumberCol].Value = oWh.omodel.HNumber;
grdMain.Rows[i].Cells[HWhNameCol].Value = oWh.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HWhIDCol].Value = "0";
grdMain.Rows[i].Cells[HWhNumberCol].Value = "";
grdMain.Rows[i].Cells[HWhNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HWhIDCol].Value = "0";
grdMain.Rows[i].Cells[HWhNumberCol].Value = "";
grdMain.Rows[i].Cells[HWhNameCol].Value = "";
}
}
///
/// ¼ìÑéÏîÄ¿
///
///
///
///
///
///
public static void SetGridByQCCheckItem(DataGridView grdMain, int i, int HQCCheckItemIDCol, int HQCCheckItemNumberCol, int HQCCheckItemNameCol)
{
DAL.ClsGy_QCCheckItem_View oQCCheckItem = new DAL.ClsGy_QCCheckItem_View();
if (oQCCheckItem.RefreshView())
{
if (oQCCheckItem.GetInfoByID(oQCCheckItem.oModel.HItemID))
{
grdMain.Rows[i].Cells[HQCCheckItemIDCol].Value = oQCCheckItem.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HQCCheckItemNumberCol].Value = oQCCheckItem.omodel.HNumber;
grdMain.Rows[i].Cells[HQCCheckItemNameCol].Value = oQCCheckItem.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HQCCheckItemIDCol].Value = "0";
grdMain.Rows[i].Cells[HQCCheckItemNumberCol].Value = "";
grdMain.Rows[i].Cells[HQCCheckItemNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HQCCheckItemIDCol].Value = "0";
grdMain.Rows[i].Cells[HQCCheckItemNumberCol].Value = "";
grdMain.Rows[i].Cells[HQCCheckItemNameCol].Value = "";
}
}
public static void SetGridByQCCheckClass(DataGridView grdMain, int i, int HQCCheckClassIDCol, int HQCCheckClassNumberCol, int HQCCheckClassNameCol)
{
DAL.ClsGy_QCCheckClass_View oQCCheckClass = new DAL.ClsGy_QCCheckClass_View();
if (oQCCheckClass.RefreshView())
{
if (oQCCheckClass.GetInfoByID(oQCCheckClass.oModel.HItemID))
{
grdMain.Rows[i].Cells[HQCCheckClassIDCol].Value = oQCCheckClass.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HQCCheckClassNumberCol].Value = oQCCheckClass.omodel.HNumber;
grdMain.Rows[i].Cells[HQCCheckClassNameCol].Value = oQCCheckClass.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HQCCheckClassIDCol].Value = "0";
grdMain.Rows[i].Cells[HQCCheckClassNumberCol].Value = "";
grdMain.Rows[i].Cells[HQCCheckClassNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HQCCheckClassIDCol].Value = "0";
grdMain.Rows[i].Cells[HQCCheckClassNumberCol].Value = "";
grdMain.Rows[i].Cells[HQCCheckClassNameCol].Value = "";
}
}
//¼ÆÁ¿µ¥Î»-Íø¸ñ
///
/// ¼ÆÁ¿µ¥Î»-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByUnit(DataGridView grdMain, int i, int HUnitIDCol, int HUnitNumberCol, int HUnitNameCol)
{
DAL.ClsGy_Unit_View oUnit = new DAL.ClsGy_Unit_View();
if (oUnit.RefreshView())
{
if (oUnit.GetInfoByID(oUnit.oModel.HItemID))
{
grdMain.Rows[i].Cells[HUnitIDCol].Value = oUnit.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HUnitNumberCol].Value = oUnit.omodel.HNumber;
grdMain.Rows[i].Cells[HUnitNameCol].Value = oUnit.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HUnitIDCol].Value = "0";
grdMain.Rows[i].Cells[HUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitNameCol].Value = "";
}
}
//²»Á¼ÔÒò-Íø¸ñ
///
/// ²»Á¼ÔÒò-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByBadReason(DataGridView grdMain, int i, int HBadReasonIDCol, int HBadReasonNumberCol, int HBadReasonNameCol)
{
DAL.ClsGy_BadReason_View oBadReason = new DAL.ClsGy_BadReason_View();
if (oBadReason.RefreshView())
{
if (oBadReason.GetInfoByID(oBadReason.oModel.HItemID))
{
grdMain.Rows[i].Cells[HBadReasonIDCol].Value = oBadReason.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HBadReasonNumberCol].Value = oBadReason.omodel.HNumber;
grdMain.Rows[i].Cells[HBadReasonNameCol].Value = oBadReason.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HBadReasonIDCol].Value = "0";
grdMain.Rows[i].Cells[HBadReasonNumberCol].Value = "";
grdMain.Rows[i].Cells[HBadReasonNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HBadReasonIDCol].Value = "0";
grdMain.Rows[i].Cells[HBadReasonNumberCol].Value = "";
grdMain.Rows[i].Cells[HBadReasonNameCol].Value = "";
}
}
//³µÁ¾-Íø¸ñ
///
/// ³µÁ¾-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByCar(DataGridView grdMain, int i, int HCarIDCol, int HCarNumberCol, int HCarNameCol)
{
DAL.ClsGy_Car_View oCar = new DAL.ClsGy_Car_View();
if (oCar.RefreshView())
{
if (oCar.GetInfoByID(oCar.oModel.HItemID))
{
grdMain.Rows[i].Cells[HCarIDCol].Value = oCar.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HCarNumberCol].Value = oCar.omodel.HNumber;
grdMain.Rows[i].Cells[HCarNameCol].Value = oCar.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HCarIDCol].Value = "0";
grdMain.Rows[i].Cells[HCarNumberCol].Value = "";
grdMain.Rows[i].Cells[HCarNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HCarIDCol].Value = "0";
grdMain.Rows[i].Cells[HCarNumberCol].Value = "";
grdMain.Rows[i].Cells[HCarNameCol].Value = "";
}
}
//¹ÊÕÏÔÒò-Íø¸ñ
///
/// ¹ÊÕÏÔÒò-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByConkReason(DataGridView grdMain, int i, int HConkReasonIDCol, int HConkReasonNumberCol, int HConkReasonNameCol)
{
DAL.ClsGy_ConkReason_View oConkReason = new DAL.ClsGy_ConkReason_View();
if (oConkReason.RefreshView())
{
if (oConkReason.GetInfoByID(oConkReason.oModel.HItemID))
{
grdMain.Rows[i].Cells[HConkReasonIDCol].Value = oConkReason.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HConkReasonNumberCol].Value = oConkReason.omodel.HNumber;
grdMain.Rows[i].Cells[HConkReasonNameCol].Value = oConkReason.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HConkReasonIDCol].Value = "0";
grdMain.Rows[i].Cells[HConkReasonNumberCol].Value = "";
grdMain.Rows[i].Cells[HConkReasonNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HConkReasonIDCol].Value = "0";
grdMain.Rows[i].Cells[HConkReasonNumberCol].Value = "";
grdMain.Rows[i].Cells[HConkReasonNameCol].Value = "";
}
}
//¹ÊÕÏÀà±ð-Íø¸ñ
///
/// ¹ÊÕÏÀà±ð-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByConkType(DataGridView grdMain, int i, int HConkTypeIDCol, int HConkTypeNumberCol, int HConkTypeNameCol)
{
DAL.ClsGy_ConkType_View oConkType = new DAL.ClsGy_ConkType_View();
if (oConkType.RefreshView())
{
if (oConkType.GetInfoByID(oConkType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HConkTypeIDCol].Value = oConkType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HConkTypeNumberCol].Value = oConkType.omodel.HNumber;
grdMain.Rows[i].Cells[HConkTypeNameCol].Value = oConkType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HConkTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HConkTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HConkTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HConkTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HConkTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HConkTypeNameCol].Value = "";
}
}
//³É±¾ÖÐÐÄ-Íø¸ñ
///
/// ³É±¾ÖÐÐÄ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByCostCenter(DataGridView grdMain, int i, int HCostCenterIDCol, int HCostCenterNumberCol, int HCostCenterNameCol)
{
DAL.ClsGy_CostCenter_View oCostCenter = new DAL.ClsGy_CostCenter_View();
if (oCostCenter.RefreshView())
{
if (oCostCenter.GetInfoByID(oCostCenter.oModel.HItemID))
{
grdMain.Rows[i].Cells[HCostCenterIDCol].Value = oCostCenter.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HCostCenterNumberCol].Value = oCostCenter.omodel.HNumber;
grdMain.Rows[i].Cells[HCostCenterNameCol].Value = oCostCenter.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HCostCenterIDCol].Value = "0";
grdMain.Rows[i].Cells[HCostCenterNumberCol].Value = "";
grdMain.Rows[i].Cells[HCostCenterNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HCostCenterIDCol].Value = "0";
grdMain.Rows[i].Cells[HCostCenterNumberCol].Value = "";
grdMain.Rows[i].Cells[HCostCenterNameCol].Value = "";
}
}
//±Ò±ð-Íø¸ñ
///
/// ±Ò±ð-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByCurrency(DataGridView grdMain, int i, int HCurrencyIDCol, int HCurrencyNumberCol, int HCurrencyNameCol)
{
DAL.ClsGy_Currency_View oCurrency = new DAL.ClsGy_Currency_View();
if (oCurrency.RefreshView())
{
if (oCurrency.GetInfoByID(oCurrency.oModel.HItemID))
{
grdMain.Rows[i].Cells[HCurrencyIDCol].Value = oCurrency.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HCurrencyNumberCol].Value = oCurrency.omodel.HNumber;
grdMain.Rows[i].Cells[HCurrencyNameCol].Value = oCurrency.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HCurrencyIDCol].Value = "0";
grdMain.Rows[i].Cells[HCurrencyNumberCol].Value = "";
grdMain.Rows[i].Cells[HCurrencyNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HCurrencyIDCol].Value = "0";
grdMain.Rows[i].Cells[HCurrencyNumberCol].Value = "";
grdMain.Rows[i].Cells[HCurrencyNameCol].Value = "";
}
}
//¿Í»§-Íø¸ñ
///
/// ¿Í»§-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByCustomer(DataGridView grdMain, int i, int HCustomerIDCol, int HCustomerNumberCol, int HCustomerNameCol)
{
DAL.ClsGy_Customer_View oCustomer = new DAL.ClsGy_Customer_View();
if (oCustomer.RefreshView())
{
if (oCustomer.GetInfoByID(oCustomer.oModel.HItemID))
{
grdMain.Rows[i].Cells[HCustomerIDCol].Value = oCustomer.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HCustomerNumberCol].Value = oCustomer.omodel.HNumber;
grdMain.Rows[i].Cells[HCustomerNameCol].Value = oCustomer.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HCustomerIDCol].Value = "0";
grdMain.Rows[i].Cells[HCustomerNumberCol].Value = "";
grdMain.Rows[i].Cells[HCustomerNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HCustomerIDCol].Value = "0";
grdMain.Rows[i].Cells[HCustomerNumberCol].Value = "";
grdMain.Rows[i].Cells[HCustomerNameCol].Value = "";
}
}
//¿Í»§·ÖÀà-Íø¸ñ
///
/// ¿Í»§·ÖÀà-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByCusType(DataGridView grdMain, int i, int HCusTypeIDCol, int HCusTypeNumberCol, int HCusTypeNameCol)
{
DAL.ClsGy_CusType_View oCusType = new DAL.ClsGy_CusType_View();
if (oCusType.RefreshView())
{
if (oCusType.GetInfoByID(oCusType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HCusTypeIDCol].Value = oCusType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HCusTypeNumberCol].Value = oCusType.omodel.HNumber;
grdMain.Rows[i].Cells[HCusTypeNameCol].Value = oCusType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HCusTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HCusTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HCusTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HCusTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HCusTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HCusTypeNameCol].Value = "";
}
}
//²¿ÃÅ-Íø¸ñ
///
/// ²¿ÃÅ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByDept(DataGridView grdMain, int i, int HDeptIDCol, int HDeptNumberCol, int HDeptNameCol)
{
DAL.ClsGy_Department_View oDept = new DAL.ClsGy_Department_View();
if (oDept.RefreshView())
{
if (oDept.GetInfoByID(oDept.oModel.HItemID))
{
grdMain.Rows[i].Cells[HDeptIDCol].Value = oDept.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HDeptNumberCol].Value = oDept.omodel.HNumber;
grdMain.Rows[i].Cells[HDeptNameCol].Value = oDept.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HDeptIDCol].Value = "0";
grdMain.Rows[i].Cells[HDeptNumberCol].Value = "";
grdMain.Rows[i].Cells[HDeptNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HDeptIDCol].Value = "0";
grdMain.Rows[i].Cells[HDeptNumberCol].Value = "";
grdMain.Rows[i].Cells[HDeptNameCol].Value = "";
}
}
//Â¥ºÅÉèÖÃ-Íø¸ñ
///
/// Â¥ºÅÉèÖÃ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByBui(DataGridView grdMain, int i, int HBuildingIDCol, int HBuildingNumberCol, int HBuildingNameCol)
{
DAL.ClsGy_Building_View oBui = new DAL.ClsGy_Building_View();
if (oBui.RefreshView())
{
if (oBui.GetInfoByID(oBui.oModel.HItemID))
{
grdMain.Rows[i].Cells[HBuildingIDCol].Value = oBui.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HBuildingNumberCol].Value = oBui.omodel.HNumber;
grdMain.Rows[i].Cells[HBuildingNameCol].Value = oBui.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HBuildingIDCol].Value = "0";
grdMain.Rows[i].Cells[HBuildingNumberCol].Value = "";
grdMain.Rows[i].Cells[HBuildingNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HBuildingIDCol].Value = "0";
grdMain.Rows[i].Cells[HBuildingNumberCol].Value = "";
grdMain.Rows[i].Cells[HBuildingNameCol].Value = "";
}
}
//
//·¿¼äÀàÐÍ-Íø¸ñ
///
/// ·¿¼äÀàÐÍ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByHouseType(DataGridView grdMain, int i, int HHouseTypeIDCol, int HHouseTypeNumberCol, int HHouseTypeNameCol)
{
DAL.ClsGy_HouseType_View oHT = new DAL.ClsGy_HouseType_View();
if (oHT.RefreshView())
{
if (oHT.GetInfoByID(oHT.oModel.HItemID))
{
grdMain.Rows[i].Cells[HHouseTypeIDCol].Value = oHT.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HHouseTypeNumberCol].Value = oHT.omodel.HNumber;
grdMain.Rows[i].Cells[HHouseTypeNameCol].Value = oHT.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HHouseTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HHouseTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HHouseTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HHouseTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HHouseTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HHouseTypeNameCol].Value = "";
}
}
//
//ÎïÁÏ-Íø¸ñ
///
/// ÎïÁÏ-Íø¸ñ
///
/// ÎÞµ¥Î»
///
///
///
///
///
///
///
///
public static void SetGridByMaterial(DataGridView grdMain, int i, int HMaterIDCol, int HMaterNumberCol, int HMaterNameCol, int HMaterModelCol)
{
DAL.ClsGy_Material_View oMater = new DAL.ClsGy_Material_View();
DAL.ClsGy_Unit_View oUnit = new DAL.ClsGy_Unit_View();
if (oMater.RefreshView())
{
if (oMater.GetInfoByID(oMater.oModel.HItemID))
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = oMater.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HMaterNumberCol].Value = oMater.omodel.HNumber;
grdMain.Rows[i].Cells[HMaterNameCol].Value = oMater.omodel.HName;
grdMain.Rows[i].Cells[HMaterModelCol].Value = oMater.omodel.HModel;
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
grdMain.Rows[i].Cells[HMaterModelCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
grdMain.Rows[i].Cells[HMaterModelCol].Value = "";
}
}
//ËÞÉá-Íø¸ñ
///
/// ËÞÉá-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByDorm(DataGridView grdMain, int i, int HDormIDCol, int HDormNumberCol, int HDormNameCol)
{
DAL.ClsGy_Dorm_View oDorm = new DAL.ClsGy_Dorm_View();
if (oDorm.RefreshView())
{
if (oDorm.GetInfoByID(oDorm.oModel.HItemID))
{
grdMain.Rows[i].Cells[HDormIDCol].Value = oDorm.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HDormNumberCol].Value = oDorm.omodel.HNumber;
grdMain.Rows[i].Cells[HDormNameCol].Value = oDorm.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HDormIDCol].Value = "0";
grdMain.Rows[i].Cells[HDormNumberCol].Value = "";
grdMain.Rows[i].Cells[HDormNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HDormIDCol].Value = "0";
grdMain.Rows[i].Cells[HDormNumberCol].Value = "";
grdMain.Rows[i].Cells[HDormNameCol].Value = "";
}
}
//¿Û²¹×ÊÁÏ-Íø¸ñ
///
/// ¿Û²¹×ÊÁÏ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByDuSubsidyItem(DataGridView grdMain, int i, int HDuSubsidyItemIDCol, int HDuSubsidyItemNumberCol, int HDuSubsidyItemNameCol)
{
DAL.ClsGy_DuSubsidyItem_View oDuSubsidyItem = new DAL.ClsGy_DuSubsidyItem_View();
if (oDuSubsidyItem.RefreshView())
{
if (oDuSubsidyItem.GetInfoByID(oDuSubsidyItem.oModel.HItemID))
{
grdMain.Rows[i].Cells[HDuSubsidyItemIDCol].Value = oDuSubsidyItem.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HDuSubsidyItemNumberCol].Value = oDuSubsidyItem.omodel.HNumber;
grdMain.Rows[i].Cells[HDuSubsidyItemNameCol].Value = oDuSubsidyItem.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HDuSubsidyItemIDCol].Value = "0";
grdMain.Rows[i].Cells[HDuSubsidyItemNumberCol].Value = "";
grdMain.Rows[i].Cells[HDuSubsidyItemNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HDuSubsidyItemIDCol].Value = "0";
grdMain.Rows[i].Cells[HDuSubsidyItemNumberCol].Value = "";
grdMain.Rows[i].Cells[HDuSubsidyItemNameCol].Value = "";
}
}
//Ö°Îñ-Íø¸ñ
///
/// Ö°Îñ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByDuty(DataGridView grdMain, int i, int HDutyIDCol, int HDutyNumberCol, int HDutyNameCol)
{
DAL.ClsGy_Duty_View oDuty = new DAL.ClsGy_Duty_View();
if (oDuty.RefreshView())
{
if (oDuty.GetInfoByID(oDuty.oModel.HItemID))
{
grdMain.Rows[i].Cells[HDutyIDCol].Value = oDuty.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HDutyNumberCol].Value = oDuty.omodel.HNumber;
grdMain.Rows[i].Cells[HDutyNameCol].Value = oDuty.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HDutyIDCol].Value = "0";
grdMain.Rows[i].Cells[HDutyNumberCol].Value = "";
grdMain.Rows[i].Cells[HDutyNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HDutyIDCol].Value = "0";
grdMain.Rows[i].Cells[HDutyNumberCol].Value = "";
grdMain.Rows[i].Cells[HDutyNameCol].Value = "";
}
}
//Ö°Ô±-Íø¸ñ-°´°à×é
///
/// Ö°Ô±-Íø¸ñ-°´°à×é
///
///
///
///
///
///
public static void SetGridByEmp_Group(DataGridView grdMain, int i, int HEmpIDCol, int HEmpNumberCol, int HEmpNameCol, long HGroupID)
{
DAL.ClsGy_Employee_View oEmp = new DAL.ClsGy_Employee_View();
if (oEmp.RefreshView("and HGroupID=" + HGroupID))
{
if (oEmp.GetInfoByID(oEmp.oModel.HItemID))
{
grdMain.Rows[i].Cells[HEmpIDCol].Value = oEmp.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HEmpNumberCol].Value = oEmp.omodel.HNumber;
grdMain.Rows[i].Cells[HEmpNameCol].Value = oEmp.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HEmpIDCol].Value = "0";
grdMain.Rows[i].Cells[HEmpNumberCol].Value = "";
grdMain.Rows[i].Cells[HEmpNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HEmpIDCol].Value = "0";
grdMain.Rows[i].Cells[HEmpNumberCol].Value = "";
grdMain.Rows[i].Cells[HEmpNameCol].Value = "";
}
}
//Ö°Ô±-Íø¸ñ
///
/// Ö°Ô±-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByEmp(DataGridView grdMain, int i, int HEmpIDCol, int HEmpNumberCol, int HEmpNameCol)
{
DAL.ClsGy_Employee_View oEmp = new DAL.ClsGy_Employee_View();
if (oEmp.RefreshView())
{
if (oEmp.GetInfoByID(oEmp.oModel.HItemID))
{
grdMain.Rows[i].Cells[HEmpIDCol].Value = oEmp.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HEmpNumberCol].Value = oEmp.omodel.HNumber;
grdMain.Rows[i].Cells[HEmpNameCol].Value = oEmp.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HEmpIDCol].Value = "0";
grdMain.Rows[i].Cells[HEmpNumberCol].Value = "";
grdMain.Rows[i].Cells[HEmpNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HEmpIDCol].Value = "0";
grdMain.Rows[i].Cells[HEmpNumberCol].Value = "";
grdMain.Rows[i].Cells[HEmpNameCol].Value = "";
}
}
//ÄÜÔ´ÏîÄ¿-Íø¸ñ
///
/// ÄÜÔ´ÏîÄ¿-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByEnergy(DataGridView grdMain, int i, int HEnergyIDCol, int HEnergyNumberCol, int HEnergyNameCol)
{
DAL.ClsGy_Energy_View oEnergy = new DAL.ClsGy_Energy_View();
if (oEnergy.RefreshView())
{
if (oEnergy.GetInfoByID(oEnergy.oModel.HItemID))
{
grdMain.Rows[i].Cells[HEnergyIDCol].Value = oEnergy.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HEnergyNumberCol].Value = oEnergy.omodel.HNumber;
grdMain.Rows[i].Cells[HEnergyNameCol].Value = oEnergy.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HEnergyIDCol].Value = "0";
grdMain.Rows[i].Cells[HEnergyNumberCol].Value = "";
grdMain.Rows[i].Cells[HEnergyNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HEnergyIDCol].Value = "0";
grdMain.Rows[i].Cells[HEnergyNumberCol].Value = "";
grdMain.Rows[i].Cells[HEnergyNameCol].Value = "";
}
}
//Òì³£ÀàÐÍ-Íø¸ñ
///
/// Òì³£ÀàÐÍ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByErrType(DataGridView grdMain, int i, int HErrTypeIDCol, int HErrTypeNumberCol, int HErrTypeNameCol)
{
DAL.ClsGy_ErrType_View oErrType = new DAL.ClsGy_ErrType_View();
if (oErrType.RefreshView())
{
if (oErrType.GetInfoByID(oErrType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HErrTypeIDCol].Value = oErrType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HErrTypeNumberCol].Value = oErrType.omodel.HNumber;
grdMain.Rows[i].Cells[HErrTypeNameCol].Value = oErrType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HErrTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HErrTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HErrTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HErrTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HErrTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HErrTypeNameCol].Value = "";
}
}
//ÆÀ¼ÛÇé¿ö-Íø¸ñ
///
/// ÆÀ¼ÛÇé¿ö-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByEvaluateStatus(DataGridView grdMain, int i, int HEvaluateStatusIDCol, int HEvaluateStatusNumberCol, int HEvaluateStatusNameCol)
{
DAL.ClsGy_EvaluateStatus_View oEvaluateStatus = new DAL.ClsGy_EvaluateStatus_View();
if (oEvaluateStatus.RefreshView())
{
if (oEvaluateStatus.GetInfoByID(oEvaluateStatus.oModel.HItemID))
{
grdMain.Rows[i].Cells[HEvaluateStatusIDCol].Value = oEvaluateStatus.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HEvaluateStatusNumberCol].Value = oEvaluateStatus.omodel.HNumber;
grdMain.Rows[i].Cells[HEvaluateStatusNameCol].Value = oEvaluateStatus.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HEvaluateStatusIDCol].Value = "0";
grdMain.Rows[i].Cells[HEvaluateStatusNumberCol].Value = "";
grdMain.Rows[i].Cells[HEvaluateStatusNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HEvaluateStatusIDCol].Value = "0";
grdMain.Rows[i].Cells[HEvaluateStatusNumberCol].Value = "";
grdMain.Rows[i].Cells[HEvaluateStatusNameCol].Value = "";
}
}
//·ÑÓÃÇé¿ö-Íø¸ñ
///
/// ·ÑÓÃÇé¿ö-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByExpenseStatus(DataGridView grdMain, int i, int HExpenseStatusIDCol, int HExpenseStatusNumberCol, int HExpenseStatusNameCol)
{
DAL.ClsGy_ExpenseStatus_View oExpenseStatus = new DAL.ClsGy_ExpenseStatus_View();
if (oExpenseStatus.RefreshView())
{
if (oExpenseStatus.GetInfoByID(oExpenseStatus.oModel.HItemID))
{
grdMain.Rows[i].Cells[HExpenseStatusIDCol].Value = oExpenseStatus.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HExpenseStatusNumberCol].Value = oExpenseStatus.omodel.HNumber;
grdMain.Rows[i].Cells[HExpenseStatusNameCol].Value = oExpenseStatus.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HExpenseStatusIDCol].Value = "0";
grdMain.Rows[i].Cells[HExpenseStatusNumberCol].Value = "";
grdMain.Rows[i].Cells[HExpenseStatusNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HExpenseStatusIDCol].Value = "0";
grdMain.Rows[i].Cells[HExpenseStatusNumberCol].Value = "";
grdMain.Rows[i].Cells[HExpenseStatusNameCol].Value = "";
}
}
//³µÁ¾³§¼Ò-Íø¸ñ
///
/// ³µÁ¾³§¼Ò-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByFactory(DataGridView grdMain, int i, int HFactoryIDCol, int HFactoryNumberCol, int HFactoryNameCol)
{
DAL.ClsGy_Factory_View oFactory = new DAL.ClsGy_Factory_View();
if (oFactory.RefreshView())
{
if (oFactory.GetInfoByID(oFactory.oModel.HItemID))
{
grdMain.Rows[i].Cells[HFactoryIDCol].Value = oFactory.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HFactoryNumberCol].Value = oFactory.omodel.HNumber;
grdMain.Rows[i].Cells[HFactoryNameCol].Value = oFactory.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HFactoryIDCol].Value = "0";
grdMain.Rows[i].Cells[HFactoryNumberCol].Value = "";
grdMain.Rows[i].Cells[HFactoryNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HFactoryIDCol].Value = "0";
grdMain.Rows[i].Cells[HFactoryNumberCol].Value = "";
grdMain.Rows[i].Cells[HFactoryNameCol].Value = "";
}
}
//°à×é-Íø¸ñ
///
/// °à×é-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByGroup(DataGridView grdMain, int i, int HGroupIDCol, int HGroupNumberCol, int HGroupNameCol)
{
DAL.ClsGy_Group_View oGroup = new DAL.ClsGy_Group_View();
if (oGroup.RefreshView())
{
if (oGroup.GetInfoByID(oGroup.oModel.HItemID))
{
grdMain.Rows[i].Cells[HGroupIDCol].Value = oGroup.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HGroupNumberCol].Value = oGroup.omodel.HNumber;
grdMain.Rows[i].Cells[HGroupNameCol].Value = oGroup.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HGroupNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HGroupNameCol].Value = "";
}
}
//½Ú¼ÙÈÕ-Íø¸ñ
///
/// ½Ú¼ÙÈÕ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByHoliday(DataGridView grdMain, int i, int HHolidayIDCol, int HHolidayNumberCol, int HHolidayNameCol)
{
DAL.ClsGy_Holiday_View oHoliday = new DAL.ClsGy_Holiday_View();
if (oHoliday.RefreshView())
{
if (oHoliday.GetInfoByID(oHoliday.oModel.HItemID))
{
grdMain.Rows[i].Cells[HHolidayIDCol].Value = oHoliday.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HHolidayNumberCol].Value = oHoliday.omodel.HNumber;
grdMain.Rows[i].Cells[HHolidayNameCol].Value = oHoliday.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HHolidayIDCol].Value = "0";
grdMain.Rows[i].Cells[HHolidayNumberCol].Value = "";
grdMain.Rows[i].Cells[HHolidayNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HHolidayIDCol].Value = "0";
grdMain.Rows[i].Cells[HHolidayNumberCol].Value = "";
grdMain.Rows[i].Cells[HHolidayNameCol].Value = "";
}
}
//±£ÑøÏîÄ¿-Íø¸ñ
///
/// ±£ÑøÏîÄ¿-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByMaintain(DataGridView grdMain, int i, int HMaintainIDCol, int HMaintainNumberCol, int HMaintainNameCol)
{
DAL.ClsGy_Maintain_View oMaintain = new DAL.ClsGy_Maintain_View();
if (oMaintain.RefreshView())
{
if (oMaintain.GetInfoByID(oMaintain.oModel.HItemID))
{
grdMain.Rows[i].Cells[HMaintainIDCol].Value = oMaintain.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HMaintainNumberCol].Value = oMaintain.omodel.HNumber;
grdMain.Rows[i].Cells[HMaintainNameCol].Value = oMaintain.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HMaintainIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaintainNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaintainNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HMaintainIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaintainNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaintainNameCol].Value = "";
}
}
//¿Í»§¶ÔÓ¦ÎïÁÏ-Íø¸ñ
///
/// ¿Í»§¶ÔÓ¦ÎïÁÏ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByMateNumRelation(DataGridView grdMain, int i, int HMateNumRelationIDCol, int HMateNumRelationNumberCol, int HMateNumRelationNameCol)
{
DAL.ClsGy_MateNumRelation_View oMateNumRelation = new DAL.ClsGy_MateNumRelation_View();
if (oMateNumRelation.RefreshView())
{
if (oMateNumRelation.GetInfoByID(oMateNumRelation.oModel.HItemID))
{
grdMain.Rows[i].Cells[HMateNumRelationIDCol].Value = oMateNumRelation.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HMateNumRelationNumberCol].Value = oMateNumRelation.omodel.HNumber;
grdMain.Rows[i].Cells[HMateNumRelationNameCol].Value = oMateNumRelation.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HMateNumRelationIDCol].Value = "0";
grdMain.Rows[i].Cells[HMateNumRelationNumberCol].Value = "";
grdMain.Rows[i].Cells[HMateNumRelationNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HMateNumRelationIDCol].Value = "0";
grdMain.Rows[i].Cells[HMateNumRelationNumberCol].Value = "";
grdMain.Rows[i].Cells[HMateNumRelationNameCol].Value = "";
}
}
//ÎïÁÏÌØÐÔ-Íø¸ñ
///
/// ÎïÁÏÌØÐÔ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByMaterTrait(DataGridView grdMain, int i, int HMaterTraitIDCol, int HMaterTraitNumberCol, int HMaterTraitNameCol)
{
DAL.ClsGy_MaterTrait_View oMaterTrait = new DAL.ClsGy_MaterTrait_View();
if (oMaterTrait.RefreshView())
{
if (oMaterTrait.GetInfoByID(oMaterTrait.oModel.HItemID))
{
grdMain.Rows[i].Cells[HMaterTraitIDCol].Value = oMaterTrait.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HMaterTraitNumberCol].Value = oMaterTrait.omodel.HNumber;
grdMain.Rows[i].Cells[HMaterTraitNameCol].Value = oMaterTrait.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HMaterTraitIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterTraitNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterTraitNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HMaterTraitIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterTraitNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterTraitNameCol].Value = "";
}
}
//¹æ¸ñÐͺÅ-Íø¸ñ
///
/// ¹æ¸ñÐͺÅ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByModel(DataGridView grdMain, int i, int HModelIDCol, int HModelNumberCol, int HModelNameCol)
{
DAL.ClsGy_Model_View oModel = new DAL.ClsGy_Model_View();
if (oModel.RefreshView())
{
if (oModel.GetInfoByID(oModel.oModel.HItemID))
{
grdMain.Rows[i].Cells[HModelIDCol].Value = oModel.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HModelNumberCol].Value = oModel.omodel.HNumber;
grdMain.Rows[i].Cells[HModelNameCol].Value = oModel.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HModelIDCol].Value = "0";
grdMain.Rows[i].Cells[HModelNumberCol].Value = "";
grdMain.Rows[i].Cells[HModelNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HModelIDCol].Value = "0";
grdMain.Rows[i].Cells[HModelNumberCol].Value = "";
grdMain.Rows[i].Cells[HModelNameCol].Value = "";
}
}
//¶©µ¥µÈ¼¶-Íø¸ñ
///
/// ¶©µ¥µÈ¼¶-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByOrderLev(DataGridView grdMain, int i, int HOrderLevIDCol, int HOrderLevNumberCol, int HOrderLevNameCol)
{
DAL.ClsGy_OrderLev_View oOrderLev = new DAL.ClsGy_OrderLev_View();
if (oOrderLev.RefreshView())
{
if (oOrderLev.GetInfoByID(oOrderLev.oModel.HItemID))
{
grdMain.Rows[i].Cells[HOrderLevIDCol].Value = oOrderLev.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HOrderLevNumberCol].Value = oOrderLev.omodel.HNumber;
grdMain.Rows[i].Cells[HOrderLevNameCol].Value = oOrderLev.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HOrderLevIDCol].Value = "0";
grdMain.Rows[i].Cells[HOrderLevNumberCol].Value = "";
grdMain.Rows[i].Cells[HOrderLevNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HOrderLevIDCol].Value = "0";
grdMain.Rows[i].Cells[HOrderLevNumberCol].Value = "";
grdMain.Rows[i].Cells[HOrderLevNameCol].Value = "";
}
}
//Ö¤¼þÀà±ð-Íø¸ñ
///
/// Ö¤¼þÀà±ð-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByPaperSort(DataGridView grdMain, int i, int HPaperSortIDCol, int HPaperSortNumberCol, int HPaperSortNameCol)
{
DAL.ClsGy_PaperSort_View oPaperSort = new DAL.ClsGy_PaperSort_View();
if (oPaperSort.RefreshView())
{
if (oPaperSort.GetInfoByID(oPaperSort.oModel.HItemID))
{
grdMain.Rows[i].Cells[HPaperSortIDCol].Value = oPaperSort.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HPaperSortNumberCol].Value = oPaperSort.omodel.HNumber;
grdMain.Rows[i].Cells[HPaperSortNameCol].Value = oPaperSort.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HPaperSortIDCol].Value = "0";
grdMain.Rows[i].Cells[HPaperSortNumberCol].Value = "";
grdMain.Rows[i].Cells[HPaperSortNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HPaperSortIDCol].Value = "0";
grdMain.Rows[i].Cells[HPaperSortNumberCol].Value = "";
grdMain.Rows[i].Cells[HPaperSortNameCol].Value = "";
}
}
//¸Û¿Ú-Íø¸ñ
///
/// ¸Û¿Ú-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByPort(DataGridView grdMain, int i, int HPortIDCol, int HPortNumberCol, int HPortNameCol)
{
DAL.ClsGy_Port_View oPort = new DAL.ClsGy_Port_View();
if (oPort.RefreshView())
{
if (oPort.GetInfoByID(oPort.oModel.HItemID))
{
grdMain.Rows[i].Cells[HPortIDCol].Value = oPort.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HPortNumberCol].Value = oPort.omodel.HNumber;
grdMain.Rows[i].Cells[HPortNameCol].Value = oPort.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HPortIDCol].Value = "0";
grdMain.Rows[i].Cells[HPortNumberCol].Value = "";
grdMain.Rows[i].Cells[HPortNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HPortIDCol].Value = "0";
grdMain.Rows[i].Cells[HPortNumberCol].Value = "";
grdMain.Rows[i].Cells[HPortNameCol].Value = "";
}
}
//¸Úλ-Íø¸ñ
///
/// ¸Úλ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByPost(DataGridView grdMain, int i, int HPostIDCol, int HPostNumberCol, int HPostNameCol)
{
DAL.ClsGy_Post_View oPost = new DAL.ClsGy_Post_View();
if (oPost.RefreshView())
{
if (oPost.GetInfoByID(oPost.oModel.HItemID))
{
grdMain.Rows[i].Cells[HPostIDCol].Value = oPost.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HPostNumberCol].Value = oPost.omodel.HNumber;
grdMain.Rows[i].Cells[HPostNameCol].Value = oPost.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HPostIDCol].Value = "0";
grdMain.Rows[i].Cells[HPostNumberCol].Value = "";
grdMain.Rows[i].Cells[HPostNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HPostIDCol].Value = "0";
grdMain.Rows[i].Cells[HPostNumberCol].Value = "";
grdMain.Rows[i].Cells[HPostNameCol].Value = "";
}
}
//ίÍ⹤Ðò-Íø¸ñ
///
/// ίÍ⹤Ðò-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProcComm(DataGridView grdMain, int i, int HProcCommIDCol, int HProcCommNumberCol, int HProcCommNameCol)
{
DAL.ClsGy_ProcComm_View oProcComm = new DAL.ClsGy_ProcComm_View();
if (oProcComm.RefreshView())
{
if (oProcComm.GetInfoByID(oProcComm.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProcCommIDCol].Value = oProcComm.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProcCommNumberCol].Value = oProcComm.omodel.HNumber;
grdMain.Rows[i].Cells[HProcCommNameCol].Value = oProcComm.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProcCommIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcCommNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcCommNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProcCommIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcCommNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcCommNameCol].Value = "";
}
}
//¹¤Ðò-Íø¸ñ
///
/// ¹¤Ðò-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProc(DataGridView grdMain, int i, int HProcIDCol, int HProcNumberCol, int HProcNameCol)
{
DAL.ClsGy_Process_View oProc = new DAL.ClsGy_Process_View();
if (oProc.RefreshView())
{
if (oProc.GetInfoByID(oProc.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProcIDCol].Value = oProc.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProcNumberCol].Value = oProc.omodel.HNumber;
grdMain.Rows[i].Cells[HProcNameCol].Value = oProc.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProcIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProcIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcNameCol].Value = "";
}
}
//¹¤¶Î-Íø¸ñ
///
/// ¹¤¶Î-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProcMul(DataGridView grdMain, int i, int HProcMulIDCol, int HProcMulNumberCol, int HProcMulNameCol)
{
DAL.ClsGy_ProcMul_View oProcMul = new DAL.ClsGy_ProcMul_View();
if (oProcMul.RefreshView())
{
if (oProcMul.GetInfoByID(oProcMul.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProcMulIDCol].Value = oProcMul.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProcMulNumberCol].Value = oProcMul.omodel.HNumber;
grdMain.Rows[i].Cells[HProcMulNameCol].Value = oProcMul.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProcMulIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcMulNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcMulNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProcMulIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcMulNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcMulNameCol].Value = "";
}
}
//¶¨¶î¹é¼¯-Íø¸ñ
///
/// ¶¨¶î¹é¼¯-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProcPriceRela(DataGridView grdMain, int i, int HProcPriceRelaIDCol, int HProcPriceRelaNumberCol, int HProcPriceRelaNameCol)
{
DAL.ClsGy_ProcPriceRela_View oProcPriceRela = new DAL.ClsGy_ProcPriceRela_View();
if (oProcPriceRela.RefreshView())
{
if (oProcPriceRela.GetInfoByID(oProcPriceRela.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProcPriceRelaIDCol].Value = oProcPriceRela.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProcPriceRelaNumberCol].Value = oProcPriceRela.omodel.HNumber;
grdMain.Rows[i].Cells[HProcPriceRelaNameCol].Value = oProcPriceRela.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProcPriceRelaIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcPriceRelaNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcPriceRelaNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProcPriceRelaIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcPriceRelaNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcPriceRelaNameCol].Value = "";
}
}
//¶¨¶î¹é¼¯×é-Íø¸ñ
///
/// ¶¨¶î¹é¼¯×é-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProcPriceRelaGroup(DataGridView grdMain, int i, int HProcPriceRelaGroupIDCol, int HProcPriceRelaGroupNumberCol, int HProcPriceRelaGroupNameCol)
{
DAL.ClsGy_ProcPriceRelaGroup_View oProcPriceRelaGroup = new DAL.ClsGy_ProcPriceRelaGroup_View();
if (oProcPriceRelaGroup.RefreshView())
{
if (oProcPriceRelaGroup.GetInfoByID(oProcPriceRelaGroup.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProcPriceRelaGroupIDCol].Value = oProcPriceRelaGroup.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProcPriceRelaGroupNumberCol].Value = oProcPriceRelaGroup.omodel.HNumber;
grdMain.Rows[i].Cells[HProcPriceRelaGroupNameCol].Value = oProcPriceRelaGroup.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProcPriceRelaGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcPriceRelaGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcPriceRelaGroupNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProcPriceRelaGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HProcPriceRelaGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HProcPriceRelaGroupNameCol].Value = "";
}
}
//Éú²úÀàÐÍ-Íø¸ñ
///
/// Éú²úÀàÐÍ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProdType(DataGridView grdMain, int i, int HProdTypeIDCol, int HProdTypeNumberCol, int HProdTypeNameCol)
{
DAL.ClsGy_ProdType_View oProdType = new DAL.ClsGy_ProdType_View();
if (oProdType.RefreshView())
{
if (oProdType.GetInfoByID(oProdType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProdTypeIDCol].Value = oProdType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProdTypeNumberCol].Value = oProdType.omodel.HNumber;
grdMain.Rows[i].Cells[HProdTypeNameCol].Value = oProdType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProdTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HProdTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HProdTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProdTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HProdTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HProdTypeNameCol].Value = "";
}
}
//²úÆ·ÌØÐÔ-Íø¸ñ
///
/// ²úÆ·ÌØÐÔ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProductSpec(DataGridView grdMain, int i, int HProductSpecIDCol, int HProductSpecNumberCol, int HProductSpecNameCol)
{
DAL.ClsGy_ProductSpec_View oProductSpec = new DAL.ClsGy_ProductSpec_View();
if (oProductSpec.RefreshView())
{
if (oProductSpec.GetInfoByID(oProductSpec.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProductSpecIDCol].Value = oProductSpec.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProductSpecNumberCol].Value = oProductSpec.omodel.HNumber;
grdMain.Rows[i].Cells[HProductSpecNameCol].Value = oProductSpec.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProductSpecIDCol].Value = "0";
grdMain.Rows[i].Cells[HProductSpecNumberCol].Value = "";
grdMain.Rows[i].Cells[HProductSpecNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProductSpecIDCol].Value = "0";
grdMain.Rows[i].Cells[HProductSpecNumberCol].Value = "";
grdMain.Rows[i].Cells[HProductSpecNameCol].Value = "";
}
}
//ÏîÄ¿¹¤³Ì-Íø¸ñ
///
/// ÏîÄ¿¹¤³Ì-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProject(DataGridView grdMain, int i, int HProjectIDCol, int HProjectNumberCol, int HProjectNameCol)
{
DAL.ClsGy_Project_View oProject = new DAL.ClsGy_Project_View();
if (oProject.RefreshView())
{
if (oProject.GetInfoByID(oProject.oModel.HItemID))
{
grdMain.Rows[i].Cells[HProjectIDCol].Value = oProject.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HProjectNumberCol].Value = oProject.omodel.HNumber;
grdMain.Rows[i].Cells[HProjectNameCol].Value = oProject.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HProjectIDCol].Value = "0";
grdMain.Rows[i].Cells[HProjectNumberCol].Value = "";
grdMain.Rows[i].Cells[HProjectNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HProjectIDCol].Value = "0";
grdMain.Rows[i].Cells[HProjectNumberCol].Value = "";
grdMain.Rows[i].Cells[HProjectNameCol].Value = "";
}
}
//¸¨ÖúÊôÐÔ-Íø¸ñ
///
/// ¸¨ÖúÊôÐÔ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByProperty(DataGridView grdMain, int i, int HPropertyIDCol, int HPropertyNumberCol, int HPropertyNameCol)
{
DAL.ClsGy_Property_View oProperty = new DAL.ClsGy_Property_View();
if (oProperty.RefreshView())
{
if (oProperty.GetInfoByID(oProperty.oModel.HItemID))
{
grdMain.Rows[i].Cells[HPropertyIDCol].Value = oProperty.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HPropertyNumberCol].Value = oProperty.omodel.HNumber;
grdMain.Rows[i].Cells[HPropertyNameCol].Value = oProperty.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HPropertyIDCol].Value = "0";
grdMain.Rows[i].Cells[HPropertyNumberCol].Value = "";
grdMain.Rows[i].Cells[HPropertyNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HPropertyIDCol].Value = "0";
grdMain.Rows[i].Cells[HPropertyNumberCol].Value = "";
grdMain.Rows[i].Cells[HPropertyNameCol].Value = "";
}
}
//¸¨ÖúÊôÐÔÀà±ð-Íø¸ñ
///
/// ¸¨ÖúÊôÐÔÀà±ð-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByPropertyType(DataGridView grdMain, int i, int HPropertyTypeIDCol, int HPropertyTypeNumberCol, int HPropertyTypeNameCol)
{
DAL.ClsGy_PropertyType_View oPropertyType = new DAL.ClsGy_PropertyType_View();
if (oPropertyType.RefreshView())
{
if (oPropertyType.GetInfoByID(oPropertyType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HPropertyTypeIDCol].Value = oPropertyType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HPropertyTypeNumberCol].Value = oPropertyType.omodel.HNumber;
grdMain.Rows[i].Cells[HPropertyTypeNameCol].Value = oPropertyType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HPropertyTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HPropertyTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HPropertyTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HPropertyTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HPropertyTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HPropertyTypeNameCol].Value = "";
}
}
//άÐÞÏîÄ¿-Íø¸ñ
///
/// άÐÞÏîÄ¿-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByRepair(DataGridView grdMain, int i, int HRepairIDCol, int HRepairNumberCol, int HRepairNameCol)
{
DAL.ClsGy_Repair_View oRepair = new DAL.ClsGy_Repair_View();
if (oRepair.RefreshView())
{
if (oRepair.GetInfoByID(oRepair.oModel.HItemID))
{
grdMain.Rows[i].Cells[HRepairIDCol].Value = oRepair.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HRepairNumberCol].Value = oRepair.omodel.HNumber;
grdMain.Rows[i].Cells[HRepairNameCol].Value = oRepair.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HRepairIDCol].Value = "0";
grdMain.Rows[i].Cells[HRepairNumberCol].Value = "";
grdMain.Rows[i].Cells[HRepairNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HRepairIDCol].Value = "0";
grdMain.Rows[i].Cells[HRepairNumberCol].Value = "";
grdMain.Rows[i].Cells[HRepairNameCol].Value = "";
}
}
//άÐÞÑéÊÕÏîÄ¿-Íø¸ñ
///
/// άÐÞÑéÊÕÏîÄ¿-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByRepairCheck(DataGridView grdMain, int i, int HRepairCheckIDCol, int HRepairCheckNumberCol, int HRepairCheckNameCol)
{
DAL.ClsGy_RepairCheck_View oRepairCheck = new DAL.ClsGy_RepairCheck_View();
if (oRepairCheck.RefreshView())
{
if (oRepairCheck.GetInfoByID(oRepairCheck.oModel.HItemID))
{
grdMain.Rows[i].Cells[HRepairCheckIDCol].Value = oRepairCheck.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HRepairCheckNumberCol].Value = oRepairCheck.omodel.HNumber;
grdMain.Rows[i].Cells[HRepairCheckNameCol].Value = oRepairCheck.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HRepairCheckIDCol].Value = "0";
grdMain.Rows[i].Cells[HRepairCheckNumberCol].Value = "";
grdMain.Rows[i].Cells[HRepairCheckNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HRepairCheckIDCol].Value = "0";
grdMain.Rows[i].Cells[HRepairCheckNumberCol].Value = "";
grdMain.Rows[i].Cells[HRepairCheckNameCol].Value = "";
}
}
//άÐÞ·½Ê½-Íø¸ñ
///
/// άÐÞ·½Ê½-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByRepairType(DataGridView grdMain, int i, int HRepairTypeIDCol, int HRepairTypeNumberCol, int HRepairTypeNameCol)
{
DAL.ClsGy_RepairType_View oRepairType = new DAL.ClsGy_RepairType_View();
if (oRepairType.RefreshView())
{
if (oRepairType.GetInfoByID(oRepairType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HRepairTypeIDCol].Value = oRepairType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HRepairTypeNumberCol].Value = oRepairType.omodel.HNumber;
grdMain.Rows[i].Cells[HRepairTypeNameCol].Value = oRepairType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HRepairTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HRepairTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HRepairTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HRepairTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HRepairTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HRepairTypeNameCol].Value = "";
}
}
//¹¤ÒÕ·Ïß´óÀà-Íø¸ñ
///
/// ¹¤ÒÕ·Ïß´óÀà-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByRoutingGroup(DataGridView grdMain, int i, int HRoutingGroupIDCol, int HRoutingGroupNumberCol, int HRoutingGroupNameCol)
{
DAL.ClsGy_RoutingGroup_View oRoutingGroup = new DAL.ClsGy_RoutingGroup_View();
if (oRoutingGroup.RefreshView())
{
if (oRoutingGroup.GetInfoByID(oRoutingGroup.oModel.HItemID))
{
grdMain.Rows[i].Cells[HRoutingGroupIDCol].Value = oRoutingGroup.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HRoutingGroupNumberCol].Value = oRoutingGroup.omodel.HNumber;
grdMain.Rows[i].Cells[HRoutingGroupNameCol].Value = oRoutingGroup.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HRoutingGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HRoutingGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HRoutingGroupNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HRoutingGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HRoutingGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HRoutingGroupNameCol].Value = "";
}
}
//°²È«ÏîÄ¿-Íø¸ñ
///
/// °²È«ÏîÄ¿-Íø¸ñ
///
///
///
///
///
///
public static void SetGridBySafety(DataGridView grdMain, int i, int HSafetyIDCol, int HSafetyNumberCol, int HSafetyNameCol)
{
DAL.ClsGy_Safety_View oSafety = new DAL.ClsGy_Safety_View();
if (oSafety.RefreshView())
{
if (oSafety.GetInfoByID(oSafety.oModel.HItemID))
{
grdMain.Rows[i].Cells[HSafetyIDCol].Value = oSafety.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HSafetyNumberCol].Value = oSafety.omodel.HNumber;
grdMain.Rows[i].Cells[HSafetyNameCol].Value = oSafety.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSafetyIDCol].Value = "0";
grdMain.Rows[i].Cells[HSafetyNumberCol].Value = "";
grdMain.Rows[i].Cells[HSafetyNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HSafetyIDCol].Value = "0";
grdMain.Rows[i].Cells[HSafetyNumberCol].Value = "";
grdMain.Rows[i].Cells[HSafetyNameCol].Value = "";
}
}
//±¨·ÏÔÒò-Íø¸ñ
///
/// ±¨·ÏÔÒò-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByScrapReason(DataGridView grdMain, int i, int HScrapReasonIDCol, int HScrapReasonNumberCol, int HScrapReasonNameCol)
{
DAL.ClsGy_ScrapReason_View oScrapReason = new DAL.ClsGy_ScrapReason_View();
if (oScrapReason.RefreshView())
{
if (oScrapReason.GetInfoByID(oScrapReason.oModel.HItemID))
{
grdMain.Rows[i].Cells[HScrapReasonIDCol].Value = oScrapReason.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HScrapReasonNumberCol].Value = oScrapReason.omodel.HNumber;
grdMain.Rows[i].Cells[HScrapReasonNameCol].Value = oScrapReason.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HScrapReasonIDCol].Value = "0";
grdMain.Rows[i].Cells[HScrapReasonNumberCol].Value = "";
grdMain.Rows[i].Cells[HScrapReasonNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HScrapReasonIDCol].Value = "0";
grdMain.Rows[i].Cells[HScrapReasonNumberCol].Value = "";
grdMain.Rows[i].Cells[HScrapReasonNameCol].Value = "";
}
}
//·þÎñÀàÐÍ-Íø¸ñ
///
/// ·þÎñÀàÐÍ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridBySecType(DataGridView grdMain, int i, int HSecTypeIDCol, int HSecTypeNumberCol, int HSecTypeNameCol)
{
DAL.ClsGy_SecType_View oSecType = new DAL.ClsGy_SecType_View();
if (oSecType.RefreshView())
{
if (oSecType.GetInfoByID(oSecType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HSecTypeIDCol].Value = oSecType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HSecTypeNumberCol].Value = oSecType.omodel.HNumber;
grdMain.Rows[i].Cells[HSecTypeNameCol].Value = oSecType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSecTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HSecTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HSecTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HSecTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HSecTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HSecTypeNameCol].Value = "";
}
}
//ÏúÊÛ·½Ê½-Íø¸ñ
///
/// ÏúÊÛ·½Ê½-Íø¸ñ
///
///
///
///
///
///
public static void SetGridBySellStyle(DataGridView grdMain, int i, int HSellStyleIDCol, int HSellStyleNumberCol, int HSellStyleNameCol)
{
DAL.ClsGy_SellStyle_View oSellStyle = new DAL.ClsGy_SellStyle_View();
if (oSellStyle.RefreshView())
{
if (oSellStyle.GetInfoByID(oSellStyle.oModel.HItemID))
{
grdMain.Rows[i].Cells[HSellStyleIDCol].Value = oSellStyle.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HSellStyleNumberCol].Value = oSellStyle.omodel.HNumber;
grdMain.Rows[i].Cells[HSellStyleNameCol].Value = oSellStyle.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSellStyleIDCol].Value = "0";
grdMain.Rows[i].Cells[HSellStyleNumberCol].Value = "";
grdMain.Rows[i].Cells[HSellStyleNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HSellStyleIDCol].Value = "0";
grdMain.Rows[i].Cells[HSellStyleNumberCol].Value = "";
grdMain.Rows[i].Cells[HSellStyleNameCol].Value = "";
}
}
//½áË㷽ʽ-Íø¸ñ
///
/// ½áË㷽ʽ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridBySettleStyle(DataGridView grdMain, int i, int HSettleStyleIDCol, int HSettleStyleNumberCol, int HSettleStyleNameCol)
{
DAL.ClsGy_SettleStyle_View oSettleStyle = new DAL.ClsGy_SettleStyle_View();
if (oSettleStyle.RefreshView())
{
if (oSettleStyle.GetInfoByID(oSettleStyle.oModel.HItemID))
{
grdMain.Rows[i].Cells[HSettleStyleIDCol].Value = oSettleStyle.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HSettleStyleNumberCol].Value = oSettleStyle.omodel.HNumber;
grdMain.Rows[i].Cells[HSettleStyleNameCol].Value = oSettleStyle.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSettleStyleIDCol].Value = "0";
grdMain.Rows[i].Cells[HSettleStyleNumberCol].Value = "";
grdMain.Rows[i].Cells[HSettleStyleNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HSettleStyleIDCol].Value = "0";
grdMain.Rows[i].Cells[HSettleStyleNumberCol].Value = "";
grdMain.Rows[i].Cells[HSettleStyleNameCol].Value = "";
}
}
//°à´Î-Íø¸ñ
///
/// °à´Î-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByShifts(DataGridView grdMain, int i, int HShiftsIDCol, int HShiftsNumberCol, int HShiftsNameCol)
{
DAL.ClsGy_Shifts_View oShifts = new DAL.ClsGy_Shifts_View();
if (oShifts.RefreshView())
{
if (oShifts.GetInfoByID(oShifts.oModel.HItemID))
{
grdMain.Rows[i].Cells[HShiftsIDCol].Value = oShifts.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HShiftsNumberCol].Value = oShifts.omodel.HNumber;
grdMain.Rows[i].Cells[HShiftsNameCol].Value = oShifts.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HShiftsIDCol].Value = "0";
grdMain.Rows[i].Cells[HShiftsNumberCol].Value = "";
grdMain.Rows[i].Cells[HShiftsNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HShiftsIDCol].Value = "0";
grdMain.Rows[i].Cells[HShiftsNumberCol].Value = "";
grdMain.Rows[i].Cells[HShiftsNameCol].Value = "";
}
}
//Éú²ú×ÊÔ´-Íø¸ñ
///
/// Éú²ú×ÊÔ´-Íø¸ñ
///
///
///
///
///
///
public static void SetGridBySource(DataGridView grdMain, int i, int HSourceIDCol, int HSourceNumberCol, int HSourceNameCol)
{
DAL.ClsGy_Source_View oSource = new DAL.ClsGy_Source_View();
if (oSource.RefreshView())
{
if (oSource.GetInfoByID(oSource.oModel.HItemID))
{
grdMain.Rows[i].Cells[HSourceIDCol].Value = oSource.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HSourceNumberCol].Value = oSource.omodel.HNumber;
grdMain.Rows[i].Cells[HSourceNameCol].Value = oSource.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSourceIDCol].Value = "0";
grdMain.Rows[i].Cells[HSourceNumberCol].Value = "";
grdMain.Rows[i].Cells[HSourceNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HSourceIDCol].Value = "0";
grdMain.Rows[i].Cells[HSourceNumberCol].Value = "";
grdMain.Rows[i].Cells[HSourceNameCol].Value = "";
}
}
//²Öλ-Íø¸ñ
///
/// ²Öλ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByStockPlace(DataGridView grdMain, int i, int HStockPlaceIDCol, int HStockPlaceNumberCol, int HStockPlaceNameCol)
{
DAL.ClsGy_StockPlace_View oStockPlace = new DAL.ClsGy_StockPlace_View();
if (oStockPlace.RefreshView())
{
if (oStockPlace.GetInfoByID(oStockPlace.oModel.HItemID))
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = oStockPlace.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = oStockPlace.omodel.HNumber;
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = oStockPlace.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceNameCol].Value = "";
}
}
//²Öλ×é-Íø¸ñ
///
/// ²Öλ×é-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByStockPlaceGroup(DataGridView grdMain, int i, int HStockPlaceGroupIDCol, int HStockPlaceGroupNumberCol, int HStockPlaceGroupNameCol)
{
DAL.ClsGy_StockPlaceGroup_View oStockPlaceGroup = new DAL.ClsGy_StockPlaceGroup_View();
if (oStockPlaceGroup.RefreshView())
{
if (oStockPlaceGroup.GetInfoByID(oStockPlaceGroup.oModel.HItemID))
{
grdMain.Rows[i].Cells[HStockPlaceGroupIDCol].Value = oStockPlaceGroup.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HStockPlaceGroupNumberCol].Value = oStockPlaceGroup.omodel.HNumber;
grdMain.Rows[i].Cells[HStockPlaceGroupNameCol].Value = oStockPlaceGroup.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HStockPlaceGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceGroupNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HStockPlaceGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HStockPlaceGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HStockPlaceGroupNameCol].Value = "";
}
}
//¹©Ó¦ÉÌ-Íø¸ñ
///
/// ¹©Ó¦ÉÌ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridBySupplier(DataGridView grdMain, int i, int HSupplierIDCol, int HSupplierNumberCol, int HSupplierNameCol)
{
DAL.ClsGy_Supplier_View oSupplier = new DAL.ClsGy_Supplier_View();
if (oSupplier.RefreshView())
{
if (oSupplier.GetInfoByID(oSupplier.oModel.HItemID))
{
grdMain.Rows[i].Cells[HSupplierIDCol].Value = oSupplier.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HSupplierNumberCol].Value = oSupplier.omodel.HNumber;
grdMain.Rows[i].Cells[HSupplierNameCol].Value = oSupplier.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSupplierIDCol].Value = "0";
grdMain.Rows[i].Cells[HSupplierNumberCol].Value = "";
grdMain.Rows[i].Cells[HSupplierNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HSupplierIDCol].Value = "0";
grdMain.Rows[i].Cells[HSupplierNumberCol].Value = "";
grdMain.Rows[i].Cells[HSupplierNameCol].Value = "";
}
}
//¹©Ó¦ÉÌÖ¸±ê-Íø¸ñ
///
/// ¹©Ó¦ÉÌÖ¸±ê-Íø¸ñ
///
///
///
///
///
///
public static void SetGridBySupTarget(DataGridView grdMain, int i, int HSupTargetIDCol, int HSupTargetNumberCol, int HSupTargetNameCol)
{
DAL.ClsGy_SupTarget_View oSupTarget = new DAL.ClsGy_SupTarget_View();
if (oSupTarget.RefreshView())
{
if (oSupTarget.GetInfoByID(oSupTarget.oModel.HItemID))
{
grdMain.Rows[i].Cells[HSupTargetIDCol].Value = oSupTarget.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HSupTargetNumberCol].Value = oSupTarget.omodel.HNumber;
grdMain.Rows[i].Cells[HSupTargetNameCol].Value = oSupTarget.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HSupTargetIDCol].Value = "0";
grdMain.Rows[i].Cells[HSupTargetNumberCol].Value = "";
grdMain.Rows[i].Cells[HSupTargetNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HSupTargetIDCol].Value = "0";
grdMain.Rows[i].Cells[HSupTargetNumberCol].Value = "";
grdMain.Rows[i].Cells[HSupTargetNameCol].Value = "";
}
}
//¼ÆÁ¿µ¥Î»×é-Íø¸ñ
///
/// ¼ÆÁ¿µ¥Î»×é-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByUnitGroup(DataGridView grdMain, int i, int HUnitGroupIDCol, int HUnitGroupNumberCol, int HUnitGroupNameCol)
{
DAL.ClsGy_UnitGroup_View oUnitGroup = new DAL.ClsGy_UnitGroup_View();
if (oUnitGroup.RefreshView())
{
if (oUnitGroup.GetInfoByID(oUnitGroup.oModel.HItemID))
{
grdMain.Rows[i].Cells[HUnitGroupIDCol].Value = oUnitGroup.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HUnitGroupNumberCol].Value = oUnitGroup.omodel.HNumber;
grdMain.Rows[i].Cells[HUnitGroupNameCol].Value = oUnitGroup.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HUnitGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HUnitGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitGroupNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HUnitGroupIDCol].Value = "0";
grdMain.Rows[i].Cells[HUnitGroupNumberCol].Value = "";
grdMain.Rows[i].Cells[HUnitGroupNameCol].Value = "";
}
}
//¹¤×÷ÖÐÐÄ-Íø¸ñ
///
/// ¹¤×÷ÖÐÐÄ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByWorkCenter(DataGridView grdMain, int i, int HWorkCenterIDCol, int HWorkCenterNumberCol, int HWorkCenterNameCol)
{
DAL.ClsGy_WorkCenter_View oWorkCenter = new DAL.ClsGy_WorkCenter_View();
if (oWorkCenter.RefreshView())
{
if (oWorkCenter.GetInfoByID(oWorkCenter.oModel.HItemID))
{
grdMain.Rows[i].Cells[HWorkCenterIDCol].Value = oWorkCenter.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HWorkCenterNumberCol].Value = oWorkCenter.omodel.HNumber;
grdMain.Rows[i].Cells[HWorkCenterNameCol].Value = oWorkCenter.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HWorkCenterIDCol].Value = "0";
grdMain.Rows[i].Cells[HWorkCenterNumberCol].Value = "";
grdMain.Rows[i].Cells[HWorkCenterNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HWorkCenterIDCol].Value = "0";
grdMain.Rows[i].Cells[HWorkCenterNumberCol].Value = "";
grdMain.Rows[i].Cells[HWorkCenterNameCol].Value = "";
}
}
//¹¤×ÊÀàÐÍ-Íø¸ñ
///
/// ¹¤×ÊÀàÐÍ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByWorkPayType(DataGridView grdMain, int i, int HWorkPayTypeIDCol, int HWorkPayTypeNumberCol, int HWorkPayTypeNameCol)
{
DAL.ClsGy_WorkPayType_View oWorkPayType = new DAL.ClsGy_WorkPayType_View();
if (oWorkPayType.RefreshView())
{
if (oWorkPayType.GetInfoByID(oWorkPayType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HWorkPayTypeIDCol].Value = oWorkPayType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HWorkPayTypeNumberCol].Value = oWorkPayType.omodel.HNumber;
grdMain.Rows[i].Cells[HWorkPayTypeNameCol].Value = oWorkPayType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HWorkPayTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HWorkPayTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HWorkPayTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HWorkPayTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HWorkPayTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HWorkPayTypeNameCol].Value = "";
}
}
//¹¤ÖÖ-Íø¸ñ
///
/// ¹¤ÖÖ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByWorkType(DataGridView grdMain, int i, int HWorkTypeIDCol, int HWorkTypeNumberCol, int HWorkTypeNameCol)
{
DAL.ClsGy_WorkType_View oWorkType = new DAL.ClsGy_WorkType_View();
if (oWorkType.RefreshView())
{
if (oWorkType.GetInfoByID(oWorkType.oModel.HItemID))
{
grdMain.Rows[i].Cells[HWorkTypeIDCol].Value = oWorkType.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HWorkTypeNumberCol].Value = oWorkType.omodel.HNumber;
grdMain.Rows[i].Cells[HWorkTypeNameCol].Value = oWorkType.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HWorkTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HWorkTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HWorkTypeNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HWorkTypeIDCol].Value = "0";
grdMain.Rows[i].Cells[HWorkTypeNumberCol].Value = "";
grdMain.Rows[i].Cells[HWorkTypeNameCol].Value = "";
}
}
//ÐéÄâ²Ö¿â-Íø¸ñ
///
/// ÐéÄâ²Ö¿â-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByVirtualWarehouse(DataGridView grdMain, int i, int HWhIDCol, int HWhNumberCol, int HWhNameCol)
{
DAL.ClsGy_VirtualWarehouse_View oWh = new DAL.ClsGy_VirtualWarehouse_View();
if (oWh.RefreshView())
{
if (oWh.GetInfoByID(oWh.oModel.HItemID))
{
grdMain.Rows[i].Cells[HWhIDCol].Value = oWh.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HWhNumberCol].Value = oWh.omodel.HNumber;
grdMain.Rows[i].Cells[HWhNameCol].Value = oWh.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HWhIDCol].Value = "0";
grdMain.Rows[i].Cells[HWhNumberCol].Value = "";
grdMain.Rows[i].Cells[HWhNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HWhIDCol].Value = "0";
grdMain.Rows[i].Cells[HWhNumberCol].Value = "";
grdMain.Rows[i].Cells[HWhNameCol].Value = "";
}
}
//ÐéÄâ²Öλ-Íø¸ñ
///
/// ÐéÄâ²Öλ-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByVirtualStockPlace(DataGridView grdMain, int i, int HVirtualStockPlaceIDCol, int HVirtualStockPlaceNumberCol, int HVirtualStockPlaceNameCol)
{
DAL.ClsGy_VirtualStockPlace_View oVirtualStockPlace = new DAL.ClsGy_VirtualStockPlace_View();
if (oVirtualStockPlace.RefreshView())
{
if (oVirtualStockPlace.GetInfoByID(oVirtualStockPlace.oModel.HItemID))
{
grdMain.Rows[i].Cells[HVirtualStockPlaceIDCol].Value = oVirtualStockPlace.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HVirtualStockPlaceNumberCol].Value = oVirtualStockPlace.omodel.HNumber;
grdMain.Rows[i].Cells[HVirtualStockPlaceNameCol].Value = oVirtualStockPlace.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HVirtualStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HVirtualStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HVirtualStockPlaceNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HVirtualStockPlaceIDCol].Value = "0";
grdMain.Rows[i].Cells[HVirtualStockPlaceNumberCol].Value = "";
grdMain.Rows[i].Cells[HVirtualStockPlaceNameCol].Value = "";
}
}
//µã¼ìÏîÄ¿-Íø¸ñ
///
/// µã¼ìÏîÄ¿-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByDotCheckItem(DataGridView grdMain, int i, int HDotCheckItemIDCol, int HDotCheckItemNumberCol, int HDotCheckItemNameCol)
{
DAL.ClsGy_DotCheck_View oDot = new DAL.ClsGy_DotCheck_View();
if (oDot.RefreshView())
{
if (oDot.GetInfoByID(oDot.oModel.HItemID))
{
grdMain.Rows[i].Cells[HDotCheckItemIDCol].Value = oDot.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HDotCheckItemNumberCol].Value = oDot.omodel.HNumber;
grdMain.Rows[i].Cells[HDotCheckItemNameCol].Value = oDot.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HDotCheckItemIDCol].Value = "0";
grdMain.Rows[i].Cells[HDotCheckItemNumberCol].Value = "";
grdMain.Rows[i].Cells[HDotCheckItemNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HDotCheckItemIDCol].Value = "0";
grdMain.Rows[i].Cells[HDotCheckItemNumberCol].Value = "";
grdMain.Rows[i].Cells[HDotCheckItemNameCol].Value = "";
}
}
//// -Íø¸ñ
/////
///// -Íø¸ñ
/////
/////
/////
/////
/////
/////
//public static void SetGridByQCCheckClass(DataGridView grdMain, int i, int HQCCheckClassIDCol, int HQCCheckClassNumberCol, int HQCCheckClassNameCol)
//{
// DAL.ClsGy_QCCheckClass_View oQCCheckClass = new DAL.ClsGy_QCCheckClass_View();
// if (oQCCheckClass.RefreshView())
// {
// if (oQCCheckClass.GetInfoByID(oQCCheckClass.oModel.HItemID))
// {
// grdMain.Rows[i].Cells[HQCCheckClassIDCol].Value = oQCCheckClass.omodel.HItemID.ToString();
// grdMain.Rows[i].Cells[HQCCheckClassNumberCol].Value = oQCCheckClass.omodel.HNumber;
// grdMain.Rows[i].Cells[HQCCheckClassNameCol].Value = oQCCheckClass.omodel.HName;
// }
// else
// {
// grdMain.Rows[i].Cells[HQCCheckClassIDCol].Value = "0";
// grdMain.Rows[i].Cells[HQCCheckClassNumberCol].Value = "";
// grdMain.Rows[i].Cells[HQCCheckClassNameCol].Value = "";
// }
// }
// else
// {
// grdMain.Rows[i].Cells[HQCCheckClassIDCol].Value = "0";
// grdMain.Rows[i].Cells[HQCCheckClassNumberCol].Value = "";
// grdMain.Rows[i].Cells[HQCCheckClassNameCol].Value = "";
// }
//}
//// -Íø¸ñ
/////
///// -Íø¸ñ
/////
/////
/////
/////
/////
/////
//public static void SetGridByQCCheckItem(DataGridView grdMain, int i, int HQCCheckItemIDCol, int HQCCheckItemNumberCol, int HQCCheckItemNameCol)
//{
// DAL.ClsGy_QCCheckItem_View oQCCheckItem = new DAL.ClsGy_QCCheckItem_View();
// if (oQCCheckItem.RefreshView())
// {
// if (oQCCheckItem.GetInfoByID(oQCCheckItem.oModel.HItemID))
// {
// grdMain.Rows[i].Cells[HQCCheckItemIDCol].Value = oQCCheckItem.omodel.HItemID.ToString();
// grdMain.Rows[i].Cells[HQCCheckItemNumberCol].Value = oQCCheckItem.omodel.HNumber;
// grdMain.Rows[i].Cells[HQCCheckItemNameCol].Value = oQCCheckItem.omodel.HName;
// }
// else
// {
// grdMain.Rows[i].Cells[HQCCheckItemIDCol].Value = "0";
// grdMain.Rows[i].Cells[HQCCheckItemNumberCol].Value = "";
// grdMain.Rows[i].Cells[HQCCheckItemNameCol].Value = "";
// }
// }
// else
// {
// grdMain.Rows[i].Cells[HQCCheckItemIDCol].Value = "0";
// grdMain.Rows[i].Cells[HQCCheckItemNumberCol].Value = "";
// grdMain.Rows[i].Cells[HQCCheckItemNameCol].Value = "";
// }
//}
//¼ì¾ß-Íø¸ñ
///
/// ¼ì¾ß-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByCheckTools(DataGridView grdMain, int i, int HCheckToolsIDCol, int HCheckToolsNumberCol, int HCheckToolsNameCol)
{
DAL.ClsGy_CheckToolsFileMain_View oCheck = new DAL.ClsGy_CheckToolsFileMain_View();
if (oCheck.RefreshView())
{
if (oCheck.GetInfoByID(oCheck.oModel.HItemID))
{
grdMain.Rows[i].Cells[HCheckToolsIDCol].Value = oCheck.oModel.HItemID.ToString();
grdMain.Rows[i].Cells[HCheckToolsNumberCol].Value = oCheck.oModel.HNumber;
grdMain.Rows[i].Cells[HCheckToolsNameCol].Value = oCheck.oModel.HName;
}
else
{
grdMain.Rows[i].Cells[HCheckToolsIDCol].Value = "0";
grdMain.Rows[i].Cells[HCheckToolsNumberCol].Value = "";
grdMain.Rows[i].Cells[HCheckToolsNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HCheckToolsIDCol].Value = "0";
grdMain.Rows[i].Cells[HCheckToolsNumberCol].Value = "";
grdMain.Rows[i].Cells[HCheckToolsNameCol].Value = "";
}
}
//Ä£Öξß-Íø¸ñ
///
/// Ä£Öξß-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByMouldFile(DataGridView grdMain, int i, int HMaterIDCol, int HMaterNumberCol, int HMaterNameCol)
{
DAL.ClsGy_MouldFileMain_View oMFM = new DAL.ClsGy_MouldFileMain_View();
if (oMFM.RefreshView())
{
if (oMFM.GetInfoByID(oMFM.oModel.HItemID))
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = oMFM.oModel.HItemID.ToString();
grdMain.Rows[i].Cells[HMaterNumberCol].Value = oMFM.oModel.HNumber;
grdMain.Rows[i].Cells[HMaterNameCol].Value = oMFM.oModel.HName;
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HMaterIDCol].Value = "0";
grdMain.Rows[i].Cells[HMaterNumberCol].Value = "";
grdMain.Rows[i].Cells[HMaterNameCol].Value = "";
}
}
//¹¤ÒÕ²ÎÊý-Íø¸ñ
///
/// ¹¤ÒÕ²ÎÊý-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByTech(DataGridView grdMain, int i, int HTechParamIDCol, int HTechParamNumberCol, int HTechParamNameCol)
{
DAL.ClsGy_TechnologyParameter_View oTech = new DAL.ClsGy_TechnologyParameter_View();
if (oTech.RefreshView())
{
if (oTech.GetInfoByID(oTech.oModel.HItemID))
{
grdMain.Rows[i].Cells[HTechParamIDCol].Value = oTech.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HTechParamNumberCol].Value = oTech.omodel.HNumber;
grdMain.Rows[i].Cells[HTechParamNameCol].Value = oTech.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HTechParamIDCol].Value = "0";
grdMain.Rows[i].Cells[HTechParamNumberCol].Value = "";
grdMain.Rows[i].Cells[HTechParamNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HTechParamIDCol].Value = "0";
grdMain.Rows[i].Cells[HTechParamNumberCol].Value = "";
grdMain.Rows[i].Cells[HTechParamNameCol].Value = "";
}
}
//¹¤ÒÕ²ÎÊýµ¥Î»-Íø¸ñ
///
/// ¹¤ÒÕ²ÎÊýµ¥Î»-Íø¸ñ
///
///
///
///
///
///
public static void SetGridByTechU(DataGridView grdMain, int i, int HTechParamUnitIDCol, int HTechParamUnitNumberCol, int HTechParamUnitNameCol)
{
DAL.ClsGy_TechnologyParameterUnit_View oTechU = new DAL.ClsGy_TechnologyParameterUnit_View();
if (oTechU.RefreshView())
{
if (oTechU.GetInfoByID(oTechU.oModel.HItemID))
{
grdMain.Rows[i].Cells[HTechParamUnitIDCol].Value = oTechU.omodel.HItemID.ToString();
grdMain.Rows[i].Cells[HTechParamUnitNumberCol].Value = oTechU.omodel.HNumber;
grdMain.Rows[i].Cells[HTechParamUnitNameCol].Value = oTechU.omodel.HName;
}
else
{
grdMain.Rows[i].Cells[HTechParamUnitIDCol].Value = "0";
grdMain.Rows[i].Cells[HTechParamUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HTechParamUnitNameCol].Value = "";
}
}
else
{
grdMain.Rows[i].Cells[HTechParamUnitIDCol].Value = "0";
grdMain.Rows[i].Cells[HTechParamUnitNumberCol].Value = "";
grdMain.Rows[i].Cells[HTechParamUnitNameCol].Value = "";
}
}
#endregion
}
}