Beispiel #1
0
        /// 생성자
        public HydtMetrDtlViewMdl(string FTR_CDE, int FTR_IDN)
        {
            try
            {
                // 1.상세마스터
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectHydtMetrDtl");
                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                Dtl = BizUtil.SelectObject(param) as HydtMetrDtl;



                //2.탭1 - 유지보수
                param = new Hashtable();
                param.Add("sqlId", "selectChscResSubList");

                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                this.Tab01List = (List <LinkFmsChscFtrRes>)BizUtil.SelectListObj <LinkFmsChscFtrRes>(param);

                //텝4 - 급수전계량기
                param = new Hashtable();
                param.Add("sqlId", "selectWttMetaHtList");

                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                this.Tab02List = (List <WttMetaHt>)BizUtil.SelectListObj <WttMetaHt>(param);
            }
            catch (Exception) {}
        }
Beispiel #2
0
        //초기모델조회
        private void InitModel()
        {
            Hashtable param = new Hashtable();

            // 0.파일첨부내역
            param.Add("sqlId", "SelectFileMap");
            param.Add("BIZ_ID", txtBIZ_ID.Text);
            param.Add("FIL_SEQ", txtFIL_SEQ.Text);

            FileMapDtl result = BizUtil.SelectObject(param) as FileMapDtl;


            // 내역없으면 신규첨부내용
            if (!FmsUtil.IsNull(result))
            {
                // 0.상세정보
                Dtl = result;

                // 1.첨부파일
                param.Clear();
                param.Add("sqlId", "SelectFileDtl2");
                param.Add("FIL_SEQ", txtFIL_SEQ.Text);

                ItemsSelect = new ObservableCollection <FileDtl>(BizUtil.SelectListObj <FileDtl>(param));
            }
        }
Beispiel #3
0
        /// 생성자
        public ValvFacDtlViewMdl(string FTR_CDE, int FTR_IDN)
        {
            try
            {
                // 1.상세마스터
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectValvFacDtl");
                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                Dtl = BizUtil.SelectObject(param) as ValvFacDtl;



                //2.유지보수(탭)
                param = new Hashtable();
                param.Add("sqlId", "selectChscResSubList");

                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                this.Tab01List = (List <LinkFmsChscFtrRes>)BizUtil.SelectListObj <LinkFmsChscFtrRes>(param);
            }
            catch (Exception) {}
        }
Beispiel #4
0
        /// <summary>
        /// 초기조회 및 바인딩
        /// </summary>
        private void InitDataBinding()
        {
            try
            {
                // cbMNG_CDE 관리기관
                BizUtil.SetCmbCode(cbMNG_CDE, "250101", "선택");

                // cbUPPER_FTR_CDE 상위블록코드
                //Func<DataRow, bool> filter = Row => (Row.Field<string>("FTR_CDE").Contains("BZ001") || Row.Field<string>("FTR_CDE").Contains("BZ002"));//대블록,중블록
                //BizUtil.SetCombo(cbUPPER_FTR_CDE, "Select_FTR_LIST", "FTR_CDE", "FTR_NAM", null, filter);


                cbUPPER_FTR_CDE.DisplayMember = "FTR_NAM";
                cbUPPER_FTR_CDE.ValueMember   = "FTR_CDE";
                Hashtable param = new Hashtable();
                param.Add("sqlId", "Select_FTR_LIST3");
                param.Add("FTR_CDE", "BZ");
                List <FctDtl> lst = BizUtil.SelectListObj <FctDtl>(param) as List <FctDtl>;

                ItemLst = lst.FindAll(f => !f.FTR_CDE.Contains("BZ003"));
            }
            catch (Exception ex)
            {
                Messages.ShowErrMsgBoxLog(ex);
            }
        }
Beispiel #5
0
        //초기모델조회
        private void InitModel()
        {
            Hashtable param = new Hashtable();

            param.Add("sqlId", "SelectFileDtl2");
            param.Add("FIL_SEQ", txtFIL_SEQ.Text);

            ItemsSelect = new ObservableCollection <FileDtl>(BizUtil.SelectListObj <FileDtl>(param));
        }
