From 10a2c84997912a411475882ee8b43f5c3042bf3d Mon Sep 17 00:00:00 2001 From: Jose Alberto Guerra Ugalde Date: Tue, 3 Feb 2026 09:53:23 -0600 Subject: [PATCH] VERSION 6.01.28 - Cambio en e manifiesto para corregir el "teclado" fantasma. --- B4A/C_Cliente.bas | 2 +- B4A/C_Principal.bas | 7 ++++- B4A/Files/principal.bal | Bin 78106 -> 78106 bytes B4A/KelloggsV4.b4a | 7 +++-- B4A/KelloggsV4.b4a.meta | 28 ++++++++++---------- B4A/Subs.bas | 57 ++++++++++++++++++++++++++-------------- 6 files changed, 62 insertions(+), 39 deletions(-) diff --git a/B4A/C_Cliente.bas b/B4A/C_Cliente.bas index 0802ee9..b80d142 100644 --- a/B4A/C_Cliente.bas +++ b/B4A/C_Cliente.bas @@ -1220,7 +1220,7 @@ Sub B_IMP_Click a_VENTA_F = 0 End If C4.Close - + C4=Starter.skmt.ExecQuery2("select count(*) as CUANTOS from pedido where substr(pe_pronombre,1,6) = ? AND PE_PROID = ? ", Array As String("CAMBIO", s.GetString("CAT_GP_ID"))) C4.Position=0 If C4.GetString("CUANTOS") > 0 Then diff --git a/B4A/C_Principal.bas b/B4A/C_Principal.bas index d6843bf..bb2b0bb 100644 --- a/B4A/C_Principal.bas +++ b/B4A/C_Principal.bas @@ -309,6 +309,10 @@ Private Sub B4XPage_Created (Root1 As B4XView) kh.centraPanel(Panel2, Root.Width) kh.centraPanel(Panel1, Root.Width) kh.centraPanel(p_botonesResumen, Root.Width) + p_transparente.Top = 0 : p_transparente.left = 0 + p_transparente.Height = Root.Height : p_transparente.Width = Root.Width +' PNL_ACCESO.Top = 0 : PNL_ACCESO.left = 0 +' PNL_ACCESO.Height = Root.Height : PNL_ACCESO.Width = Root.Width ' kh.centraPanel(Panel7, Root.Width) ' kh.centraPanel(PNL_ACCESO, Root.Width) @@ -565,7 +569,7 @@ Sub B4XPage_Appear NUEVO.Enabled = True B_PROXIMA.Enabled = True End If - + '############# Deshabilitamos botones para validacion de ruta y vinculo ######### c = Starter.skmt.ExecQuery("select count(*) as cuantos from CAT_VARIABLES WHERE CAT_VA_DESCRIPCION = 'LIGADO' and CAT_VA_VALOR = 1") c.Position = 0 @@ -2522,6 +2526,7 @@ Private Sub connecta_LongClick '' End If ' Log("MANDAMOS BITACORA") If e_ruta.Text = "KMTKLL1" Then Subs.deshabilitaValidaciones +' B4XPages.MainPage.recordatorio.agregaPanelRecordatorio(Root) End Sub Sub BUSCA_Click diff --git a/B4A/Files/principal.bal b/B4A/Files/principal.bal index 112247da7d3561ef01f0f2458577bb4dd93845c5..4abd027a3db978215214ab0112bfd389e9535a3b 100644 GIT binary patch delta 55 zcmbRBh-KCzmJR7nOxgc7XFBbDDjd$hz#s|4jAe`r3{oJ*#L0pN8j~md;hJX1$hEyx IgK;Sb00R*aWdHyG delta 46 zcmbRBh-KCzmJR7nOjZ9kXFBbD$`!-Fz#s|4jAfG*JPapK_`@~LkdbS9sRrXx4gjLH B5A*;4 diff --git a/B4A/KelloggsV4.b4a b/B4A/KelloggsV4.b4a index e2b8e2f..8f497d3 100644 --- a/B4A/KelloggsV4.b4a +++ b/B4A/KelloggsV4.b4a @@ -875,7 +875,7 @@ Library6=camera Library7=contentresolver Library8=core Library9=fileprovider -ManifestCode='This code will be applied to the manifest file during compilation.~\n~'You do not need to modify it in most cases.~\n~'See this link for for more information: https://www.b4x.com/forum/showthread.php?p=78136~\n~AddManifestText(~\n~~\n~)~\n~SetApplicationAttribute(android:icon, "@drawable/icon")~\n~SetApplicationAttribute(android:label, "$LABEL$")~\n~CreateResourceFromFile(Macro, Themes.LightTheme)~\n~'End of default text.~\n~~\n~AddApplicationText(~\n~)~\n~'Set activity to Landscape~\n~SetActivityAttribute(foto, android:screenOrientation, "landscape")~\n~AddApplicationText(~\n~~\n~ ~\n~)~\n~AddManifestText(~\n~~\n~)~\n~'''' para el teclado~\n~ SetActivityAttribute(main, android:windowSoftInputMode, adjustResize|stateHidden)~\n~SetApplicationAttribute(android:allowBackup, "false")~\n~SetServiceAttribute(Tracker, android:foregroundServiceType, "location")~\n~ ~\n~AddManifestText(~\n~~\n~)~\n~AddManifestText(~\n~~\n~)~\n~''CreateResourceFromFile(Macro, FirebaseAnalytics.GooglePlayBase)~\n~ 'End of default text.~\n~ ~\n~SetApplicationAttribute(android:usesCleartextTraffic, "true")~\n~ AddManifestText(~\n~~\n~)~\n~AddPermission(android.permission.ACCESS_BACKGROUND_LOCATION)~\n~AddManifestText(~\n~~\n~)~\n~AddManifestText()~\n~'AddManifestText()~\n~'AddManifestText()~\n~'AddManifestText()~\n~~\n~AddPermission(android.permission.ACCESS_FINE_LOCATION)~\n~AddPermission(android.permission.BLUETOOTH_ADVERTISE)~\n~AddPermission(android.permission.BLUETOOTH_CONNECT)~\n~AddPermission(android.permission.BLUETOOTH_SCAN)~\n~~\n~AddPermission(android.permission.MANAGE_EXTERNAL_STORAGE)~\n~AddManifestText() 'in order to access the device non-resettable identifiers such as IMEI and serial number.~\n~~\n~'///////////////////////// FLP Y PUSH /////////////~\n~' CreateResourceFromFile(Macro, FirebaseAnalytics.GooglePlayBase)~\n~' CreateResourceFromFile(Macro, FirebaseAnalytics.Firebase)~\n~' CreateResourceFromFile(Macro, FirebaseAnalytics.FirebaseAnalytics)~\n~' CreateResourceFromFile(Macro, FirebaseNotifications.FirebaseNotifications)~\n~SetServiceAttribute(Tracker, android:foregroundServiceType, "location")~\n~'//////////////////////////////////////////////////////~\n~'Le da mas memoria a la aplicacion~\n~SetApplicationAttribute(android:largeHeap, "true")~\n~AddApplicationText(~\n~ ~\n~ ~\n~ ~\n~)~\n~CreateResource(xml, provider_paths, ~\n~~\n~ ~\n~ ~\n~ ~\n~~\n~)~\n~~\n~'Si al cargar un mapa de google manda este error "java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion". agregar la siguiente linea:~\n~AddApplicationText()~\n~SetApplicationAttribute(android:allowBackup, "false")~\n~SetApplicationAttribute(android:exported, "true")~\n~AddManifestText()~\n~AddApplicationText(~\n~~\n~ ~\n~ )~\n~~\n~ 'Para que se registre para abrir bases de datos~\n~' AddActivityText(main,~\n~'~\n~'~\n~'~\n~'~\n~')~\n~~\n~ 'Para que se registre para abrir bases de datos~\n~ AddActivityText(main,~\n~~\n~~\n~~\n~~\n~~\n~) +ManifestCode='This code will be applied to the manifest file during compilation.~\n~'You do not need to modify it in most cases.~\n~'See this link for for more information: https://www.b4x.com/forum/showthread.php?p=78136~\n~AddManifestText(~\n~~\n~)~\n~SetApplicationAttribute(android:icon, "@drawable/icon")~\n~SetApplicationAttribute(android:label, "$LABEL$")~\n~CreateResourceFromFile(Macro, Themes.LightTheme)~\n~'End of default text.~\n~~\n~AddApplicationText(~\n~)~\n~'Set activity to Landscape~\n~SetActivityAttribute(foto, android:screenOrientation, "landscape")~\n~AddApplicationText(~\n~~\n~ ~\n~)~\n~AddManifestText(~\n~~\n~)~\n~'''' para el teclado~\n~' SetActivityAttribute(main, android:windowSoftInputMode, adjustResize|stateHidden)~\n~ SetActivityAttribute(main, android:windowSoftInputMode, stateHidden|adjustPan)~\n~SetApplicationAttribute(android:allowBackup, "false")~\n~SetServiceAttribute(Tracker, android:foregroundServiceType, "location")~\n~ ~\n~AddManifestText(~\n~~\n~)~\n~AddManifestText(~\n~~\n~)~\n~''CreateResourceFromFile(Macro, FirebaseAnalytics.GooglePlayBase)~\n~ 'End of default text.~\n~ ~\n~SetApplicationAttribute(android:usesCleartextTraffic, "true")~\n~ AddManifestText(~\n~~\n~)~\n~AddPermission(android.permission.ACCESS_BACKGROUND_LOCATION)~\n~AddManifestText(~\n~~\n~)~\n~AddManifestText()~\n~'AddManifestText()~\n~'AddManifestText()~\n~'AddManifestText()~\n~~\n~AddPermission(android.permission.ACCESS_FINE_LOCATION)~\n~AddPermission(android.permission.BLUETOOTH_ADVERTISE)~\n~AddPermission(android.permission.BLUETOOTH_CONNECT)~\n~AddPermission(android.permission.BLUETOOTH_SCAN)~\n~~\n~AddPermission(android.permission.MANAGE_EXTERNAL_STORAGE)~\n~AddManifestText() 'in order to access the device non-resettable identifiers such as IMEI and serial number.~\n~~\n~'///////////////////////// FLP Y PUSH /////////////~\n~' CreateResourceFromFile(Macro, FirebaseAnalytics.GooglePlayBase)~\n~' CreateResourceFromFile(Macro, FirebaseAnalytics.Firebase)~\n~' CreateResourceFromFile(Macro, FirebaseAnalytics.FirebaseAnalytics)~\n~' CreateResourceFromFile(Macro, FirebaseNotifications.FirebaseNotifications)~\n~SetServiceAttribute(Tracker, android:foregroundServiceType, "location")~\n~'//////////////////////////////////////////////////////~\n~'Le da mas memoria a la aplicacion~\n~SetApplicationAttribute(android:largeHeap, "true")~\n~AddApplicationText(~\n~ ~\n~ ~\n~ ~\n~)~\n~CreateResource(xml, provider_paths, ~\n~~\n~ ~\n~ ~\n~ ~\n~~\n~)~\n~~\n~'Si al cargar un mapa de google manda este error "java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/ProtocolVersion". agregar la siguiente linea:~\n~AddApplicationText()~\n~SetApplicationAttribute(android:allowBackup, "false")~\n~SetApplicationAttribute(android:exported, "true")~\n~AddManifestText()~\n~AddApplicationText(~\n~~\n~ ~\n~ )~\n~~\n~ 'Para que se registre para abrir bases de datos~\n~' AddActivityText(main,~\n~'~\n~'~\n~'~\n~'~\n~')~\n~~\n~ 'Para que se registre para abrir bases de datos~\n~ AddActivityText(main,~\n~~\n~~\n~~\n~~\n~~\n~) Module1=B4XMainPage Module10=C_NoVenta Module11=C_NuevoCliente @@ -918,7 +918,7 @@ Version=12.8 #Region Project Attributes #ApplicationLabel: Kelloggs Venta #VersionCode: 3000 - #VersionName: 5.12.18 + #VersionName: 6.01.28 #SupportedOrientations: portrait #CanInstallToExternalStorage: False #BridgeLogger:true @@ -935,9 +935,8 @@ Version=12.8 #End Region '222543 - ' Version que estaba en la tabla CAT_VERSION antes -> 2.95 -' 5.08.30 --> corrige que en la barra de busqeda en productos no hacia nada! +' 5.08.30 --> corrige que en la barra de busqueda en productos no hacia nada! Sub Process_Globals Public ActionBarHomeClicked As Boolean diff --git a/B4A/KelloggsV4.b4a.meta b/B4A/KelloggsV4.b4a.meta index f6989ae..9d5f100 100644 --- a/B4A/KelloggsV4.b4a.meta +++ b/B4A/KelloggsV4.b4a.meta @@ -69,40 +69,40 @@ ModuleBreakpoints7= ModuleBreakpoints8= ModuleBreakpoints9= ModuleClosedNodes0= -ModuleClosedNodes1=3,4,6,10,11,12,13,14,15,16,18,19,20,21,22,23,24,25,26,27,28,29,31,33,34,35,37,38,39,40,41,42,43,45,46,47 +ModuleClosedNodes1= ModuleClosedNodes10= ModuleClosedNodes11= ModuleClosedNodes12= -ModuleClosedNodes13=1,3 -ModuleClosedNodes14=3,8,9,11,12 -ModuleClosedNodes15=1,2 -ModuleClosedNodes16=3 -ModuleClosedNodes17=3,8,17 +ModuleClosedNodes13= +ModuleClosedNodes14= +ModuleClosedNodes15= +ModuleClosedNodes16= +ModuleClosedNodes17= ModuleClosedNodes18= ModuleClosedNodes19= ModuleClosedNodes2= -ModuleClosedNodes20=7,8,9,10,11,12,13,14 -ModuleClosedNodes21=3,4 +ModuleClosedNodes20= +ModuleClosedNodes21= ModuleClosedNodes22= ModuleClosedNodes23= ModuleClosedNodes24= ModuleClosedNodes25= ModuleClosedNodes26= -ModuleClosedNodes27=24,26,31,32,33,35 +ModuleClosedNodes27= ModuleClosedNodes28= -ModuleClosedNodes29=3,4 +ModuleClosedNodes29=3 ModuleClosedNodes3= ModuleClosedNodes30= ModuleClosedNodes31= ModuleClosedNodes32= -ModuleClosedNodes33=116 +ModuleClosedNodes33= ModuleClosedNodes34= ModuleClosedNodes4= ModuleClosedNodes5= ModuleClosedNodes6= ModuleClosedNodes7= ModuleClosedNodes8= -ModuleClosedNodes9=3 -NavigationStack=C_Auditoria,traeCliente,67,6,C_Auditoria,traeRuta,46,0,C_Auditoria,traeUsuarioDeBD,60,4,C_Auditoria,traeAlmacen,36,6,C_Auditoria,Class_Globals,0,0,C_Auditoria,B4XPage_Created,15,0,C_Auditoria,Initialize,12,0,B4XMainPage,B4XPage_Appear,409,0,B4XMainPage,Class_Globals,120,0,Starter,Process_Globals,55,0 +ModuleClosedNodes9= +NavigationStack=B4XMainPage,B4XPage_Appear,484,0,B4XMainPage,B4XPage_Created,392,0,B4XMainPage,Initialize,123,0,C_Principal,B4XPage_Appear,333,0,C_Principal,connecta_LongClick,2504,0,C_Principal,connecta3,2503,0,C_Principal,connecta2,2488,0,C_Principal,b_motivoNoVisita_Click,4075,0,Diseñador Visual,principal.bal,-100,6,C_Principal,B4XPage_Created,311,0 SelectedBuild=0 -VisibleModules=32,1,13,4,33,15,34,2,20,14,16,8,7,9,10,11,12,29,5 +VisibleModules=32,1,13,4,33,15,34,14,29 diff --git a/B4A/Subs.bas b/B4A/Subs.bas index d4b41e0..a5264cd 100644 --- a/B4A/Subs.bas +++ b/B4A/Subs.bas @@ -2498,32 +2498,51 @@ Public Sub RecalcularInventario ' 3. FILTRA (Ignora) los RMIs usando PE_CEDIS <> 'DUR' y el nombre '%CAMBIO%'. ' 4. Actualiza CAT_GUNAPROD2 masivamente. +' Dim sql As String = _ +' "UPDATE CAT_GUNAPROD2 " & _ +' "SET CAT_GP_ALMACEN = ( " & _ +' " SELECT (IFNULL(T5.CAT_GP_ALMACEN, 0) - IFNULL(Ventas.CantidadVendida, 0)) " & _ +' " FROM CAT_GUNAPROD5 T5 " & _ +' " LEFT JOIN ( " & _ +' " SELECT PE_PROID, SUM(PE_CANT) AS CantidadVendida " & _ +' " FROM PEDIDO " & _ +' " WHERE PE_CLIENTE <> '0' " & _ +' " AND PE_CEDIS <> 'DUR' " & _ +' " AND PE_PRONOMBRE NOT LIKE '%CAMBIO%' " & _ +' " GROUP BY PE_PROID " & _ +' " ) Ventas ON T5.CAT_GP_ID = Ventas.PE_PROID " & _ +' " WHERE T5.CAT_GP_ID = CAT_GUNAPROD2.CAT_GP_ID " & _ +' ") " & _ +' "WHERE EXISTS ( " & _ '<-- ESTA ES LA CLAVE QUE EVITA LOS NULLS +' " SELECT 1 FROM CAT_GUNAPROD5 T5 " & _ +' " WHERE T5.CAT_GP_ID = CAT_GUNAPROD2.CAT_GP_ID " & _ +' ")" + Dim sql As String = _ - "UPDATE CAT_GUNAPROD2 " & _ - "SET CAT_GP_ALMACEN = ( " & _ - " SELECT (IFNULL(T5.CAT_GP_ALMACEN, 0) - IFNULL(Ventas.CantidadVendida, 0)) " & _ - " FROM CAT_GUNAPROD5 T5 " & _ - " LEFT JOIN ( " & _ - " SELECT PE_PROID, SUM(PE_CANT) AS CantidadVendida " & _ - " FROM PEDIDO " & _ - " WHERE PE_CLIENTE <> '0' " & _ - " AND PE_CEDIS <> 'DUR' " & _ - " AND PE_PRONOMBRE NOT LIKE '%CAMBIO%' " & _ - " GROUP BY PE_PROID " & _ - " ) Ventas ON T5.CAT_GP_ID = Ventas.PE_PROID " & _ - " WHERE T5.CAT_GP_ID = CAT_GUNAPROD2.CAT_GP_ID " & _ - ") " & _ - "WHERE EXISTS ( " & _ '<-- ESTA ES LA CLAVE QUE EVITA LOS NULLS - " SELECT 1 FROM CAT_GUNAPROD5 T5 " & _ - " WHERE T5.CAT_GP_ID = CAT_GUNAPROD2.CAT_GP_ID " & _ - ")" + "UPDATE CAT_GUNAPROD2 " & _ + "SET CAT_GP_ALMACEN = ( " & _ + " SELECT (IFNULL(INV.CI_INVENTARIO, 0) - IFNULL(Ventas.CantidadVendida, 0)) " & _ + " FROM CAT_INVENTARIO INV " & _ + " LEFT JOIN ( " & _ + " SELECT PE_PROID, SUM(PE_CANT) AS CantidadVendida " & _ + " FROM PEDIDO " & _ + " WHERE PE_CLIENTE <> '0' " & _ + " AND PE_CEDIS <> 'DUR' " & _ + " AND PE_PRONOMBRE NOT LIKE '%CAMBIO%' " & _ + " GROUP BY PE_PROID " & _ + " ) Ventas ON INV.CI_IDPROD = Ventas.PE_PROID " & _ + " WHERE INV.CI_IDPROD = CAT_GUNAPROD2.CAT_GP_ID " & _ + ") " & _ + "WHERE EXISTS ( " & _ + " SELECT 1 FROM CAT_INVENTARIO INV " & _ + " WHERE INV.CI_IDPROD = CAT_GUNAPROD2.CAT_GP_ID " & _ + ")" ' Ejecutamos el cálculo masivo Starter.skmt.ExecNonQuery(sql) Starter.skmt.TransactionSuccessful If Starter.Logger Then Log("Inventario Sincronizado (Excluyendo RMIs)") - Catch Log("Error al recalcular inventario: " & LastException) End Try