public Biz_EstDeptInfos(int estterm_ref_id, int est_dept_ref_id) { DataSet ds = _estDeptInfos.Select(estterm_ref_id, est_dept_ref_id); DataRow dr; if (ds.Tables[0].Rows.Count == 1) { dr = ds.Tables[0].Rows[0]; _est_dept_ref_id = (dr["EST_DEPT_REF_ID"] == DBNull.Value) ? 0 : int.Parse(dr["EST_DEPT_REF_ID"].ToString()); _estterm_ref_id = (dr["ESTTERM_REF_ID"] == DBNull.Value) ? 0 : int.Parse(dr["ESTTERM_REF_ID"].ToString()); _dept_ref_id = (dr["DEPT_REF_ID"] == DBNull.Value) ? 0 : int.Parse(dr["DEPT_REF_ID"].ToString()); _up_est_dept_id = (dr["UP_EST_DEPT_ID"] == DBNull.Value) ? 0 : int.Parse(dr["UP_EST_DEPT_ID"].ToString()); _dept_level = (dr["DEPT_LEVEL"] == DBNull.Value) ? 0 : int.Parse(dr["DEPT_LEVEL"].ToString()); _dept_name = (dr["DEPT_NAME"] == DBNull.Value) ? "" : (string)dr["DEPT_NAME"]; if (DbAgentHelper.GetProviderType() == "ORACLE") { decimal sflag = (dr["TEMP_FLAG"] == DBNull.Value) ? 0 : decimal.Parse(dr["TEMP_FLAG"].ToString()); _temp_flag = (sflag == 0) ? false : true; } else { _temp_flag = (dr["TEMP_FLAG"] == DBNull.Value) ? false : bool.Parse(dr["TEMP_FLAG"].ToString()); } _est_dept_group_id = (dr["EST_DEPT_GROUP_ID"] == DBNull.Value) ? 0 : int.Parse(dr["EST_DEPT_GROUP_ID"].ToString()); _dept_type = (dr["DEPT_TYPE"] == DBNull.Value) ? 0 : int.Parse(dr["DEPT_TYPE"].ToString()); _sort_order = (dr["SORT_ORDER"] == DBNull.Value) ? 0 : int.Parse(dr["SORT_ORDER"].ToString()); _view_yn_org = (dr["VIEW_YN_ORG"] == DBNull.Value) ? "" : (string)dr["VIEW_YN_ORG"]; _header_img_org = (dr["HEADER_IMG_ORG"] == DBNull.Value) ? "" : (string)dr["HEADER_IMG_ORG"]; _sort_org = (dr["SORT_ORG"] == DBNull.Value) ? 0 : int.Parse(dr["SORT_ORG"].ToString()); _dept_name_org = (dr["DEPT_NAME_ORG"] == DBNull.Value) ? "" : (string)dr["DEPT_NAME_ORG"]; _industry_type = (dr["INDUSTRY_TYPE"] == DBNull.Value) ? "" : (string)dr["INDUSTRY_TYPE"]; _industry_type_order = (dr["INDUSTRY_TYPE_ORDER"] == DBNull.Value) ? 0 : int.Parse(dr["INDUSTRY_TYPE_ORDER"].ToString()); _update_user = (dr["UPDATE_USER"] == DBNull.Value) ? 0 : int.Parse(dr["UPDATE_USER"].ToString()); _update_date = (dr["UPDATE_DATE"] == DBNull.Value) ? DateTime.MinValue : (DateTime)dr["UPDATE_DATE"]; } }