Beispiel #6
0
        /// 생성자
        public WtlPipeDtlViewMdl(string FTR_CDE, int FTR_IDN)
        {
            try
            {
                // 1.상세마스터
                //DataTable dt = new DataTable();
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectWtlPipeDtl2");
                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                PipeDtl result = new PipeDtl();
                result = BizUtil.SelectObject(param) as PipeDtl;
                //결과를 뷰모델멤버로 매칭
                Type dbmodel = result.GetType();
                Type model   = this.GetType();

                //모델프로퍼티 순회
                foreach (PropertyInfo prop in model.GetProperties())
                {
                    string propName = prop.Name;
                    //db프로퍼티 순회
                    foreach (PropertyInfo dbprop in dbmodel.GetProperties())
                    {
                        string colName  = dbprop.Name;
                        var    colValue = dbprop.GetValue(result, null);
                        if (colName.Equals(propName))
                        {
                            try { prop.SetValue(this, colValue); } catch (Exception) { }
                        }
                    }
                    Console.WriteLine(propName + " - " + prop.GetValue(this, null));
                }



                //2.유지보수(탭1)
                param = new Hashtable();
                param.Add("sqlId", "selectChscResSubList");

                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                this.Tab01List = (List <LinkFmsChscFtrRes>)BizUtil.SelectListObj <LinkFmsChscFtrRes>(param);

                //3.누수지점(탭3)
                param = new Hashtable();
                param.Add("sqlId", "selectWtlLeakSubList");

                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                this.Tab03List = (List <LinkWtlLeakPs>)BizUtil.SelectListObj <LinkWtlLeakPs>(param);
            }
            catch (Exception) {}
        }
Beispiel #7
0
        /// 생성자
        public SupDutDtlViewMdl(string FTR_CDE, int FTR_IDN)
        {
            try
            {
                // 1.상세마스터
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectSupDutDtl");
                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                SupDutDtl result = new SupDutDtl();
                result = BizUtil.SelectObject(param) as SupDutDtl;
                //결과를 뷰모델멤버로 매칭
                Type dbmodel = result.GetType();
                Type model   = this.GetType();

                //모델프로퍼티 순회
                foreach (PropertyInfo prop in model.GetProperties())
                {
                    string propName = prop.Name;
                    //db프로퍼티 순회
                    foreach (PropertyInfo dbprop in dbmodel.GetProperties())
                    {
                        string colName  = dbprop.Name;
                        var    colValue = dbprop.GetValue(result, null);
                        if (colName.Equals(propName))
                        {
                            try { prop.SetValue(this, colValue); } catch (Exception) { }
                        }
                    }
                    Console.WriteLine(propName + " - " + prop.GetValue(this, null));
                }



                //2.텝1 - 유지보tn
                param = new Hashtable();
                param.Add("sqlId", "selectChscResSubList");

                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                this.Tab01List = (List <LinkFmsChscFtrRes>)BizUtil.SelectListObj <LinkFmsChscFtrRes>(param);

                //텝4 - 급수전계량기
                param = new Hashtable();
                param.Add("sqlId", "SelectHydtMetrDtl");

                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);

                this.Tab02List = (List <HydtMetrDtl>)BizUtil.SelectListObj <HydtMetrDtl>(param);
            }
            catch (Exception) { }
        }
