Venta rapida tbs enter

This commit is contained in:
rakcsle
2023-12-11 10:40:31 -07:00
parent 30e2f4ee89
commit 10f89bdac2
2 changed files with 52 additions and 5 deletions

View File

@@ -8578,7 +8578,7 @@
</div>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<script src="/Metronic/assets/global/scripts/jquery-sortable.js"></script>
@@ -10434,9 +10434,13 @@
$('#divAgregarSucursal').modal();
}
function hideDivAgregarSucursal() {
$('#divAgregarSucursal').modal('hide');
}
function hideDivAgregarSucursal() {
$('#divAgregarSucursal').modal('hide');
}
</script>
</asp:Content>

View File

@@ -3446,6 +3446,37 @@ Partial Class Ventas
End If
If UsuarioActual.CveEmpresa = 186 Then
Dim jsFocus As String = "$(document).ready(function () {
$('#TxtCantidad').on('keydown', function (e) {
if (e.which == 13 || e.which == 9 ) {
let valorNumericoCantidad = parseFloat($('#TxtCantidad').val());
e.preventDefault();
if(valorNumericoCantidad > 0){
$('#C_Tab_TabGenerales_DdlPS > select').select2('open').next().find(':input.select2-search__field').focus();
}
}
});
$('#TxtPrecio').on('keydown', function (e) {
if (e.which == 13 || e.which == 9 ) {
let valorNumericoPrecio = parseFloat($('#TxtCantidad').val());
e.preventDefault();
if(valorNumericoPrecio > 0){
$('#LbAgregar').focus();
}
}
});
});"
RegistraScript(jsFocus)
End If
End Sub
Private Sub CargaListasPrecios()
@@ -6877,7 +6908,7 @@ Partial Class Ventas
HabilitarRemisionesPublicoGeneral()
End If
TxtCantidad.Focus()
'If UsuarioActual.Empresa.Funcionalidad(705) = "1" Then
' Using ObjVentas As New ClsVentas
' If ObjVentas.GetLineasAdicionales(-1, CveCliente, -1, -1, DdlMoneda.SelectedValue.ToEntero(), MinFecha, MaxFecha, 0, UsuarioActual.CveEmpresa) Then
@@ -16835,6 +16866,12 @@ Partial Class Ventas
CargaPS(DdlClasificacion.SelectedValue.ToEntero(), Ddl)
End If
If UsuarioActual.CveEmpresa = 186 Then
TxtPrecio.Focus()
End If
UPPPS.Update()
UpPS.Update()
@@ -18070,6 +18107,11 @@ Partial Class Ventas
CargaGvComercioExterior()
End If
End If
If UsuarioActual.CveEmpresa = 186 Then
TxtCantidad.Focus()
End If
UpPS.Update()
Catch ex As Exception
OnError("Ocurrió un error al agregar el producto", ex)
@@ -36201,5 +36243,6 @@ Partial Class Ventas
'End Sub
End Class