private void CargarArea(int idArea) { //PreventaArea oArea = PreventaArea.Select(tr, idArea); IB.SUPER.ADM.SIC.Models.AreaPreventa oArea = new IB.SUPER.ADM.SIC.Models.AreaPreventa(); IB.SUPER.ADM.SIC.BLL.AreaPreventa oElem = new IB.SUPER.ADM.SIC.BLL.AreaPreventa(); oArea = oElem.Select2(idArea); txtArea.Text = oArea.ta200_denominacion; hdnIdArea.Text = oArea.ta200_idareapreventa.ToString(); //Por defecto el responsable de un subarea es el del área if (this.hdnIDResponsable.Text == "") { this.hdnIDResponsable.Text = oArea.t001_idficepi_responsable.ToString(); this.txtDesResponsable.Text = oArea.Responsable; } oElem.Dispose(); }
private void CargarDatosItem(int idArea) { IB.SUPER.ADM.SIC.Models.AreaPreventa oArea = new IB.SUPER.ADM.SIC.Models.AreaPreventa(); IB.SUPER.ADM.SIC.BLL.AreaPreventa oElem = new IB.SUPER.ADM.SIC.BLL.AreaPreventa(); oArea = oElem.Select2(idArea); //PreventaArea oArea = PreventaArea.Select(null, idArea); txtID.Text = idArea.ToString(); txtDenominacion.Text = oArea.ta200_denominacion; hdnIDResponsable.Text = oArea.t001_idficepi_responsable.ToString(); txtDesResponsable.Text = oArea.Responsable; if (oArea.ta200_estadoactiva) { chkActivo.Checked = true; } else { chkActivo.Checked = false; } oElem.Dispose(); #region Datos del PT if (oArea.t331_idpt != null) { IB.SUPER.SIC.Models.ProyectoTecnico oPT = new IB.SUPER.SIC.Models.ProyectoTecnico(); IB.SUPER.SIC.BLL.ProyectoTecnico oElemPT = new IB.SUPER.SIC.BLL.ProyectoTecnico(); oPT = oElemPT.Select((int)oArea.t331_idpt); this.hdnIDPT.Value = oPT.t331_idpt.ToString(); this.txtNumPT.Text = oPT.t331_idpt.ToString("#,###"); this.txtPT.Text = oPT.t331_despt; this.hdnT305IdProy.Value = oPT.t305_idproyectosubnodo.ToString(); this.txtNumPE.Text = oPT.t301_idproyecto.ToString("#,###"); this.txtPE.Text = oPT.t301_denominacion; oElemPT.Dispose(); } #endregion }