Beispiel #8
0
        /// <summary>
        /// 조회작업
        /// </summary>
        private void initModel()
        {
            try
            {
                //초기조회
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectPdjtInHtPopList");
                param.Add("PDH_NUM", PDH_NUM);

                GrdLst = new ObservableCollection <PdjtInDtl>(BizUtil.SelectListObj <PdjtInDtl>(param));
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
Beispiel #9
0
        /// <summary>
        /// 조회작업
        /// </summary>
        private void initModel()
        {
            try
            {
                //초기조회
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectWttSubcDtList2");
                param.Add("CNT_NUM", this.CNT_NUM);

                GrdLst = new ObservableCollection <WttSubcDt>(BizUtil.SelectListObj <WttSubcDt>(param));
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
Beispiel #10
0
        // 업로드 스레드핸들러
        private void UploadFileListFX()
        {
            try
            {
                //로딩바..
                fileMngView.Dispatcher.Invoke(DispatcherPriority.ApplicationIdle,
                                              new Action((delegate()
                {
                    (fileMngView.FindName("waitindicator") as WaitIndicator).DeferedVisibility = true;
                })));


                //업로드시작...
                UploadFileList();

                // 생성된 첨부파일아이디 반환 -> 뷰쪽으로 바인딩 -> 부모창에서 접근가능
                Dtl.FIL_SEQ = ret_fil_seq;


                fileMngView.Dispatcher.Invoke(DispatcherPriority.ApplicationIdle,
                                              new Action((delegate()
                {
                    (fileMngView.FindName("waitindicator") as WaitIndicator).DeferedVisibility = false;
                    //첨부파일 그리드에 재조회
                    Hashtable param = new Hashtable();
                    param.Add("sqlId", "SelectFileDtl2");
                    param.Add("FIL_SEQ", Dtl.FIL_SEQ);
                    ItemsSelect = new ObservableCollection <FileDtl>(BizUtil.SelectListObj <FileDtl>(param));

                    Messages.ShowOkMsgBox();
                    //팝업닫기
                    //btnClose.RaiseEvent(new RoutedEventArgs(Button.ClickEvent));
                })));
            }
            catch (Exception ex)
            {
                fileMngView.Dispatcher.Invoke(DispatcherPriority.ApplicationIdle,
                                              new Action((delegate()
                {
                    (fileMngView.FindName("waitindicator") as WaitIndicator).DeferedVisibility = false;
                    Messages.ShowErrMsgBoxLog(ex);
                })));
            }
        }
Beispiel #11
0
        /// <summary>
        /// 조회작업
        /// </summary>
        private void initModel()
        {
            try
            {
                //초기조회
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectPdhUseList");
                param.Add("SCL_NUM", SCL_NUM);
                param.Add("FTR_CDE", FTR_CDE);
                param.Add("FTR_IDN", FTR_IDN);
                param.Add("SEQ", SEQ);
                param.Add("PDT_CAT_CDE", PDT_CAT_CDE); //소모품

                GrdLst = new ObservableCollection <PdjtHtDtl>(BizUtil.SelectListObj <PdjtHtDtl>(param));
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
Beispiel #12
0
        /// <summary>
        /// 조회작업
        /// </summary>
        private void SearchAction(object obj)
        {
            try
            {
                DataTable dt = new DataTable();

                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectPdjtMaMngList");

                param.Add("PDT_NAM", pdjtMngListView.txtPDT_NAM.Text);
                param.Add("PDT_MDL_STD", pdjtMngListView.txtPDT_MDL_STD.Text);
                param.Add("PDT_MNF", pdjtMngListView.txtPDT_MNF.Text);
                param.Add("PDT_CAT_CDE", pdjtMngListView.cbPDT_CAT_CDE.EditValue); //소모품

                GrdLst = new ObservableCollection <PdjtMaDtl>(BizUtil.SelectListObj <PdjtMaDtl>(param));
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
Beispiel #13
0
        /// <summary>
        /// 초기화 바인딩
        /// </summary>
        private void InitDataBinding()
        {
            try
            {
                // cbMNG_CDE 관리기관
                BizUtil.SetCmbCode(uC_BLKS_AS.cbMNG_CDE, "250101", "선택");

                uC_BLKS_AS.cbUPPER_FTR_CDE.DisplayMember = "FTR_NAM";
                uC_BLKS_AS.cbUPPER_FTR_CDE.ValueMember   = "FTR_CDE";
                Hashtable param = new Hashtable();
                param.Add("sqlId", "Select_FTR_LIST3");
                param.Add("FTR_CDE", "BZ");
                List <FctDtl> lst = BizUtil.SelectListObj <FctDtl>(param) as List <FctDtl>;

                ItemLst = lst.FindAll(f => !f.FTR_CDE.Contains("BZ003"));
            }
            catch (Exception ex)
            {
                Messages.ShowErrMsgBoxLog(ex);
            }
        }
Beispiel #14
0
        /// <summary>
        /// 조회작업
        /// </summary>
        private void initModel()
        {
            // 4.초기조회
            //a.마스터
            //DataTable dt = new DataTable();
            Hashtable param = new Hashtable();

            param.Add("sqlId", "SelectChscMaList");
            param.Add("SCL_NUM", Dtl.SCL_NUM);

            Dtl = BizUtil.SelectObject(param) as ChscMaDtl;

            //점검결과 다큐먼트 수동세팅
            try
            {
                chkSchDtlView.richBox.Document.Blocks.Clear();
                Paragraph paragraph = new Paragraph();
                paragraph.Inlines.Add(Dtl.CHK_CTNT.Trim());
                chkSchDtlView.richBox.Document.Blocks.Add(paragraph);
            }
            catch (Exception) {}


            //b.점검결과
            param = new Hashtable();
            param.Add("sqlId", "SelectChscResultList");
            param.Add("SCL_NUM", Dtl.SCL_NUM);

            GrdLst = new ObservableCollection <ChscResultDtl>(BizUtil.SelectListObj <ChscResultDtl>(param));

            // 1.1 점검결과 첫행선택
            if (GrdLst.Count > 0)
            {
                //SEL_FTR_CDE = GrdLst[0].FTR_CDE.ToString();
                //SEL_FTR_IDN = dt.Rows[0]["FTR_IDN"].ToString();
                //SEL_SEQ = dt.Rows[0]["SEQ"].ToString();
            }
        }
Beispiel #15
0
        /// <summary>
        /// 조회
        /// </summary>
        private void SearchAction()
        {
            DataTable dt = new DataTable();

            Hashtable param = new Hashtable();

            param.Add("sqlId", "SelectChscMaList");

            param.Add("TIT_NAM", txtTIT_NAM.Text);
            param.Add("CKM_PEO", txtCKM_PEO.Text);

            //점검월
            param.Add("CHK_YM", Convert.ToDateTime(dtCHK_YM.EditValue).ToString("yyyyMM"));

            param.Add("MNG_CDE", cbMNG_CDE.EditValue); //관리기관
            param.Add("SCL_CDE", cbSCL_CDE.EditValue);
            param.Add("SCL_STAT_CDE", cbSCL_STAT_CDE.EditValue);


            List <ChscMaDtl> lst = (List <ChscMaDtl>)BizUtil.SelectListObj <ChscMaDtl>(param);

            grid.ItemsSource = lst;
        }
Beispiel #16
0
        // 초기조회
        private void InitModel()
        {
            try
            {
                ChscMaLst.Clear();
            }
            catch (Exception) { }

            //리소스소스
            ResSrcs = new ObservableCollection <ResSrc>();
            ResSrcs.Add(ResSrc.Create(Id: 1, Name: "점검일정"));


            //점검스케줄
            Hashtable param = new Hashtable();

            param.Add("sqlId", "SelectChscMaList");
            param.Add("MNG_CDE", cbMNG_CDE.EditValue);
            param.Add("SCL_CDE", cbSCL_CDE.EditValue);
            param.Add("SCL_STAT_CDE", cbSCL_STAT_CDE.EditValue);
            param.Add("TIT_NAM", txtTIT_NAM.Text.Trim());
            param.Add("CKM_PEO", txtCKM_PEO.Text.Trim());

            ChscMaLst = new ObservableCollection <ChscMaDtl>(BizUtil.SelectListObj <ChscMaDtl>(param));
            //기존목록 이벤트핸들러 등록

            /*
             */
            foreach (ChscMaDtl item in ChscMaLst)
            {
                item.PropertyChanged += ChscMaDtl_PropertyChanged;
            }

            //목록변경 이벤트핸들러 등록
            ChscMaLst.CollectionChanged += Lst_CollectionChanged;
        }
Beispiel #17
0
        /// 생성자
        public CnstMngDtlViewMdl(string CNT_NUM)
        {
            try
            {
                // 1.상세마스터
                Hashtable param = new Hashtable();
                param.Add("sqlId", "SelectWttConsMaDtl");
                param.Add("CNT_NUM", CNT_NUM);

                CnstDtl result = new CnstDtl();
                result = BizUtil.SelectObject(param) as CnstDtl;
                //결과를 뷰모델멤버로 매칭
                Type dbmodel = result.GetType();
                Type model   = this.GetType();

                //모델프로퍼티 순회
                foreach (PropertyInfo prop in model.GetProperties())
                {
                    string propName = prop.Name;
                    //db프로퍼티 순회
                    foreach (PropertyInfo dbprop in dbmodel.GetProperties())
                    {
                        string colName  = dbprop.Name;
                        var    colValue = dbprop.GetValue(result, null);
                        if (colName.Equals(propName))
                        {
                            try { prop.SetValue(this, colValue); } catch (Exception) { }
                        }
                    }
                    Console.WriteLine(propName + " - " + prop.GetValue(this, null));
                }



                //2.Tab(4)

                //공사비지급내역
                param = new Hashtable();
                param.Add("CNT_NUM", CNT_NUM);
                param.Add("sqlId", "SelectWttCostDtList");
                this.Tab01List = (List <WttCostDt>)BizUtil.SelectListObj <WttCostDt>(param);

                //설계변경내역
                param = new Hashtable();
                param.Add("CNT_NUM", CNT_NUM);
                param.Add("sqlId", "SelectWttChngDtList");
                this.Tab02List = (List <WttChngDt>)BizUtil.SelectListObj <WttChngDt>(param);

                //공사하도급내역
                param = new Hashtable();
                param.Add("CNT_NUM", CNT_NUM);
                param.Add("sqlId", "SelectWttSubcDtList2");
                this.Tab03List = (List <WttSubcDt>)BizUtil.SelectListObj <WttSubcDt>(param);

                //하자보수목록
                param = new Hashtable();
                param.Add("CNT_NUM", CNT_NUM);
                param.Add("sqlId", "SelectWttFlawDtList");
                this.Tab04List = (List <WttFlawDt>)BizUtil.SelectListObj <WttFlawDt>(param);
            }
            catch (Exception) {}
        }