diff --git a/App_Code/ClsGenerales.vb b/App_Code/ClsGenerales.vb index 86122f871..23bdee732 100644 --- a/App_Code/ClsGenerales.vb +++ b/App_Code/ClsGenerales.vb @@ -2926,5 +2926,66 @@ Public Class ClsGenerales End Sub #End Region +#Region " P O L I Z A V I R T U A L " + Public Function ModelosAutosGet(CveEmpresa As Integer) As Boolean + Dim Retorno As Boolean = False + DataAdapter("PA_Gral_ModelosAutosGet") + With SqlAdapter.SelectCommand.Parameters + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + End With + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + OnError("Ocurrió un error al obtener los Modelos de Autos.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + End Try + Return Retorno + End Function + + Public Function MarcasAutosGet(CveEmpresa As Integer) As Boolean + Dim Retorno As Boolean = False + DataAdapter("PA_Gral_MarcasAutosGet") + With SqlAdapter.SelectCommand.Parameters + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + End With + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + OnError("Ocurrió un error al obtener las Marcas de Autos.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + End Try + Return Retorno + End Function + + Public Function MarcasUsadoGet(CveEmpresa As Integer) As Boolean + Dim Retorno As Boolean = False + DataAdapter("PA_Gral_MarcasUsadoGet") + With SqlAdapter.SelectCommand.Parameters + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + End With + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + OnError("Ocurrió un error al obtener las Marcas de Usados.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + End Try + Return Retorno + End Function + + Public Function BCIUsadoGet(CveEmpresa As Integer) As Boolean + Dim Retorno As Boolean = False + DataAdapter("PA_Gral_BCIUsadoGet") + With SqlAdapter.SelectCommand.Parameters + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + End With + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As Exception + OnError("Ocurrió un error al obtener los BCI de Usados.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + End Try + Return Retorno + End Function +#End Region End Class diff --git a/Ventas/PV.aspx b/Ventas/PV.aspx index 423ebafff..e30c6fe9b 100644 --- a/Ventas/PV.aspx +++ b/Ventas/PV.aspx @@ -2659,12 +2659,12 @@
- - + @@ -2674,6 +2674,17 @@
+ +
+
+
+ +
+ + +
+
+
@@ -3134,8 +3145,7 @@ $("#DivAnticipos").show(); $("#DivAnticipos").center(); } - catch (e) - { alert(e); } + catch (e) { alert(e); } } @@ -3144,8 +3154,7 @@ $("#ModalOtrosConceptos").show(); $("#ModalOtrosConceptos").center(); } - catch (e) - { alert(e); } + catch (e) { alert(e); } } @@ -3155,8 +3164,7 @@ $("#DivEstadoCaja").show(); $("#DivEstadoCaja").center(); } - catch (e) - { alert(e); } + catch (e) { alert(e); } } @@ -3169,8 +3177,7 @@ return false; } - catch (e) - { alert(e); } + catch (e) { alert(e); } } @@ -3189,8 +3196,7 @@ $get("HdnTipoMovimiento").value = "1"; } } - catch (e) - { alert(e); } + catch (e) { alert(e); } } diff --git a/Ventas/PV.aspx.vb b/Ventas/PV.aspx.vb index d2cadd606..b23c44a76 100644 --- a/Ventas/PV.aspx.vb +++ b/Ventas/PV.aspx.vb @@ -3598,6 +3598,7 @@ Partial Class PV Private Sub CargaAgregar() Modalidad = "A" LnkAgregarPS.Text = "Agregar" + CargaBCI() LimpiaAgregar() LimpiaAjuste() ModalidadAjuste = "A" @@ -3606,6 +3607,16 @@ Partial Class PV UpVenta.Update() RegistraScript(String.Format("$('#{0}').modal('show');", "DivAddVenta")) End Sub + Private Sub CargaBCI() + Dim ObjGral As New ClsGenerales + + If ObjGral.BCIUsadoGet(UsuarioActual.CveEmpresa) Then + DdlBCIUsado.DataSource = ObjGral.DtResultados + End If + DdlBCIUsado.Items.Insert(0, New ListItem("Seleccione", "-1")) + DdlBCIUsado.SelectedValueExist(-1) + DdlBCIUsado.DataBind() + End Sub Public Sub Edit_Click(sender As Object, e As EventArgs) Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow) Modalidad = "U"