Se le agrego la validacion, si ya abono al pagare y lo liquida, con eso ya lo deja meter venta

This commit is contained in:
IsR0d
2024-05-22 18:27:24 -06:00
parent 3046ec99bc
commit ee15d2289e
3 changed files with 36 additions and 7 deletions

View File

@@ -572,15 +572,44 @@ Sub Guardar_Click
GuardaVenta GuardaVenta
End If End If
Else Else
GuardaVenta Dim credi2 As Cursor = B4XPages.MainPage.skmt.ExecQuery("SELECT CAT_CL_BCREDITO, a_abono, SALDO_PENDIENTE FROM KMT_INFO INNER JOIN ABONOSP ON CAT_CL_CODIGO = CLIENTE INNER JOIN ABONOS ON CAT_CL_CODIGO = a_cliente WHERE CAT_CL_CODIGO IN (SELECT CUENTA FROM CUENTAA)")
ToastMessageShow("HOLA",True) If credi2.RowCount > 0 Then
credi2.Position = 0
If credi2.GetString ("CAT_CL_BCREDITO") = "1" And credi2.GetString ("a_abono")=credi2.GetString ("SALDO_PENDIENTE") Then
If pre_act <> Starter.pre_viejo Then
Msgbox2Async("La venta es a credito?", "ATENCION","SI","", "NO",LoadBitmap(File.DirAssets,"alert2.png"), False)
Wait For Msgbox_Result (resultado As Int)
If resultado = DialogResponse.POSITIVE Then
p_credito.Visible = True
Dim limitcred As Cursor
limitcred = B4XPages.MainPage.skmt.ExecQuery("SELECT CAT_CL_LIMITECREDITO FROM kmt_info WHERE CAT_CL_CODIGO IN (SELECT CUENTA FROM CUENTAA)")
limitcred.Position = 0
l_limite.Text = "Limite de credito: $" & limitcred.GetString("CAT_CL_LIMITECREDITO")
If Subs.traeTotalClientepreventaparacredito >= limitcred.GetString("CAT_CL_LIMITECREDITO") Then
et_montoacredito.Text = limitcred.GetString("CAT_CL_LIMITECREDITO")
Else
et_montoacredito.Text = Subs.traeTotalClientepreventaparacredito
End If End If
limitcred.Close
End If
Else If pre_act = Starter.pre_viejo Then
GuardaVenta
End If
Else
GuardaVenta
End If
End If
End If
' Credi.Close
Else If la_cuenta.Text = 0 Then Else If la_cuenta.Text = 0 Then
GuardaVenta GuardaVenta
End If End If
Else If c.GetString("CUANTOS") = 0 Then Else If c.GetString("CUANTOS") = 0 Then
GuardaVenta GuardaVenta
End If End If
' c.Close
End Sub End Sub
Private Sub b_acred_Click Private Sub b_acred_Click

View File

@@ -184,12 +184,12 @@ Module9=C_Nota
NumberOfFiles=59 NumberOfFiles=59
NumberOfLibraries=34 NumberOfLibraries=34
NumberOfModules=28 NumberOfModules=28
Version=12.5 Version=12.8
@EndOfDesignText@ @EndOfDesignText@
#Region Project Attributes #Region Project Attributes
#ApplicationLabel: Marquez #ApplicationLabel: Marquez
#VersionCode: 1 #VersionCode: 1
#VersionName: 4.05.20 #VersionName: 4.05.21
'SupportedOrientations possible values: unspecified, landscape or portrait. 'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: portrait #SupportedOrientations: portrait
#CanInstallToExternalStorage: False #CanInstallToExternalStorage: False

View File

@@ -85,6 +85,6 @@ ModuleClosedNodes6=
ModuleClosedNodes7= ModuleClosedNodes7=
ModuleClosedNodes8= ModuleClosedNodes8=
ModuleClosedNodes9= ModuleClosedNodes9=
NavigationStack=MAPA_RUTAS,OnInfoWindowClickListener1_click,270,1,Starter,Timer1_Tick,61,0,Starter,ENVIA_ULTIMA_GPS,87,0,C_Principal,B4XPage_Appear,425,4,C_Cliente,MODS,0,0,Starter,Process_Globals,17,0,B4XMainPage,i_engrane_Click,689,0,C_NoVenta,B4XPage_Created,37,0,Subs,pedidoGuardado,1414,0,C_NoVenta,GUARDA_Click,94,0,C_NoVenta,B4XPage_Appear,51,0 NavigationStack=Diseñador Visual,clientes.bal,-100,1,Diseñador Visual,cliente.bal,-100,6,C_Clientes,Class_Globals,0,0,C_Cliente,b_abono_Click,1276,0,C_Cliente,gest_Click,465,0,C_Nota,Regresar_Click,138,0,Subs,traeUsuarioDeBD,744,0,C_Cliente,Guardar_Click,562,6,Main,Activity_Pause,50,0,B4XMainPage,B4XPage_Created,145,0
SelectedBuild=0 SelectedBuild=0
VisibleModules=1,2,3,4,5,6,7,8,9,10,27 VisibleModules=1,2,3,4,5,6,7,8,9,10,13,27