Exemplo n.º 1
0
        private void ShiftMain_Load(object sender, EventArgs e)
        {
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "ID", "s_id", false, 60);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "설비코드", "m_code", true, 80);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "설비명", "m_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "Shift", "common_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "시작시간", "shift_stime", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "완료시간", "shift_etime", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "적용시작일", "shift_sdate", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "적용완료일", "shift_edate", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "사용유무", "shift_yn", true);

            dataGridView1.AllowUserToAddRows = false;
            dataGridView1.SelectionMode      = DataGridViewSelectionMode.FullRowSelect;
            //     ShiftService S_service = new ShiftService();
            LoadData();

            ResourceService  R_service = new ResourceService();
            List <MachineVO> m_list    = R_service.GetMachineAll();

            ComboUtil.ComboBinding(cboMachine, m_list, "m_id", "m_name", "미선택");

            CommonCodeService C_service = new CommonCodeService();


            List <CommonVO> c_list     = C_service.GetCommonCodeAll();
            var             shift_code = (from shift in c_list
                                          where shift.common_type == "shift_code"
                                          select shift).ToList();

            ComboUtil.ComboBinding(cboShift, shift_code, "common_value", "common_name", "전체");

            GridViewUtil.SetDataGridView(dataGridView1);
        }
Exemplo n.º 2
0
        private void ComboBinding()
        {
            common_service  = new CommonCodeService();
            codelist        = common_service.GetCommonCodeAll();
            product_service = new ProductService();

            List <FactoryDB_VO> f_list           = new List <FactoryDB_VO>();
            ResourceService     resource_service = new ResourceService();

            f_list = resource_service.GetFactoryAll();

            List <UserVO> user_list = product_service.GetUserAll();

            #region 사용여부cbo
            List <CommonVO> _cboUseFlag = (from item in codelist
                                           where item.common_type == "user_flag"
                                           select item).ToList();
            ComboUtil.ComboBinding(cboIsUsed, _cboUseFlag, "common_value", "common_name", "선택");
            #endregion

            #region 품목유형cbo
            _cboUseFlag = (from item in codelist
                           where item.common_type == "item_type"
                           select item).ToList();
            ComboUtil.ComboBinding(cboProductType, _cboUseFlag, "common_value", "common_name", "선택");
            #endregion

            #region 납품업체cbo
            List <CompanyVO> company_list  = new List <CompanyVO>();
            OrderService     order_service = new OrderService();
            company_list = order_service.GetCompanyAll("customer");
            ComboUtil.ComboBinding(cboCompany, company_list, "company_code", "company_name", "선택");
            #endregion

            #region 발주업체cbo
            company_list = order_service.GetCompanyAll("cooperative");
            ComboUtil.ComboBinding(cboSupplyCompany, company_list, "company_code", "company_name", "선택");

            List <UserVO> user_vo = new List <UserVO>();
            #endregion

            #region 담당자cbo

            ComboUtil.ComboBinding(cboAdmin, user_list, "user_id", "user_name", "선택");
            #endregion

            #region 입고창고cbo
            List <FactoryDB_VO> _cboInSector = (from item in f_list
                                                where item.facility_value == "FAC200"
                                                select item).ToList();
            ComboUtil.ComboBinding(cboInSector, _cboInSector, "factory_code", "factory_name", "선택");
            #endregion

            #region 출고창고cbo
            List <FactoryDB_VO> _cboOutSector = (from item in f_list
                                                 where item.facility_value == "FAC100"
                                                 select item).ToList();
            ComboUtil.ComboBinding(cboOutSector, _cboOutSector, "factory_code", "factory_name", "선택");
            #endregion
        }
Exemplo n.º 3
0
        private void CboBinding()
        {
            OrderService      order_service   = new OrderService();
            ProductService    product_service = new ProductService();
            CommonCodeService common_service  = new CommonCodeService();

            #region 발주업체cbo
            List <CompanyVO> company_list = order_service.GetCompanyAll("COOPERATIVE");
            ComboUtil.ComboBinding(cboCompany, company_list, "company_id", "company_name", "선택");
            #endregion

            #region 품목cbo

            product_service = new ProductService();
            List <ProductVO> product_list = new List <ProductVO>();
            product_list = product_service.GetAllProducts();
            ComboUtil.ComboBinding(cboProduct, product_list, "product_id", "product_name", "선택");
            #endregion

            #region 사용여부
            List <CommonVO> codelist    = common_service.GetCommonCodeAll();
            List <CommonVO> _cboUseFlag = (from item in codelist
                                           where item.common_type == "user_flag"
                                           select item).ToList();
            ComboUtil.ComboBinding(cboIsUsed, _cboUseFlag, "common_value", "common_name", "선택");
            #endregion
        }
