mirror of
https://github.com/KeymonSoft/Kelloggs_v4.git
synced 2026-04-22 12:20:09 +00:00
Correcciones de pedido sugerido y ordenamiento
This commit is contained in:
@@ -736,6 +736,7 @@ Sub B4XPage_Appear
|
|||||||
' l_doe.Text = $"Pedido DOE: $${kh.traeTotalClienteDOE}${CRLF}TOTAL PEDIDO: $${(kh.traeTotalCliente+kh.traeTotalClienteDOE)}"$
|
' l_doe.Text = $"Pedido DOE: $${kh.traeTotalClienteDOE}${CRLF}TOTAL PEDIDO: $${(kh.traeTotalCliente+kh.traeTotalClienteDOE)}"$
|
||||||
End If
|
End If
|
||||||
If Subs.revisaImpresa Then Guardar.Visible = True
|
If Subs.revisaImpresa Then Guardar.Visible = True
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Sub Printer1_Connected (Success As Boolean)
|
Sub Printer1_Connected (Success As Boolean)
|
||||||
@@ -1081,7 +1082,30 @@ Sub B_IMP_Click
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Sub B_IMP2_Click
|
Sub B_IMP2_Click
|
||||||
' Log("inicia B_IMP2_Click")
|
LogColor(kh.traeDisponibleAbordo,Colors.Green)
|
||||||
|
If kh.traeDisponibleAbordo < 0 Then
|
||||||
|
Msgbox2Async("No tienes venta suficiente","Atención", "Modificar pedido", "", "Borrar pedido",LoadBitmap(File.DirAssets,"alert2.png"),False)
|
||||||
|
Wait For Msgbox_Result (result As Int)
|
||||||
|
If result = DialogResponse.POSITIVE Then
|
||||||
|
|
||||||
|
ToastMessageShow("Positivo",True)
|
||||||
|
B4XPages.ShowPage("Productos")
|
||||||
|
|
||||||
|
Else If result = DialogResponse.NEGATIVE Then
|
||||||
|
|
||||||
|
ToastMessageShow("Negativo",True)
|
||||||
|
B4XPages.MainPage.nota.borra_Click
|
||||||
|
B4XPage_Appear
|
||||||
|
|
||||||
|
End If
|
||||||
|
Else If kh.traeDisponibleAbordo >= 0 Then
|
||||||
|
Imprime_ticket
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Sub Imprime_ticket
|
||||||
|
Log("inicia B_IMP2_Click")
|
||||||
B_IMP2.Enabled = False
|
B_IMP2.Enabled = False
|
||||||
If l_total.Text <> Null And l_total.Text <> "null" Then Subs.ponImpreso(la_cuenta.Text) 'Solo lo marcamos como impreso si tiene venta (total > 0).
|
If l_total.Text <> Null And l_total.Text <> "null" Then Subs.ponImpreso(la_cuenta.Text) 'Solo lo marcamos como impreso si tiene venta (total > 0).
|
||||||
ProgressDialogShow("Imprimiendo, un momento ...")
|
ProgressDialogShow("Imprimiendo, un momento ...")
|
||||||
|
|||||||
@@ -256,7 +256,7 @@ Sub borra_Click
|
|||||||
Private textoExtra As String = ""
|
Private textoExtra As String = ""
|
||||||
If pedidoMostrado = "DOE" Then textoExtra = " DOE"
|
If pedidoMostrado = "DOE" Then textoExtra = " DOE"
|
||||||
If kh.clienteConDOE And pedidoMostrado = "NORMAL" Then textoExtra = " (Sin DOE)"
|
If kh.clienteConDOE And pedidoMostrado = "NORMAL" Then textoExtra = " (Sin DOE)"
|
||||||
If folio = "0" or 1 = 1 Then 'Si el folio es 0 o el cliente actual es "abordo", los deja borrar. - Mod por CHV 220512 'Para que el abordo borre siempre agregar -> " Or Subs.clienteActual = "0""
|
If folio = "0" Or 1 = 1 Then 'Si el folio es 0 o el cliente actual es "abordo", los deja borrar. - Mod por CHV 220512 'Para que el abordo borre siempre agregar -> " Or Subs.clienteActual = "0""
|
||||||
result = Msgbox2($"¿Seguro que desea borrar el pedido${textoExtra}?"$,"Cancelar pedido", "Si", "", "No", LoadBitmap(File.DirAssets,"alert2.png")) 'ignore
|
result = Msgbox2($"¿Seguro que desea borrar el pedido${textoExtra}?"$,"Cancelar pedido", "Si", "", "No", LoadBitmap(File.DirAssets,"alert2.png")) 'ignore
|
||||||
If result = DialogResponse.POSITIVE Then
|
If result = DialogResponse.POSITIVE Then
|
||||||
' c = Starter.skmt.ExecQuery("select PE_PROID, PE_CANT, PE_TIPO, PE_CEDIS FROM PEDIDO where pe_cliente in (Select CUENTA from cuentaa) ")
|
' c = Starter.skmt.ExecQuery("select PE_PROID, PE_CANT, PE_TIPO, PE_CEDIS FROM PEDIDO where pe_cliente in (Select CUENTA from cuentaa) ")
|
||||||
|
|||||||
@@ -1209,7 +1209,7 @@ Sub Busca_TextChanged (Old As String, New As String)
|
|||||||
' Log($"${Starter.tipov} - ${query} - ${Subs.traeTablaProds(Starter.tipov)}"$)
|
' Log($"${Starter.tipov} - ${query} - ${Subs.traeTablaProds(Starter.tipov)}"$)
|
||||||
If lfila.text = "PROMOCIONES" Then
|
If lfila.text = "PROMOCIONES" Then
|
||||||
If Not(lv_promos.Visible) Then lv_promos.Visible = True
|
If Not(lv_promos.Visible) Then lv_promos.Visible = True
|
||||||
Private cPromo As Cursor=Starter.skmt.ExecQuery($"select CAT_GP_ID, CAT_GP_NOMBRE, CAT_GP_PRECIO, CAT_GP_ALMACEN, CAT_GP_TIPO, CAT_GP_IMG from ${Subs.traeTablaProds(Starter.tipov)} where CAT_GP_NOMBRE like '%${New}%' and CAT_GP_ALMACEN > 0 AND CAT_GP_TIPO = 'PROMOS' AND CAT_GP_SUBTIPO = 'PROMOS' AND CAT_GP_TIPOPROD <> 1 and (length(CAT_GP_CODPROMO) = 1 OR CAT_GP_CODPROMO = CAT_GP_ID)"$)
|
Private cPromo As Cursor=Starter.skmt.ExecQuery($"select CAT_GP_ID, CAT_GP_NOMBRE, CAT_GP_PRECIO, CAT_GP_ALMACEN, CAT_GP_TIPO, CAT_GP_IMG from ${Subs.traeTablaProds(Starter.tipov)} where CAT_GP_NOMBRE like '%${New}%' and CAT_GP_ALMACEN > 0 AND CAT_GP_TIPO = 'PROMOS' AND CAT_GP_SUBTIPO = 'PROMOS' AND CAT_GP_TIPOPROD <> 1 and (length(CAT_GP_CODPROMO) = 1 OR CAT_GP_CODPROMO = CAT_GP_ID ORDER BY CAT_GP_TIPOPROD2 DESC, CAT_GP_NOMBRE)"$)
|
||||||
Log($"res:${cPromo.RowCount}"$)
|
Log($"res:${cPromo.RowCount}"$)
|
||||||
If cPromo.RowCount > 0 Then
|
If cPromo.RowCount > 0 Then
|
||||||
lv_promos.Clear
|
lv_promos.Clear
|
||||||
@@ -1274,7 +1274,7 @@ Sub LlenaProdsLL(p As ResultSet, extra As String)
|
|||||||
Log($"YA HAY RESULTSET ${p.RowCount}"$)
|
Log($"YA HAY RESULTSET ${p.RowCount}"$)
|
||||||
Else
|
Else
|
||||||
' Log("NO HAY RESULTSET")
|
' Log("NO HAY RESULTSET")
|
||||||
Dim p As ResultSet = Starter.skmt.ExecQuery($"select CAT_GP_ID, CAT_GP_NOMBRE, CAT_GP_ALMACEN, CAT_GP_PRECIO, CAT_GP_TIPO, CAT_GP_TIPOPROD from ${Subs.traeTablaProds(Starter.tipov)} where CAT_GP_PRECIO > 0 And CAT_GP_CLASIF <> 'PROMOS' order by CAT_GP_NOMBRE"$)
|
Dim p As ResultSet = Starter.skmt.ExecQuery($"select CAT_GP_ID, CAT_GP_NOMBRE, CAT_GP_ALMACEN, CAT_GP_PRECIO, CAT_GP_TIPO, CAT_GP_TIPOPROD from ${Subs.traeTablaProds(Starter.tipov)} where CAT_GP_PRECIO > 0 And CAT_GP_CLASIF <> 'PROMOS' ORDER BY CAT_GP_TIPOPROD2 DESC, CAT_GP_NOMBRE"$)
|
||||||
' Log(p.RowCount & " - " & Subs.traeTablaProds(Starter.tipov))
|
' Log(p.RowCount & " - " & Subs.traeTablaProds(Starter.tipov))
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -864,12 +864,12 @@ Module9=C_NuevoCliente
|
|||||||
NumberOfFiles=401
|
NumberOfFiles=401
|
||||||
NumberOfLibraries=29
|
NumberOfLibraries=29
|
||||||
NumberOfModules=29
|
NumberOfModules=29
|
||||||
Version=12.8
|
Version=12.5
|
||||||
@EndOfDesignText@
|
@EndOfDesignText@
|
||||||
#Region Project Attributes
|
#Region Project Attributes
|
||||||
#ApplicationLabel: Kelloggs Venta
|
#ApplicationLabel: Kelloggs Venta
|
||||||
#VersionCode: 3000
|
#VersionCode: 3000
|
||||||
#VersionName: 4.04.25
|
#VersionName: 4.04.29
|
||||||
#SupportedOrientations: portrait
|
#SupportedOrientations: portrait
|
||||||
#CanInstallToExternalStorage: False
|
#CanInstallToExternalStorage: False
|
||||||
#BridgeLogger:true
|
#BridgeLogger:true
|
||||||
|
|||||||
@@ -88,6 +88,6 @@ ModuleClosedNodes6=
|
|||||||
ModuleClosedNodes7=
|
ModuleClosedNodes7=
|
||||||
ModuleClosedNodes8=
|
ModuleClosedNodes8=
|
||||||
ModuleClosedNodes9=
|
ModuleClosedNodes9=
|
||||||
NavigationStack=kms_helperSubs,RD_respalda_cat_gunaprod2,203,0,kms_helperSubs,dbInit,121,0,kms_helperSubs,RD_respalda_pedido,136,0,Subs,traeTablaProds,1611,0,Subs,traeInvDeBD,881,0,Subs,guardaProductoSinGestion,926,0,C_Productos,lv_catalogos_ItemClick,315,0,B4XMainPage,Class_Globals,26,0,kms_helperSubs,RD_respalda_cat_gunaprod,151,0,kms_helperSubs,RD_restaura_cat_gunaprod,181,0,kms_helperSubs,RD_Init,68,0
|
NavigationStack=Diseñador Visual,nota.bal,-100,1,C_NoVenta,Class_Globals,0,0,C_Nota,Class_Globals,0,0,C_Nota,B4XPage_CloseRequest,246,0,C_Nota,borra_Click,246,0,C_Cliente,B_IMP2_Click,1090,6,C_Productos,lv_catalogos_ItemClick,315,0,C_Productos,LlenaProdsLL,1270,2,C_Productos,Busca_TextChanged,1205,0,B4XMainPage,Class_Globals,23,0
|
||||||
SelectedBuild=0
|
SelectedBuild=0
|
||||||
VisibleModules=1,27,11,3,12,4,28,17,23,29
|
VisibleModules=1,27,11,3,12,4,28,17,23,29,8,7
|
||||||
|
|||||||
Reference in New Issue
Block a user