mirror of
https://github.com/KeymonSoft/Lanterna.git
synced 2026-04-20 06:09:16 +00:00
Cambio de texto del Inicio Dia e imagen de login y configuracion
This commit is contained in:
@@ -115,52 +115,33 @@ Private Sub B4XPage_Created (Root1 As B4XView)
|
|||||||
p_historial.Height = Root.Height - WobbleMenu1.Height
|
p_historial.Height = Root.Height - WobbleMenu1.Height
|
||||||
p_transparenteCierreAdmin.Height = Root.Height : p_transparenteCierreAdmin.Width = Root.Width
|
p_transparenteCierreAdmin.Height = Root.Height : p_transparenteCierreAdmin.Width = Root.Width
|
||||||
p_transparenteCierreAdmin.Top = 0 : p_transparenteCierreAdmin.left = 0
|
p_transparenteCierreAdmin.Top = 0 : p_transparenteCierreAdmin.left = 0
|
||||||
|
Dim cs As CSBuilder
|
||||||
|
cs.Initialize
|
||||||
|
l_inicioDia.Text = cs.append("Para iniciar día, ingrese el texto ").bold.Append("INICIO DIA").Pop.Append(" y la tecla ").Bold.Append("Retorno").Pop.Append(" del teclado.").Color(Colors.red).Append(" Los datos del día anterior se borraran.").Popall
|
||||||
' p_botonesVenta.Top = Root.Height - p_botonesVenta.Height - WobbleMenu1.Height + 10
|
' p_botonesVenta.Top = Root.Height - p_botonesVenta.Height - WobbleMenu1.Height + 10
|
||||||
Subs.centraPanel(p_pago, p_mesaAbierta.Width)
|
Subs.centraPanel(p_pago, p_mesaAbierta.Width)
|
||||||
Subs.centraBoton(b_abrirMesa, Root.Width)
|
Subs.centraBoton(b_abrirMesa, Root.Width)
|
||||||
b_mesaCerrar.Top = clv_prods_ll.AsView.top + clv_prods_ll.AsView.Height + 15 ' - b_mesaCerrar.Height
|
b_mesaCerrar.Top = clv_prods_ll.AsView.top + clv_prods_ll.AsView.Height + 15 ' - b_mesaCerrar.Height
|
||||||
' Subs.centraEtiqueta(l_mesa, Root.Width)
|
|
||||||
' Subs.centraEtiqueta(l_comensales, Root.Width)
|
|
||||||
' Subs.centraEtiqueta(l_mesero, Root.Width)
|
|
||||||
Subs.centraPanel(p_mesaCampos, Root.Width)
|
Subs.centraPanel(p_mesaCampos, Root.Width)
|
||||||
Subs.centraPanel(p_mesaAbierta, Root.Width)
|
Subs.centraPanel(p_mesaAbierta, Root.Width)
|
||||||
lv_historial.Height = Root.Height * 0.7
|
lv_historial.Height = Root.Height * 0.7
|
||||||
p_botonesCierre.Top = lv_historial.Top + lv_historial.Height + 20dip
|
p_botonesCierre.Top = lv_historial.Top + lv_historial.Height + 20dip
|
||||||
Subs.centraPanel(p_botonesCierre, p_historial.Width)
|
Subs.centraPanel(p_botonesCierre, p_historial.Width)
|
||||||
' Dim ri As Cursor = Starter.skmt.ExecQuery($"select count(*) as cuantos from cat_gunaprod"$)
|
|
||||||
' ri.Position = 0
|
|
||||||
' If ri.GetString("cuantos") = "0" Then 'Si no hay productos, los descargamos
|
|
||||||
' Starter.reqManager.Initialize(Me, Starter.server)
|
|
||||||
' Dim cmd As DBCommand
|
|
||||||
' cmd.Initialize
|
|
||||||
' cmd.Name = "selectPedigree"
|
|
||||||
' cmd.Parameters = Array As Object(DateTime.Date(DateTime.Now))
|
|
||||||
' Log($"Traemos productos, ${DateTime.Date(DateTime.Now)}"$)
|
|
||||||
' Starter.reqManager.ExecuteQuery(cmd , 0, "descargaProds")
|
|
||||||
' End If
|
|
||||||
' query = "cat_gunaprod"
|
|
||||||
prodsMap.Initialize
|
prodsMap.Initialize
|
||||||
listaProds.Initialize
|
listaProds.Initialize
|
||||||
listaHints.Initialize
|
listaHints.Initialize
|
||||||
listaHintsM.Initialize
|
listaHintsM.Initialize
|
||||||
p_mesas.Width = Root.Width
|
p_mesas.Width = Root.Width
|
||||||
' Log(p_meseros.Width)
|
|
||||||
Subs.panelVisible(p_mesas, 0, 0)
|
Subs.panelVisible(p_mesas, 0, 0)
|
||||||
cb_comensales.SetItems(Array As String(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20))
|
cb_comensales.SetItems(Array As String(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20))
|
||||||
cb_pago.SetItems(Array As String("Tarjeta","Efectivo"))
|
cb_pago.SetItems(Array As String("Tarjeta","Efectivo"))
|
||||||
cb_mesero.SetItems(Subs.traeMeserosLista)
|
cb_mesero.SetItems(Subs.traeMeserosLista)
|
||||||
|
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Sub B4XPage_Appear
|
Sub B4XPage_Appear
|
||||||
reqManager.Initialize(Me, Starter.DBReqServer)
|
reqManager.Initialize(Me, Starter.DBReqServer)
|
||||||
' ticketId = Subs.traeTicket
|
|
||||||
' rutaUsuario = Subs.traeMesa
|
|
||||||
' Log($"${clv_carrito.AsView.Width}, ${Root.Width}"$)
|
|
||||||
clv = clv_prods_ll
|
clv = clv_prods_ll
|
||||||
cuentaProds
|
cuentaProds
|
||||||
' LlenaProdsLL(Null, Null)
|
|
||||||
LlenaMesas(Null, Null)
|
LlenaMesas(Null, Null)
|
||||||
LlenaProdsLL(Null, Null)
|
LlenaProdsLL(Null, Null)
|
||||||
PCLV.lblHint.SetTextSizeAnimated(0,13)
|
PCLV.lblHint.SetTextSizeAnimated(0,13)
|
||||||
@@ -192,7 +173,6 @@ Sub B4XPage_Appear
|
|||||||
PCLVM.pnlOverlay.Width = clv_mesas.AsView.Width
|
PCLVM.pnlOverlay.Width = clv_mesas.AsView.Width
|
||||||
PCLVM.B4XSeekBar1.Update
|
PCLVM.B4XSeekBar1.Update
|
||||||
p_meseros.Height = Root.Height - WobbleMenu1.Height
|
p_meseros.Height = Root.Height - WobbleMenu1.Height
|
||||||
' If et_busca.Text <> "" Then et_busca.Text =""
|
|
||||||
If p_mesas.Visible And Subs.revisaCierreAdmin Then p_transparenteCierreAdmin.Visible = True Else p_transparenteCierreAdmin.Visible = False
|
If p_mesas.Visible And Subs.revisaCierreAdmin Then p_transparenteCierreAdmin.Visible = True Else p_transparenteCierreAdmin.Visible = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -206,11 +186,6 @@ Sub B4XPage_CloseRequest As ResumableSub
|
|||||||
p_mesa.Visible = False
|
p_mesa.Visible = False
|
||||||
p_mesas.Visible = True
|
p_mesas.Visible = True
|
||||||
LlenaMesas(Null, Null)
|
LlenaMesas(Null, Null)
|
||||||
' Else if p_carrito.Visible Then
|
|
||||||
'' p_carrito.Visible = False
|
|
||||||
'' p_mesas.Visible = True
|
|
||||||
' WobbleMenu1_Tab1Click
|
|
||||||
' WobbleMenu1.SetCurrentTab(1)
|
|
||||||
Else
|
Else
|
||||||
B4XPages.ShowPage("Login")
|
B4XPages.ShowPage("Login")
|
||||||
End If
|
End If
|
||||||
@@ -219,7 +194,6 @@ End Sub
|
|||||||
|
|
||||||
Sub b_prodMenos_Click
|
Sub b_prodMenos_Click
|
||||||
etCantHasFocus = False
|
etCantHasFocus = False
|
||||||
' If WobbleMenu1.GetCurrentTab = 3 Then clv = clv_carrito Else clv = clv_prods_ll
|
|
||||||
clv = clv_prods_ll
|
clv = clv_prods_ll
|
||||||
' Log(Sender.As(Button).text & "|" & Sender.As(Button).tag)
|
' Log(Sender.As(Button).text & "|" & Sender.As(Button).tag)
|
||||||
Private buttonTag As String = Sender.As(Button).tag
|
Private buttonTag As String = Sender.As(Button).tag
|
||||||
@@ -235,13 +209,10 @@ Sub b_prodMenos_Click
|
|||||||
Dim elNombre As B4XView = pnl.GetView(1)
|
Dim elNombre As B4XView = pnl.GetView(1)
|
||||||
If WobbleMenu1.GetCurrentTab = 3 Then laCant = pnl.GetView(2).GetView(4)
|
If WobbleMenu1.GetCurrentTab = 3 Then laCant = pnl.GetView(2).GetView(4)
|
||||||
Log($"${pnl.GetView(1)}${CRLF}${pnl.GetView(2).GetView(2)}${CRLF}${pnl.GetView(2).GetView(3)}${CRLF}${pnl.GetView(2).GetView(4)}"$)
|
Log($"${pnl.GetView(1)}${CRLF}${pnl.GetView(2).GetView(2)}${CRLF}${pnl.GetView(2).GetView(3)}${CRLF}${pnl.GetView(2).GetView(4)}"$)
|
||||||
' Log($"precio|stock:${laCant.tag}"$)
|
|
||||||
' Log("lacant.text="&laCant.text & "|" & buttonTag)
|
|
||||||
If buttonTag = "vendido" And laCant.Text > 0 Then
|
If buttonTag = "vendido" And laCant.Text > 0 Then
|
||||||
Log(clv.GetValue(index).As(Map))
|
Log(clv.GetValue(index).As(Map))
|
||||||
clv.GetValue(index).As(Map).Put("almacen",inv + 1)
|
clv.GetValue(index).As(Map).Put("almacen",inv + 1)
|
||||||
Log(clv.GetValue(index).As(Map))
|
Log(clv.GetValue(index).As(Map))
|
||||||
' clv.GetValue(index).As(Map).Get("almacen") = clv.GetValue(index).As(Map).Get("almacen") + 1
|
|
||||||
End If
|
End If
|
||||||
If laCant.Text = "" Then laCant.Text = 0
|
If laCant.Text = "" Then laCant.Text = 0
|
||||||
Log($"|${laCant.Text}|"$)
|
Log($"|${laCant.Text}|"$)
|
||||||
@@ -254,9 +225,6 @@ Sub b_prodMenos_Click
|
|||||||
' Log(tmpMap)
|
' Log(tmpMap)
|
||||||
prodsMap.Put(id, tmpMap)
|
prodsMap.Put(id, tmpMap)
|
||||||
If laCant.Text = 0 Then prodsMap.Remove(id)
|
If laCant.Text = 0 Then prodsMap.Remove(id)
|
||||||
' LogColor("prodsMap="&prodsMap, Colors.blue)
|
|
||||||
' (Subs.traeAlmacen, p1.Get("precio"), p1.Get("cant"), pn, p, ticketId, Subs.traeFecha, Subs.traeUsuarioDeBD, rutaUsuario, 0, B4XPages.MainPage.tipo_venta)
|
|
||||||
' Private almacenX As String = Subs.traeAlmacen
|
|
||||||
Private nombreX As String = Subs.traeProdNombre(id)
|
Private nombreX As String = Subs.traeProdNombre(id)
|
||||||
Subs.actualizaProducto(precio, laCant.text, nombreX, id, Starter.ticketActual, Subs.traeFecha, Starter.meseroActual, Starter.mesaActual, 0, Starter.tipov, Starter.comensalesActuales)
|
Subs.actualizaProducto(precio, laCant.text, nombreX, id, Starter.ticketActual, Subs.traeFecha, Starter.meseroActual, Starter.mesaActual, 0, Starter.tipov, Starter.comensalesActuales)
|
||||||
cuentaProds
|
cuentaProds
|
||||||
@@ -273,7 +241,6 @@ End Sub
|
|||||||
|
|
||||||
Sub b_prodMas_Click
|
Sub b_prodMas_Click
|
||||||
etCantHasFocus = False
|
etCantHasFocus = False
|
||||||
' If WobbleMenu1.GetCurrentTab = 3 Then clv = clv_carrito Else clv = clv_prods_ll
|
|
||||||
clv = clv_prods_ll
|
clv = clv_prods_ll
|
||||||
Private buttonTag As String = Sender.As(Button).tag
|
Private buttonTag As String = Sender.As(Button).tag
|
||||||
Dim index As Int = clv.GetItemFromView(Sender)
|
Dim index As Int = clv.GetItemFromView(Sender)
|
||||||
@@ -285,7 +252,6 @@ Sub b_prodMas_Click
|
|||||||
If WobbleMenu1.GetCurrentTab = 3 Then laCant = pnl.GetView(2).GetView(4)
|
If WobbleMenu1.GetCurrentTab = 3 Then laCant = pnl.GetView(2).GetView(4)
|
||||||
Log($"${pnl.GetView(2).GetView(1)}${CRLF}${pnl.GetView(2).GetView(2)}${CRLF}${pnl.GetView(2).GetView(3)}${CRLF}${pnl.GetView(2).GetView(4)}"$)
|
Log($"${pnl.GetView(2).GetView(1)}${CRLF}${pnl.GetView(2).GetView(2)}${CRLF}${pnl.GetView(2).GetView(3)}${CRLF}${pnl.GetView(2).GetView(4)}"$)
|
||||||
If laCant.Text = "" Then laCant.Text = 0
|
If laCant.Text = "" Then laCant.Text = 0
|
||||||
' Private tmpMap As Map = clv.GetValue(index).As(Map)
|
|
||||||
Private precio As String=clv.GetValue(index).As(Map).Get("precio")
|
Private precio As String=clv.GetValue(index).As(Map).Get("precio")
|
||||||
Private inv As Int = clv.GetValue(index).As(Map).Get("almacen")
|
Private inv As Int = clv.GetValue(index).As(Map).Get("almacen")
|
||||||
Log($"|${laCant.Text}, ${inv}"$)
|
Log($"|${laCant.Text}, ${inv}"$)
|
||||||
@@ -298,12 +264,10 @@ Sub b_prodMas_Click
|
|||||||
' Log(clv.GetValue(index).As(Map))
|
' Log(clv.GetValue(index).As(Map))
|
||||||
End If
|
End If
|
||||||
else If laCant.Text + 1 <= inv Then
|
else If laCant.Text + 1 <= inv Then
|
||||||
' LogColor(inv, Colors.blue)
|
|
||||||
laCant.Text = $"$1.0{laCant.Text + 1}"$
|
laCant.Text = $"$1.0{laCant.Text + 1}"$
|
||||||
Log(Subs.totalPedido)
|
Log(Subs.totalPedido)
|
||||||
End If
|
End If
|
||||||
Private id As String=clv.GetValue(index).As(Map).Get("id")
|
Private id As String=clv.GetValue(index).As(Map).Get("id")
|
||||||
' Private almacenX As String = Subs.traeAlmacen
|
|
||||||
Private nombreX As String = Subs.traeProdNombre(id)
|
Private nombreX As String = Subs.traeProdNombre(id)
|
||||||
Private precioX As String = precio
|
Private precioX As String = precio
|
||||||
Subs.actualizaProducto(precioX, laCant.text, nombreX, id, Starter.ticketActual, Subs.traeFecha, Starter.meseroActual, Starter.mesaActual, 0, Starter.tipov, Starter.comensalesActuales)
|
Subs.actualizaProducto(precioX, laCant.text, nombreX, id, Starter.ticketActual, Subs.traeFecha, Starter.meseroActual, Starter.mesaActual, 0, Starter.tipov, Starter.comensalesActuales)
|
||||||
@@ -331,10 +295,8 @@ Sub cuentaProds
|
|||||||
' Log(Subs.totalPedido)
|
' Log(Subs.totalPedido)
|
||||||
Private cant0 As String = "0"
|
Private cant0 As String = "0"
|
||||||
Private total0 As String = "0"
|
Private total0 As String = "0"
|
||||||
|
|
||||||
If c.GetString("cant") <> Null And c.GetString("cant") <> "null" Then cant0 = c.GetString("cant")
|
If c.GetString("cant") <> Null And c.GetString("cant") <> "null" Then cant0 = c.GetString("cant")
|
||||||
If c.GetString("total") <> Null And c.GetString("total") <> "null" Then total0 = c.GetString("total")
|
If c.GetString("total") <> Null And c.GetString("total") <> "null" Then total0 = c.GetString("total")
|
||||||
|
|
||||||
Private p As Cursor = Starter.skmt.ExecQuery("select count(PT_TICKET) as ordenes from PEDIDO_TICKET where PT_PAGO <> 'VENTA'")
|
Private p As Cursor = Starter.skmt.ExecQuery("select count(PT_TICKET) as ordenes from PEDIDO_TICKET where PT_PAGO <> 'VENTA'")
|
||||||
p.Position = 0
|
p.Position = 0
|
||||||
' Log($"Total Prods: ${cant0}, Total Compra: $$1.2{total0}"$)
|
' Log($"Total Prods: ${cant0}, Total Compra: $$1.2{total0}"$)
|
||||||
@@ -387,7 +349,6 @@ Sub LlenaProdsLL(p As ResultSet, extra As String)
|
|||||||
' Log($"${p.GetString("CAT_GP_ID")}, ${p.GetString("CAT_GP_NOMBRE")}, ${cant}"$)
|
' Log($"${p.GetString("CAT_GP_ID")}, ${p.GetString("CAT_GP_NOMBRE")}, ${cant}"$)
|
||||||
Loop
|
Loop
|
||||||
p.Close
|
p.Close
|
||||||
|
|
||||||
' Log("LISTAPRODS: " & listaProds)
|
' Log("LISTAPRODS: " & listaProds)
|
||||||
PCLV.Commit
|
PCLV.Commit
|
||||||
clv_prods_ll.Clear
|
clv_prods_ll.Clear
|
||||||
@@ -429,10 +390,6 @@ Sub LlenaProdsLL(p As ResultSet, extra As String)
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
Next
|
Next
|
||||||
' LogColor(clv_prods_ll.Size, Colors.red)
|
|
||||||
' PCLV.Commit
|
|
||||||
' Log("CONT=" & cont)
|
|
||||||
' Log("CLV_PRODSLL="&clv_prods_ll.Size)
|
|
||||||
If clv_prods_ll.Size > 0 Then
|
If clv_prods_ll.Size > 0 Then
|
||||||
clv_prods_ll.JumpToItem(0) 'Vamos al primer artículo de la lista.
|
clv_prods_ll.JumpToItem(0) 'Vamos al primer artículo de la lista.
|
||||||
End If
|
End If
|
||||||
@@ -672,10 +629,6 @@ Private Sub lv_promos_ItemClick (Position As Int, Value As Object)
|
|||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
'Private Sub p_mesas_Click
|
|
||||||
' 'Para evitar que el clic en pantalla no se siga hacia atras
|
|
||||||
'End Sub
|
|
||||||
|
|
||||||
Private Sub p_historial_Click
|
Private Sub p_historial_Click
|
||||||
'Para evitar que el clic en pantalla no se siga hacia atras
|
'Para evitar que el clic en pantalla no se siga hacia atras
|
||||||
End Sub
|
End Sub
|
||||||
@@ -684,66 +637,41 @@ Private Sub p_carrito_Click
|
|||||||
'Para evitar que el clic en pantalla no se siga hacia atras
|
'Para evitar que el clic en pantalla no se siga hacia atras
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
'Private Sub b_buscar_Click
|
|
||||||
' forzarBusqueda = True
|
|
||||||
' et_busca_TextChanged("",et_busca.Text)
|
|
||||||
'End Sub
|
|
||||||
|
|
||||||
Private Sub b_terminar_Click
|
Private Sub b_terminar_Click
|
||||||
DateTime.DateFormat= $"yyMMdd-HHmmss-${Starter.ticketActual}"$
|
DateTime.DateFormat= $"yyMMdd-HHmmss-${Starter.ticketActual}"$
|
||||||
Private id As String = DateTime.Date(DateTime.Now)
|
Private id As String = DateTime.Date(DateTime.Now)
|
||||||
Starter.skmt.ExecNonQuery($"insert into cat_hist_compras (H_IDCOMPRA, H_FOLIO, H_MESA, H_CEDIS, H_COSTO_TOT, H_COSTOU, H_CANT, H_PRONOMBRE, H_PROID, H_TICKET, H_FECHA) select '${id}', PE_FOLIO, PE_MESA, PE_CEDIS, PE_COSTO_TOT, PE_COSTOU, PE_CANT, PE_PRONOMBRE, PE_PROID, PE_TICKET, PE_FECHA from pedido where PE_TICKET = '${Starter.ticketActual}'"$)
|
Starter.skmt.ExecNonQuery($"insert into cat_hist_compras (H_IDCOMPRA, H_FOLIO, H_MESA, H_CEDIS, H_COSTO_TOT, H_COSTOU, H_CANT, H_PRONOMBRE, H_PROID, H_TICKET, H_FECHA) select '${id}', PE_FOLIO, PE_MESA, PE_CEDIS, PE_COSTO_TOT, PE_COSTOU, PE_CANT, PE_PRONOMBRE, PE_PROID, PE_TICKET, PE_FECHA from pedido where PE_TICKET = '${Starter.ticketActual}'"$)
|
||||||
Starter.skmt.ExecNonQuery($"delete from pedido where PE_TICKET = '${Starter.ticketActual}'"$)
|
Starter.skmt.ExecNonQuery($"delete from pedido where PE_TICKET = '${Starter.ticketActual}'"$)
|
||||||
' lv_carrito.Clear
|
|
||||||
' clv_carrito.Clear
|
|
||||||
' et_busca_TextChanged("", et_busca.Text)
|
|
||||||
LlenaProdsLL(Null, Null)
|
LlenaProdsLL(Null, Null)
|
||||||
l_compraTerminada.Text = $"¡Felicidades!${CRLF}${CRLF}Tu compra con número de orden ${id} ha sido registrada.${CRLF}${CRLF}Llegará en tu siguiente día de entrega."$
|
l_compraTerminada.Text = $"¡Felicidades!${CRLF}${CRLF}Tu compra con número de orden ${id} ha sido registrada.${CRLF}${CRLF}Llegará en tu siguiente día de entrega."$
|
||||||
l_compraTerminada.Visible = True
|
l_compraTerminada.Visible = True
|
||||||
l_compraTerminada.BringToFront
|
l_compraTerminada.BringToFront
|
||||||
' l_totalCarrito.Text = ""
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Sub llenaHistorial
|
Sub llenaHistorial
|
||||||
Dim rs_hist As ResultSet = Starter.skmt.ExecQuery($"Select * from pedido_ticket where PT_PAGO <> 'VENTA' order by PT_PAGO, PT_TICKET"$)
|
Dim rs_hist As ResultSet = Starter.skmt.ExecQuery($"Select * from pedido_ticket where PT_PAGO <> 'VENTA' order by PT_PAGO, PT_TICKET"$)
|
||||||
If rs_hist.RowCount > 0 Then
|
If rs_hist.RowCount > 0 Then
|
||||||
' c_prods.Position = 0
|
|
||||||
' l_total2.Text = c_prods.GetString("PE_COSTO_TOT")
|
|
||||||
' lv_historial.BringToFront
|
|
||||||
l_historialVacio.Visible = False
|
l_historialVacio.Visible = False
|
||||||
Private cs As CSBuilder
|
Private cs As CSBuilder
|
||||||
lv_historial.Clear
|
lv_historial.Clear
|
||||||
lv_historial.Visible = True
|
lv_historial.Visible = True
|
||||||
Do While rs_hist.NextRow
|
Do While rs_hist.NextRow
|
||||||
' Private rs_do As ResultSet = Starter.skmt.ExecQuery($"select * from CAT_HIST_COMPRAS where H_IDCOMPRA = '${rs_hist.GetString("H_IDCOMPRA")}'"$)
|
' cs.Initialize
|
||||||
cs.Initialize
|
|
||||||
Dim Label1 As Label
|
Dim Label1 As Label
|
||||||
' lv_historial.TwoLinesLayout.ItemHeight = 50dip
|
|
||||||
Label1 = lv_historial.TwoLinesLayout.Label
|
Label1 = lv_historial.TwoLinesLayout.Label
|
||||||
Label1.TextSize = 16
|
Label1.TextSize = 16
|
||||||
' Label1.TextColor = Colors.red
|
|
||||||
Private elColor As Int = Colors.Red
|
Private elColor As Int = Colors.Red
|
||||||
If rs_hist.GetString("PT_PAGO") = "TARJETA" Then elColor = Colors.RGB(0,0,122)
|
If rs_hist.GetString("PT_PAGO") = "TARJETA" Then elColor = Colors.RGB(0,0,122)
|
||||||
Label1.color = Colors.White
|
Label1.color = Colors.White
|
||||||
Label1.Height = 30dip
|
Label1.Height = 30dip
|
||||||
' Private textColor As Int = Colors.black
|
|
||||||
Dim label2 As Label
|
Dim label2 As Label
|
||||||
label2 = lv_historial.TwoLinesLayout.SecondLabel
|
label2 = lv_historial.TwoLinesLayout.SecondLabel
|
||||||
label2.TextSize = 14
|
label2.TextSize = 14
|
||||||
label2.TextColor = Colors.RGB(1,127,1)
|
label2.TextColor = Colors.RGB(1,127,1)
|
||||||
' Do While rs_do.NextRow
|
|
||||||
' Log($"${rs_do.GetString("H_IDCOMPRA")}, ${rs_do.GetString("H_PRONOMBRE")}, ${rs_do.GetString("H_CANT")}"$)
|
|
||||||
' Loop
|
|
||||||
Private fecha As String = rs_hist.GetString("PT_FECHA")
|
Private fecha As String = rs_hist.GetString("PT_FECHA")
|
||||||
fecha = fecha.SubString2(1,10)
|
fecha = fecha.SubString2(1,10)
|
||||||
lv_historial.AddTwoLines(cs.Color(elColor).Append("Orden: " & rs_hist.GetString("PT_TICKET") & " - Mesa: " & rs_hist.GetString("PT_MESA")).PopAll, $"Fecha: ${fecha}, Productos: ${rs_hist.GetString("PT_NOART")}, Total: $${NumberFormat2(rs_hist.GetString("PT_MONTO"), 1, 2, 2, True)}"$)
|
lv_historial.AddTwoLines(cs.Color(elColor).Append("Orden: " & rs_hist.GetString("PT_TICKET") & " - Mesa: " & rs_hist.GetString("PT_MESA")).PopAll, $"Fecha: ${fecha}, Productos: ${rs_hist.GetString("PT_NOART")}, Total: $${NumberFormat2(rs_hist.GetString("PT_MONTO"), 1, 2, 2, True)}"$)
|
||||||
' totalPedido = totalPedido + (rs_hist.GetString("PE_COSTOU") * rs_hist.GetString("PE_CANT"))
|
|
||||||
' cantPedido = cantPedido + rs_hist.GetString("PE_CANT")
|
|
||||||
Loop
|
Loop
|
||||||
' Private c As Cursor = Starter.skmt.ExecQuery("select pc_noart, pc_monto from PEDIDO_TICKET where pc_cliente in (Select CUENTA from cuentaa)")
|
|
||||||
' c.Position=0
|
|
||||||
'' l_cant.Text = c.GetString("PC_NOART")
|
|
||||||
' c.Close
|
|
||||||
Else
|
Else
|
||||||
lv_historial.Visible = False
|
lv_historial.Visible = False
|
||||||
l_historialVacio.Visible = True
|
l_historialVacio.Visible = True
|
||||||
@@ -752,48 +680,6 @@ Sub llenaHistorial
|
|||||||
rs_hist.Close
|
rs_hist.Close
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Sub llenaHistorial_old
|
|
||||||
' Dim rs_hist As ResultSet = Starter.skmt.ExecQuery($"Select h_idcompra, sum(h_costo_tot) as total, sum(h_cant) as cantidad, h_fecha from cat_hist_compras group by h_idcompra"$)
|
|
||||||
' If rs_hist.RowCount > 0 Then
|
|
||||||
'' c_prods.Position = 0
|
|
||||||
'' l_total2.Text = c_prods.GetString("PE_COSTO_TOT")
|
|
||||||
'' lv_historial.BringToFront
|
|
||||||
' Private cs As CSBuilder
|
|
||||||
' Do While rs_hist.NextRow
|
|
||||||
'' Private rs_do As ResultSet = Starter.skmt.ExecQuery($"select * from CAT_HIST_COMPRAS where H_IDCOMPRA = '${rs_hist.GetString("H_IDCOMPRA")}'"$)
|
|
||||||
' cs.Initialize
|
|
||||||
' Dim Label1 As Label
|
|
||||||
'' lv_historial.TwoLinesLayout.ItemHeight = 50dip
|
|
||||||
' Label1 = lv_historial.TwoLinesLayout.Label
|
|
||||||
' Label1.TextSize = 16
|
|
||||||
' Label1.TextColor = Colors.red
|
|
||||||
' Label1.color = Colors.White
|
|
||||||
' Label1.Height = 30dip
|
|
||||||
'' Private textColor As Int = Colors.black
|
|
||||||
' Dim label2 As Label
|
|
||||||
' label2 = lv_historial.TwoLinesLayout.SecondLabel
|
|
||||||
' label2.TextSize = 14
|
|
||||||
' label2.TextColor = Colors.RGB(1,127,1)
|
|
||||||
'' Do While rs_do.NextRow
|
|
||||||
'' Log($"${rs_do.GetString("H_IDCOMPRA")}, ${rs_do.GetString("H_PRONOMBRE")}, ${rs_do.GetString("H_CANT")}"$)
|
|
||||||
'' Loop
|
|
||||||
' Private fecha As String = rs_hist.GetString("H_FECHA")
|
|
||||||
' fecha = fecha.SubString2(1,10)
|
|
||||||
' lv_historial.AddTwoLines("Orden: " & rs_hist.GetString("H_IDCOMPRA"), $"Fecha: ${fecha}, Productos: ${rs_hist.GetString("cantidad")}, Total: $${NumberFormat2(rs_hist.GetString("total"), 1, 2, 2, True)}"$)
|
|
||||||
'' totalPedido = totalPedido + (rs_hist.GetString("PE_COSTOU") * rs_hist.GetString("PE_CANT"))
|
|
||||||
'' cantPedido = cantPedido + rs_hist.GetString("PE_CANT")
|
|
||||||
' Loop
|
|
||||||
'' Private c As Cursor = Starter.skmt.ExecQuery("select pc_noart, pc_monto from PEDIDO_TICKET where pc_cliente in (Select CUENTA from cuentaa)")
|
|
||||||
'' c.Position=0
|
|
||||||
' '' l_cant.Text = c.GetString("PC_NOART")
|
|
||||||
'' c.Close
|
|
||||||
' Else
|
|
||||||
' l_historialVacio.Visible = True
|
|
||||||
' l_historialVacio.Text = "No hay ordenes en tu historial."
|
|
||||||
' End If
|
|
||||||
' rs_hist.Close
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Sub CreateListItem(Text As String, cant As Int, precioU As String, inv As Int, Width As Int, Height As Int, img As Bitmap, prodId As String) As Panel 'ignore
|
Sub CreateListItem(Text As String, cant As Int, precioU As String, inv As Int, Width As Int, Height As Int, img As Bitmap, prodId As String) As Panel 'ignore
|
||||||
' Dim p As B4XView = xui.CreatePanel("")
|
' Dim p As B4XView = xui.CreatePanel("")
|
||||||
' Dim cs As CSBuilder
|
' Dim cs As CSBuilder
|
||||||
@@ -886,10 +772,7 @@ Sub LlenaMesas(p As ResultSet, extra As String) 'ignore
|
|||||||
Private o As Cursor = Starter.skmt.ExecQuery("select count(PT_TICKET) as ordenes from PEDIDO_TICKET where PT_PAGO <> 'VENTA'")
|
Private o As Cursor = Starter.skmt.ExecQuery("select count(PT_TICKET) as ordenes from PEDIDO_TICKET where PT_PAGO <> 'VENTA'")
|
||||||
o.Position = 0
|
o.Position = 0
|
||||||
If o.GetInt("ordenes") > 0 Then WobbleMenu1.SetBadge(3, o.GetInt("ordenes"), Colors.white, Colors.red) Else WobbleMenu1.RemoveBadge(3)
|
If o.GetInt("ordenes") > 0 Then WobbleMenu1.SetBadge(3, o.GetInt("ordenes"), Colors.white, Colors.red) Else WobbleMenu1.RemoveBadge(3)
|
||||||
|
|
||||||
Dim p As ResultSet = Starter.skmt.ExecQuery($"select *, IFNULL(M_ESTATUS, 'CERRADA') as ESTATUS2, IFNULL(M_MESERO, 'NINGUNO') as MESERO, IFNULL(M_COMENSALES, 0) as COMENSALES from cat_mesas"$)
|
Dim p As ResultSet = Starter.skmt.ExecQuery($"select *, IFNULL(M_ESTATUS, 'CERRADA') as ESTATUS2, IFNULL(M_MESERO, 'NINGUNO') as MESERO, IFNULL(M_COMENSALES, 0) as COMENSALES from cat_mesas"$)
|
||||||
' Dim p As ResultSet = Starter.skmt.ExecQuery($"Select *, IFNULL(M_ESTATUS, 'CERRADA') as ESTATUS2, IFNULL(M_MESERO, 'NINGUNO') as MESERO, IFNULL(M_COMENSALES, 0) as COMENSALES, M_TICKET, IFNULL(PT_MONTO, 0) as SUBTOTAL, IFNULL(PT_NOART, 0) as NO_ARTS from CAT_MESAS left join pedido_ticket on M_TICKET = pt_ticket and M_ID = PT_MESA"$)
|
|
||||||
|
|
||||||
' Log(p.RowCount)
|
' Log(p.RowCount)
|
||||||
PCLVM.Commit
|
PCLVM.Commit
|
||||||
clv_mesas.Clear
|
clv_mesas.Clear
|
||||||
@@ -925,7 +808,6 @@ Sub LlenaMesas(p As ResultSet, extra As String) 'ignore
|
|||||||
reiniciarlistaProds = False
|
reiniciarlistaProds = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
'Entramos a la mesa seleccionada.
|
'Entramos a la mesa seleccionada.
|
||||||
Private Sub p_mesasItem_Click
|
Private Sub p_mesasItem_Click
|
||||||
Log(Sender.As(Panel).tag)
|
Log(Sender.As(Panel).tag)
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
@@ -1,20 +1,19 @@
|
|||||||
Build1=Default,mp.keymon.lat,HU2_PUBLIC
|
Build1=Default,mp.keymon.lat,HU2_PUBLIC
|
||||||
File1=candado.png
|
File1=candado.png
|
||||||
File10=MainPage.bal
|
File10=mesasItem.bal
|
||||||
File11=mesasItem.bal
|
File11=principal.bal
|
||||||
File12=principal.bal
|
File12=proditem.bal
|
||||||
File13=proditem.bal
|
File13=proditemCarrito.bal
|
||||||
File14=proditemCarrito.bal
|
File14=usuario.png
|
||||||
File15=usuario.png
|
File15=vecteezy_white-diagonal-stripes-with-red-line-isolated-on-white.png
|
||||||
File16=vecteezy_white-diagonal-stripes-with-red-line-isolated-on-white_12833309-[Convertido].png
|
|
||||||
File2=durakelo.png
|
File2=durakelo.png
|
||||||
File3=engrane.png
|
File3=engrane.png
|
||||||
File4=engranes.png
|
File4=engranes.png
|
||||||
File5=errormanager.bal
|
File5=errormanager.bal
|
||||||
File6=fondoblanco.png
|
File6=kmt.db
|
||||||
File7=kmt.db
|
File7=login.bal
|
||||||
File8=login.bal
|
File8=logo.png
|
||||||
File9=logo.png
|
File9=MainPage.bal
|
||||||
FileGroup1=Default Group
|
FileGroup1=Default Group
|
||||||
FileGroup10=Default Group
|
FileGroup10=Default Group
|
||||||
FileGroup11=Default Group
|
FileGroup11=Default Group
|
||||||
@@ -22,7 +21,6 @@ FileGroup12=Default Group
|
|||||||
FileGroup13=Default Group
|
FileGroup13=Default Group
|
||||||
FileGroup14=Default Group
|
FileGroup14=Default Group
|
||||||
FileGroup15=Default Group
|
FileGroup15=Default Group
|
||||||
FileGroup16=Default Group
|
|
||||||
FileGroup2=Default Group
|
FileGroup2=Default Group
|
||||||
FileGroup3=Default Group
|
FileGroup3=Default Group
|
||||||
FileGroup4=Default Group
|
FileGroup4=Default Group
|
||||||
@@ -56,7 +54,7 @@ Module3=DBRequestManager
|
|||||||
Module4=errorManager
|
Module4=errorManager
|
||||||
Module5=Starter
|
Module5=Starter
|
||||||
Module6=Subs
|
Module6=Subs
|
||||||
NumberOfFiles=16
|
NumberOfFiles=15
|
||||||
NumberOfLibraries=17
|
NumberOfLibraries=17
|
||||||
NumberOfModules=6
|
NumberOfModules=6
|
||||||
Version=12.8
|
Version=12.8
|
||||||
|
|||||||
@@ -14,11 +14,11 @@ ModuleBreakpoints5=
|
|||||||
ModuleBreakpoints6=
|
ModuleBreakpoints6=
|
||||||
ModuleClosedNodes0=
|
ModuleClosedNodes0=
|
||||||
ModuleClosedNodes1=
|
ModuleClosedNodes1=
|
||||||
ModuleClosedNodes2=
|
ModuleClosedNodes2=11,12,13,14,23,24,25,27,28,29,30,31
|
||||||
ModuleClosedNodes3=
|
ModuleClosedNodes3=
|
||||||
ModuleClosedNodes4=
|
ModuleClosedNodes4=
|
||||||
ModuleClosedNodes5=
|
ModuleClosedNodes5=
|
||||||
ModuleClosedNodes6=68
|
ModuleClosedNodes6=68
|
||||||
NavigationStack=C_Principal,b_mesaCerrar_Click,999,6,Main,Globals,21,0,Visual Designer,principal.bal,-100,6,B4XMainPage,Initialize,44,0,Visual Designer,login.bal,-100,6,B4XMainPage,Class_Globals,40,0,B4XMainPage,B4XPage_Created,63,6,Subs,traeTotalesTicketActual,1131,0,C_Principal,p_mesasItem_Click,936,0,Starter,Process_Globals,18,0,errorManager,Activity_Resume,117,0
|
NavigationStack=C_Principal,B4XPage_CloseRequest,181,0,C_Principal,b_prodMenos_Click,220,0,C_Principal,b_prodMas_Click,263,0,C_Principal,cuentaProds,292,0,C_Principal,LlenaProdsLL,385,0,C_Principal,lv_promos_ItemClick,623,0,C_Principal,p_carrito_Click,631,0,C_Principal,b_terminar_Click,641,0,C_Principal,llenaHistorial,674,0,C_Principal,LlenaMesas,802,0
|
||||||
SelectedBuild=0
|
SelectedBuild=0
|
||||||
VisibleModules=1,5,6,2,4,3
|
VisibleModules=1,5,6,2,4,3
|
||||||
|
|||||||
Reference in New Issue
Block a user