Exemplo n.º 4
0
        private void FactoryMgt_Load(object sender, EventArgs e)
        {
            this.ImeMode = ImeMode.Hangul;
            dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "ID", "factory_id", false, 60);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "시설군", "facility_class", true, 80);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "시설구분", "facility_type", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "시설타입", "facility_value", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "시설코드", "factory_code", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "시설명", "factory_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "상위시설", "factory_parent", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "업체명", "company_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "사용유무", "factory_yn", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "수정자", "factory_uadmin", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "수정시간", "factory_udate", true);
            GridViewUtil.SetDataGridView(dataGridView1);
            LoadData();
            CommonCodeService Common_service = new CommonCodeService();

            common_list = Common_service.GetCommonCodeAll();

            var mCode = (from item in common_list
                         where item.common_type == "facility_class_id"
                         select item).ToList();

            ComboUtil.ComboBinding <CommonVO>(cboSearchFacilityGroup, mCode, "common_value", "common_name", "미선택");

            panel1.Focus();
            dataGridView1.CurrentCell = null;

            dataGridView1.ClearSelection();
        }
Exemplo n.º 5
0
        }   //cbo.SelectedValue null처리(string)

        private void ComboBoxBinding()
        {
            common_service = new CommonCodeService();
            bom_service    = new BomService();
            codelist       = common_service.GetCommonCodeAll();

            #region 사용여부cbo
            List <CommonVO> _cboUseFlag = (from item in codelist
                                           where item.common_type == "user_flag"
                                           select item).ToList();
            ComboUtil.ComboBinding(cboIsUsed, _cboUseFlag, "common_value", "common_name", "선택");

            List <CommonVO> _cboRequiredPlan = (from item in codelist
                                                where item.common_type == "user_flag"
                                                select item).ToList();
            ComboUtil.ComboBinding(cboRequiredPlan, _cboRequiredPlan, "common_value", "common_name");
            #endregion

            #region 품목cbo

            product_service = new ProductService();
            List <ProductVO> product_list = new List <ProductVO>();
            product_list = product_service.GetAllProducts();
            ComboUtil.ComboBinding(cboProduct, product_list, "product_id", "product_name", "선택");
            #endregion

            #region 상위품목cbo
            List <BomVO> bom_list = new List <BomVO>();
            bom_list = bom_service.GetBomAll();
            ComboUtil.ComboBinding(cboParentProduct, bom_list, "product_id", "bom_name", "-");



            #endregion
        }
Exemplo n.º 6
0
        private void FacilitieInfoPop_Load(object sender, EventArgs e)
        {
            txtModifyTime.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", today);
            //콤보박스 바인딩
            {
                service = new CommonCodeService();
                list    = service.GetCommonCodeAll();
                {
                    //사용유무
                    var mCode = (from item in list
                                 where item.common_type == "user_flag"
                                 select item).ToList();

                    ComboUtil.ComboBinding <CommonVO>(cboIsUsed, mCode, "common_value", "common_name");
                }
                {
                    var mCode = (from item in list
                                 where item.common_type == "user_flag"
                                 select item).ToList();

                    mCode.Reverse();
                    ComboUtil.ComboBinding <CommonVO>(cboIsOS, mCode, "common_value", "common_name");
                }
                R_service = new ResourceService();
                var Fatory_list = R_service.GetFactoryAll();

                var WH1 = (from wh1 in Fatory_list
                           where wh1.facility_class == "창고"
                           select wh1).ToList();
                ComboUtil.ComboBinding <FactoryDB_VO>(cboUseWH, WH1, "factory_id", "factory_name", "미선택");
                var WH2 = (from wh1 in Fatory_list
                           where wh1.facility_class == "창고"
                           select wh1).ToList();
                ComboUtil.ComboBinding <FactoryDB_VO>(cboOkWH, WH2, "factory_id", "factory_name", "미선택");
                var WH3 = (from wh1 in Fatory_list
                           where wh1.facility_class == "창고"
                           select wh1).ToList();
                ComboUtil.ComboBinding <FactoryDB_VO>(cboNgWH, WH3, "factory_id", "factory_name", "미선택");
            }
            if (mode == EditMode.Update)
            {
                MachineVO vo = this.VO;
                lblID.Text           = VO.m_id.ToString();
                lblGrCodeID.Text     = VO.mgrade_id.ToString();
                txtMgrade_code.Text  = VO.mgrade_code;
                txtCodeFacility.Text = VO.m_code;
                txtNameFacility.Text = VO.m_name;
                cboUseWH.Text        = VO.m_use_sector;
                cboOkWH.Text         = VO.m_ok_sector;
                cboNgWH.Text         = VO.m_ng_sector;
                cboIsUsed.Text       = VO.m_yn;
                cboIsOS.Text         = VO.m_os_yn;
                txtModifier.Text     = VO.m_uadmin;
                txtModifyTime.Text   = VO.m_udate;
                txtCheck.Text        = VO.m_check;
                txtComment.Text      = VO.m_comment;
            }
        }
