public void DatoToInterfazUsuario(ListadoVerificacionCompresorPortatilBO bo) { #region General (Campos booleanos) this.vista.tienePresionEnLlantas = bo.TienePresionEnLlantas.HasValue ? bo.TienePresionEnLlantas : false; this.vista.tieneBandaVentilador = bo.TieneBandaVentilador.HasValue ? bo.TieneBandaVentilador : false; this.vista.tieneBarraTiro = bo.TieneBarraTiro.HasValue ? bo.TieneBarraTiro : false; this.vista.tieneManguerasYAbrazaderas = bo.TieneManguerasYAbrazaderas.HasValue ? bo.TieneManguerasYAbrazaderas : false; this.vista.tieneCartuchoFiltro = bo.TieneCartuchoFiltro.HasValue ? bo.TieneCartuchoFiltro : false; this.vista.tieneBtnServicioAire = bo.TieneBtnServicioAire.HasValue ? bo.TieneBtnServicioAire : false; #endregion #region Niveles Flujos (Campos booleanos) this.vista.tieneCombustible = bo.TieneCombustible.HasValue ? bo.TieneCombustible : false; this.vista.tieneAceiteMotor = bo.TieneAceiteMotor.HasValue ? bo.TieneAceiteMotor : false; this.vista.tieneAceiteCompresor = bo.TieneAceiteCompresor.HasValue ? bo.TieneAceiteCompresor : false; this.vista.tieneLiquidoRefrigerante = bo.TieneLiquidoRefrigerante.HasValue ? bo.TieneLiquidoRefrigerante : false; this.vista.tieneBateria = bo.TieneBateria.HasValue ? bo.TieneBateria : false; #endregion #region Lubricación (Campos booleanos) #endregion #region Funciones Electricias (Campos numericos) this.vista.tieneLucesTransito = bo.TieneLucesTransito.HasValue ? bo.TieneLucesTransito : false; this.vista.tieneSwitchArranque = bo.TieneSwitchArranque.HasValue ? bo.TieneSwitchArranque : false; this.vista.tieneIndicadores = bo.TieneIndicadores.HasValue ? bo.TieneIndicadores : false; this.vista.tieneLamparasTablero = bo.TieneLamparasTablero.HasValue ? bo.TieneLamparasTablero : false; #endregion #region Controles (Campos booleanos) this.vista.tieneTacometro = bo.TieneTacometro.HasValue ? bo.TieneTacometro : false; this.vista.tieneManometroPresion = bo.TieneManometroPresion.HasValue ? bo.TieneManometroPresion : false; this.vista.tieneVelocidadMinMotor = bo.TieneVelocidadMinMotor.HasValue ? bo.TieneVelocidadMinMotor : false; this.vista.tieneVelocidadMaxMotor = bo.TieneVelocidadMaxMotor.HasValue ? bo.TieneVelocidadMaxMotor : false; #endregion #region Miscelaneo (Campos numericos) this.vista.tieneTapaCombustible = bo.TieneTapaCombustible.HasValue ? bo.TieneTapaCombustible : false; this.vista.tieneCondicionLlantas = bo.TieneCondicionLlantas.HasValue ? bo.TieneCondicionLlantas : false; this.vista.tieneCondicionPintura = bo.TieneCondicionPintura.HasValue ? bo.TieneCondicionPintura : false; this.vista.tieneCondicionCalcas = bo.TieneCondicionCalcas.HasValue ? bo.TieneCondicionCalcas : false; this.vista.tieneSimbolosSeguridad = bo.TieneSimbolosSeguridad.HasValue ? bo.TieneSimbolosSeguridad : false; this.vista.tieneEstructuraChasis = bo.TieneEstructuraChasis.HasValue ? bo.TieneEstructuraChasis : false; this.vista.tieneAntenasMonitoreo = bo.TieneAntenasMonitoreo.HasValue ? bo.TieneAntenasMonitoreo : false; this.vista.lubricacion = !string.IsNullOrEmpty(bo.Lubricacion) ? bo.Lubricacion : string.Empty; #endregion }
public object InterfazUsuarioADato() { ListadoVerificacionCompresorPortatilBO bo = new ListadoVerificacionCompresorPortatilBO(); #region General (Campos booleanos) if (this.vista.tienePresionEnLlantas != null) { bo.TienePresionEnLlantas = this.vista.tienePresionEnLlantas.Value; } if (this.vista.tieneBandaVentilador != null) { bo.TieneBandaVentilador = this.vista.tieneBandaVentilador.Value; } if (this.vista.tieneBarraTiro != null) { bo.TieneBarraTiro = this.vista.tieneBarraTiro.Value; } if (this.vista.tieneManguerasYAbrazaderas != null) { bo.TieneManguerasYAbrazaderas = this.vista.tieneManguerasYAbrazaderas.Value; } if (this.vista.tieneCartuchoFiltro != null) { bo.TieneCartuchoFiltro = this.vista.tieneCartuchoFiltro.Value; } if (this.vista.tieneBtnServicioAire != null) { bo.TieneBtnServicioAire = this.vista.tieneBtnServicioAire.Value; } #endregion #region Niveles Flujos (Campos booleanos) if (this.vista.tieneCombustible != null) { bo.TieneCombustible = this.vista.tieneCombustible.Value; } if (this.vista.tieneAceiteMotor != null) { bo.TieneAceiteMotor = this.vista.tieneAceiteMotor.Value; } if (this.vista.tieneAceiteCompresor != null) { bo.TieneAceiteCompresor = this.vista.tieneAceiteCompresor.Value; } if (this.vista.tieneLiquidoRefrigerante != null) { bo.TieneLiquidoRefrigerante = this.vista.tieneLiquidoRefrigerante.Value; } if (this.vista.tieneBateria != null) { bo.TieneBateria = this.vista.tieneBateria.Value; } #endregion #region Lubricación (Campos booleanos) #endregion #region Funciones Electricias (Campos numericos) if (this.vista.tieneLucesTransito != null) { bo.TieneLucesTransito = this.vista.tieneLucesTransito.Value; } if (this.vista.tieneSwitchArranque != null) { bo.TieneSwitchArranque = this.vista.tieneSwitchArranque.Value; } if (this.vista.tieneIndicadores != null) { bo.TieneIndicadores = this.vista.tieneIndicadores.Value; } if (this.vista.tieneLamparasTablero != null) { bo.TieneLamparasTablero = this.vista.tieneLamparasTablero.Value; } #endregion #region Controles (Campos booleanos) if (this.vista.tieneIndicadores != null) { bo.TieneIndicadores = this.vista.tieneIndicadores.Value; } if (this.vista.tieneTacometro != null) { bo.TieneTacometro = this.vista.tieneTacometro.Value; } if (this.vista.tieneManometroPresion != null) { bo.TieneManometroPresion = this.vista.tieneManometroPresion.Value; } if (this.vista.tieneVelocidadMinMotor != null) { bo.TieneVelocidadMinMotor = this.vista.tieneVelocidadMinMotor.Value; } if (this.vista.tieneVelocidadMaxMotor != null) { bo.TieneVelocidadMaxMotor = this.vista.tieneVelocidadMaxMotor.Value; } #endregion #region Miscelaneo (Campos numericos) if (this.vista.tieneTapaCombustible != null) { bo.TieneTapaCombustible = this.vista.tieneTapaCombustible.Value; } if (this.vista.tieneCondicionLlantas != null) { bo.TieneCondicionLlantas = this.vista.tieneCondicionLlantas.Value; } if (this.vista.tieneCondicionPintura != null) { bo.TieneCondicionPintura = this.vista.tieneCondicionPintura.Value; } if (this.vista.tieneCondicionCalcas != null) { bo.TieneCondicionCalcas = this.vista.tieneCondicionCalcas.Value; } if (this.vista.tieneSimbolosSeguridad != null) { bo.TieneSimbolosSeguridad = this.vista.tieneSimbolosSeguridad.Value; } if (this.vista.tieneEstructuraChasis != null) { bo.TieneEstructuraChasis = this.vista.tieneEstructuraChasis.Value; } if (this.vista.tieneAntenasMonitoreo != null) { bo.TieneAntenasMonitoreo = this.vista.tieneAntenasMonitoreo.Value; } if (this.vista.lubricacion != null) { bo.Lubricacion = this.vista.lubricacion; } #endregion return(bo); }
public void Registrar() { ListadoVerificacionCompresorPortatilBO bo = (ListadoVerificacionCompresorPortatilBO)this.InterfazUsuarioADato(); }