-- option explcit
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
Option Explicit On
|
Option Explicit On
|
||||||
Option Strict On
|
Option Strict On
|
||||||
|
Option Infer On
|
||||||
|
|
||||||
Imports System.Data
|
Imports System.Data
|
||||||
Imports System.Data.SqlClient
|
Imports System.Data.SqlClient
|
||||||
@@ -2637,7 +2638,7 @@ Partial Class Ventas
|
|||||||
ViewState("CveAcercamientoCRM") = Request("CveAcercamientoCRM")
|
ViewState("CveAcercamientoCRM") = Request("CveAcercamientoCRM")
|
||||||
|
|
||||||
Dim cRMService As ICRMService = New CRMService(System.Configuration.ConfigurationManager.ConnectionStrings("Conexion").ConnectionString)
|
Dim cRMService As ICRMService = New CRMService(System.Configuration.ConfigurationManager.ConnectionStrings("Conexion").ConnectionString)
|
||||||
Dim AcercamientoModel As RequestAcercamiento = New RequestAcercamiento(UsuarioActual.CveEmpresa, CveAcercamientoCRM)
|
Dim AcercamientoModel As New RequestAcercamiento(UsuarioActual.CveEmpresa, CveAcercamientoCRM)
|
||||||
Dim objAcercamiento = cRMService.GetAceracamientoCRM(AcercamientoModel)
|
Dim objAcercamiento = cRMService.GetAceracamientoCRM(AcercamientoModel)
|
||||||
|
|
||||||
If objAcercamiento.Result.Count > 0 Then
|
If objAcercamiento.Result.Count > 0 Then
|
||||||
@@ -3484,7 +3485,7 @@ Partial Class Ventas
|
|||||||
|
|
||||||
If ObjPVenta.DtResultados.Rows.Count > 0 Then
|
If ObjPVenta.DtResultados.Rows.Count > 0 Then
|
||||||
CveCorte = ObjPVenta.CveCorte
|
CveCorte = ObjPVenta.CveCorte
|
||||||
Dim FechaICorte = ObjPVenta.FechaInicial.Date '.AddDays(-5)
|
Dim FechaICorte As Date = ObjPVenta.FechaInicial.Date '.AddDays(-5)
|
||||||
If UsuarioActual.Empresa.Funcionalidad(531) = "1" AndAlso FechaICorte < Now.Date Then
|
If UsuarioActual.Empresa.Funcionalidad(531) = "1" AndAlso FechaICorte < Now.Date Then
|
||||||
DebeCerrarCorte = True
|
DebeCerrarCorte = True
|
||||||
LblMotivoBloqueo.Text = $"Existe un corte del día <b>{FechaICorte.ToString("dd/MM/yyyy")}</b>. Favor de cerrarlo para iniciar un nuevo corte."
|
LblMotivoBloqueo.Text = $"Existe un corte del día <b>{FechaICorte.ToString("dd/MM/yyyy")}</b>. Favor de cerrarlo para iniciar un nuevo corte."
|
||||||
@@ -3554,17 +3555,17 @@ Partial Class Ventas
|
|||||||
Dt.Columns.Add("Descripcion", GetType(String))
|
Dt.Columns.Add("Descripcion", GetType(String))
|
||||||
Dt.Columns.Add("Importe", GetType(Decimal))
|
Dt.Columns.Add("Importe", GetType(Decimal))
|
||||||
|
|
||||||
Dim Dr1 = Dt.NewRow
|
Dim Dr1 As DataRow = Dt.NewRow
|
||||||
Dr1("Descripcion") = "Fondo de Caja"
|
Dr1("Descripcion") = "Fondo de Caja"
|
||||||
Dr1("Importe") = ObjPVenta.DtResultados(0)("ImporteInicial").ToString().ToDouble
|
Dr1("Importe") = ObjPVenta.DtResultados(0)("ImporteInicial").ToString().ToDouble
|
||||||
Dt.Rows.Add(Dr1)
|
Dt.Rows.Add(Dr1)
|
||||||
|
|
||||||
Dim Dr2 = Dt.NewRow
|
Dim Dr2 As DataRow = Dt.NewRow
|
||||||
Dr2("Descripcion") = "Ventas en Efectivo"
|
Dr2("Descripcion") = "Ventas en Efectivo"
|
||||||
Dr2("Importe") = ObjPVenta.DtResultados(0)("VentasEfectivo").ToString().ToDouble
|
Dr2("Importe") = ObjPVenta.DtResultados(0)("VentasEfectivo").ToString().ToDouble
|
||||||
Dt.Rows.Add(Dr2)
|
Dt.Rows.Add(Dr2)
|
||||||
|
|
||||||
Dim Dr21 = Dt.NewRow
|
Dim Dr21 As DataRow = Dt.NewRow
|
||||||
Dr21("Descripcion") = "Devoluciones"
|
Dr21("Descripcion") = "Devoluciones"
|
||||||
Dr21("Importe") = ObjPVenta.DtResultados(0)("Devoluciones").ToString().ToDouble
|
Dr21("Importe") = ObjPVenta.DtResultados(0)("Devoluciones").ToString().ToDouble
|
||||||
Dt.Rows.Add(Dr21)
|
Dt.Rows.Add(Dr21)
|
||||||
@@ -3574,17 +3575,17 @@ Partial Class Ventas
|
|||||||
'Dr3("Importe") = ObjPVenta.DtResultados(0)("Propina").ToString().ToDouble
|
'Dr3("Importe") = ObjPVenta.DtResultados(0)("Propina").ToString().ToDouble
|
||||||
'Dt.Rows.Add(Dr3)
|
'Dt.Rows.Add(Dr3)
|
||||||
|
|
||||||
Dim Dr4 = Dt.NewRow
|
Dim Dr4 As DataRow = Dt.NewRow
|
||||||
Dr4("Descripcion") = "Entradas"
|
Dr4("Descripcion") = "Entradas"
|
||||||
Dr4("Importe") = ObjPVenta.DtResultados(0)("Ingresado").ToString().ToDouble
|
Dr4("Importe") = ObjPVenta.DtResultados(0)("Ingresado").ToString().ToDouble
|
||||||
Dt.Rows.Add(Dr4)
|
Dt.Rows.Add(Dr4)
|
||||||
|
|
||||||
Dim Dr5 = Dt.NewRow
|
Dim Dr5 As DataRow = Dt.NewRow
|
||||||
Dr5("Descripcion") = "Salidas"
|
Dr5("Descripcion") = "Salidas"
|
||||||
Dr5("Importe") = ObjPVenta.DtResultados(0)("Retirado").ToString().ToDouble
|
Dr5("Importe") = ObjPVenta.DtResultados(0)("Retirado").ToString().ToDouble
|
||||||
Dt.Rows.Add(Dr5)
|
Dt.Rows.Add(Dr5)
|
||||||
|
|
||||||
Dim Dr6 = Dt.NewRow
|
Dim Dr6 As DataRow = Dt.NewRow
|
||||||
Dr6("Descripcion") = "Total"
|
Dr6("Descripcion") = "Total"
|
||||||
Dr6("Importe") = Total
|
Dr6("Importe") = Total
|
||||||
Dt.Rows.Add(Dr6)
|
Dt.Rows.Add(Dr6)
|
||||||
@@ -3654,7 +3655,7 @@ Partial Class Ventas
|
|||||||
If TxtEfectivoEnCaja.Text.Trim <> "" Then
|
If TxtEfectivoEnCaja.Text.Trim <> "" Then
|
||||||
If ObjPVenta.UpdateFinalizadoVtaCortes(CveCorte, TxtEfectivoEnCaja.Text.ToDouble, LblDiferenciaCaja.Text.ToDouble, Now, UsuarioActual.CveEmpresa) Then
|
If ObjPVenta.UpdateFinalizadoVtaCortes(CveCorte, TxtEfectivoEnCaja.Text.ToDouble, LblDiferenciaCaja.Text.ToDouble, Now, UsuarioActual.CveEmpresa) Then
|
||||||
RegistraScript($"window.location.href = '/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=CORT&CVECORTE={0}&FORMATO={1}", CveCorte, "PDF"))}'", "Imprimir")
|
RegistraScript($"window.location.href = '/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=CORT&CVECORTE={0}&FORMATO={1}", CveCorte, "PDF"))}'", "Imprimir")
|
||||||
Dim Liga = "document.location.href=""/Ventas/Ventas.aspx?CveVenta=-1"";"
|
Dim Liga As String = "document.location.href=""/Ventas/Ventas.aspx?CveVenta=-1"";"
|
||||||
Alert("Se ha cerrado el turno correctamente.", TipoMensaje.MsgInformacion, Liga)
|
Alert("Se ha cerrado el turno correctamente.", TipoMensaje.MsgInformacion, Liga)
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -3666,7 +3667,7 @@ Partial Class Ventas
|
|||||||
If TxtEfectivoCajaBloqueo.Text.Trim <> "" Then
|
If TxtEfectivoCajaBloqueo.Text.Trim <> "" Then
|
||||||
If ObjPVenta.UpdateFinalizadoVtaCortes(CveCorte, TxtEfectivoCajaBloqueo.Text.ToDouble, LblDiferenciaCajaBloqueo.Text.ToDouble, Now, UsuarioActual.CveEmpresa) Then
|
If ObjPVenta.UpdateFinalizadoVtaCortes(CveCorte, TxtEfectivoCajaBloqueo.Text.ToDouble, LblDiferenciaCajaBloqueo.Text.ToDouble, Now, UsuarioActual.CveEmpresa) Then
|
||||||
RegistraScript($"window.location.href = '/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=CORT&CVECORTE={0}&FORMATO={1}", CveCorte, "PDF"))}'", "Imprimir")
|
RegistraScript($"window.location.href = '/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=CORT&CVECORTE={0}&FORMATO={1}", CveCorte, "PDF"))}'", "Imprimir")
|
||||||
Dim Liga = "document.location.href=""/Ventas/Ventas.aspx?CveVenta=-1"";"
|
Dim Liga As String = "document.location.href=""/Ventas/Ventas.aspx?CveVenta=-1"";"
|
||||||
Alert("Se ha cerrado el turno correctamente.", TipoMensaje.MsgInformacion, Liga)
|
Alert("Se ha cerrado el turno correctamente.", TipoMensaje.MsgInformacion, Liga)
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
|
|||||||
Reference in New Issue
Block a user