Exemplo n.º 7
0
        private void ComboBinding()
        {
            common_service = new CommonCodeService();
            codelist       = common_service.GetCommonCodeAll();
            List <CommonVO> _cboUseFlag = (from item in codelist
                                           where item.common_type == "user_flag"
                                           select item).ToList();

            ComboUtil.ComboBinding(cboIsUsed, _cboUseFlag, "common_value", "common_name", "선택");
        }
Exemplo n.º 8
0
        private void CompanyPop_Load(object sender, EventArgs e)
        {
            string udate = string.Format("{0:yyyy-MM-dd HH:mm:ss}", today);

            txtUdate.Text = udate;
            service       = new CommonCodeService();
            common_list   = service.GetCommonCodeAll();
            {
                //사용유무
                var mCode = (from item in common_list
                             where item.common_type == "vendor_type"
                             select item).ToList();

                ComboUtil.ComboBinding <CommonVO>(cboCompanyType, mCode, "common_value", "common_name", "미선택");
            }
            {
                //사용유무
                var mCode = (from item in common_list
                             where item.common_type == "user_flag"
                             select item).ToList();

                ComboUtil.ComboBinding <CommonVO>(cboYN, mCode, "common_value", "common_name");
            }
            {
                R_service = new ResourceService();
                u_list    = R_service.GetUserAll();

                ComboUtil.ComboBinding <UserVO>(cboUser, u_list, "user_id", "user_name");
            }
            if (mode == EditMode.Update)
            {
                if (lblID.Text != "")
                {
                    CompanyDB_VO vo = R_service.GetCompanyByID(Convert.ToInt32(lblID.Text));

                    txtCodeCompany.Text = vo.company_code;
                    txtNameCompany.Text = vo.company_name;
                    cboCompanyType.Text = vo.common_name;
                    txtCEO.Text         = vo.company_ceo;
                    txtCnum.Text        = vo.company_cnum;
                    txtbtype.Text       = vo.company_btype;
                    txtGtype.Text       = vo.company_gtype;
                    cboUser.Text        = vo.user_name;
                    txtEmail.Text       = vo.company_email;
                    txtPhone.Text       = vo.company_phone;
                    txtFax.Text         = vo.company_fax;
                    cboYN.Text          = vo.company_yn;
                    txtAdmin.Text       = vo.company_uadmin;
                    txtUdate.Text       = udate;
                    txtComment.Text     = vo.company_comment;
                    txtOrder_code.Text  = vo.company_order_code;
                }
            }
        }
Exemplo n.º 9
0
        private void SOO_Load(object sender, EventArgs e)
        {
            radioButton6.Checked = true;
            ResourceService   R_service = new ResourceService();
            CommonCodeService C_service = new CommonCodeService();
            List <CommonVO>   c_list    = C_service.GetCommonCodeAll();

            {
                var list_c = (from item in c_list
                              where item.common_type == "create_work_order"
                              select item).ToList();

                ComboUtil.ComboBinding(cboStatus, list_c, "common_value", "common_name", "미선택");
            }
            {
                var R_list = (from item in R_service.GetFactoryAll()
                              where item.facility_class == "창고"
                              select item).ToList();
                ComboUtil.ComboBinding(cboWH, R_list, "factory_id", "factory_name", "미선택");
            }
            {
                ComboUtil.ComboBinding(cboMachine, R_service.GetMachineAll(), "m_id", "m_name", "미선택");
            }

            dateTimePicker1.Value = today.AddDays(-10);
            dateTimePicker2.Value = today.AddDays(20);


            dt = P_service.GetProductionPlanCheckHis(dateTimePicker1.Value.ToShortDateString(), dateTimePicker2.Value.ToShortDateString());


            GridViewUtil.SetDataGridView(dataGridView1);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "상품ID", "pro_id", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "투입일", "pro_date", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "지시일", "so_sdate", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "설비코드", "m_code", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "설비명", "m_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "상태", "common_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "상태", "pro_state", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "품목", "product_codename", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "품명", "producct_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "소진창고", "m_use_sector", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "양품창고", "m_ok_sector", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "불량창고", "m_ng_sector", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "계획수량", "pro_count", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "지시수량", "pro_pcount", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "수량", "pro_mcount", true);
            GridViewUtil.SetDataGridView(dataGridView1);
            dataGridView1.DataSource = dt;
        }
