Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -332,6 +332,9 @@ Partial Class AC_RepEstadoActividades
|
||||
If (UsuarioActual.CveEmpresa = 48 And ChkFirma.Checked) Then
|
||||
params.Add(New ReportParameter("pFirma1", String.Format("Lic. Damian A. Benitez Alcantar{0}Director Administrativo", vbCrLf)))
|
||||
params.Add(New ReportParameter("pFirma2", String.Format("Ing. Soraida Mesinas Reyes{0}Director General", vbCrLf)))
|
||||
ElseIf (UsuarioActual.CveEmpresa = 120 And ChkFirma.Checked) Then
|
||||
params.Add(New ReportParameter("pFirma1", String.Format("C.P.NEFTALI PEÑA MIRANDA{0}Subdirector de Contabilidad", vbCrLf)))
|
||||
params.Add(New ReportParameter("pFirma2", String.Format("Dra. María Antonieta Laso López{0}Director General", vbCrLf)))
|
||||
ElseIf (ChkFirma.Checked) Then
|
||||
params.Add(New ReportParameter("pFirma1", String.Format("C.P. Izelda Angulo Peraza{0} Subdirector de Contabilidad", vbCrLf)))
|
||||
params.Add(New ReportParameter("pFirma2", String.Format("ING. Soraida Mesinas Reyes{0} Director General", vbCrLf)))
|
||||
|
||||
@@ -642,6 +642,9 @@ Partial Class AC_SituacionFinanciera
|
||||
If (UsuarioActual.CveEmpresa = 48 And ChkFirma.Checked) Then
|
||||
params.Add(New ReportParameter("pFirma1", String.Format("Lic. Damian A. Benitez Alcantar{0}Director Administrativo", vbCrLf)))
|
||||
params.Add(New ReportParameter("pFirma2", String.Format("Ing. Soraida Mesinas Reyes{0}Director General", vbCrLf)))
|
||||
ElseIf (UsuarioActual.CveEmpresa = 120 And ChkFirma.Checked) Then
|
||||
params.Add(New ReportParameter("pFirma1", String.Format("C.P.NEFTALI PEÑA MIRANDA{0}Subdirector de Contabilidad", vbCrLf)))
|
||||
params.Add(New ReportParameter("pFirma2", String.Format("Dra. María Antonieta Laso López{0}Director General", vbCrLf)))
|
||||
ElseIf (ChkFirma.Checked) Then
|
||||
params.Add(New ReportParameter("pFirma1", String.Format("C.P. Izelda Angulo Peraza{0} Subdirector de Contabilidad", vbCrLf)))
|
||||
params.Add(New ReportParameter("pFirma2", String.Format("ING. Soraida Mesinas Reyes{0} Director General", vbCrLf)))
|
||||
|
||||
@@ -998,7 +998,7 @@
|
||||
</Style>
|
||||
</PageHeader>
|
||||
<PageFooter>
|
||||
<Height>4.50688cm</Height>
|
||||
<Height>2.76063cm</Height>
|
||||
<PrintOnFirstPage>true</PrintOnFirstPage>
|
||||
<PrintOnLastPage>true</PrintOnLastPage>
|
||||
<ReportItems>
|
||||
@@ -1019,8 +1019,8 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox2</rd:DefaultName>
|
||||
<Top>3.36021cm</Top>
|
||||
<Left>6.16434cm</Left>
|
||||
<Top>0.49389cm</Top>
|
||||
<Left>10.80759cm</Left>
|
||||
<Height>0.9616cm</Height>
|
||||
<Width>8.02269cm</Width>
|
||||
<Visibility>
|
||||
@@ -1097,7 +1097,7 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox3</rd:DefaultName>
|
||||
<Top>3.85438cm</Top>
|
||||
<Top>1.92292cm</Top>
|
||||
<Left>0.62818cm</Left>
|
||||
<Height>0.6cm</Height>
|
||||
<Width>18.2021cm</Width>
|
||||
@@ -1112,44 +1112,6 @@
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
<Textbox Name="Textbox38">
|
||||
<CanGrow>true</CanGrow>
|
||||
<KeepTogether>true</KeepTogether>
|
||||
<Paragraphs>
|
||||
<Paragraph>
|
||||
<TextRuns>
|
||||
<TextRun>
|
||||
<Value>Director administrativo</Value>
|
||||
<Style />
|
||||
</TextRun>
|
||||
</TextRuns>
|
||||
<Style>
|
||||
<TextAlign>Center</TextAlign>
|
||||
</Style>
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox2</rd:DefaultName>
|
||||
<Top>0.49389cm</Top>
|
||||
<Left>9.9076cm</Left>
|
||||
<Height>0.99688cm</Height>
|
||||
<Width>8.02269cm</Width>
|
||||
<ZIndex>3</ZIndex>
|
||||
<Visibility>
|
||||
<Hidden>=Microsoft.VisualBasic.Interaction.Iif((Globals!PageNumber = Globals!TotalPages) And (Parameters!pFirma1.Value <> ""), False, True)</Hidden>
|
||||
</Visibility>
|
||||
<Style>
|
||||
<Border>
|
||||
<Style>None</Style>
|
||||
</Border>
|
||||
<TopBorder>
|
||||
<Style>Solid</Style>
|
||||
</TopBorder>
|
||||
<PaddingLeft>2pt</PaddingLeft>
|
||||
<PaddingRight>2pt</PaddingRight>
|
||||
<PaddingTop>2pt</PaddingTop>
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
</ReportItems>
|
||||
<Style>
|
||||
<Border>
|
||||
|
||||
@@ -2859,7 +2859,7 @@
|
||||
</Style>
|
||||
</PageHeader>
|
||||
<PageFooter>
|
||||
<Height>3.73062cm</Height>
|
||||
<Height>2.27541cm</Height>
|
||||
<PrintOnFirstPage>true</PrintOnFirstPage>
|
||||
<PrintOnLastPage>true</PrintOnLastPage>
|
||||
<ReportItems>
|
||||
@@ -2883,7 +2883,7 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox3</rd:DefaultName>
|
||||
<Top>3.13062cm</Top>
|
||||
<Top>1.41083cm</Top>
|
||||
<Left>16.37931cm</Left>
|
||||
<Height>0.6cm</Height>
|
||||
<Width>3.95896cm</Width>
|
||||
@@ -2952,8 +2952,8 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox2</rd:DefaultName>
|
||||
<Top>2.73374cm</Top>
|
||||
<Left>6.03938cm</Left>
|
||||
<Top>0.07056cm</Top>
|
||||
<Left>10.88047cm</Left>
|
||||
<Height>0.99688cm</Height>
|
||||
<Width>8.02269cm</Width>
|
||||
<ZIndex>2</ZIndex>
|
||||
@@ -2973,45 +2973,6 @@
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
<Textbox Name="Textbox38">
|
||||
<CanGrow>true</CanGrow>
|
||||
<KeepTogether>true</KeepTogether>
|
||||
<Paragraphs>
|
||||
<Paragraph>
|
||||
<TextRuns>
|
||||
<TextRun>
|
||||
<Value xml:space="preserve">
|
||||
</Value>
|
||||
<Style />
|
||||
</TextRun>
|
||||
</TextRuns>
|
||||
<Style>
|
||||
<TextAlign>Center</TextAlign>
|
||||
</Style>
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox2</rd:DefaultName>
|
||||
<Top>0.10582cm</Top>
|
||||
<Left>10.37435cm</Left>
|
||||
<Height>0.99688cm</Height>
|
||||
<Width>8.02269cm</Width>
|
||||
<ZIndex>3</ZIndex>
|
||||
<Visibility>
|
||||
<Hidden>=Microsoft.VisualBasic.Interaction.Iif((Globals!PageNumber = Globals!TotalPages) And (Parameters!pFirma1.Value <> ""), False, True)</Hidden>
|
||||
</Visibility>
|
||||
<Style>
|
||||
<Border>
|
||||
<Style>None</Style>
|
||||
</Border>
|
||||
<TopBorder>
|
||||
<Style>Solid</Style>
|
||||
</TopBorder>
|
||||
<PaddingLeft>2pt</PaddingLeft>
|
||||
<PaddingRight>2pt</PaddingRight>
|
||||
<PaddingTop>2pt</PaddingTop>
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
</ReportItems>
|
||||
<Style>
|
||||
<Border>
|
||||
|
||||
19
Acumuladores/EntradasUsados.aspx
Normal file
19
Acumuladores/EntradasUsados.aspx
Normal file
@@ -0,0 +1,19 @@
|
||||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="EntradasUsados.aspx.vb" Inherits="Acumuladores_EntradasUsados" %>
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="CP" Runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="Css" Runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="E" Runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="HB" Runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content5" ContentPlaceHolderID="H" Runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content6" ContentPlaceHolderID="HA" Runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content7" ContentPlaceHolderID="C" Runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content8" ContentPlaceHolderID="JS" Runat="Server">
|
||||
</asp:Content>
|
||||
|
||||
5
Acumuladores/EntradasUsados.aspx.vb
Normal file
5
Acumuladores/EntradasUsados.aspx.vb
Normal file
@@ -0,0 +1,5 @@
|
||||
|
||||
Partial Class Acumuladores_EntradasUsados
|
||||
Inherits System.Web.UI.Page
|
||||
|
||||
End Class
|
||||
@@ -306,6 +306,7 @@ Public Class CFDIConceptos
|
||||
Public Property ClaveUnidad As String = ""
|
||||
Public Property Impuestos As List(Of CFDIConceptosImpuestos)
|
||||
Public Property Descuento As Decimal = 0.00D
|
||||
Public Property ImporteGravaIVAAdicional As Decimal = 0.00D 'caso IEPS
|
||||
|
||||
Sub New()
|
||||
Impuestos = New List(Of CFDIConceptosImpuestos)
|
||||
|
||||
@@ -838,12 +838,39 @@ Public Class ClsAcumuladores
|
||||
OnError("Ocurrió un error al consultar el reporte de usados. ", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||
End Try
|
||||
Return Retorno
|
||||
End Function
|
||||
End Function
|
||||
|
||||
Public Function EntradasUsadosGet(CveAlmacen As Integer, FechaI As Date, FechaF As Date, CveUsuario As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
'Data = New DataTable
|
||||
|
||||
SqlDataAdapter("PA_Acum_EntradasUsadosGet")
|
||||
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
|
||||
.Add("@FechaInicio", SqlDbType.Date).Value = FechaI
|
||||
.Add("@FechaFin", SqlDbType.Date).Value = FechaF
|
||||
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
Retorno = True
|
||||
Catch ex As SqlException
|
||||
|
||||
OnError("Ocurrió un error al consultar los movimientos. ", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||
|
||||
End Try
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
|
||||
#Region " IDisposable Support "
|
||||
' IDisposable
|
||||
' IDisposable
|
||||
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
|
||||
If Not disposedValue Then
|
||||
If disposing Then
|
||||
|
||||
@@ -1453,7 +1453,7 @@ Public Class ClsInventarios
|
||||
Return Retorno
|
||||
|
||||
End Function
|
||||
Public Function GetKardexAlmacenHorizontal(CvePS As Integer, FechaFin As Date, CveAlmacen As Integer, CveUnidadMedida As Integer, CveProveedor As Integer, CveTipoAlmacen As Integer, IncluyeTransitorios As Integer, CveUsuario As Integer, CveEmpresa As Integer) As Boolean
|
||||
Public Function GetKardexAlmacenHorizontal(CvePS As Integer, FechaFin As Date, CveAlmacen As Integer, CveUnidadMedida As Integer, CveProveedor As Integer, CveTipoAlmacen As Integer, IncluyeTransitorios As Integer, CveUsuario As Integer, CveEmpresa As Integer, Optional CondicionExistencias As Integer = 0) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
DataAdapter("PA_Inv_KardexAlmacenHorizontalGet")
|
||||
@@ -1469,6 +1469,7 @@ Public Class ClsInventarios
|
||||
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
||||
.Add("@CveProveedorCompra", SqlDbType.Int).Value = CveProveedor
|
||||
.Add("@CveTipoAlmacen", SqlDbType.Int).Value = CveTipoAlmacen
|
||||
.Add("@ExistenciasCondicion", SqlDbType.Int).Value = CondicionExistencias
|
||||
End With
|
||||
|
||||
Try
|
||||
|
||||
@@ -4093,6 +4093,7 @@ Public Class ClsPaginas
|
||||
PaginaDict.Add("/Inventarios/RepTraspasoEmitido.aspx".ToUpper(), 891)
|
||||
PaginaDict.Add("/Inventarios/KardexSeccionAlmacen.aspx".ToUpper(), 892)
|
||||
PaginaDict.Add("/Inventarios/RepTraspasoAlmacen.aspx".ToUpper(), 688)
|
||||
|
||||
#End Region
|
||||
#Region "MF"
|
||||
PaginaDict.Add("/MF/BitacoraDiaria.aspx".ToUpper(), 801)
|
||||
@@ -4578,7 +4579,8 @@ Public Class ClsPaginas
|
||||
PaginaDict.Add("/Acumuladores/CatTiposDefecto.aspx".ToUpper(), 1033)
|
||||
PaginaDict.Add("/Acumuladores/CatTiposUso.aspx".ToUpper(), 1034)
|
||||
PaginaDict.Add("/Acumuladores/CatFoliosGarantia.aspx".ToUpper(), 1035)
|
||||
PaginaDict.Add("/Acumuladores/CatGarantiasMeses.aspx".ToUpper(), 1036)
|
||||
PaginaDict.Add("/Acumuladores/CatGarantiasMeses.aspx".ToUpper(), 1036)
|
||||
PaginaDict.Add("/Acumuladores/EntradasUsados.aspx".ToUpper(), 543)
|
||||
|
||||
|
||||
'Antes de aquí.
|
||||
|
||||
@@ -4105,6 +4105,11 @@ Namespace Modelos
|
||||
CvePrePoliza = ObjConta.AddPrePolizas("Modelos/CancelarDocumento", CvePlantillaPoliza, ObjFactura.Total, ObjFactura.Total, ObjFactura.CveMoneda, Now, ObjFactura.Cliente.Nombre, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveTipoPoliza:=3)
|
||||
ObjFactura.CvePrePoliza = CvePrePoliza
|
||||
|
||||
If ObjFactura.CvePrePoliza <= 0 Then
|
||||
ErrorCancelar = True
|
||||
MensajeError = "Ocurrió un error al generar la prepoliza de cancelación."
|
||||
End If
|
||||
|
||||
'CANCELAR PAGOS
|
||||
If ObjFactura.TipoDocto.Contiene("Egs", "Dev") Then
|
||||
If Not ErrorCancelar Then
|
||||
@@ -4315,6 +4320,7 @@ Namespace Modelos
|
||||
If Not ErrorCancelar AndAlso RealizarDevolucionAlmacen AndAlso CveMovimiento > 0 Then
|
||||
Dim MensajeBitacora = "Devuelta"
|
||||
If Not ObjEventos.AddEventoBitacora(String.Format("Venta {2} en Folio: <a href=""/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}"" target=""_blank"">{1}</a>", CveMovimiento, Folio, MensajeBitacora), "-1", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveVenta:=CveVenta) Then
|
||||
MensajeError = "Ocurrió un error al agregar la bitacora."
|
||||
ErrorCancelar = True
|
||||
End If
|
||||
End If
|
||||
@@ -4327,12 +4333,16 @@ Namespace Modelos
|
||||
If Not ErrorCancelar Then
|
||||
If ObjFactura.CveContrato > 0 AndAlso ObjFactura.TipoDocto.Contiene("Ing", "Ant") Then
|
||||
ObjFactura.GuardarContratoAvanceEstimaciones(ObjContrato, ErrorList, -1, True)
|
||||
ErrorCancelar = ErrorList.Count > 0
|
||||
MensajeError = "Ocurrió un error al cancelar las estimaciones del contrato."
|
||||
If ErrorList.Count > 0 Then
|
||||
ErrorCancelar = True
|
||||
MensajeError = "Ocurrió un error al cancelar las estimaciones del contrato."
|
||||
End If
|
||||
ElseIf ObjFactura.CveContrato > 0 AndAlso ObjFactura.TipoDocto.Contiene("Egs", "Dev") Then
|
||||
ObjFactura.GuardarContratoAvanceEstimaciones(ObjContrato, ErrorList, 1, True)
|
||||
ErrorCancelar = ErrorList.Count > 0
|
||||
MensajeError = "Ocurrió un error al cancelar los avances del contrato."
|
||||
If ErrorList.Count > 0 Then
|
||||
ErrorCancelar = True
|
||||
MensajeError = "Ocurrió un error al cancelar los avances del contrato."
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
@@ -197,7 +197,7 @@
|
||||
<div class="form-group whitoutcol" style="width: 280px;">
|
||||
<span class="whitoutcol linewhitsize comprasdfleft">Tipo:</span>
|
||||
<div class="whitoutcol whitoutcol comprasdfleftvar">
|
||||
<asp:DropDownList ID="DdlTipoComprobante" runat="server" AutoPostBack="true" CssClass="form-control input-sm input-small">
|
||||
<asp:DropDownList ID="DdlTipoComprobante" runat="server" AutoPostBack="true" CssClass="form-control input-sm input-small" OnSelectedIndexChanged="DdlTipoComprobante_SelectedIndexChanged">
|
||||
<asp:ListItem Selected="True" Text="Factura" Value="Fac"></asp:ListItem>
|
||||
<asp:ListItem Text="Nota de Crédito" Value="NC"></asp:ListItem>
|
||||
<asp:ListItem Text="Anticipo" Value="Ant"></asp:ListItem>
|
||||
|
||||
@@ -10,14 +10,16 @@ Imports System
|
||||
Imports System.IO
|
||||
Imports ADServerControl
|
||||
Imports System.Threading.Tasks
|
||||
Imports System.Diagnostics
|
||||
|
||||
Partial Class Compras_Compras
|
||||
Inherits ClsPaginas
|
||||
|
||||
|
||||
|
||||
Inherits ClsPaginas
|
||||
|
||||
|
||||
|
||||
#Region "Propiedades"
|
||||
|
||||
'Local
|
||||
|
||||
'Local
|
||||
Private Property RequiereEvaluacion() As Boolean
|
||||
Get
|
||||
Return If(IsNothing(ViewState("RequiereEvaluacion")), False, CBool(ViewState("RequiereEvaluacion")))
|
||||
@@ -754,9 +756,9 @@ Partial Class Compras_Compras
|
||||
Set(value As Boolean)
|
||||
ViewState("EsNoDeducible") = value
|
||||
End Set
|
||||
End Property
|
||||
End Property
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "PROPIEDADES - AC NEW"
|
||||
Private Property DtPresupuestos As DataTable
|
||||
Get
|
||||
@@ -773,9 +775,9 @@ Partial Class Compras_Compras
|
||||
Set(value As Integer)
|
||||
ViewState("EjercicioAC") = value
|
||||
End Set
|
||||
End Property
|
||||
End Property
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " PROPIEDADES REFACTURACION "
|
||||
Private Property DtRefacturacion As DataTable
|
||||
Get
|
||||
@@ -816,10 +818,10 @@ Partial Class Compras_Compras
|
||||
Set(value As ArrayList)
|
||||
ViewState("ClavesBorradas") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
End Property
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " PROPIEDADES OC "
|
||||
Private Property TipoCambioOC As Decimal
|
||||
Get
|
||||
@@ -836,9 +838,9 @@ Partial Class Compras_Compras
|
||||
Set(value As Boolean)
|
||||
ViewState("PopUpOC") = value
|
||||
End Set
|
||||
End Property
|
||||
End Property
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "PROPIEDADES ALMACEN" 'Charlie
|
||||
Private Property TotalAlmacen As Decimal
|
||||
Get
|
||||
@@ -856,12 +858,12 @@ Partial Class Compras_Compras
|
||||
Set(value As Decimal)
|
||||
ViewState("TotalFlete") = value
|
||||
End Set
|
||||
End Property
|
||||
End Property
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "Propiedades"
|
||||
|
||||
'CFDi
|
||||
|
||||
'CFDi
|
||||
Private Property Serie As String
|
||||
Private Property Folio As String
|
||||
Private Property Fecha As String
|
||||
@@ -1000,10 +1002,10 @@ Partial Class Compras_Compras
|
||||
Set(value As Integer)
|
||||
ViewState("FleteImportacionOpcion") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
End Property
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " PROPIEDADES DE TOTALES "
|
||||
Private Property SubTotalOriginal As Double
|
||||
Get
|
||||
@@ -1060,10 +1062,10 @@ Partial Class Compras_Compras
|
||||
Set(value As Boolean)
|
||||
ViewState("ActualizaTotales") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
End Property
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
Dim DTConceptos As DataTable
|
||||
Private Property EmpresasOC As List(Of Integer)
|
||||
Get
|
||||
@@ -1585,8 +1587,8 @@ Partial Class Compras_Compras
|
||||
|
||||
|
||||
'RegistraScript("ScrollVentanaAddProducto();")
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#Region "C A R G A S"
|
||||
Private Sub CargaOrdenCorte()
|
||||
Dim ObjCGame As New ClsCGame()
|
||||
@@ -1645,10 +1647,28 @@ Partial Class Compras_Compras
|
||||
If IO.File.Exists(Archivo) Then
|
||||
|
||||
Dim Validada As Boolean = True
|
||||
If Not UsuarioActual.Empresa.Funcionalidad(529) = "1" Then
|
||||
'verificacion doble, si no la han cancelado, ya tiene una validaci[on para que llegue aqui
|
||||
Dim Valida As New ClsValidaCFDi(dr("UUID").ToString(), dr("RFCDe").ToString, dr("RFCPara").ToString(), dr("Total").ToString.ToDecimal)
|
||||
|
||||
If Not UsuarioActual.Empresa.Funcionalidad(529) = "1" Then
|
||||
'verificacion doble, si no la han cancelado, ya tiene una validaci[on para que llegue aqui
|
||||
|
||||
|
||||
|
||||
|
||||
Dim SWatch As New Stopwatch
|
||||
SWatch.Start()
|
||||
Dim ts As New TimeSpan
|
||||
|
||||
|
||||
Dim Valida As New ClsValidaCFDi(dr("UUID").ToString(), dr("RFCDe").ToString, dr("RFCPara").ToString(), dr("Total").ToString.ToDecimal)
|
||||
|
||||
SWatch.Stop()
|
||||
|
||||
Dim SegundosRespuesta As Double = SWatch.ElapsedMilliseconds / 1000
|
||||
SegundosRespuesta = SegundosRespuesta.ToEntero
|
||||
|
||||
If SWatch.ElapsedMilliseconds >= 5000 Then
|
||||
Alert($"Los servicios de validacion del SAT presentan lentitud en la respuesta [{ SegundosRespuesta } s].", TipoMensaje.ToastError, "", 0)
|
||||
End If
|
||||
|
||||
If UsuarioActual.CveEmpresa < 2 Then
|
||||
Valida.EsValida = 1
|
||||
End If
|
||||
@@ -3609,9 +3629,9 @@ Partial Class Compras_Compras
|
||||
'TmpDT = DtPSTemp.Copy
|
||||
'DtPSTemp.Dispose()
|
||||
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "Vinculacion De Servcios"
|
||||
Private Function isAdminObraGluyas() As Boolean
|
||||
Return (UsuarioActual.CveRol = 1047 And UsuarioActual.CveEmpresa = 66)
|
||||
@@ -3638,10 +3658,10 @@ Partial Class Compras_Compras
|
||||
dt.Dispose()
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "BTN'S"
|
||||
Protected Sub BtnVincularServicios_Click(sender As Object, e As EventArgs) Handles BtnVincularServicios.Click
|
||||
Dim correcto As Boolean = True
|
||||
@@ -15644,11 +15664,21 @@ Partial Class Compras_Compras
|
||||
RBLPago.Items(2).Enabled = True
|
||||
End If
|
||||
ImgAnticiposPendientes.Visible = False
|
||||
If DdlTipoComprobante.SelectedValue.Contiene("NC", "DEV") Then
|
||||
paneldevolucion.Visible = True
|
||||
Pnlalmaceninventarios.Visible = False
|
||||
cargaddldevoluciones(CveProveedor, TxtSubTotal.Text.ToDouble)
|
||||
InicializaAplicaNCFact()
|
||||
DivReembolso.Visible = False
|
||||
RBLPago.Items(2).Enabled = False
|
||||
UpPS.Update()
|
||||
|
||||
End If
|
||||
End If
|
||||
UPCondicionesPago.Update()
|
||||
End Sub
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
#Region " ENVIA CORREO NOTICIACION - VENDEDOR "
|
||||
Private Sub MandaCorreoOCVendedores(CveCompra As Integer)
|
||||
|
||||
@@ -15853,65 +15883,65 @@ Partial Class Compras_Compras
|
||||
Next
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
'VIEJO - COMENTADO IPP 12 JULIO 2017
|
||||
'Private Sub MandaCorreo(CveCompra As Integer)
|
||||
' Dim ObjOC As New ClsOC
|
||||
' Dim DTCorreos As New DataTable
|
||||
' Dim DTFolios As New DataTable
|
||||
' Dim strBody As New StringBuilder
|
||||
|
||||
' ObjOC.GetOrdenesCompraCorreo(CveCompra)
|
||||
' DTCorreos = ObjOC.DtResultados
|
||||
|
||||
' ObjOC.GetComprasOC(CveCompra)
|
||||
' DTFolios = ObjOC.DtResultados
|
||||
|
||||
' strBody.AppendFormat("Se ha vinculado la compra <b>{0}-{1}</b> a la siguiente OC", Serie, Folio)
|
||||
' strBody.Append("<html xmlns=""http://www.w3.org/1999/xhtml""> ")
|
||||
' strBody.Append("<head> ")
|
||||
' strBody.Append("</head> ")
|
||||
' strBody.Append("<body> ")
|
||||
|
||||
' 'Cargo el detalle
|
||||
' strBody.Append(" <div style='width: 550px'> ")
|
||||
' strBody.Append(" <fieldset> ")
|
||||
' strBody.Append(" <legend>Ordenes de compra</legend> ")
|
||||
' strBody.Append(" <table width=""550px""> <tr style='background-color:gray;color:White;font-family:Verdana;font-size:10px;text-align:center;vertical-align:middle;font-weight:bold;height:20px;text-decoration:none;'>
|
||||
' <th scope='col' style='width: 50px'>Folio</th>
|
||||
' <th scope='col' style='width: 50px'>Tipo</th>")
|
||||
|
||||
' For Each row As DataRow In DTCorreos.Rows
|
||||
' Dim Asunto, Para, ArrayCC, Body As String
|
||||
' Asunto = "Vinculación de Factura"
|
||||
' Para = row("Correo").ToString
|
||||
' ArrayCC = ""
|
||||
|
||||
' For Each RowM As DataRow In DTFolios.Rows
|
||||
' strBody.AppendFormat("<tr class='Texto'><td style='width:50px;'>{0}</td><td style='width:50px;'>{1}</td></tr>", RowM("Folio").ToString, RowM("Tipo"))
|
||||
' Next
|
||||
|
||||
' strBody.Append(" </table> ")
|
||||
' strBody.Append(" </fieldset> ")
|
||||
' strBody.Append(" </div> ")
|
||||
' strBody.Append("</body></html>")
|
||||
|
||||
' Body = strBody.ToString
|
||||
|
||||
' ObjOC.Dispose()
|
||||
|
||||
' Dim Mail As New ClsSisMail()
|
||||
' Mail.SendMail(ClsPaginas.EmpresaNotificaciones, Para, Asunto, Body, ArrayCC)
|
||||
' Next
|
||||
|
||||
'End Sub
|
||||
End Sub
|
||||
|
||||
'VIEJO - COMENTADO IPP 12 JULIO 2017
|
||||
'Private Sub MandaCorreo(CveCompra As Integer)
|
||||
' Dim ObjOC As New ClsOC
|
||||
' Dim DTCorreos As New DataTable
|
||||
' Dim DTFolios As New DataTable
|
||||
' Dim strBody As New StringBuilder
|
||||
|
||||
' ObjOC.GetOrdenesCompraCorreo(CveCompra)
|
||||
' DTCorreos = ObjOC.DtResultados
|
||||
|
||||
' ObjOC.GetComprasOC(CveCompra)
|
||||
' DTFolios = ObjOC.DtResultados
|
||||
|
||||
' strBody.AppendFormat("Se ha vinculado la compra <b>{0}-{1}</b> a la siguiente OC", Serie, Folio)
|
||||
' strBody.Append("<html xmlns=""http://www.w3.org/1999/xhtml""> ")
|
||||
' strBody.Append("<head> ")
|
||||
' strBody.Append("</head> ")
|
||||
' strBody.Append("<body> ")
|
||||
|
||||
' 'Cargo el detalle
|
||||
' strBody.Append(" <div style='width: 550px'> ")
|
||||
' strBody.Append(" <fieldset> ")
|
||||
' strBody.Append(" <legend>Ordenes de compra</legend> ")
|
||||
' strBody.Append(" <table width=""550px""> <tr style='background-color:gray;color:White;font-family:Verdana;font-size:10px;text-align:center;vertical-align:middle;font-weight:bold;height:20px;text-decoration:none;'>
|
||||
' <th scope='col' style='width: 50px'>Folio</th>
|
||||
' <th scope='col' style='width: 50px'>Tipo</th>")
|
||||
|
||||
' For Each row As DataRow In DTCorreos.Rows
|
||||
' Dim Asunto, Para, ArrayCC, Body As String
|
||||
' Asunto = "Vinculación de Factura"
|
||||
' Para = row("Correo").ToString
|
||||
' ArrayCC = ""
|
||||
|
||||
' For Each RowM As DataRow In DTFolios.Rows
|
||||
' strBody.AppendFormat("<tr class='Texto'><td style='width:50px;'>{0}</td><td style='width:50px;'>{1}</td></tr>", RowM("Folio").ToString, RowM("Tipo"))
|
||||
' Next
|
||||
|
||||
' strBody.Append(" </table> ")
|
||||
' strBody.Append(" </fieldset> ")
|
||||
' strBody.Append(" </div> ")
|
||||
' strBody.Append("</body></html>")
|
||||
|
||||
' Body = strBody.ToString
|
||||
|
||||
' ObjOC.Dispose()
|
||||
|
||||
' Dim Mail As New ClsSisMail()
|
||||
' Mail.SendMail(ClsPaginas.EmpresaNotificaciones, Para, Asunto, Body, ArrayCC)
|
||||
' Next
|
||||
|
||||
'End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " CIERRE PERIODO "
|
||||
Private Function ValidaCierrePeriodo() As Boolean
|
||||
'solo se permiten, mes actual, mes anterior <= #dias
|
||||
@@ -15927,9 +15957,9 @@ Partial Class Compras_Compras
|
||||
' Return True
|
||||
'End If
|
||||
'Return False
|
||||
End Function
|
||||
End Function
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " AGREGA POR SERIE/LOTE "
|
||||
Private Sub CreaDtDetalle()
|
||||
If DtDatosDetalle Is Nothing Then
|
||||
@@ -16036,9 +16066,9 @@ Partial Class Compras_Compras
|
||||
Protected Sub GvSerie_RowDeleting(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewDeleteEventArgs) Handles GvSerie.RowDeleting
|
||||
DtDatosDetalle.Rows.Remove(DtDatosDetalle.Rows(e.RowIndex))
|
||||
CargaSerie()
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " TIPO CAMBIO "
|
||||
Protected Sub DdlMoneda_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
CambiaMoneda()
|
||||
@@ -16084,9 +16114,9 @@ Partial Class Compras_Compras
|
||||
Protected Sub BtnCambiaFechaTC_Click(sender As Object, e As EventArgs)
|
||||
LblTC.Text = GlobalTipoCambio(TxtFecha.Text.ToDate).ToString.FormatoNumero(4)
|
||||
TxtTC.Text = GlobalTipoCambio(TxtFecha.Text.ToDate).ToString.FormatoNumero(4)
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " CONVERTIR PESOS "
|
||||
Protected Sub BtnConvertirPesos_Click(sender As Object, e As EventArgs)
|
||||
Dim TipoCambioTemp = TxtConvertirPesos.Text.ToDouble
|
||||
@@ -16139,9 +16169,9 @@ Partial Class Compras_Compras
|
||||
|
||||
DdlMoneda.Enabled = False
|
||||
RegistraScript("$('#ModalPesos').modal('hide');")
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " TOTALES: VALIDA Y CALCULA "
|
||||
Private Sub AsignaValoresOriginales(SubTotal As Double, SubTotal2 As Double, IVA As Double, RetIVA As Double, RetISR As Double, Total As Double)
|
||||
SubTotalOriginal = SubTotal
|
||||
@@ -16359,9 +16389,9 @@ Partial Class Compras_Compras
|
||||
Next
|
||||
UpPS.Update()
|
||||
RegistraScript(String.Format("$('#{0}').modal('hide');", "divAddAcarreo"))
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "Historial de Modificacion"
|
||||
Private Sub CargaGvBitacora()
|
||||
' COMENTADO POR IPP PARA SUBIR 5 ABRIL 2017
|
||||
@@ -16371,11 +16401,11 @@ Partial Class Compras_Compras
|
||||
GvBitacora.DataBind()
|
||||
End If
|
||||
ObjGral.Dispose()
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " FLETES "
|
||||
|
||||
|
||||
Private Sub CargaFletes()
|
||||
|
||||
If UsuarioActual.CveEmpresa <> 125 Or CveCompra > 0 Then
|
||||
@@ -16394,13 +16424,13 @@ Partial Class Compras_Compras
|
||||
UpFletes.Update()
|
||||
|
||||
ObjVentas.Dispose()
|
||||
End Sub
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "I M P R I M I R D E S G L O S E"
|
||||
|
||||
|
||||
Private Sub LnkExportaGv_Click(sender As Object, e As EventArgs) Handles LnkExportaGv.Click
|
||||
Dim dt As New DataTable
|
||||
dt.Columns.Add("Consecutivo", GetType(Integer))
|
||||
@@ -16424,14 +16454,14 @@ Partial Class Compras_Compras
|
||||
dt.Rows.Add(Row)
|
||||
Next
|
||||
ExportToExcel(dt, "Desglose")
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
'DE AQUI PARA ABAJO SE ESTAN REORDENANDO REGIONES --- FAVOR DE SI SE MUEVE UNA COSITA O SE HACE UNA NUEVA FUNCION/METODO AGRUPARLO EN LA REGION CORRECTA O GENERAR UNA EN CASO DE NO EXISTIR
|
||||
|
||||
|
||||
|
||||
|
||||
'DE AQUI PARA ABAJO SE ESTAN REORDENANDO REGIONES --- FAVOR DE SI SE MUEVE UNA COSITA O SE HACE UNA NUEVA FUNCION/METODO AGRUPARLO EN LA REGION CORRECTA O GENERAR UNA EN CASO DE NO EXISTIR
|
||||
|
||||
|
||||
#Region " MODAL ADD PS - AGREGAR Y EDITAR PS (PARTIDA-CONCEPTO) "
|
||||
Private Sub HabilitaEdicionManualAgregar()
|
||||
If Not (CveCompra > 0 Or CveFactura > 0 Or OCVinculada) Then
|
||||
@@ -17139,9 +17169,9 @@ Partial Class Compras_Compras
|
||||
AddPS2(AplicaCalculaTotales)
|
||||
CargaGvInv()
|
||||
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " RECLASIFICA PARTIDAS - CLASIFICACION - SUBPROYECTO "
|
||||
Private Sub CargaClasificaciones()
|
||||
If UsuarioActual.Empresa.UsaAC Then
|
||||
@@ -17313,10 +17343,10 @@ Partial Class Compras_Compras
|
||||
|
||||
Alert("Los tipos de gastos han sido cambiados correctamente", TipoMensaje.MsgInformacion)
|
||||
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " PS ALIAS "
|
||||
Protected Sub DdlPSAlias_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlPSAlias2.selectedindexchange
|
||||
If Not DdlPSAlias2.SelectedValue = "" Then
|
||||
@@ -17386,9 +17416,9 @@ Partial Class Compras_Compras
|
||||
GlobalDTProductosServiciosEquivalencias(-1, -1) = ObjPS.DtResultados
|
||||
End If
|
||||
ObjPS.Dispose()
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " UM: ALIAS - EQUIVALENCIAS "
|
||||
Private Sub CargarUMAlias()
|
||||
DdlUMAlias.DataSource = GlobalDTUnidadesMedida(UsuarioActual.CveEmpresa)
|
||||
@@ -17554,12 +17584,12 @@ Partial Class Compras_Compras
|
||||
|
||||
ObjPS.Dispose()
|
||||
OjbUM.Dispose()
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " COMPLEMENTOS PAGO "
|
||||
|
||||
|
||||
Private Sub CargaComplementosPago()
|
||||
|
||||
Dim ObjCompras As New ClsCompras
|
||||
@@ -17587,11 +17617,11 @@ Partial Class Compras_Compras
|
||||
e.Row.Cells(3).Text = String.Format("<a class=""texto"" href=""/Compras/PopUpVerFactura.aspx?P={0}"" target=""_blank""><i class=""fa fa-ad-excel""></i></a>", Encripta(String.Format("OP=Fact&EXT=xml&CveFactura={0}&RFC={1}", e.Row.DBCampo("CveFactura"), e.Row.DBCampo(("RFCde").ToString.Replace("&", "%26%")))))
|
||||
e.Row.Cells(4).Text = String.Format("<a class=""texto"" href=""/Compras/PopUpVerFactura.aspx?P={0}"" target=""_blank""><i class=""fa fa-ad-pdf""></i></a>", Encripta(String.Format("OP=Fact&EXT=pdf&CveFactura={0}&RFC={1}", e.Row.DBCampo("CveFactura"), e.Row.DBCampo("RFCde").ToString.Replace("&", "%26%"))))
|
||||
End If
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " OTROS GASTOS "
|
||||
|
||||
|
||||
Protected Sub LnkAddOtrosGastos_Click(sender As Object, e As EventArgs)
|
||||
DdlOrdenCorte.SelectedIndex = 0
|
||||
DdlOrdenCorte.SelectedValueExist(CveOrdenCorte)
|
||||
@@ -17602,18 +17632,18 @@ Partial Class Compras_Compras
|
||||
Protected Sub BtnAddOtrosGastos_Click(sender As Object, e As EventArgs)
|
||||
CveOrdenCorte = DdlOrdenCorte.SelectedValue.ToEntero()
|
||||
RegistraScript("$('#DivOtrosGastos').modal('hide');")
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
'#Region " DROPDOWN IVA "
|
||||
' 'Protected Sub DdlIVA_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
' ' CalculaTotales(True)
|
||||
' 'End Sub
|
||||
'#End Region
|
||||
|
||||
|
||||
'#Region " DROPDOWN IVA "
|
||||
' 'Protected Sub DdlIVA_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
' ' CalculaTotales(True)
|
||||
' 'End Sub
|
||||
'#End Region
|
||||
|
||||
#Region " APLICA NC "
|
||||
|
||||
|
||||
Private Sub InicializaAplicaNCFact()
|
||||
HLAplicaNCFact.Visible = True
|
||||
LblTotalNC.Text = TxtTotal.Text.FormatoNumero
|
||||
@@ -17641,10 +17671,10 @@ Partial Class Compras_Compras
|
||||
e.Row.FCCheckBox("ChkFacturaNC").Attributes.Add("onclick", $"FnCambiaFacturaNC({e.Row.DBCampo("Saldo").ToDouble},{e.Row.FCTextBox("TxtImporte").ClientID},{TxtTotal.Text.ToDouble},{LblAplicado.ClientID}, this);")
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " DEVOLUCION DE ALMACEN - DEVOLUCION AL PROVEEDOR "
|
||||
Private Sub InicializaDevolucionAlmacen()
|
||||
If Not GvInv.Rows.Count > 0 Or LblCompraEstatus.Text = "CANCELADA" Then
|
||||
@@ -17835,9 +17865,9 @@ Partial Class Compras_Compras
|
||||
End Sub
|
||||
Protected Sub BtnNCConfirmacion_Click(sender As Object, e As EventArgs)
|
||||
GuardaAnticipos(Nothing, Nothing)
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " INVENTARIO: MOVIMIENTOS DE LA COMPRA "
|
||||
Private Sub InventarioMov()
|
||||
Dim ObjVentas As New ClsInventarios
|
||||
@@ -17875,11 +17905,11 @@ Partial Class Compras_Compras
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
e.Row.FCLiteral("LtlImporte").Text = "$" + FormatNumber(e.Row.FCLiteral("LtlImporte").Text.ToDouble, 2, , , TriState.True)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " REGENERA PREPOLIZA "
|
||||
Protected Sub BtnRegenerarPrePolizaAlmacen_Click(sender As Object, e As EventArgs)
|
||||
'RegeneraPrePoliza()
|
||||
@@ -18144,9 +18174,9 @@ Partial Class Compras_Compras
|
||||
|
||||
ObjConta.Dispose()
|
||||
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " ACTUALIZAR TIPO CAMBIO PREPOLIZA "
|
||||
Private Sub InicializaActualizarTC()
|
||||
If CveCompra > 0 And DdlMoneda.SelectedValue.ToEntero = 2 And CvePrePoliza > 0 Then
|
||||
@@ -18187,16 +18217,16 @@ Partial Class Compras_Compras
|
||||
End If
|
||||
|
||||
ObjContabilidad.Dispose()
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "PAQUETERIAS GUIAS"
|
||||
Protected Sub LnkAgregarGuia_Click(sender As Object, e As EventArgs)
|
||||
'' 25/05/2018 - Se agrega Link a Modulo Paqueterias Guias
|
||||
RegistraScript(String.Format("AbrirVentana('/General/PopUpPaqueteriasGuias.aspx?CveCompra={0}',800,620);", CveCompra))
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "DEDUCCIONES IEPS / OTROS IMPUESTOS"
|
||||
Protected Sub CargaProductos(Ddl As DropDownList, CvePS As Integer)
|
||||
Ddl.DataSource = TmpDT
|
||||
@@ -18251,11 +18281,11 @@ Partial Class Compras_Compras
|
||||
Alert("Debe seleccionar al menos un impuesto", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "C R E D I T O S"
|
||||
|
||||
|
||||
Private Sub ChkCreditoMultiple_CheckedChanged(sender As Object, e As EventArgs) Handles ChkCreditoMultiple.CheckedChanged
|
||||
|
||||
If ChkCreditoMultiple.Checked Then
|
||||
@@ -18336,9 +18366,9 @@ Partial Class Compras_Compras
|
||||
|
||||
UpGvCreditos.Update()
|
||||
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "FLETES / IMPORTACIONES"
|
||||
Private Sub CargaFolio()
|
||||
Dim ObjFolios As New ClsGralFolios
|
||||
@@ -18632,10 +18662,10 @@ Partial Class Compras_Compras
|
||||
Protected Sub DdlFleteImportacion_SelectedIndexChanged1(sender As Object, e As EventArgs)
|
||||
CambiaTipo()
|
||||
UpModalFletesImportaciones.Update()
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
Private Function AjustarPrePolizaVinculacionOC(ByRef OC As ClsOC, ByRef OCBitacora As ClsOIEventos, ByRef ObjInventarios As ClsInventarios, ByRef ObjConta As ClsContabilidad, ByRef ObjAC As ClsContPAQi) As Boolean
|
||||
|
||||
'VARIABLES
|
||||
@@ -18874,8 +18904,8 @@ Partial Class Compras_Compras
|
||||
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
End Function
|
||||
|
||||
#Region "A G R E G A R - P R O D U C T O S S E R V I C I O S"
|
||||
Private Sub CargaDatosAgregarPS()
|
||||
DdlClasificacionPS.Items.Clear()
|
||||
@@ -18929,27 +18959,27 @@ Partial Class Compras_Compras
|
||||
If ObjPS.GetPSSimplificado(-1) Then Application("GlobalDTPSSimplificado") = ObjPS.DtResultados.AsEnumerable()
|
||||
|
||||
ObjPS.Dispose()
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "TIPO DE COMPRA"
|
||||
|
||||
|
||||
Protected Sub DdlTipoCompra_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
|
||||
|
||||
Protected Sub BtnFacturaNC_Click(sender As Object, e As EventArgs)
|
||||
If ChkNCInvNC.Checked Then
|
||||
CargaNCINV()
|
||||
Else
|
||||
RegistraScript("$('#FacturaNC').modal('hide');", "FacturaNC")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Sub
|
||||
|
||||
#Region "ES NO DEDUCIBLE"
|
||||
Protected Sub ChkEsNoDeducible_CheckedChanged1(sender As Object, e As EventArgs)
|
||||
If ChkEsNoDeducible.Checked Then
|
||||
@@ -18982,9 +19012,9 @@ Partial Class Compras_Compras
|
||||
'TmpDT.AcceptChanges()
|
||||
AddPS2(EsNoDeducible:=EsNoDeducible)
|
||||
UpPS.Update()
|
||||
End Sub
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
Public Sub LnkDesVincularComplemento_Click(sender As Object, e As EventArgs)
|
||||
|
||||
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
|
||||
|
||||
@@ -656,7 +656,7 @@ Partial Class Compras_ReembolsosComprobaciones
|
||||
End If
|
||||
End If
|
||||
|
||||
If gvr.DataKey("Original").ToDecimal > 0 Then PorcentajePago = (ImporteMovto / gvr.DataKey("Original").ToDecimal).RoundSQL(6) Else PorcentajePago = 1
|
||||
If gvr.DataKey("Original").ToDecimal > 0 Then PorcentajePago = (ImporteMovto / gvr.DataKey("Original").ToDecimal).RoundSQL Else PorcentajePago = 1
|
||||
|
||||
If Not ChkReembolsarSinBancos.Checked AndAlso (Not HdnCheque.Value.ToEntero > 0 Or Not UsuarioActual.CveEmpresa.Contiene(119)) Then
|
||||
'Si es caja chica metemos el concepto 30, si es funcionario metemos 29
|
||||
@@ -984,7 +984,7 @@ Partial Class Compras_ReembolsosComprobaciones
|
||||
End If
|
||||
End If
|
||||
|
||||
If gvr.DataKey("Original").ToDecimal > 0 Then PorcentajePago = (ImporteMovto / gvr.DataKey("Original").ToDecimal).RoundSQL(6) Else PorcentajePago = 1
|
||||
If gvr.DataKey("Original").ToDecimal > 0 Then PorcentajePago = (ImporteMovto / gvr.DataKey("Original").ToDecimal).RoundSQL Else PorcentajePago = 1
|
||||
|
||||
If Not ObjMov.AddPrePolizasDetalle(CvePrePolizaExcedente, True, ImporteMovto, Referencia, 17, ConceptoMovimiento, gvr.FCLiteral("LtlFecha").Text.ToDate, IdCtaProveedor, -1, CveIE:=CveIEExcedente, CveCompra:=gvr.FCHyperLink("HplF2").Text.ToEntero, CveProveedor:=gvr.FCHyperLink("HLProv").Text.ToEntero, ImporteME:=If(tipoCambio = 1, 0, ImporteMovto), ImporteMX:=(ImporteMovto * tipoCambio), CveCuenta:=CveCuentaProveedor) Then
|
||||
MsgError = "Detalle"
|
||||
|
||||
Binary file not shown.
@@ -601,6 +601,20 @@
|
||||
<FontSize>9pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value> - </Value>
|
||||
<Style>
|
||||
<FontFamily>Myriad Pro</FontFamily>
|
||||
<FontSize>9pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value>=Parameters!ClienteNombre.Value</Value>
|
||||
<Style>
|
||||
<FontFamily>Myriad Pro</FontFamily>
|
||||
<FontSize>9pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
</TextRuns>
|
||||
<Style>
|
||||
<TextAlign>Left</TextAlign>
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
<Style />
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value>=Parameters!NombreCliente.Value</Value>
|
||||
<Value>=Parameters!NombreDistribuidor.Value</Value>
|
||||
<Style />
|
||||
</TextRun>
|
||||
</TextRuns>
|
||||
@@ -1933,6 +1933,12 @@
|
||||
<AllowBlank>true</AllowBlank>
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
<ReportParameter Name="NombreDistribuidor">
|
||||
<DataType>String</DataType>
|
||||
<Nullable>true</Nullable>
|
||||
<AllowBlank>true</AllowBlank>
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
</ReportParameters>
|
||||
<Language>Es-MX</Language>
|
||||
<rd:ReportUnitType>Inch</rd:ReportUnitType>
|
||||
|
||||
3871
GPS/Rastreo.aspx
3871
GPS/Rastreo.aspx
File diff suppressed because it is too large
Load Diff
@@ -617,10 +617,16 @@ Partial Class GPS_Rastreo
|
||||
|
||||
AddRowPosiciones(Vehiculo, Coord, row("SPD").ToString.ToDouble, Fecha, row("CveDispositivo").ToString.ToEntero, row("TiempoDetenido").ToString.ToDouble)
|
||||
Next
|
||||
|
||||
If ChkTrazarGeocercas.Checked Then
|
||||
Dim Dispositivos As String = Equipos.Replace(";", ",").Remove(Equipos.Length - 1, 1)
|
||||
CargaGeocercas(Dispositivos)
|
||||
End If
|
||||
|
||||
If ChkTrazarGeorutas.Checked Then
|
||||
MostarGeoRutas()
|
||||
End If
|
||||
|
||||
RegistraScript("setTimeout(function(){ $('#LnkMostarGeocercas').css('display', 'block'); },1000);")
|
||||
Else
|
||||
Alert($"No se encontraron resultados", TipoMensaje.MsgAdvertencia)
|
||||
@@ -715,6 +721,21 @@ Partial Class GPS_Rastreo
|
||||
SbJS.Append(" VerGeocercas(); },1000);")
|
||||
RegistraScript(SbJS.ToString)
|
||||
End If
|
||||
End Sub
|
||||
Private Sub MostarGeoRutas()
|
||||
Dim count = 0
|
||||
RegistraScript($"initGeoRutas();", count.ToString())
|
||||
|
||||
For Each GvRow As GridViewRow In GvGeorutas.Rows
|
||||
If GvRow.RowType = DataControlRowType.DataRow Then
|
||||
If GvRow.FCCheckBox("ChkRutas").Checked Then
|
||||
count += 1
|
||||
Dim Coord As String = SQLToGmaps(GvRow.DataKey("Coordenadas").ToString, "LINESTRING")
|
||||
RegistraScript($"creaPolylineRuta({Coord}, '{GvRow.DataKey("Color").ToString}', '{GvRow.DataKey("GeoReferencia")}')", count.ToString())
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
|
||||
End Sub
|
||||
Protected Sub TimmerRefresh_Tick(sender As Object, e As EventArgs)
|
||||
|
||||
@@ -1136,6 +1157,7 @@ Partial Class GPS_Rastreo
|
||||
dvDispositivos.Visible = True
|
||||
dvTrazo.Visible = False
|
||||
dvTrazoGeo.Visible = True
|
||||
dvTrazoRutas.Visible = True
|
||||
ChkTrazarGeocercas.Visible = True
|
||||
dvMinutos.Visible = False
|
||||
RegistraScript("$('#dvConsulta').modal();TerminaDibujado();")
|
||||
@@ -1148,7 +1170,8 @@ Partial Class GPS_Rastreo
|
||||
dvDispositivos.Visible = True
|
||||
txtFechaF.Text = ""
|
||||
dvTrazo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoRutas.Visible = False
|
||||
dvMinutos.Visible = False
|
||||
BtnRastrear.ValidationGroup = "GrpFechas"
|
||||
RegistraScript("$('#dvConsulta').modal();TerminaDibujado();")
|
||||
@@ -1160,6 +1183,7 @@ Partial Class GPS_Rastreo
|
||||
txtFechaF.Text = ""
|
||||
dvTrazo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoRutas.Visible = False
|
||||
dvDispositivos.Visible = True
|
||||
dvMinutos.Visible = False
|
||||
GvDispositivos.DataSource = GlobalDTDispositivosUsuarios(UsuarioActual.CveCliente, UsuarioActual.CveUsuario).FiltraParametros("Estatus = 1 AND LimiteVelocidad = 1")
|
||||
@@ -1175,7 +1199,8 @@ Partial Class GPS_Rastreo
|
||||
txtFechaF.Text = ""
|
||||
dvDispositivos.Visible = True
|
||||
dvTrazo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoRutas.Visible = False
|
||||
dvMinutos.Visible = True
|
||||
dvEventos.Visible = False
|
||||
BtnRastrear.ValidationGroup = "GrpFechas"
|
||||
@@ -1188,6 +1213,7 @@ Partial Class GPS_Rastreo
|
||||
dvDispositivos.Visible = True
|
||||
dvTrazo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoRutas.Visible = False
|
||||
dvMinutos.Visible = False
|
||||
dvEventos.Visible = False
|
||||
BtnRastrear.ValidationGroup = "GrpFechas"
|
||||
@@ -1198,6 +1224,7 @@ Partial Class GPS_Rastreo
|
||||
dvDispositivos.Visible = True
|
||||
dvTrazo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoRutas.Visible = False
|
||||
dvMinutos.Visible = False
|
||||
dvEventos.Visible = False
|
||||
BtnRastrear.ValidationGroup = "xx"
|
||||
@@ -1208,6 +1235,7 @@ Partial Class GPS_Rastreo
|
||||
dvMinutos.Visible = False
|
||||
dvTrazo.Visible = True
|
||||
dvTrazoGeo.Visible = True
|
||||
dvTrazoRutas.Visible = True
|
||||
dvEventos.Visible = False
|
||||
BtnRastrear.ValidationGroup = "xx"
|
||||
RegistraScript("$('#dvConsulta').modal();TerminaDibujado();")
|
||||
@@ -1219,7 +1247,8 @@ Partial Class GPS_Rastreo
|
||||
dvDispositivos.Visible = True
|
||||
dvMinutos.Visible = False
|
||||
dvTrazo.Visible = True
|
||||
dvTrazoGeo.Visible = True
|
||||
dvTrazoGeo.Visible = True
|
||||
dvTrazoRutas.Visible = True
|
||||
dvEventos.Visible = False
|
||||
BtnRastrear.ValidationGroup = "xx"
|
||||
RegistraScript("$('#dvConsulta').modal();TerminaDibujado();")
|
||||
@@ -1229,7 +1258,8 @@ Partial Class GPS_Rastreo
|
||||
dvDispositivos.Visible = False
|
||||
dvMinutos.Visible = False
|
||||
dvTrazo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoGeo.Visible = False
|
||||
dvTrazoRutas.Visible = False
|
||||
dvEventos.Visible = False
|
||||
BtnRastrear.ValidationGroup = "xx"
|
||||
RegistraScript("$('#dvConsulta').modal();TerminaDibujado();")
|
||||
@@ -1246,6 +1276,11 @@ Partial Class GPS_Rastreo
|
||||
RegistraScript("$('#dvConsulta').modal();TerminaDibujado();")
|
||||
myModalLabel2.InnerHtml = "Contador de pasajeros"
|
||||
End If
|
||||
If dvTrazoRutas.Visible Then
|
||||
CargaGeoRutas()
|
||||
Else
|
||||
RegistraScript("$('#LnkMostarGeoRutas').css('display', 'none');")
|
||||
End If
|
||||
If opcion <> "Speed" AndAlso opcion <> "TPS" AndAlso Filtrado Then
|
||||
CargaDispositivos()
|
||||
Filtrado = False
|
||||
@@ -2122,5 +2157,24 @@ Partial Class GPS_Rastreo
|
||||
End Try
|
||||
End Using
|
||||
Return retorno
|
||||
End Function
|
||||
End Function
|
||||
#Region "G E O R U T A S"
|
||||
Protected Sub ChkTrazarGeorutas_CheckedChanged(sender As Object, e As EventArgs)
|
||||
If ChkTrazarGeorutas.Checked Then
|
||||
RegistraScript("$('#DivGeoRutas').modal('show');")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub CargaGeoRutas()
|
||||
Dim ObjGPS As New ClsGPS
|
||||
If ObjGPS.GeoReferenciaGet(-1, 1, "Ruta", UsuarioActual.CveCliente) Then
|
||||
GvGeorutas.DataSource = ObjGPS.DtResultados
|
||||
End If
|
||||
ObjGPS.Dispose()
|
||||
GvGeorutas.DataBind()
|
||||
|
||||
UpGeorutas.Update()
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
End Class
|
||||
|
||||
145
GPS/Rastreo/JS/GeoRutas.js
Normal file
145
GPS/Rastreo/JS/GeoRutas.js
Normal file
@@ -0,0 +1,145 @@
|
||||
//REGION GEORUTAS
|
||||
var markersRutas = [];
|
||||
var polylinesGeoRutas = [];
|
||||
var polybounds = [];
|
||||
|
||||
function initGeoRutas() {
|
||||
NuevaConsultaGeoRutas();
|
||||
var upRutasDiv = document.createElement('div');
|
||||
var upRutas = new ControlGeoRutas(upRutasDiv, map);
|
||||
|
||||
map.controls[google.maps.ControlPosition.TOP_LEFT].push(upRutasDiv);
|
||||
}
|
||||
|
||||
function creaPolylineRuta(coords, color, GeoCerca) {
|
||||
var polyline = new google.maps.Polyline({
|
||||
path: coords,
|
||||
strokeColor: color,
|
||||
strokeOpacity: 0.8,
|
||||
strokeWeight: 2,
|
||||
fillOpacity: 0.35
|
||||
});
|
||||
|
||||
polyline.setMap(map);
|
||||
polylinesGeoRutas.push(polyline);
|
||||
polybounds.push(coords[0]);
|
||||
polybounds.push(coords[coords.length - 1]);
|
||||
CreaMarcadorPoligonoRuta(coords, GeoCerca);
|
||||
}
|
||||
|
||||
function CreaMarcadorPoligonoRuta(coords, GeoCerca) {
|
||||
var bounds = new google.maps.LatLngBounds();
|
||||
for (i = 0; i < coords.length; i++) {
|
||||
bounds.extend(coords[i]);
|
||||
}
|
||||
|
||||
var marker = new google.maps.Marker({
|
||||
position: bounds.getCenter(),
|
||||
title: GeoCerca,
|
||||
map: map
|
||||
});
|
||||
|
||||
var infowindow = new google.maps.InfoWindow({
|
||||
content: '<h4><b>' + GeoCerca + '</b></h4>'
|
||||
});
|
||||
|
||||
marker.addListener('click', function () {
|
||||
closeLastOpenedInfoWindow();
|
||||
infowindow.open(map, marker);
|
||||
lastOpenedInfoWindow = infowindow;
|
||||
});
|
||||
|
||||
markersRutas.push(marker);
|
||||
}
|
||||
|
||||
function NuevaConsultaGeoRutas() {
|
||||
|
||||
for (var i = 0; i < polylinesGeoRutas.length; i++) {
|
||||
polylinesGeoRutas[i].setMap(null);
|
||||
}
|
||||
|
||||
for (var i = 0; i < markersRutas.length; i++) {
|
||||
markersRutas[i].setMap(null);
|
||||
}
|
||||
|
||||
polylinesGeoRutas = [];
|
||||
polybounds = [];
|
||||
markersRutas = [];
|
||||
}
|
||||
|
||||
function ControlGeoRutas(controlDiv, map) {
|
||||
|
||||
// Set CSS for the control border.
|
||||
var controlUI = document.createElement('div');
|
||||
controlUI.style.marginLeft = '10px';
|
||||
controlUI.style.zIndex = '0';
|
||||
controlUI.style.cursor = 'pointer';
|
||||
// controlUI.style.position = 'absolute';
|
||||
controlUI.style.left = "0px";
|
||||
controlUI.style.width = "150px";
|
||||
controlUI.style.marginTop = "10px"
|
||||
controlUI.style.top = "0px";
|
||||
controlUI.className = 'gmnoprint';
|
||||
|
||||
controlDiv.appendChild(controlUI);
|
||||
|
||||
var ControlSub1 = document.createElement('div')
|
||||
ControlSub1.style.float = 'left';
|
||||
ControlSub1.className = 'gm-style-mtc'
|
||||
controlUI.appendChild(ControlSub1)
|
||||
|
||||
var ControlSub2 = document.createElement('div')
|
||||
ControlSub2.style.direction = 'ltr';
|
||||
ControlSub2.style.overflow = 'hidden';
|
||||
ControlSub2.id = "LnkMostarGeoRutas"
|
||||
ControlSub2.style.textAlign = 'center';
|
||||
ControlSub2.style.position = 'relative';
|
||||
ControlSub2.style.color = 'rgb(0,0,0)';
|
||||
ControlSub2.style.fontFamily = ' "Open Sans", sans-serif; ';
|
||||
ControlSub2.style.msUserSelect = 'none;';
|
||||
ControlSub2.style.fontSize = '11px'
|
||||
ControlSub2.style.display = 'block'
|
||||
ControlSub2.style.backgroundColor = 'rgb(255,255,255)'
|
||||
ControlSub2.style.padding = '11px'
|
||||
ControlSub2.style.backgroundClip = 'padding-box'
|
||||
ControlSub2.style.minWidth = '28px'
|
||||
ControlSub2.style.fontWeight = '500'
|
||||
ControlSub2.style.boxShadow = '0 1px 4px -1px rgba(0,0,0,.3)';
|
||||
ControlSub2.innerHTML = 'Mostrar GeoRutas'
|
||||
ControlSub1.appendChild(ControlSub2)
|
||||
|
||||
ControlSub1.addEventListener('click', function () {
|
||||
VerGeoRutas();
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
var IsRutasVisibles = false;
|
||||
|
||||
function VerGeoRutas() {
|
||||
if (IsRutasVisibles) {
|
||||
HideGeoRutas();
|
||||
IsRutasVisibles = false;
|
||||
} else {
|
||||
CargaGeoRutas();
|
||||
IsRutasVisibles = true;
|
||||
}
|
||||
}
|
||||
|
||||
function HideGeoRutas() {
|
||||
for (var i = 0; i < polylinesGeoRutas.length; i++) {
|
||||
polylinesGeoRutas[i].setMap(null);
|
||||
}
|
||||
for (var j = 0; j < markersRutas.length; j++) {
|
||||
markersRutas[j].setMap(null);
|
||||
}
|
||||
}
|
||||
|
||||
function CargaGeoRutas() {
|
||||
for (var i = 0; i < polylinesGeoRutas.length; i++) {
|
||||
polylinesGeoRutas[i].setMap(map);
|
||||
}
|
||||
for (var j = 0; j < markersRutas.length; j++) {
|
||||
markersRutas[j].setMap(map);
|
||||
}
|
||||
}
|
||||
@@ -110,6 +110,14 @@
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="TxtFechaF" PopupButtonID="ImgFechaF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-md-1 truncate" style="width:120px">Producto:</label>
|
||||
<div class="col-md-1">
|
||||
<asp:DropDownList ID="DdlExistencia" runat="server" CssClass="select2me">
|
||||
<asp:ListItem Text="Todos" Value="1" />
|
||||
<asp:ListItem Text="Con existencia" Value="2" />
|
||||
<asp:ListItem Text="Sin existencia" Value="3" />
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -169,6 +177,7 @@
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Left">
|
||||
<HeaderTemplate>
|
||||
Código
|
||||
|
||||
</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<div class='truncate' style='width: 200px;'>
|
||||
@@ -179,6 +188,7 @@
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Left">
|
||||
<HeaderTemplate>
|
||||
Producto
|
||||
|
||||
</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<div class='truncate' style='width: 200px;'>
|
||||
|
||||
@@ -128,7 +128,7 @@ Partial Class Inventarios_KardexAlmacen
|
||||
Dim CveAlmacen As Integer = ddlAlmacen.SelectedValue.ToEntero
|
||||
Dim CveProveedorCompra As Integer = If(DdlProveedor.SelectedValue.ToEntero > 0, DdlProveedor.SelectedValue.ToEntero, -1)
|
||||
|
||||
If ObjMovimientos.GetKardexAlmacenHorizontal(CvePS, FechaF, CveAlmacen, DdlUnidadMedida.SelectedValue.ToEntero, CveProveedorCompra, DdlTipoAlmacen.SelectedValue.ToEntero(), If(ChkIncluyeTransitorios.Checked, 1, 0), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) Then
|
||||
If ObjMovimientos.GetKardexAlmacenHorizontal(CvePS, FechaF, CveAlmacen, DdlUnidadMedida.SelectedValue.ToEntero, CveProveedorCompra, DdlTipoAlmacen.SelectedValue.ToEntero(), If(ChkIncluyeTransitorios.Checked, 1, 0), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CondicionExistencias:=DdlExistencia.SelectedValue) Then
|
||||
If ObjMovimientos.DtResultados IsNot Nothing AndAlso ObjMovimientos.DtResultados.Rows.Count > 0 Then
|
||||
dt = ObjMovimientos.DtResultados
|
||||
Dim ListaBorrar As New List(Of DataColumn)
|
||||
@@ -137,9 +137,9 @@ Partial Class Inventarios_KardexAlmacen
|
||||
For Each Dr As DataRow In dt.Rows
|
||||
TotColumna += Dr.Item(index).ToString.ToDouble
|
||||
Next
|
||||
If Not TotColumna > 0 Then
|
||||
ListaBorrar.Add(dt.Columns(index))
|
||||
End If
|
||||
'If Not TotColumna > 0 Then
|
||||
' ListaBorrar.Add(dt.Columns(index))
|
||||
'End If
|
||||
Next
|
||||
For Each item As DataColumn In ListaBorrar
|
||||
dt.Columns().Remove(item)
|
||||
@@ -226,7 +226,7 @@ Partial Class Inventarios_KardexAlmacen
|
||||
e.Row.Cells(2).Visible = False
|
||||
e.Row.Cells(3).Visible = False
|
||||
If e.Row.RowType = DataControlRowType.Header Then
|
||||
e.Row.Cells(6).ToolTip = "Costo Promedio"
|
||||
'e.Row.Cells(6).ToolTip = "Costo"
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -2171,11 +2171,19 @@
|
||||
<div class="form-group ">
|
||||
<label class="col-md-2" for="<%= DDLUsuarioNomina.ClientID.ToString()%>">Nominista:</label>
|
||||
<asp:DropDownList ID="DDLUsuarioNomina" runat="server" CssClass="select2me" Width="200px" DataTextField="Nombre" DataValueField="CveUsuario">
|
||||
|
||||
<asp:ListItem Selected="True" Value="-1">Seleccione uno</asp:ListItem>
|
||||
<asp:ListItem Value="1446">Alicia Cordova</asp:ListItem>
|
||||
|
||||
<asp:ListItem Value="79">Pamela Cabrera</asp:ListItem>
|
||||
<asp:ListItem Value="2625">Paola Guerrereo</asp:ListItem>
|
||||
<asp:ListItem Value="2626">Lucero Millanes</asp:ListItem>
|
||||
|
||||
<%--<asp:ListItem Value="1446">Alicia Cordova</asp:ListItem>
|
||||
<asp:ListItem Value="16">Matilde Gonzalez</asp:ListItem>
|
||||
<asp:ListItem Value="1670">Claudia Hernandez</asp:ListItem>
|
||||
<asp:ListItem Value="1670">Claudia Hernandez</asp:ListItem>--%>
|
||||
|
||||
|
||||
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator InitialValue="-1" ID="rfvDDLUsuarioNomina" Enabled="true" CssClass="help-block errorimput" Display="none" ControlToValidate="DDLUsuarioNomina" ValidationGroup="FirmaDocumentos" runat="server" Text="*" ErrorMessage="Seleccione una de las opciones"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="rfvcDDLUsuarioNomina" runat="server" HighlightCssClass="vco" TargetControlID="rfvDDLUsuarioNomina" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
@@ -5352,7 +5352,8 @@ Partial Class RH_Reclutamiento
|
||||
End If
|
||||
Dim CveCaptacion As Integer = If(DdlCaptacion.SelectedValue.ToEntero = 0, -1, DdlCaptacion.SelectedValue.ToEntero)
|
||||
|
||||
Edad = Now.Year - TxtFechaN4.Text.ToDate.Year
|
||||
Edad = Now.Year - TxtFechaN4.Text.ToDate.Year
|
||||
|
||||
If ValidaGuardaFirmaContratoEvento() Then
|
||||
If objRh.PersonalReclutamientoUpdate(CvePersonal, TxtNombres4.Text, TxtAPaterno4.Text, TxtAmaterno4.Text, TxtEstatura4.Text.ToDecimal, TxtPeso4.Text.ToDecimal,
|
||||
TxtLugarnacimiento4.Text, TxtContactoEmergencia4.Text, TxtTipoSangre4.Text, TxtViveCon4.Text, txtCasaDondevive4.Text, DDLEstadoCivil4.Text.ToEntero,
|
||||
@@ -5447,7 +5448,10 @@ Partial Class RH_Reclutamiento
|
||||
DdlRuta.Items.Insert(0, New ListItem("Seleccione una ruta", "-1"))
|
||||
|
||||
DDLUsuarioNomina.DataBind()
|
||||
DDLUsuarioNomina.Items.Insert(0, New ListItem("Seleccione uno", "-1"))
|
||||
|
||||
If Not UsuarioActual.CveEmpresa.Contiene(4, 7, 11, 12, 122) Then
|
||||
DDLUsuarioNomina.Items.Insert(0, New ListItem("Seleccione uno", "-1"))
|
||||
End If
|
||||
|
||||
DdlUniforme.DataBind()
|
||||
DdlUniforme.Items.Insert(0, New ListItem("Seleccione uno", "-1"))
|
||||
|
||||
@@ -594,7 +594,7 @@
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright" runat="server" id="DivCargoUsado" visible="false">
|
||||
<label>Cargo Usado:</label>
|
||||
<asp:CheckBox ID="ChkCargoUsado" runat="server" CssClass="make-switchsd" data-size="small" Text="" ClientIDMode="Static" Enabled="false" />
|
||||
<asp:CheckBox ID="ChkCargoUsado" runat="server" CssClass="make-switchsd" data-size="small" Text="" ClientIDMode="Static" Enabled="true" />
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright" runat="server" id="DivBonificacionUsado" visible="false">
|
||||
<label>Bonificación Usado:</label>
|
||||
|
||||
@@ -3862,7 +3862,7 @@ Partial Class Clientes
|
||||
Dim lista = New List(Of CrystalParametro)
|
||||
lista.Add(New CrystalParametro("Empresa", UsuarioActual.Empresa.Empresa))
|
||||
lista.Add(New CrystalParametro("TipoCuentas", DdlTipoCuentasCxC.SelectedItem.Text))
|
||||
lista.Add(New CrystalParametro("NombreCliente", $"Cliente: {LtlCliente.Text}"))
|
||||
lista.Add(New CrystalParametro("NombreCliente", LtlCliente.Text))
|
||||
lista.Add(New CrystalParametro("FechaInicio", If(FI = "-1", "-", FI)))
|
||||
lista.Add(New CrystalParametro("FechaFin", If(FF = "-1", DateTime.Now.ToShortDateString, FF)))
|
||||
lista.Add(New CrystalParametro("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
@@ -3933,7 +3933,7 @@ Partial Class Clientes
|
||||
Dim lista = New List(Of CrystalParametro)
|
||||
lista.Add(New CrystalParametro("Empresa", UsuarioActual.Empresa.Empresa))
|
||||
lista.Add(New CrystalParametro("TipoCuentas", DdlTipoCuentasCxC.SelectedItem.Text))
|
||||
lista.Add(New CrystalParametro("NombreCliente", $"Cliente: {LtlCliente.Text}"))
|
||||
lista.Add(New CrystalParametro("NombreCliente", LtlCliente.Text))
|
||||
lista.Add(New CrystalParametro("FechaInicio", If(FI = "-1", "-", FI)))
|
||||
lista.Add(New CrystalParametro("FechaFin", If(FF = "-1", DateTime.Now.ToShortDateString, FF)))
|
||||
lista.Add(New CrystalParametro("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
@@ -8745,7 +8745,7 @@ Partial Class Clientes
|
||||
|
||||
'If ObjFactura.CveCliente > 0 Then
|
||||
' If TmpDT.Rows.Count > 0 Then
|
||||
' Dim Retorno = ObjFactura.EmitirFactura()
|
||||
' Dim Retorno = ObjFactura.EmitirFactura(false)
|
||||
' For Each Mensaje In Retorno.Mensajes
|
||||
' Alert(Mensaje, If(Retorno.TieneError, TipoMensaje.MsgError, TipoMensaje.MsgInformacion))
|
||||
' Next
|
||||
@@ -8792,14 +8792,16 @@ Partial Class Clientes
|
||||
|
||||
CreaObjetosVenta(2)
|
||||
|
||||
'If ObjFactura.CveCliente > 0 Then
|
||||
' If TmpDT.Rows.Count > 0 Then
|
||||
' Dim Retorno = ObjFactura.EmitirFactura()
|
||||
' For Each Mensaje In Retorno.Mensajes
|
||||
' Alert(Mensaje, If(Retorno.TieneError, TipoMensaje.MsgError, TipoMensaje.MsgInformacion))
|
||||
' Next
|
||||
' End If
|
||||
'End If
|
||||
If ObjFactura.CveCliente > 0 Then
|
||||
If TmpDT.Rows.Count > 0 Then
|
||||
Dim Retorno = ObjFactura.EmitirFactura(False)
|
||||
For Each Mensaje In Retorno.Mensajes
|
||||
Alert(Mensaje, If(Retorno.TieneError, TipoMensaje.MsgError, TipoMensaje.MsgInformacion))
|
||||
Next
|
||||
End If
|
||||
End If
|
||||
|
||||
Alert("Listo")
|
||||
|
||||
CargaUsados()
|
||||
|
||||
@@ -8857,7 +8859,7 @@ Partial Class Clientes
|
||||
e.Row.FCCheckBox("ChkCargo").Visible = False
|
||||
Else
|
||||
e.Row.FCCheckBox("ChkCargo").Checked = False
|
||||
e.Row.FCCheckBox("ChkCargo").Visible = True
|
||||
e.Row.FCCheckBox("ChkCargo").Visible = False 'True
|
||||
End If
|
||||
|
||||
If FacturadoBonificacion Then
|
||||
@@ -9647,29 +9649,29 @@ Partial Class Clientes
|
||||
' ObjVentas.Commit()
|
||||
' CargaUsados()
|
||||
|
||||
' Dim DtDetallesVenta As New DataTable
|
||||
' 'Dim DtDetallesVenta As New DataTable
|
||||
|
||||
' If ObjVentas.GetVentaDetalle(CveVenta) Then
|
||||
' 'If ObjVentas.GetVentaDetalle(CveVenta) Then
|
||||
|
||||
' DtDetallesVenta = ObjVentas.DtResultados
|
||||
' 'CreaObjetosVenta(CveVenta, Serie, Folio, SubTotal, Iva, DtDetallesVenta)
|
||||
' ' DtDetallesVenta = ObjVentas.DtResultados
|
||||
' ' 'CreaObjetosVenta(CveVenta, Serie, Folio, SubTotal, Iva, DtDetallesVenta)
|
||||
|
||||
' ObjFactura.Timbre = PreParaTimbre(ObjFactura, ObjFactura.CveSubProyecto)
|
||||
' ' ObjFactura.Timbre = PreParaTimbre(ObjFactura, ObjFactura.CveSubProyecto)
|
||||
|
||||
' Dim ObjTimbrado As New Timbrado
|
||||
' Dim SeTimbro As Boolean = False
|
||||
' ' Dim ObjTimbrado As New Timbrado
|
||||
' ' Dim SeTimbro As Boolean = False
|
||||
|
||||
' SeTimbro = ObjTimbrado.TimbrarFactura(UsuarioActual, ObjFactura)
|
||||
' ' SeTimbro = ObjTimbrado.TimbrarFactura(UsuarioActual, ObjFactura)
|
||||
|
||||
' If SeTimbro Then
|
||||
' Alert("Se timbro correctamente")
|
||||
' Else
|
||||
' Alert("No se pudo timbrar, intente mas tarde.", TipoMensaje.MsgError)
|
||||
' End If
|
||||
' ' If SeTimbro Then
|
||||
' ' Alert("Se timbro correctamente")
|
||||
' ' Else
|
||||
' ' Alert("No se pudo timbrar, intente mas tarde.", TipoMensaje.MsgError)
|
||||
' ' End If
|
||||
|
||||
' Else
|
||||
' Alert("No se pudo timbrar, no se pudieron obtener los detalles de la venta.", TipoMensaje.MsgError)
|
||||
' End If
|
||||
' 'Else
|
||||
' ' Alert("No se pudo timbrar, no se pudieron obtener los detalles de la venta.", TipoMensaje.MsgError)
|
||||
' 'End If
|
||||
|
||||
' End If
|
||||
|
||||
|
||||
@@ -2793,7 +2793,7 @@
|
||||
<a href="javascript;" class="collapse" data-original-title="" title=""></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="row" style="display:none;">
|
||||
<div class="col-md-12">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlFacturas" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="SerieFolio" DataValueField="CveVenta" OnSelectedIndexChanged="DdlFacturas_SelectedIndexChanged" Width="100%" AutoPostBack="true">
|
||||
@@ -2803,19 +2803,18 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlClientes" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="NombreComercial" DataValueField="CveCliente" Width="100%" AutoPostBack="true">
|
||||
</asp:DropDownList>
|
||||
<label for="<%= DdlClientes.ClientID.ToString()%>">Cliente:</label>
|
||||
<div class="col-md-5">
|
||||
<div >
|
||||
<label for="<%= DdlDistribuidor.ClientID.ToString()%>">Distribuidor:</label><br />
|
||||
<ADS:Dropdownlost ID="DdlDistribuidor" data-metodo="getcliente" CssStyle="width:100%" CssClassDdl="select2me" runat="server" DataTextField="CodigoNombre" DataValueField="CveCliente" Width="300px"></ADS:Dropdownlost>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-9">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlPSAjuste" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="PSCodigo" DataValueField="CvePS" OnSelectedIndexChanged="DdlPSAjuste_selectedindexchange" Width="100%" AutoPostBack="true">
|
||||
</asp:DropDownList>
|
||||
<ADS:DropDownLost ID="DdlPSAjuste" CssStyle="width: 100%;" CssClass=" form-control input-sm DdlPS" IncluyeTodos="false" CssClassDdl="select2me form-control" runat="server" CausesValidation="true" DataTextField="PSCodigo" DataValueField="CvePS" Onselectedindexchange="DdlPSAjuste_selectedindexchange" >
|
||||
</ADS:DropDownLost>
|
||||
<label for="<%= DdlPSAjuste.ClientID.ToString()%>">Producto/Servicio a Recibir:</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1071,6 +1071,7 @@ Partial Class PV
|
||||
CargaSucursales()
|
||||
CargaClasificaciones()
|
||||
CargaPS(-1, DdlPS)
|
||||
CargaPS(-1, DdlPSAjuste)
|
||||
CargaEmpresa()
|
||||
CreaDTVentas()
|
||||
CargaMetodosPago()
|
||||
@@ -4973,16 +4974,6 @@ Partial Class PV
|
||||
UpAjuste.Update()
|
||||
End Sub
|
||||
|
||||
Private Sub CargaClienteAjuste()
|
||||
DdlClientes.Items.Clear()
|
||||
|
||||
DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
||||
DdlClientes.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
|
||||
DdlClientes.DataBind()
|
||||
UpAjuste.Update()
|
||||
End Sub
|
||||
|
||||
Private Sub CargaBCIAjuste()
|
||||
Dim ObjGral As New ClsGenerales
|
||||
If ObjGral.BCIUsadoGet(UsuarioActual.CveEmpresa) Then
|
||||
@@ -5026,8 +5017,8 @@ Partial Class PV
|
||||
|
||||
CreaDTmpDTAjustes()
|
||||
CreaDTmpDTRecepcionUsados()
|
||||
CargaClienteAjuste()
|
||||
CargaBCIAjuste()
|
||||
DdlDistribuidor.setEsWebService(True)
|
||||
DivChkAjuste.Visible = True
|
||||
End Sub
|
||||
|
||||
@@ -5056,7 +5047,7 @@ Partial Class PV
|
||||
End Sub
|
||||
|
||||
Private Sub CargaPSAjuste()
|
||||
DdlPSAjuste.Items.Clear()
|
||||
'DdlPSAjuste.Items.Clear()
|
||||
DtPUFacturas.Rows.Clear()
|
||||
|
||||
If DdlFacturas.SelectedValue.ToEntero > 0 Then
|
||||
@@ -5074,7 +5065,7 @@ Partial Class PV
|
||||
DdlPSAjuste.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa)
|
||||
End If
|
||||
DdlPSAjuste.DataBind()
|
||||
DdlPSAjuste.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
' DdlPSAjuste.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DtPUFacturas.AcceptChanges()
|
||||
UpAjuste.Update()
|
||||
CalculaPorcentajeAjuste()
|
||||
@@ -5109,7 +5100,7 @@ Partial Class PV
|
||||
TxtPorcentajeAjuste.Text = ""
|
||||
TxtPoliza.Text = ""
|
||||
TxtImporteAjuste.Text = ""
|
||||
DdlPSAjuste.SelectedIndex = -1
|
||||
DdlPSAjuste.SelectedValue = "-1"
|
||||
ChkAjuste.Checked = False
|
||||
DivAjuste.Visible = False
|
||||
End Sub
|
||||
@@ -5140,7 +5131,7 @@ Partial Class PV
|
||||
TxtImporteAjuste.Text = Dr("Importe").ToString
|
||||
DdlFacturas.SelectedValueExist(Dr("CveVenta").ToString)
|
||||
CargaPSAjuste()
|
||||
DdlPSAjuste.SelectedValueExist(Dr("CvePS").ToString)
|
||||
DdlPSAjuste.SelectedValue = (Dr("CvePS").ToString)
|
||||
TxtFechaAjuste.Text = Dr("FechaAjuste").ToString.ToDate.ToShortDateString
|
||||
TxtPrecio.Text = Dr("PUFactura").ToString.ToDecimal.FormatoNumero(2)
|
||||
TxtPrecio.Enabled = Not Dr("CveVenta").ToString.ToEntero > 0
|
||||
@@ -5174,7 +5165,7 @@ Partial Class PV
|
||||
|
||||
Protected Sub DdlPSAjuste_selectedindexchange(sender As Object, e As EventArgs)
|
||||
If DdlPSAjuste.SelectedValue.ToEntero > 0 AndAlso DdlFacturas.SelectedValue.ToEntero > 0 Then
|
||||
Dim Index As Integer = DdlPSAjuste.SelectedIndex
|
||||
|
||||
Dim Contador As Integer = 1
|
||||
Dim PUFactura As Decimal = 0
|
||||
For Each Dr As DataRow In DtPUFacturas.Rows
|
||||
@@ -5187,8 +5178,8 @@ Partial Class PV
|
||||
|
||||
End If
|
||||
|
||||
If DdlPSAjuste.SelectedValue.ToEntero > 0 AndAlso Not DdlFacturas.SelectedValue.ToEntero > 0 Then
|
||||
Dim Index As Integer = DdlPSAjuste.SelectedIndex
|
||||
If DdlPSAjuste.SelectedValue.ToEntero > 0 AndAlso DdlFacturas.SelectedValue.ToEntero <= 0 Then
|
||||
|
||||
Dim CvePSParametro As Integer = DdlPSAjuste.SelectedValue.ToEntero
|
||||
Dim PrecioSugerido As Decimal = 0
|
||||
Dim drPS As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CvePSParametro).FiltroPrimero("")
|
||||
@@ -5199,9 +5190,9 @@ Partial Class PV
|
||||
|
||||
TxtPUFactura.Text = PrecioSugerido.FormatoNumero(2)
|
||||
|
||||
End If
|
||||
End If
|
||||
|
||||
If Not DdlPSAjuste.SelectedValue.ToEntero > 0 AndAlso DdlFacturas.SelectedValue.ToEntero > 0 Then
|
||||
If Not DdlPSAjuste.SelectedValue.ToEntero > 0 AndAlso DdlFacturas.SelectedValue.ToEntero > 0 Then
|
||||
TxtPUFactura.Text = ""
|
||||
End If
|
||||
|
||||
@@ -5217,56 +5208,65 @@ Partial Class PV
|
||||
End Sub
|
||||
|
||||
Private Sub CalculaPorcentajeAjuste()
|
||||
If DdlTipoUso.SelectedValue.ToEntero > 0 AndAlso DdlPSAjuste.SelectedValue.ToEntero > 0 AndAlso TxtMesesUso.Text <> "" AndAlso DdlPS.SelectedValue.ToEntero > 0 Then
|
||||
Dim CveMarca As Integer = -1
|
||||
If GlobalDTPS(UsuarioActual.CveEmpresa, DdlPSAjuste.SelectedValue.ToEntero).Rows.Count > 0 Then
|
||||
CveMarca = GlobalDTPS(UsuarioActual.CveEmpresa, DdlPSAjuste.SelectedValue.ToEntero).Rows(0)("CveMarca").ToString.ToEntero
|
||||
End If
|
||||
Dim ObjAcum As New ClsAcumuladores
|
||||
If ObjAcum.GarantiasMesesGet(-1, UsuarioActual.CveEmpresa, CveMarca, DdlTipoUso.SelectedValue.ToEntero, TxtMesesUso.Text.ToEntero) Then
|
||||
If ObjAcum.DtResultados.Rows.Count > 0 Then
|
||||
TxtPorcentajeAjuste.Text = (ObjAcum.DtResultados.Rows(0)("Valor").ToString.ToDouble / 100).ToString
|
||||
|
||||
TxtImporteAjuste.Text = (TxtPorcentajeAjuste.Text.ToDecimal * TxtPUFactura.Text.ToDecimal).FormatoNumero
|
||||
|
||||
Dim CargoVendido As Decimal = 0
|
||||
Dim CargoGarantia As Decimal = 0
|
||||
Dim CveTamaño As Integer = 0
|
||||
|
||||
If DdlPSAjuste.SelectedValue.ToEntero > 0 Then
|
||||
Dim Dr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, DdlPSAjuste.SelectedValue.ToEntero).Rows(0)
|
||||
If Dr IsNot Nothing Then
|
||||
CargoGarantia = Dr("Cargo").ToString.ToDecimal
|
||||
End If
|
||||
End If
|
||||
|
||||
If DdlPS.SelectedValue.ToEntero > 0 Then
|
||||
Dim Dr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, DdlPS.SelectedValue.ToEntero).Rows(0)
|
||||
If Dr IsNot Nothing Then
|
||||
CveTamaño = Dr("CveTamaño").ToString.ToEntero
|
||||
End If
|
||||
End If
|
||||
|
||||
If GlobalDTAcumTamaños.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveTamaño = {CveTamaño}").Rows(0) IsNot Nothing AndAlso GlobalDTAcumTamaños.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveTamaño = {CveTamaño}").Rows.Count > 0 Then
|
||||
Dim DrCargo As DataRow = GlobalDTAcumTamaños.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveTamaño = {CveTamaño}").Rows(0)
|
||||
If DrCargo IsNot Nothing Then
|
||||
CargoVendido = DrCargo("Cargo").ToString.ToDecimal
|
||||
End If
|
||||
End If
|
||||
|
||||
'el ajuste no puede ser mayor al precio de lo vendido de nuevo
|
||||
If (TxtPrecio.Text.ToDouble - ((TxtPUFactura.Text.ToDouble - TxtImporteAjuste.Text.ToDouble) - (CargoVendido - CargoGarantia))) < 0 Then
|
||||
|
||||
TxtImporteAjuste.Text = "0.00"
|
||||
CargoGarantia = CargoVendido
|
||||
End If
|
||||
TxtImporteAjuste.ToolTip = $"La diferencia de ajuste fue: {(TxtPrecio.Text.ToDouble - TxtImporteAjuste.Text.ToDouble).FormatoNumero()}. La diferencia de tamaños fue: {(CargoVendido - CargoGarantia).FormatoNumero}."
|
||||
TxtImporteAjuste.Text = ((TxtPUFactura.Text.ToDouble - TxtImporteAjuste.Text.ToDouble) - (CargoVendido - CargoGarantia)).FormatoNumero
|
||||
|
||||
End If
|
||||
End If
|
||||
ObjAcum.Dispose()
|
||||
If DdlPS.SelectedValue.ToEntero <= 0 Then
|
||||
'Alert("No se ha especificado producto a entregar")
|
||||
Exit Sub
|
||||
End If
|
||||
Try
|
||||
If DdlTipoUso.SelectedValue.ToEntero > 0 AndAlso DdlPSAjuste.SelectedValue.ToEntero > 0 AndAlso TxtMesesUso.Text <> "" AndAlso DdlPS.SelectedValue.ToEntero > 0 Then
|
||||
Dim CveMarca As Integer = -1
|
||||
If GlobalDTPS(UsuarioActual.CveEmpresa, DdlPSAjuste.SelectedValue.ToEntero).Rows.Count > 0 Then
|
||||
CveMarca = GlobalDTPS(UsuarioActual.CveEmpresa, DdlPSAjuste.SelectedValue.ToEntero).Rows(0)("CveMarca").ToString.ToEntero
|
||||
End If
|
||||
Dim ObjAcum As New ClsAcumuladores
|
||||
If ObjAcum.GarantiasMesesGet(-1, UsuarioActual.CveEmpresa, CveMarca, DdlTipoUso.SelectedValue.ToEntero, TxtMesesUso.Text.ToEntero) Then
|
||||
If ObjAcum.DtResultados.Rows.Count > 0 Then
|
||||
TxtPorcentajeAjuste.Text = (ObjAcum.DtResultados.Rows(0)("Valor").ToString.ToDouble / 100).ToString
|
||||
|
||||
TxtImporteAjuste.Text = (TxtPorcentajeAjuste.Text.ToDecimal * TxtPUFactura.Text.ToDecimal).FormatoNumero
|
||||
|
||||
Dim CargoVendido As Decimal = 0
|
||||
Dim CargoGarantia As Decimal = 0
|
||||
Dim CveTamaño As Integer = 0
|
||||
|
||||
If DdlPSAjuste.SelectedValue.ToEntero > 0 Then
|
||||
Dim Dr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, DdlPSAjuste.SelectedValue.ToEntero).Rows(0)
|
||||
If Dr IsNot Nothing Then
|
||||
CargoGarantia = Dr("Cargo").ToString.ToDecimal
|
||||
End If
|
||||
End If
|
||||
|
||||
If DdlPS.SelectedValue.ToEntero > 0 Then
|
||||
Dim Dr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, DdlPS.SelectedValue.ToEntero).Rows(0)
|
||||
If Dr IsNot Nothing Then
|
||||
CveTamaño = Dr("CveTamaño").ToString.ToEntero
|
||||
End If
|
||||
End If
|
||||
|
||||
If GlobalDTAcumTamaños.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveTamaño = {CveTamaño}").Rows.Count > 0 Then
|
||||
Dim DrCargo As DataRow = GlobalDTAcumTamaños.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveTamaño = {CveTamaño}").Rows(0)
|
||||
If DrCargo IsNot Nothing Then
|
||||
CargoVendido = DrCargo("Cargo").ToString.ToDecimal
|
||||
End If
|
||||
End If
|
||||
|
||||
'el ajuste no puede ser mayor al precio de lo vendido de nuevo
|
||||
If (TxtPrecio.Text.ToDouble - ((TxtPUFactura.Text.ToDouble - TxtImporteAjuste.Text.ToDouble) - (CargoVendido - CargoGarantia))) < 0 Then
|
||||
|
||||
TxtImporteAjuste.Text = "0.00"
|
||||
CargoGarantia = CargoVendido
|
||||
End If
|
||||
TxtImporteAjuste.ToolTip = $"La diferencia de ajuste fue: {(TxtPrecio.Text.ToDouble - TxtImporteAjuste.Text.ToDouble).FormatoNumero()}. La diferencia de tamaños fue: {(CargoVendido - CargoGarantia).FormatoNumero}."
|
||||
TxtImporteAjuste.Text = ((TxtPUFactura.Text.ToDouble - TxtImporteAjuste.Text.ToDouble) - (CargoVendido - CargoGarantia)).FormatoNumero
|
||||
|
||||
End If
|
||||
End If
|
||||
ObjAcum.Dispose()
|
||||
End If
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al recalcular el costo", ex)
|
||||
End Try
|
||||
|
||||
UpAjuste.Update()
|
||||
End Sub
|
||||
|
||||
@@ -5293,7 +5293,7 @@ Partial Class PV
|
||||
Row("Importe") = TxtImporteAjuste.Text.ToDouble
|
||||
Row("ConsecutivoVenta") = ConsecutivoVenta
|
||||
Row("CvePS") = DdlPSAjuste.SelectedValue
|
||||
Row("PS") = DdlPSAjuste.SelectedItem.Text
|
||||
Row("PS") = DdlPSAjuste.SelectedText
|
||||
Row("CveVenta") = DdlFacturas.SelectedValue
|
||||
Row("PUFactura") = TxtPrecio.Text.ToDouble
|
||||
Row("Cantidad") = 1
|
||||
@@ -5323,7 +5323,7 @@ Partial Class PV
|
||||
TmpDTAjustes.Rows(IndexAjuste)("Importe") = TxtImporteAjuste.Text.ToDouble
|
||||
TmpDTAjustes.Rows(IndexAjuste)("ConsecutivoVenta") = ConsecutivoVenta
|
||||
TmpDTAjustes.Rows(IndexAjuste)("CvePS") = DdlPSAjuste.SelectedValue
|
||||
TmpDTAjustes.Rows(IndexAjuste)("PS") = DdlPSAjuste.SelectedItem.Text
|
||||
TmpDTAjustes.Rows(IndexAjuste)("PS") = DdlPSAjuste.SelectedText
|
||||
TmpDTAjustes.Rows(IndexAjuste)("CveVenta") = DdlFacturas.SelectedValue
|
||||
TmpDTAjustes.Rows(IndexAjuste)("PUFactura") = TxtPrecio.Text.ToDouble
|
||||
TmpDTAjustes.Rows(IndexAjuste)("Cantidad") = 1
|
||||
@@ -5393,6 +5393,7 @@ Partial Class PV
|
||||
DivDatosVenta.Attributes.Add("class", "col-md-6")
|
||||
TxtPrecio.Attributes.Add("onKeyUp", $"CambiaAjuste(this,{TxtPrecio.ClientID});")
|
||||
TxtPrecio.Text = TxtPrecio.Text
|
||||
TxtObsPS.Text = "Descuento por garantía"
|
||||
Else
|
||||
For Each Gvr As GridViewRow In GvRecepcionUsados.Rows
|
||||
If Gvr.RowType = DataControlRowType.DataRow Then
|
||||
@@ -5752,20 +5753,18 @@ Partial Class PV
|
||||
|
||||
Dim params As New List(Of ReportParameter)
|
||||
|
||||
If DdlClientes.SelectedValue.ToEntero = -1 Then
|
||||
params.Add(New ReportParameter("NombreCliente", LtlCliente.Text))
|
||||
params.Add(New ReportParameter("CiudadEstado", LblCiudad.Text.Trim + ", " + LblEstado.Text))
|
||||
params.Add(New ReportParameter("TelCliente", LblTelefono.Text))
|
||||
Else
|
||||
Dim DatosClienteSeleccionado As DataRow = GlobalDTCliente(UsuarioActual.CveEmpresa).FiltroPrimero(String.Format("CveCliente = {0}", DdlClientes.SelectedValue.ToEntero))
|
||||
Dim Ciudad As String = DatosClienteSeleccionado.Item("Ciudad").ToString 'GlobalDTCliente(UsuarioActual.CveEmpresa).FiltroPrimeroValor("Ciudad", String.Format("CveCliente = {0}", DdlClientes.SelectedValue.ToEntero)).Trim
|
||||
Dim Estado As String = DatosClienteSeleccionado.Item("Estado").ToString 'GlobalDTCliente(UsuarioActual.CveEmpresa).FiltroPrimeroValor("Estado", String.Format("CveCliente = {0}", DdlClientes.SelectedValue.ToEntero))
|
||||
params.Add(New ReportParameter("NombreCliente", DdlClientes.SelectedItem.Text))
|
||||
params.Add(New ReportParameter("CiudadEstado", String.Format("{0}, {1}", Ciudad.Trim, Estado)))
|
||||
params.Add(New ReportParameter("TelCliente", DatosClienteSeleccionado.Item("Telefono").ToString))
|
||||
End If
|
||||
|
||||
'Informacion Distribuidor
|
||||
If (DdlDistribuidor.SelectedValue.ToEntero > 0) Then
|
||||
|
||||
Dim DatosClienteSeleccionado As DataRow = GlobalDTCliente(UsuarioActual.CveEmpresa).FiltroPrimero(String.Format("CveCliente = {0}", DdlDistribuidor.SelectedValue.ToEntero))
|
||||
Dim Ciudad As String = DatosClienteSeleccionado.Item("Ciudad").ToString
|
||||
Dim Estado As String = DatosClienteSeleccionado.Item("Estado").ToString
|
||||
params.Add(New ReportParameter("NombreDistribuidor", DdlDistribuidor.SelectedText))
|
||||
params.Add(New ReportParameter("CiudadEstado", String.Format("{0}, {1}", Ciudad.Trim, Estado)))
|
||||
params.Add(New ReportParameter("TelCliente", DatosClienteSeleccionado.Item("Telefono").ToString))
|
||||
|
||||
End If
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("Consec", TxtConsecutivoAjuste.Text.Trim))
|
||||
params.Add(New ReportParameter("FolioAcuse", If(DdlFolioGarantia.SelectedValue.ToEntero = -1, "", DdlFolioGarantia.SelectedItem.Text)))
|
||||
@@ -5789,6 +5788,7 @@ Partial Class PV
|
||||
params.Add(New ReportParameter("TipoAuto", If(DdlPS.SelectedValue.ToEntero > 0, DtModelosAuto.FiltroPrimeroValor("Modelo", $"CveModeloAuto ={DdlModeloAuto.SelectedValue}"), "")))
|
||||
|
||||
'Informacion Consumidor
|
||||
params.Add(New ReportParameter("NombreCliente", LtlCliente.Text))
|
||||
params.Add(New ReportParameter("Direccion", LblDireccion.Text))
|
||||
|
||||
If Imagen.Exists Then
|
||||
|
||||
@@ -4362,7 +4362,7 @@
|
||||
<div style="max-height: 300px; overflow-y: auto;">
|
||||
<asp:GridView ID="GvRem" runat="server" AutoGenerateColumns="false" GridLines="None"
|
||||
CssClass="table table-grid table-striped table-advance table-hover Widthall"
|
||||
DataKeyNames="CveVenta, SubTotal, IVA,Total, CveContrato" AllowPaging="False">
|
||||
DataKeyNames="CveVenta, SubTotal, IVA,Total, CveContrato,Surtido" AllowPaging="False">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<ItemTemplate>
|
||||
@@ -4377,11 +4377,12 @@
|
||||
<asp:BoundField HeaderText="SubTotal" DataField="SubTotal" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="IVA" DataField="Iva" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Total" DataField="Total" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField DataField="Surtido" HeaderText="Surtido" ItemStyle-HorizontalAlign="Center" />
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
|
||||
<asp:GridView ID="GvRemPS" runat="server" AutoGenerateColumns="false" GridLines="None" Visible="false" CssClass="table table-grid table-striped table-advance table-hover Widthall"
|
||||
DataKeyNames="CveVentaDetalle, PU, Total, Cantidad, CveContrato" AllowPaging="False">
|
||||
DataKeyNames="CveVentaDetalle, PU, Total, Cantidad, CveContrato,Surtido" AllowPaging="False">
|
||||
<Columns>
|
||||
<asp:TemplateField>
|
||||
<ItemTemplate>
|
||||
@@ -4406,6 +4407,7 @@
|
||||
<asp:BoundField HeaderText="Producto" DataField="CodigoPS" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="PU" DataField="PU" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Total" DataField="Total" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField DataField="Surtido" HeaderText="Surtido" ItemStyle-HorizontalAlign="Center" />
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</div>
|
||||
@@ -5871,9 +5873,8 @@
|
||||
<div class="col-md-2">
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#ModalAplicarRemisionesNC">
|
||||
Aplicar Remisiones
|
||||
</button>
|
||||
<asp:Button ID = "BtnModalAplicarRemisionesNC" runat="server" OnClick="BtnModalAplicarRemisionesNC_Click" class="btn btn-primary" data-toggle="modal" data-target="#ModalAplicarRemisionesNC"/>
|
||||
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
</div>
|
||||
|
||||
@@ -1697,6 +1697,7 @@ Partial Class Ventas
|
||||
DdlBPPS.setEsWebService(True)
|
||||
DdlBPPS.ddlWS.Attributes.Add("data-clear", "1")
|
||||
ViewState("ProcesoCorrecto") = True
|
||||
ViewState("CargoUsado") = True
|
||||
ViewState("NuevaFactura") = -1
|
||||
ViewState("CveDevolucion") = -1
|
||||
ViewState("CvePedido") = -1
|
||||
@@ -4729,6 +4730,7 @@ Partial Class Ventas
|
||||
DivClienteMsg.Visible = True
|
||||
LtlClienteMsg.Text = "Cálculo sin desglose de IEPS"
|
||||
End If
|
||||
ViewState("CargoUsado") = ObjCliente.CargoUsados
|
||||
|
||||
Dim dr As DataRow = Nothing
|
||||
dr = GlobalDTSubProyectos(-1, CveEmpresa:=UsuarioActual.CveEmpresa).FiltroPrimero("TipoSucursal = 1 And Estatus = 'Activo' AND CveEmpresa = " & UsuarioActual.CveEmpresa)
|
||||
@@ -6702,10 +6704,11 @@ Partial Class Ventas
|
||||
Obj2.Add(ObjFacturaDevolucion)
|
||||
End If
|
||||
Catch ex As Exception
|
||||
ErrorList.Add("No se pudo generarse la nota de crédito de amortización")
|
||||
OnError("Ocurrió un error al generar nota de crédito de amortización", ex)
|
||||
ErrorList.Add("No se pudo generar la nota de crédito de amortización")
|
||||
End Try
|
||||
If Obj2 Is Nothing AndAlso Obj2.Count = 0 Then
|
||||
ErrorList.Add("No se pudo generarse la nota de crédito de amortización")
|
||||
ErrorList.Add("No se pudo generar la nota de crédito de amortización")
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
@@ -8544,7 +8547,8 @@ Partial Class Ventas
|
||||
.ClaveUnidad = drr("SATClaveUM").ToString,
|
||||
.ClaveProdServ = drr("SATClaveProdServ").ToString,
|
||||
.Noidentificacion = drr("Noidentificacion").ToString,
|
||||
.CuentaPredial = drr("CuentaPredial").ToString}
|
||||
.CuentaPredial = drr("CuentaPredial").ToString,
|
||||
.ImporteGravaIVAAdicional = drr("ImporteIEPS").ToString.ToDecimal}
|
||||
'verifica suma subtotales
|
||||
If i = Obj.DtDetalle.Rows.Count AndAlso totSubTotal <> concepto.Importe Then 'proceso de ajusta de decimales
|
||||
concepto.Importe = totSubTotal
|
||||
@@ -8556,7 +8560,7 @@ Partial Class Ventas
|
||||
|
||||
'si es ingreso amortizado por la totalidad, y arroja el valor total de cero, no debe de impuestos
|
||||
If Timbre.Comprobante.Total > 0 Then
|
||||
concepto.Impuestos.Add(New CFDIConceptosImpuestos With {.TrasladooRetencion = "T", .Base = concepto.Importe - concepto.Descuento, .TasaOCuota = drr("PorcentajeIVA").ToString.ToDecimal, .Impuesto = "002", .Importe = drr("ImporteIVA").ToString.ToDecimal})
|
||||
concepto.Impuestos.Add(New CFDIConceptosImpuestos With {.TrasladooRetencion = "T", .Base = concepto.Importe - concepto.Descuento + concepto.ImporteGravaIVAAdicional, .TasaOCuota = drr("PorcentajeIVA").ToString.ToDecimal, .Impuesto = "002", .Importe = drr("ImporteIVA").ToString.ToDecimal})
|
||||
End If
|
||||
|
||||
If drr("ImporteIEPS").ToString.ToDouble > 0 Then
|
||||
@@ -14003,6 +14007,7 @@ Partial Class Ventas
|
||||
|
||||
Dim Row As DataRow = Nothing
|
||||
Dim TotalCalculableImpuestos As Decimal = 0
|
||||
Dim TotalCalculableImpuestosIVA As Decimal = 0
|
||||
PU = Math.Round(PU, 6) ' el precio unitario puede llevar hasta 6 decimales permitidos
|
||||
|
||||
Row = TmpDT.NewRow()
|
||||
@@ -14105,6 +14110,7 @@ Partial Class Ventas
|
||||
|
||||
'End If
|
||||
TotalCalculableImpuestos = (Cantidad * (PU)) - Descuento
|
||||
TotalCalculableImpuestosIVA = TotalCalculableImpuestos * (1 + DrPS("IEPSPorcentaje").ToString.ToDecimal)
|
||||
|
||||
Row("PU") = PU
|
||||
Row("Codigo") = DrPS("Codigo")
|
||||
@@ -14135,7 +14141,7 @@ Partial Class Ventas
|
||||
End If
|
||||
|
||||
Row("IVA") = Row("PorcentajeIVA")
|
||||
Row("ImporteIVA") = Math.Round(Row("PorcentajeIVA").ToString.ToDecimal * TotalCalculableImpuestos, NumeroDecimales)
|
||||
Row("ImporteIVA") = Math.Round(Row("PorcentajeIVA").ToString.ToDecimal * TotalCalculableImpuestosIVA, NumeroDecimales)
|
||||
Row("ImporteRetIVA") = Math.Round(ClienteRetIVA * TotalCalculableImpuestos, NumeroDecimales)
|
||||
Row("ImporteRetISR") = Math.Round(ClienteRetISR * TotalCalculableImpuestos, NumeroDecimales)
|
||||
Row("PorcentajeRetIVA") = ClienteRetIVA
|
||||
@@ -15256,7 +15262,7 @@ Partial Class Ventas
|
||||
End If
|
||||
|
||||
'VALIDAR SI TIENE PRODUCTOS POR TRASPASAR
|
||||
If DtMovimientos.Rows.Count > 0 AndAlso (DtMovimientosDetalles.Rows.Count > 0 AndAlso DtMovimientosDetalles.SUM("SaldoAlmacen") > 0) Then
|
||||
If DtMovimientos.Rows.Count > 0 Then
|
||||
Dim GeneroMovimientoAlmacen As Boolean = False
|
||||
For Each dr As DataRow In DtMovimientos.Rows
|
||||
'Obtenemos los Movimientos de salida
|
||||
@@ -15289,7 +15295,7 @@ Partial Class Ventas
|
||||
'Le damos salida normal
|
||||
If ConSalida Then
|
||||
|
||||
GeneroMovimientoAlmacen = GenerarMovimientoAlmacen(ObjInventario, MovDetalle, CveAlmacenSalida, 40, CveMoneda, CveRemision, MovimientoPrePoliza:=True, ObjConta:=ObjConta) > 0
|
||||
GeneroMovimientoAlmacen = GenerarMovimientoAlmacen(ObjInventario, MovDetalle, CveAlmacenSalida, 40, CveMoneda, CveRemision, AplicaMovimientoDetalleEntrada:=AplicaMovimientoDetalleEntrada, MovimientoPrePoliza:=True, ObjConta:=ObjConta) > 0
|
||||
|
||||
If Not GeneroMovimientoAlmacen Then
|
||||
OcurrioError = True
|
||||
@@ -20872,6 +20878,7 @@ Partial Class Ventas
|
||||
End If
|
||||
ObjMovtos.Dispose()
|
||||
GvRemisionesNC.DataBind()
|
||||
UpModalRemisionesNC.Update()
|
||||
End Sub
|
||||
Private Sub CargaDescRNC()
|
||||
|
||||
@@ -22485,6 +22492,25 @@ Partial Class Ventas
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
'VERIFICA QUE LAS FACTURAS TENGAN EL MISMO ESTATUS EN ALMACEN (NO MEZCLAR REMISIONES 'SURTIDAS' CON 'NO SURTIDAS')
|
||||
If dtSeleccionadas.COUNT("Surtido", "Surtido = 'Si'") > 0 AndAlso dtSeleccionadas.COUNT("Surtido", "Surtido = 'No'") > 0 Then
|
||||
Dim SbRem As New StringBuilder
|
||||
SbRem.Append("Solo debe seleccionar remisiones con el mismo estatus de almacen. Por favor verifique y vuelva a intentar.</br>")
|
||||
|
||||
SbRem.Append("<b>Remisiones Surtidas:</b></br>")
|
||||
For Each RowSurtida As DataRow In dtSeleccionadas.FiltraParametros("Surtido = 'Si'", DistinctColumns:={"Folio"}).Rows
|
||||
SbRem.AppendFormat("{0}</br>", RowSurtida("Folio"))
|
||||
Next
|
||||
|
||||
SbRem.Append("<b>Remisiones No Surtidas:</b></br>")
|
||||
For Each RowSurtida As DataRow In dtSeleccionadas.FiltraParametros("Surtido = 'No'", DistinctColumns:={"Folio"}).Rows
|
||||
SbRem.AppendFormat("{0}</br>", RowSurtida("Folio"))
|
||||
Next
|
||||
|
||||
Alert(SbRem.ToString(), TipoMensaje.MsgAdvertencia)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
DdlMoneda.SelectedValue = GlobalDTMonedas.FiltroPrimeroValor("CveMoneda", $"Abreviatura = '{dtSeleccionadas.FiltroPrimeroValor("Abreviatura")}'")
|
||||
DdlMoneda.Enabled = False
|
||||
CambiaMoneda()
|
||||
@@ -23489,6 +23515,9 @@ Partial Class Ventas
|
||||
|
||||
|
||||
TmpDT.AcceptChanges()
|
||||
If ViewState("CargoUsado").ToString = "False" Then
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
Dim ObjProductosServicios As New ClsProductosServicios()
|
||||
|
||||
@@ -23780,4 +23809,8 @@ Partial Class Ventas
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
Protected Sub BtnModalAplicarRemisionesNC_Click(sender As Object, e As EventArgs)
|
||||
CargaRNC()
|
||||
RegistraScript("$('#ModalAplicarRemisionesNC').modal()")
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user