mirror of
https://github.com/KeymonSoft/Guna_Reparto_Imp.git
synced 2026-04-21 14:49:14 +00:00
...
This commit is contained in:
@@ -86,6 +86,9 @@ End Sub
|
||||
'You can see the list of page related events in the B4XPagesManager object. The event name is B4XPage.
|
||||
|
||||
Sub B4XPage_Appear
|
||||
|
||||
|
||||
|
||||
Subs.centraPanel(p_principal, Root.Width)
|
||||
' b_guardar.Visible = False
|
||||
' Titulo.Left = Round(p_principal.Width/2)-(Titulo.Width/2)
|
||||
@@ -308,6 +311,8 @@ Sub B4XPage_Appear
|
||||
Else
|
||||
L_CANT.Text = NumberFormat2((arti + arti1 +arti2 + arti3),0,0,0,True)
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Sub GPS_LocationChanged (Location1 As Location)
|
||||
@@ -503,6 +508,20 @@ Sub CreateListItem2(Text As String, precioU As String, inv As Int, inv2 As Int,
|
||||
End Sub
|
||||
|
||||
Sub b_prodMenos_Click
|
||||
|
||||
Dim x2 As Cursor =Starter.skmt.ExecQuery("SELECT gestion FROM kmt_info where CAT_CL_CODIGO IN (SELECT CUENTA FROM CUENTAA)")
|
||||
x2.Position = 0
|
||||
If x2.GetString("gestion") = 2 Then
|
||||
MsgboxAsync("Ya se gestiono el cliente, no se pueden hacer modificaciones","Atención")
|
||||
' Wait For Msgbox_Result (result2 As Int)
|
||||
' If result= DialogResponse.NEGATIVE Then
|
||||
' B4XPages.ShowPage("Principal")
|
||||
' End If
|
||||
|
||||
' b_prodMas.Enabled = False
|
||||
' b_prodMenos.Enabled = False
|
||||
Else
|
||||
|
||||
etCantHasFocus = False
|
||||
Log("etCantHasFocus=" & etCantHasFocus)
|
||||
LogColor("b_prodMenos_Click", Colors.Magenta)
|
||||
@@ -637,9 +656,26 @@ Sub b_prodMenos_Click
|
||||
' L_CANT.Text = cym.Get("cantidad")
|
||||
' L_TOTAL.Text = Round2(cym.Get("monto"), 2)
|
||||
' cuentaProds("-")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Sub b_prodMas_Click
|
||||
|
||||
Dim x2 As Cursor =Starter.skmt.ExecQuery("SELECT gestion FROM kmt_info where CAT_CL_CODIGO IN (SELECT CUENTA FROM CUENTAA)")
|
||||
x2.Position = 0
|
||||
If x2.GetString("gestion") = 2 Then
|
||||
MsgboxAsync("Ya se gestiono el cliente, no se pueden hacer modificaciones","Atención")
|
||||
' Wait For Msgbox_Result (result2 As Int)
|
||||
' If result= DialogResponse.NEGATIVE Then
|
||||
' B4XPages.ShowPage("Principal")
|
||||
' End If
|
||||
|
||||
' b_prodMas.Enabled = False
|
||||
' b_prodMenos.Enabled = False
|
||||
Else
|
||||
|
||||
|
||||
|
||||
etCantHasFocus = False
|
||||
' Log("etCantHasFocus=" & etCantHasFocus)
|
||||
LogColor("b_prodMas_Click", Colors.Magenta)
|
||||
@@ -728,6 +764,8 @@ Sub b_prodMas_Click
|
||||
' If cantoriginal <= esteTag.Get(1) Then
|
||||
' L_CANT.Text = L_CANT.Text + 1
|
||||
' End If
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Sub cuentaProds(accion As String)
|
||||
@@ -1018,12 +1056,25 @@ Private Sub l_pCantC_Click
|
||||
End Sub
|
||||
|
||||
Private Sub b_revversar_Click
|
||||
Private c3 As Cursor = Starter.skmt.ExecQuery("SELECT * FROM PEDIDO WHERE PE_CLIENTEOR IN (SELECT CUENTA FROM CUENTAA)")
|
||||
If c3.RowCount = 0 Then
|
||||
Starter.skmt.ExecNonQuery($"update HIST_VENTAS set HVD_RECHAZO = 0, HVD_RECHAZOCANT = 0, BCAJAS = BCAJAS_OR, CANTC = CANTC_OR WHERE HVD_cliente in (Select CUENTA from cuentaa)"$)
|
||||
B4XPage_Appear
|
||||
Dim x2 As Cursor =Starter.skmt.ExecQuery("SELECT gestion FROM kmt_info where CAT_CL_CODIGO IN (SELECT CUENTA FROM CUENTAA)")
|
||||
x2.Position = 0
|
||||
If x2.GetString("gestion") = 2 Then
|
||||
MsgboxAsync("Ya se gestiono el cliente, no se pueden hacer modificaciones","Atención")
|
||||
' Wait For Msgbox_Result (result2 As Int)
|
||||
' If result= DialogResponse.NEGATIVE Then
|
||||
' B4XPages.ShowPage("Principal")
|
||||
' End If
|
||||
|
||||
' b_prodMas.Enabled = False
|
||||
' b_prodMenos.Enabled = False
|
||||
Else
|
||||
MsgboxAsync("Hay productos que ya se vendieron, no se puede regresar la venta","Atención")
|
||||
Private c3 As Cursor = Starter.skmt.ExecQuery("SELECT * FROM PEDIDO WHERE PE_CLIENTEOR IN (SELECT CUENTA FROM CUENTAA)")
|
||||
If c3.RowCount = 0 Then
|
||||
Starter.skmt.ExecNonQuery($"update HIST_VENTAS set HVD_RECHAZO = 0, HVD_RECHAZOCANT = 0, BCAJAS = BCAJAS_OR, CANTC = CANTC_OR WHERE HVD_cliente in (Select CUENTA from cuentaa)"$)
|
||||
B4XPage_Appear
|
||||
Else
|
||||
MsgboxAsync("Hay productos que ya se vendieron, no se puede regresar la venta","Atención")
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
Reference in New Issue
Block a user