Exemplo n.º 10
0
        private void FacilitiesPop_Load(object sender, EventArgs e)
        {
            string todayFormat = string.Format("{0:yyyy-MM-dd HH:mm:ss}", today);

            txtMgrade_udate.Text = todayFormat;
            service = new CommonCodeService();
            list    = service.GetCommonCodeAll();
            {
                //사용유무
                var mCode = (from item in list
                             where item.common_type == "user_flag"
                             select item).ToList();

                ComboUtil.ComboBinding <CommonVO>(cboYN, mCode, "common_value", "common_name");
            }
        }
Exemplo n.º 11
0
        private void GOO_Load(object sender, EventArgs e)
        {
            CommonCodeService C_service = new CommonCodeService();
            List <CommonVO>   c_list    = C_service.GetCommonCodeAll();

            {
                var list_c = (from item in c_list
                              where item.common_type == "create_work_order"
                              select item).ToList();

                ComboUtil.ComboBinding(cboStatus, list_c, "common_value", "common_name", "미선택");
            }
            dataGridView1.SelectionMode      = DataGridViewSelectionMode.FullRowSelect;
            dataGridView1.AllowUserToAddRows = false;

            dateTimePicker1.Value = DateTime.Now.AddDays(-7);
            dateTimePicker2.Value = DateTime.Now.AddDays(7);
            ResourceService  R_service = new ResourceService();
            List <MachineVO> m_list    = R_service.GetMachineAll();

            ComboUtil.ComboBinding(cboMachine, m_list, "m_code", "m_name", "미선택");

            DataGridViewCheckBoxColumn checkBoxColumn = new DataGridViewCheckBoxColumn();

            checkBoxColumn.AutoSizeMode = DataGridViewAutoSizeColumnMode.DisplayedCells;
            checkBoxColumn.HeaderText   = "선택";
            dataGridView1.Columns.Add(checkBoxColumn);

            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "작업지시번호", "WorkID", true, 60);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "품목", "product_codename", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "품명", "product_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "상태", "common_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "상태", "pro_state", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "설비코드", "m_code", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "설비명", "m_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "계획수량", "pro_count", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "지시수량", "pro_pcount", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "계획시작일", "pro_date", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "마스터ID", "plan_id", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "상품ID", "pro_id", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView1, "소요시간", "use_time", true);
            GridViewUtil.SetDataGridView(dataGridView1);


            LoadData();
        }
Exemplo n.º 12
0
        private void BORPop_Load(object sender, EventArgs e)
        {
            R_survice = new ResourceService();
            #region 콤보박스 바인딩
            common_service = new CommonCodeService();
            common_list    = common_service.GetCommonCodeAll();
            {
                //공정
                var mCode = (from item in common_list
                             where item.common_type == "route"
                             select item).ToList();

                ComboUtil.ComboBinding <CommonVO>(cboRoute, mCode, "common_value", "common_name", "미선택");
            }
            {
                //사용유무
                var mCode = (from item in common_list
                             where item.common_type == "user_flag"
                             select item).ToList();

                ComboUtil.ComboBinding <CommonVO>(cboYN, mCode, "common_value", "common_name");
            }
            R_survice = new ResourceService();
            List <MachineVO> lst = R_survice.GetMachineAll();
            ComboUtil.ComboBinding <MachineVO>(cboM_name, lst, "m_id", "m_name", "미선택");
            ProductService   product_service = new ProductService();
            List <ProductVO> list            = product_service.GetAllProducts();
            ComboUtil.ComboBinding <ProductVO>(cboP_Name, list, "product_id", "product_name", "미선택");
            #endregion

            if (mode == EditMode.Update)
            {
                R_survice         = new ResourceService();
                vo                = R_survice.GetBORByID(Convert.ToInt32(lblID.Text), lblRoute.Text);
                lblID.Text        = vo.bor_id.ToString();
                cboP_Name.Text    = vo.product_name;
                cboM_name.Text    = vo.m_name;
                cboYN.Text        = vo.bor_yn;
                cboRoute.Text     = vo.common_name;
                txtComment.Text   = vo.bor_comment;
                txtReadyTime.Text = vo.bor_readytime.ToString();
                txtTactTime.Text  = vo.bor_tacktime.ToString();
            }
        }
