mirror of
https://github.com/KeymonSoft/Kelloggs_v4.git
synced 2026-04-20 19:49:12 +00:00
- Se regresaron cambios de correciones a carga local y encuestas que se habian borrado por error
This commit is contained in:
@@ -512,15 +512,6 @@ Sub JobDone(Job As HttpJob)
|
|||||||
Next
|
Next
|
||||||
paso1 = 1
|
paso1 = 1
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim result As DBResult = reqManager.HandleJob(Job)
|
|
||||||
If result.Tag = "fecha" Then 'query tag
|
|
||||||
For Each records() As Object In result.Rows
|
|
||||||
Starter.FECHA_HOY = records(result.Columns.Get("FECHA"))
|
|
||||||
Starter.skmt.ExecNonQuery2("delete from CAT_VARIABLES where CAT_VA_DESCRIPCION = ?", Array As Object ("FECHA"))
|
|
||||||
Starter.skmt.ExecNonQuery2("INSERT INTO CAT_VARIABLES(CAT_VA_DESCRIPCION, CAT_VA_VALOR) VALUES (?,?)", Array As Object ("FECHA",Starter.FECHA_HOY))
|
|
||||||
Next
|
|
||||||
End If
|
|
||||||
End If
|
End If
|
||||||
Job.Release
|
Job.Release
|
||||||
End If
|
End If
|
||||||
@@ -751,6 +742,8 @@ Private Sub b_cargaLocalOk_Click
|
|||||||
kh.RD_restaura_kmt_info
|
kh.RD_restaura_kmt_info
|
||||||
kh.RD_restaura_promos_comp
|
kh.RD_restaura_promos_comp
|
||||||
ime.HideKeyboard
|
ime.HideKeyboard
|
||||||
|
' DateTime.DateFormat = "yyyyMMdd"
|
||||||
|
' Starter.skmt.ExecNonQuery($"update USUARIOA set fecha = '${DateTime.Date(DateTime.Now)}'"$)
|
||||||
ToastMessageShow("¡¡CARGA EXITOSA!!", True)
|
ToastMessageShow("¡¡CARGA EXITOSA!!", True)
|
||||||
Else
|
Else
|
||||||
ToastMessageShow("CODIGO EQUIVOCADO", True)
|
ToastMessageShow("CODIGO EQUIVOCADO", True)
|
||||||
|
|||||||
@@ -294,7 +294,7 @@ Sub Class_Globals
|
|||||||
Private R_5 As RadioButton
|
Private R_5 As RadioButton
|
||||||
Private e_comm As EditText
|
Private e_comm As EditText
|
||||||
Private p_infoGral2 As Panel
|
Private p_infoGral2 As Panel
|
||||||
dim indicePregunta as Int
|
Dim indicePregunta As Int
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
'You can add more parameters here.
|
'You can add more parameters here.
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ Sub B4XPage_Appear
|
|||||||
busca.Text = ""
|
busca.Text = ""
|
||||||
entro = "2"
|
entro = "2"
|
||||||
colonia = 0
|
colonia = 0
|
||||||
c = Starter.skmt.ExecQuery2("select CAT_CL_NOMBRE, CAT_CL_CALLE, CAT_CL_CODIGO, CAT_CL_NUM_SERIEFISICO from kmt_info where CAT_CL_DIAS_VISITA = (SELECT CAT_VA_VALOR FROM CAT_VARIABLES WHERE CAT_VA_DESCRIPCION = ?) and gestion = 0 and cat_cl_codigo not in (select pe_cliente from pedido) and cat_cl_codigo <> 0 AND CAT_CL_TIPO_RUTA IN (?,?) and CAT_CL_CODIGO not in (select NV_CLIENTE from NOVENTA) ORDER BY CAT_CL_NUM_SERIEFISICO", Array As String("DIA_VISITA",SEMANA, "SEMANAL"))
|
c = Starter.skmt.ExecQuery2("select CAT_CL_NOMBRE, CAT_CL_CALLE, CAT_CL_CODIGO, CAT_CL_NUM_SERIEFISICO from kmt_info where CAT_CL_DIAS_VISITA = (SELECT CAT_VA_VALOR FROM CAT_VARIABLES WHERE CAT_VA_DESCRIPCION = ?) and gestion = 0 and cat_cl_codigo not in (select pe_cliente from pedido) and cat_cl_codigo <> 0 AND CAT_CL_TIPO_RUTA IN (?,?) and CAT_CL_CODIGO not in (select NV_CLIENTE from NOVENTA) ORDER BY CAT_CL_NUM_SERIEFISICO", Array As String("DIA_VISITA", SEMANA, "SEMANAL"))
|
||||||
ListView1.Clear
|
ListView1.Clear
|
||||||
lfila.Text = "NOMBRE"
|
lfila.Text = "NOMBRE"
|
||||||
If c.RowCount > 0 Then
|
If c.RowCount > 0 Then
|
||||||
|
|||||||
@@ -289,6 +289,7 @@ End Sub
|
|||||||
'You can see the list of page related events in the B4XPagesManager object. The event name is B4XPage.
|
'You can see the list of page related events in the B4XPagesManager object. The event name is B4XPage.
|
||||||
|
|
||||||
Sub B4XPage_Appear
|
Sub B4XPage_Appear
|
||||||
|
' Log(Subs.traeDiaSemana)
|
||||||
StartBluetooth
|
StartBluetooth
|
||||||
' If Not(kh.CheckNotificationAccess) Then
|
' If Not(kh.CheckNotificationAccess) Then
|
||||||
' Msgbox2Async($"Se necesita acceso a las notificaciones, haga clic en "Aceptar" y en la siguiente pantalla permita el acceso a la aplicación "${Application.LabelName}"."$, "Permisos necesarios", "Aceptar", "", "", Null, True)
|
' Msgbox2Async($"Se necesita acceso a las notificaciones, haga clic en "Aceptar" y en la siguiente pantalla permita el acceso a la aplicación "${Application.LabelName}"."$, "Permisos necesarios", "Aceptar", "", "", Null, True)
|
||||||
@@ -1038,14 +1039,12 @@ Sub JobDone(Job As HttpJob)
|
|||||||
For Each records() As Object In RESULT.Rows
|
For Each records() As Object In RESULT.Rows
|
||||||
Dim ID_PRODUCTO As String = records(RESULT.Columns.Get("ID_PRODUCTO"))
|
Dim ID_PRODUCTO As String = records(RESULT.Columns.Get("ID_PRODUCTO"))
|
||||||
Dim CANTIDAD As String = records(RESULT.Columns.Get("PROMEDIO"))
|
Dim CANTIDAD As String = records(RESULT.Columns.Get("PROMEDIO"))
|
||||||
|
|
||||||
c = Starter.skmt.ExecQuery2("SELECT * FROM CAT_GUNAPROD WHERE CAT_GP_ID = ?",Array As String(ID_PRODUCTO))
|
c = Starter.skmt.ExecQuery2("SELECT * FROM CAT_GUNAPROD WHERE CAT_GP_ID = ?",Array As String(ID_PRODUCTO))
|
||||||
If c.RowCount > 0 Then
|
If c.RowCount > 0 Then
|
||||||
c.Position = 0
|
c.Position = 0
|
||||||
Subs.actualizaProducto(ALMACEN, c.GetString("CAT_GP_PRECIO"),CANTIDAD, c.GetString("CAT_GP_NOMBRE"), ID_PRODUCTO,"0",Subs.traeFecha,usuario,e_ruta.Text,c.GetString("CAT_GP_PRECIO"),"ABORDO")
|
Subs.actualizaProducto(ALMACEN, c.GetString("CAT_GP_PRECIO"),CANTIDAD, c.GetString("CAT_GP_NOMBRE"), ID_PRODUCTO,"0",Subs.traeFecha,usuario,e_ruta.Text,c.GetString("CAT_GP_PRECIO"),"ABORDO")
|
||||||
End If
|
End If
|
||||||
' Starter.skmt.ExecNonQuery2("INSERT INTO PEDIDO(PE_TIPO, PE_RUTA, PE_CEDIS, PE_CANT,PE_PROID,PE_CLIENTE, PE_USUARIO) VALUES (?,?,?,?,?,?,?)", Array As Object ("ABORDO", e_ruta.Text, ALMACEN, CANTIDAD, ID_PRODUCTO, "0", usuario))
|
' Starter.skmt.ExecNonQuery2("INSERT INTO PEDIDO(PE_TIPO, PE_RUTA, PE_CEDIS, PE_CANT,PE_PROID,PE_CLIENTE, PE_USUARIO) VALUES (?,?,?,?,?,?,?)", Array As Object ("ABORDO", e_ruta.Text, ALMACEN, CANTIDAD, ID_PRODUCTO, "0", usuario))
|
||||||
|
|
||||||
Next
|
Next
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -869,7 +869,7 @@ Version=12.8
|
|||||||
#Region Project Attributes
|
#Region Project Attributes
|
||||||
#ApplicationLabel: Kelloggs Venta
|
#ApplicationLabel: Kelloggs Venta
|
||||||
#VersionCode: 3000
|
#VersionCode: 3000
|
||||||
#VersionName: 4.03.04
|
#VersionName: 4.04.02
|
||||||
#SupportedOrientations: portrait
|
#SupportedOrientations: portrait
|
||||||
#CanInstallToExternalStorage: False
|
#CanInstallToExternalStorage: False
|
||||||
#BridgeLogger:true
|
#BridgeLogger:true
|
||||||
|
|||||||
@@ -88,6 +88,6 @@ ModuleClosedNodes6=
|
|||||||
ModuleClosedNodes7=3,11,12
|
ModuleClosedNodes7=3,11,12
|
||||||
ModuleClosedNodes8=
|
ModuleClosedNodes8=
|
||||||
ModuleClosedNodes9=
|
ModuleClosedNodes9=
|
||||||
NavigationStack=C_NoVenta,GUARDA_Click,85,1,C_Cliente,b_inicioFinVenta_Click,4164,6,Subs,traeNombreCliente,839,6,C_Principal,cargar_Click,521,0,C_Cliente,Bt_GuardarBoleta_Click,3630,0,C_Principal,borraClientesNuevosSinVenta,3336,0,C_Principal,GetBA,3304,0,C_Principal,connecta_LongClick,3306,6,Visual Designer,principal.bal,-100,1,C_Principal,Subir_Click,501,0,C_Principal,SUBIR_INFO_PEDIDO,2731,3
|
NavigationStack=C_Principal,cargar_Click,676,0,C_Principal,JobDone,1029,0,C_Principal,B_PROXIMA_Click,2477,0,C_Productos,Class_Globals,13,0,C_Productos,B4XPage_Appear,170,0,Subs,sumaPedido,1676,0,C_Principal,B4XPage_Appear,285,0,Subs,traeDiaSemana,1680,0,kms_helperSubs,RD_restaura_kmt_info,336,0,C_Productos,b_prodMas_Click,672,0
|
||||||
SelectedBuild=0
|
SelectedBuild=0
|
||||||
VisibleModules=1,27,11,3,12,4,28,13,2,8
|
VisibleModules=1,27,11,3,12,4,28,2,23
|
||||||
|
|||||||
23
B4A/Subs.bas
23
B4A/Subs.bas
@@ -1682,3 +1682,26 @@ Sub sumaPedido(cliente As String) As String 'ignore
|
|||||||
x.Close
|
x.Close
|
||||||
Return NumberFormat2(total, 1, 2, 2, False)
|
Return NumberFormat2(total, 1, 2, 2, False)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
'Regresa el dia de la semana como string.
|
||||||
|
Sub traeDiaSemana As String
|
||||||
|
Private hoyNum As Int = DateTime.GetDayOfWeek(DateTime.Now)
|
||||||
|
Private diaSemana As String = ""
|
||||||
|
Select Case hoyNum
|
||||||
|
Case 1
|
||||||
|
diaSemana = "DOMINGO"
|
||||||
|
Case 2
|
||||||
|
diaSemana = "LUNES"
|
||||||
|
Case 3
|
||||||
|
diaSemana = "MARTES"
|
||||||
|
Case 4
|
||||||
|
diaSemana = "MIERCOLES"
|
||||||
|
Case 5
|
||||||
|
diaSemana = "JUEVES"
|
||||||
|
Case 6
|
||||||
|
diaSemana = "VIERNES"
|
||||||
|
Case 7
|
||||||
|
diaSemana = "SABADO"
|
||||||
|
End Select
|
||||||
|
Return diaSemana
|
||||||
|
End Sub
|
||||||
@@ -333,6 +333,13 @@ Sub RD_restaura_kmt_info
|
|||||||
If c.RowCount > 0 Then
|
If c.RowCount > 0 Then
|
||||||
c.Position = 0
|
c.Position = 0
|
||||||
' Log(c.GetString("FECHA"))
|
' Log(c.GetString("FECHA"))
|
||||||
|
skmt.ExecNonQuery2("delete from CAT_VARIABLES where CAT_VA_DESCRIPCION = ?", Array As Object ("DIA_VISITA"))' Ponemos el dia de hoy para visita.
|
||||||
|
skmt.ExecNonQuery2("INSERT INTO CAT_VARIABLES(CAT_VA_DESCRIPCION, CAT_VA_VALOR) VALUES (?,?)", Array As Object ("DIA_VISITA", Subs.traeDiaSemana))
|
||||||
|
skmt.ExecNonQuery2("delete from CAT_VARIABLES where CAT_VA_DESCRIPCION = ?", Array As Object ("FINDIA_FECHA"))' Borramos fecha de FIN DIA.
|
||||||
|
skmt.ExecNonQuery2("delete from CAT_VARIABLES where CAT_VA_DESCRIPCION = ?", Array As Object ("FINDIA_PASS"))' Ponemos la contraseña del FIN DIA en "CL"
|
||||||
|
skmt.ExecNonQuery2("INSERT INTO CAT_VARIABLES(CAT_VA_DESCRIPCION, CAT_VA_VALOR) VALUES (?,?)", Array As Object ("FINDIA_PASS", "CL"))
|
||||||
|
Starter.skmt.ExecNonQuery2("delete from CAT_VARIABLES where CAT_VA_DESCRIPCION = ?", Array As Object ("FECHA")) 'Ponemos la fecha de hoy en CAT_VARIABLES para que nos deje ingresar con el usuario guardado.
|
||||||
|
Starter.skmt.ExecNonQuery2("INSERT INTO CAT_VARIABLES(CAT_VA_DESCRIPCION, CAT_VA_VALOR) VALUES (?,?)", Array As Object ("FECHA", fechaHoy))
|
||||||
skmt.ExecNonQuery("delete from kmt_info")
|
skmt.ExecNonQuery("delete from kmt_info")
|
||||||
skmt.ExecNonQuery($"insert into kmt_info (${lasCols}) select ${lasCols} from rkmt1.kmt_info where fecha = '${c.GetString("FECHA")}'"$)
|
skmt.ExecNonQuery($"insert into kmt_info (${lasCols}) select ${lasCols} from rkmt1.kmt_info where fecha = '${c.GetString("FECHA")}'"$)
|
||||||
Log($"insert into kmt_info (${lasCols}) select ${lasCols} from rkmt1.kmt_info where fecha = '${c.GetString("FECHA")}'"$)
|
Log($"insert into kmt_info (${lasCols}) select ${lasCols} from rkmt1.kmt_info where fecha = '${c.GetString("FECHA")}'"$)
|
||||||
|
|||||||
Reference in New Issue
Block a user