Exemplo n.º 13
0
        private void FactoryPop_Load(object sender, EventArgs e)
        {
            {
                //콤보박스 업체 바인딩
                R_service    = new ResourceService();
                Company_list = R_service.GetCompanyAll();
                var C_Code = (from R_Item in Company_list
                              select R_Item).ToList();

                ComboUtil.ComboBinding <CompanyDB_VO>(cboCompany, C_Code, "company_id", "company_name", "미선택");
            }

            service = new CommonCodeService();

            Common_list = service.GetCommonCodeAll();

            ComboUtil.ComboBinding <CommonVO>(cboFactoryGrade, Combo("facility_class_id"), "common_value", "common_name", "미선택");
            ComboUtil.ComboBinding <CommonVO>(cboTypeFactory, Combo("facility_type"), "common_value", "common_name", "미선택");
            ComboUtil.ComboBinding <CommonVO>(cboYN, Combo("user_flag2"), "common_value", "common_name");

            {
                if (mode == EditMode.Update)
                {
                    VO = R_service.GetFactoryByID(Convert.ToInt32(lblID.Text));
                    string Comapany_Name = (VO.company_name == null) ? "" : VO.company_name.ToString();
                    txtCodeFactory.Text  = VO.factory_code;
                    txtComment.Text      = VO.factory_comment;
                    txtUadmin.Text       = VO.factory_uadmin;
                    txtUdate.Text        = string.Format("{0:yyyy-MM-dd HH:mm:ss}", today);
                    txtNameFactory.Text  = VO.factory_name;
                    cboCompany.Text      = Comapany_Name;
                    cboTypeFactory.Text  = VO.factory_type;
                    txtpr.Text           = VO.factory_parent;
                    cboYN.Text           = VO.factory_yn;
                    cboFactoryGrade.Text = VO.factory_grade;
                }
                else if (mode == EditMode.Input)
                {
                    txtUdate.Text = string.Format("{0:yyyy-MM-dd HH:mm:ss}", today);
                }
            }
        }
Exemplo n.º 14
0
        private void businessMgt_Load(object sender, EventArgs e)
        {
            dataGridView2.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업체ID", "company_id", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업체코드", "company_code", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업체명", "company_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업체타입", "common_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업체타입", "company_type", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "대표자명", "company_ceo", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "사업자등록번호", "company_cnum", true);

            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업종", "company_btype", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업태", "company_gtype", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "담당자", "user_name", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "담당자id", "user_id", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "이메일", "company_email", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "전화번호", "company_phone", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "팩스", "company_fax", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "수정자", "company_uadmin", false);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "수정시간", "company_udate", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업체정보", "company_comment", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "사용유무", "company_yn", true);
            GridViewUtil.AddNewColumnToDataGridView(dataGridView2, "업체발주코드", "company_order_code", false);
            GridViewUtil.SetDataGridView(dataGridView2);

            LoadData();

            common_service = new CommonCodeService();
            common_list    = common_service.GetCommonCodeAll();
            {
                //사용유무
                var mCode = (from item in common_list
                             where item.common_type == "vendor_type"
                             select item).ToList();

                ComboUtil.ComboBinding <CommonVO>(cboTypeCompany, mCode, "common_value", "common_name", "미선택");
            }
        }
Exemplo n.º 15
0
        private void BOR_Load(object sender, EventArgs e)
        {
            this.ImeMode = ImeMode.Hangul;
            GridViewUtil.SetDataGridView(dataGridView1);
            dgvColumnSet();



            LoadData();
            dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect; // 셀 클릭하면 행 전체가 선택


            common_service = new CommonCodeService();
            common_list    = common_service.GetCommonCodeAll();
            {
                //사용유무
                var mCode = (from item in common_list
                             where item.common_type == "route"
                             select item).ToList();

                ComboUtil.ComboBinding <CommonVO>(cboProcess, mCode, "common_value", "common_name", "미선택");
            }
        }
Exemplo n.º 16
0
        private void InitComboBind()
        {
            string todayFormat = string.Format("{0:yyyy-MM-dd HH:mm:ss}", today);

            txtUdate.Text = todayFormat;
            ResourceService  R_service = new ResourceService();
            List <MachineVO> m_list    = R_service.GetMachineAll();

            ComboUtil.ComboBinding(cboM_code, m_list, "m_id", "m_code");

            CommonCodeService C_service = new CommonCodeService();
            List <CommonVO>   c_list    = C_service.GetCommonCodeAll();
            var shift_code = (from shift in c_list
                              where shift.common_type == "shift_code"
                              select shift).ToList();

            ComboUtil.ComboBinding(cboShiftID, shift_code, "common_value", "common_name");

            var YN = (from shift in c_list
                      where shift.common_type == "user_flag"
                      select shift).ToList();

            ComboUtil.ComboBinding(cboYN, YN, "common_value", "common_name");
        }
Exemplo n.º 17
0
        private void ComboBoxBinding()
        {
            //TODO 메서드 하나로 모듈화
            ProductService      product_service  = new ProductService();
            ResourceService     resource_service = new ResourceService();
            List <FactoryDB_VO> f_list           = new List <FactoryDB_VO>();

            common_service = new CommonCodeService();
            codelist       = common_service.GetCommonCodeAll();

            List <UserVO> user_list = product_service.GetUserAll();

            List <CommonVO> _cboUnit = (from item in codelist
                                        where item.common_type == "item_unit"
                                        select item).ToList();

            ComboUtil.ComboBinding(cboProductUnit, _cboUnit, "common_value", "common_name", "선택");


            List <CommonVO> _cboUseFlag = (from item in codelist
                                           where item.common_type == "user_flag"
                                           select item).ToList();

            ComboUtil.ComboBinding(cboIsUsed, _cboUseFlag, "common_value", "common_name", "선택");


            List <CommonVO> _commonlist = (from item in codelist
                                           where item.common_type == "item_type"
                                           select item).ToList();

            ComboUtil.ComboBinding(cboProductType, _commonlist, "common_value", "common_name", "선택");

            List <CommonVO> _commonmeastype = (from item in codelist
                                               where item.common_type == "meastype"
                                               select item).ToList();

            ComboUtil.ComboBinding(cboMeasType, _commonmeastype, "common_value", "common_name", "선택");

            #region 담당자cbo

            ComboUtil.ComboBinding(cboAdmin, user_list, "user_id", "user_name", "선택");
            #endregion

            #region 입고창고cbo
            f_list = resource_service.GetFactoryAll();
            List <FactoryDB_VO> _cboInSector = (from item in f_list
                                                where item.facility_value == "FAC200" || item.facility_value == "FAC400"
                                                select item).ToList();
            ComboUtil.ComboBinding(cboInSector, _cboInSector, "factory_code", "factory_name", "선택");
            #endregion

            #region 출고창고cbo
            List <FactoryDB_VO> _cboOutSector = (from item in f_list
                                                 where item.facility_value == "FAC100"
                                                 select item).ToList();
            ComboUtil.ComboBinding(cboOutSector, _cboOutSector, "factory_code", "factory_name", "선택");
            #endregion


            #region 발주방식cbo
            _commonlist = (from item in codelist
                           where item.common_type == "order_method"
                           select item).ToList();
            ComboUtil.ComboBinding(cboOrderType, _commonlist, "common_value", "common_name", "선택");
            #endregion

            #region 납품업체cbo
            List <CompanyVO> company_list  = new List <CompanyVO>();
            OrderService     order_service = new OrderService();
            company_list = order_service.GetCompanyAll("COOPERATIVE");
            ComboUtil.ComboBinding(cboSupplyCompany, company_list, "company_code", "company_name", "선택");
            #endregion

            #region 발주업체cbo
            company_list = order_service.GetCompanyAll("CUSTOMER");
            ComboUtil.ComboBinding(cboDemandCompany, company_list, "company_code", "company_name", "선택");

            List <UserVO> user_vo = new List <UserVO>();
            #endregion
        }